TIMBOVILL commited on
Commit
02c31be
·
verified ·
1 Parent(s): 6dcc1a0

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +18 -9
app.py CHANGED
@@ -83,12 +83,21 @@ def process_video_interface():
83
  description="Select a video file from 'videos' folder, add text, and process.",
84
  )
85
 
86
- demo = gr.Interface(
87
- fn=None,
88
- interfaces=[chat_interface(), process_video_interface()],
89
- title="YTSHorts Maker",
90
- description="Powered by GROQ, MoviePy, and other tools.",
91
- theme="soft",
92
- )
93
-
94
- demo.launch()
 
 
 
 
 
 
 
 
 
 
83
  description="Select a video file from 'videos' folder, add text, and process.",
84
  )
85
 
86
+ # Main app definition
87
+ with gr.Blocks(theme=gr.themes.Soft(primary_hue="red", secondary_hue="pink")) as demo:
88
+ with gr.Tabs():
89
+ # Chat Ta
90
+ with gr.TabItem("Video Processing"):
91
+ text_input = gr.Textbox(lines=5, label="Text (8 words max per line)")
92
+ process_button = gr.Button("Process Video")
93
+ video_output = gr.Video(label="Processed Video")
94
+
95
+ process_button.click(
96
+ fn=process_video,
97
+ inputs=text_input,
98
+ outputs=video_output,
99
+ )
100
+
101
+ # Launch the Gradio interface
102
+ if __name__ == "__main__":
103
+ demo.launch()