Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -87,17 +87,17 @@ with gr.Blocks() as demo:
|
|
87 |
gr.Markdown("## African ASR Evaluation Platform")
|
88 |
|
89 |
with gr.Row():
|
|
|
90 |
audio_input = gr.Audio(sources=["upload", "microphone"], type="filepath", label="Upload or record audio")
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
transcribed_text = gr.Textbox(label="Transcription")
|
95 |
submit_btn = gr.Button("Transcribe")
|
96 |
submit_btn.click(fn=transcribe, inputs=[audio_input, lang], outputs=[transcribed_text, audio_input])
|
97 |
|
98 |
gr.Markdown("---\n## Feedback Form")
|
99 |
-
|
100 |
-
|
|
|
101 |
domain = gr.Textbox(label="Was the speech related to a specific topic? If yes, please specify the topic (e.g., news, education, medical, law, religious, sports, science).")
|
102 |
accuracy = gr.Slider(1, 10, step=1, label="Overall, how accurate was the model's transcription for the audio you reviewed? *")
|
103 |
transcript_edit = gr.Textbox(label="If the transcription provided by the model was incorrect, please enter your corrected version.")
|
@@ -128,7 +128,7 @@ with gr.Blocks() as demo:
|
|
128 |
transcript_edit, orthography, orthography_issues,
|
129 |
meaning, meaning_loss, errors, error_examples, performance
|
130 |
],
|
131 |
-
outputs=[output_msg]
|
132 |
)
|
133 |
|
134 |
# Launch the interface
|
|
|
87 |
gr.Markdown("## African ASR Evaluation Platform")
|
88 |
|
89 |
with gr.Row():
|
90 |
+
lang = gr.Dropdown(list(model_map.keys()), label="Select Language", value=None)
|
91 |
audio_input = gr.Audio(sources=["upload", "microphone"], type="filepath", label="Upload or record audio")
|
92 |
+
|
93 |
+
transcribed_text = gr.Textbox(label="Transcription", interactive=False)
|
|
|
|
|
94 |
submit_btn = gr.Button("Transcribe")
|
95 |
submit_btn.click(fn=transcribe, inputs=[audio_input, lang], outputs=[transcribed_text, audio_input])
|
96 |
|
97 |
gr.Markdown("---\n## Feedback Form")
|
98 |
+
user_id = gr.Textbox(label="Please enter user ID.*")
|
99 |
+
env = gr.Dropdown(["Studio/Professional Recording", "Quiet Room (minimal noise)", "Noisy Background (e.g., street, cafe, market)"], label="What was the type of recording environment for the speech you evaluated? *",value=None)
|
100 |
+
device = gr.Dropdown(["Mobile Phone/Tablet", "Laptop/Computer Microphone", "Dedicated Microphone (e.g., headset, studio mic)"], label="What type of recording device was used? *",value=None)
|
101 |
domain = gr.Textbox(label="Was the speech related to a specific topic? If yes, please specify the topic (e.g., news, education, medical, law, religious, sports, science).")
|
102 |
accuracy = gr.Slider(1, 10, step=1, label="Overall, how accurate was the model's transcription for the audio you reviewed? *")
|
103 |
transcript_edit = gr.Textbox(label="If the transcription provided by the model was incorrect, please enter your corrected version.")
|
|
|
128 |
transcript_edit, orthography, orthography_issues,
|
129 |
meaning, meaning_loss, errors, error_examples, performance
|
130 |
],
|
131 |
+
# outputs=[output_msg]
|
132 |
)
|
133 |
|
134 |
# Launch the interface
|