Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -32,14 +32,14 @@ def transcribe(audio, model_name):
|
|
32 |
return transcription
|
33 |
|
34 |
# Gradio app
|
35 |
-
with gr.Blocks(
|
36 |
gr.Markdown("""
|
37 |
<h1 style="color: #4CAF50; text-align: center;">Persian Speech-to-Text Models</h1>
|
38 |
<p style="text-align: center;">Test the best Persian STT models in one place!</p>
|
39 |
""")
|
40 |
|
41 |
with gr.Row():
|
42 |
-
audio_input = gr.Audio(
|
43 |
model_dropdown = gr.Dropdown(
|
44 |
choices=list(models.keys()),
|
45 |
label="Select Model",
|
@@ -48,7 +48,7 @@ with gr.Blocks(theme="compact") as demo:
|
|
48 |
|
49 |
output_text = gr.Textbox(label="Transcription", lines=5, placeholder="The transcription will appear here...")
|
50 |
|
51 |
-
transcribe_button = gr.Button("Transcribe"
|
52 |
|
53 |
transcribe_button.click(
|
54 |
fn=transcribe,
|
|
|
32 |
return transcription
|
33 |
|
34 |
# Gradio app
|
35 |
+
with gr.Blocks() as demo:
|
36 |
gr.Markdown("""
|
37 |
<h1 style="color: #4CAF50; text-align: center;">Persian Speech-to-Text Models</h1>
|
38 |
<p style="text-align: center;">Test the best Persian STT models in one place!</p>
|
39 |
""")
|
40 |
|
41 |
with gr.Row():
|
42 |
+
audio_input = gr.Audio(type="filepath", label="Upload your audio file")
|
43 |
model_dropdown = gr.Dropdown(
|
44 |
choices=list(models.keys()),
|
45 |
label="Select Model",
|
|
|
48 |
|
49 |
output_text = gr.Textbox(label="Transcription", lines=5, placeholder="The transcription will appear here...")
|
50 |
|
51 |
+
transcribe_button = gr.Button("Transcribe")
|
52 |
|
53 |
transcribe_button.click(
|
54 |
fn=transcribe,
|