Samarth991 commited on
Commit
9ed131e
·
1 Parent(s): b2a19a3

adding video examples as Radio

Browse files
Files changed (1) hide show
  1. app.py +9 -5
app.py CHANGED
@@ -20,6 +20,11 @@ DEFAULT_MAX_NEW_TOKENS = 2048
20
  MAX_INPUT_TOKEN_LENGTH = 4000
21
  DEFAULT_CHAR_LENGTH = 1000
22
 
 
 
 
 
 
23
  def loading_file():
24
  return "Loading..."
25
 
@@ -147,17 +152,16 @@ with gr.Blocks(css=css) as demo:
147
  chatbot = gr.Chatbot(height=250)
148
 
149
  with gr.Row():
 
150
  with gr.Box():
151
- question = gr.Textbox(label="Type your question !",lines=1).style(full_width=True)
152
  submit_btn = gr.Button(value="Send message", variant="primary", scale = 1)
153
  clean_chat_btn = gr.Button("Delete Chat")
154
-
155
- examples_set = gr.Radio(label="Examples of some You tube Video ",choices=["https://www.youtube.com/watch?v=aircAruvnKk&ab_channel=3Blue1Brown",
156
- "https://www.youtube.com/watch?v=5p248yoa3oE&ab_channel=StanfordOnline","https://www.youtube.com/watch?v=Ilg3gGewQ5U" ])
157
-
158
  with gr.Column():
159
  with gr.Box():
160
  youtube_link = gr.Textbox(label="Add your you tube Link",text_align='left',autofocus=True)
 
 
161
  with gr.Row():
162
  load_youtube_bt = gr.Button("Process Youtube Link",).style(full_width = False)
163
  langchain_status = gr.Textbox(label="Status", placeholder="", interactive = False)
 
20
  MAX_INPUT_TOKEN_LENGTH = 4000
21
  DEFAULT_CHAR_LENGTH = 1000
22
 
23
+ EXAMPLES = ["https://www.youtube.com/watch?v=aircAruvnKk&ab_channel=3Blue1Brown",
24
+ "https://www.youtube.com/watch?v=5p248yoa3oE&ab_channel=StanfordOnline",
25
+ "https://www.youtube.com/watch?v=Ilg3gGewQ5U" ]
26
+
27
+
28
  def loading_file():
29
  return "Loading..."
30
 
 
152
  chatbot = gr.Chatbot(height=250)
153
 
154
  with gr.Row():
155
+ question = gr.Textbox(label="Type your question !",lines=1).style(full_width=True)
156
  with gr.Box():
 
157
  submit_btn = gr.Button(value="Send message", variant="primary", scale = 1)
158
  clean_chat_btn = gr.Button("Delete Chat")
159
+
 
 
 
160
  with gr.Column():
161
  with gr.Box():
162
  youtube_link = gr.Textbox(label="Add your you tube Link",text_align='left',autofocus=True)
163
+ examples_set = gr.Radio(label="Examples of some You tube Videos",
164
+ choices=EXAMPLES)
165
  with gr.Row():
166
  load_youtube_bt = gr.Button("Process Youtube Link",).style(full_width = False)
167
  langchain_status = gr.Textbox(label="Status", placeholder="", interactive = False)