TIMBOVILL commited on
Commit
76cffc0
·
verified ·
1 Parent(s): b016235

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +12 -4
app.py CHANGED
@@ -85,20 +85,28 @@ additional_inputs = [
85
  # Gradio interface with blocks and tabs
86
  with gr.Blocks(theme=gr.themes.Soft(primary_hue="red", secondary_hue="pink")) as demo:
87
  with gr.Tabs():
 
88
  with gr.TabItem("Chat"):
89
- # Define a unique variable name for the chat interface
90
- chat_interface_1 = gr.ChatInterface(
91
  fn=generate_response,
92
- chatbot=gr.Chatbot(show_label=False, show_share_button=False, show_copy_button=True, likeable=True, layout="panel"),
 
 
 
 
 
 
93
  additional_inputs=additional_inputs,
94
  title="YTSHorts Maker",
95
  description="Powered by GROQ, MoviePy, and other tools.",
96
  )
 
 
97
  with gr.TabItem("Video Processing"):
98
  text_input = gr.Textbox(lines=5, label="Text (8 words max per line)")
99
  process_button = gr.Button("Process Video")
100
  video_output = gr.Video(label="Processed Video")
101
-
102
  process_button.click(
103
  fn=process_video,
104
  inputs=text_input,
 
85
  # Gradio interface with blocks and tabs
86
  with gr.Blocks(theme=gr.themes.Soft(primary_hue="red", secondary_hue="pink")) as demo:
87
  with gr.Tabs():
88
+ # Chat Tab
89
  with gr.TabItem("Chat"):
90
+ chat_interface = gr.ChatInterface(
 
91
  fn=generate_response,
92
+ chatbot=gr.Chatbot(
93
+ show_label=False,
94
+ show_share_button=False,
95
+ show_copy_button=True,
96
+ likeable=True,
97
+ layout="panel"
98
+ ),
99
  additional_inputs=additional_inputs,
100
  title="YTSHorts Maker",
101
  description="Powered by GROQ, MoviePy, and other tools.",
102
  )
103
+
104
+ # Video Processing Tab
105
  with gr.TabItem("Video Processing"):
106
  text_input = gr.Textbox(lines=5, label="Text (8 words max per line)")
107
  process_button = gr.Button("Process Video")
108
  video_output = gr.Video(label="Processed Video")
109
+
110
  process_button.click(
111
  fn=process_video,
112
  inputs=text_input,