Spaces:
Running
Running
oceansweep
commited on
Commit
•
2db874e
1
Parent(s):
012529d
Update app.py
Browse files
app.py
CHANGED
@@ -1292,11 +1292,11 @@ def launch_ui(demo_mode=False):
|
|
1292 |
with gr.Row():
|
1293 |
# Light/Dark mode toggle switch
|
1294 |
theme_toggle = gr.Radio(choices=["Light", "Dark"], value="Light",
|
1295 |
-
label="Light/Dark Mode Toggle (Toggle to change UI color scheme)")
|
1296 |
|
1297 |
# UI Mode toggle switch
|
1298 |
ui_mode_toggle = gr.Radio(choices=["Simple", "Advanced"], value="Simple",
|
1299 |
-
label="UI Mode (Toggle to show all options)")
|
1300 |
|
1301 |
# URL input is always visible
|
1302 |
url_input = gr.Textbox(label="URL (Mandatory)", placeholder="Enter the video URL here")
|
@@ -1308,7 +1308,7 @@ def launch_ui(demo_mode=False):
|
|
1308 |
label="Whisper Model(This is the ML model used for transcription.)",
|
1309 |
visible=False)
|
1310 |
custom_prompt_input = gr.Textbox(
|
1311 |
-
label="Custom Prompt (Customize your
|
1312 |
placeholder="Q: As a professional summarizer, create a concise and comprehensive summary of the "
|
1313 |
"provided text.\nA: Here is a detailed, bulleted list of the key points made in the "
|
1314 |
"transcribed video and supporting arguments:",
|
@@ -1318,7 +1318,7 @@ def launch_ui(demo_mode=False):
|
|
1318 |
api_name_input = gr.Dropdown(
|
1319 |
choices=[None, "huggingface", "openai", "anthropic", "cohere", "groq", "llama", "kobold", "ooba"],
|
1320 |
value=None,
|
1321 |
-
label="API Name (Mandatory Unless you just want a Transcription)", visible=True)
|
1322 |
api_key_input = gr.Textbox(label="API Key (Mandatory if API Name is specified)",
|
1323 |
placeholder="Enter your API key here", visible=True)
|
1324 |
vad_filter_input = gr.Checkbox(label="VAD Filter(Can safely ignore)", value=False, visible=False)
|
@@ -1367,18 +1367,20 @@ def launch_ui(demo_mode=False):
|
|
1367 |
fn=process_url,
|
1368 |
inputs=all_inputs,
|
1369 |
outputs=outputs,
|
1370 |
-
title="TL/DW: Video Transcription and Summarization with Custom Prompt Support",
|
1371 |
description="Submit a video URL for transcription and summarization. Ensure you input all necessary "
|
1372 |
"information including API keys."
|
1373 |
)
|
1374 |
|
1375 |
with gr.Tab("Transcription & Summarization History"):
|
1376 |
-
|
1377 |
-
|
|
|
|
|
|
|
1378 |
|
1379 |
with gr.Accordion("Open for More!", open=False):
|
1380 |
-
gr.Markdown("
|
1381 |
-
gr.Slider(minimum=0.0, maximum=1.0, value=0.1, step=0.1, interactive=True, label="Slide me")
|
1382 |
|
1383 |
iface.launch(share=False)
|
1384 |
|
|
|
1292 |
with gr.Row():
|
1293 |
# Light/Dark mode toggle switch
|
1294 |
theme_toggle = gr.Radio(choices=["Light", "Dark"], value="Light",
|
1295 |
+
label="Light/Dark Mode Toggle (Toggle to change UI color scheme) (WIP)")
|
1296 |
|
1297 |
# UI Mode toggle switch
|
1298 |
ui_mode_toggle = gr.Radio(choices=["Simple", "Advanced"], value="Simple",
|
1299 |
+
label="UI Mode (Toggle to show all options) (WIP)")
|
1300 |
|
1301 |
# URL input is always visible
|
1302 |
url_input = gr.Textbox(label="URL (Mandatory)", placeholder="Enter the video URL here")
|
|
|
1308 |
label="Whisper Model(This is the ML model used for transcription.)",
|
1309 |
visible=False)
|
1310 |
custom_prompt_input = gr.Textbox(
|
1311 |
+
label="Custom Prompt (Customize your summarization, or ask a question about the video and have it answered)",
|
1312 |
placeholder="Q: As a professional summarizer, create a concise and comprehensive summary of the "
|
1313 |
"provided text.\nA: Here is a detailed, bulleted list of the key points made in the "
|
1314 |
"transcribed video and supporting arguments:",
|
|
|
1318 |
api_name_input = gr.Dropdown(
|
1319 |
choices=[None, "huggingface", "openai", "anthropic", "cohere", "groq", "llama", "kobold", "ooba"],
|
1320 |
value=None,
|
1321 |
+
label="API Name (Mandatory Unless you just want a Transcription - Can use Cohere with no API Key)", visible=True)
|
1322 |
api_key_input = gr.Textbox(label="API Key (Mandatory if API Name is specified)",
|
1323 |
placeholder="Enter your API key here", visible=True)
|
1324 |
vad_filter_input = gr.Checkbox(label="VAD Filter(Can safely ignore)", value=False, visible=False)
|
|
|
1367 |
fn=process_url,
|
1368 |
inputs=all_inputs,
|
1369 |
outputs=outputs,
|
1370 |
+
title="TL/DW: Video Transcription and Summarization with Custom Prompt Support (Demo Page)",
|
1371 |
description="Submit a video URL for transcription and summarization. Ensure you input all necessary "
|
1372 |
"information including API keys."
|
1373 |
)
|
1374 |
|
1375 |
with gr.Tab("Transcription & Summarization History"):
|
1376 |
+
gr.Markdown("Plan to put access to SQLite DB here")
|
1377 |
+
gr.Markdown("Allow for searching/retrieval/re-prompting of previous transcriptions")
|
1378 |
+
gr.Markdown("Also allow for re-transcribing videos if they're still online, while updating/adding to prior entry")
|
1379 |
+
gr.Markdown("RAG here we come....:/")
|
1380 |
+
|
1381 |
|
1382 |
with gr.Accordion("Open for More!", open=False):
|
1383 |
+
gr.Markdown("Plan to put Prompt Samples/Templates down here")
|
|
|
1384 |
|
1385 |
iface.launch(share=False)
|
1386 |
|