Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -128,7 +128,8 @@ def compare_texts(reference_text, transcribed_text):
|
|
128 |
html_output += f'{word}: '
|
129 |
html_output += f'<audio controls><source src="{audio_src}" type="audio/mpeg">Your browser does not support the audio tag.</audio>{suggestion_text}<br>'
|
130 |
|
131 |
-
return [html_output, [audio for _, audio in incorrect_words_audios]]
|
|
|
132 |
|
133 |
# Step 4: Text-to-Speech Function
|
134 |
def text_to_speech(paragraph):
|
@@ -157,7 +158,8 @@ interface = gr.Interface(
|
|
157 |
gr.Textbox(lines=5, label="Input Paragraph"),
|
158 |
gr.Audio(type="filepath", label="Record Audio")
|
159 |
],
|
160 |
-
outputs=["html","files"],
|
|
|
161 |
title="Speech Recognition Comparison",
|
162 |
description="Input a paragraph, record your audio, and compare the transcription to the original text."
|
163 |
)
|
|
|
128 |
html_output += f'{word}: '
|
129 |
html_output += f'<audio controls><source src="{audio_src}" type="audio/mpeg">Your browser does not support the audio tag.</audio>{suggestion_text}<br>'
|
130 |
|
131 |
+
#return [html_output, [audio for _, audio in incorrect_words_audios]]
|
132 |
+
return [html_output]
|
133 |
|
134 |
# Step 4: Text-to-Speech Function
|
135 |
def text_to_speech(paragraph):
|
|
|
158 |
gr.Textbox(lines=5, label="Input Paragraph"),
|
159 |
gr.Audio(type="filepath", label="Record Audio")
|
160 |
],
|
161 |
+
#outputs=["html","files"],
|
162 |
+
outputs=["html"],
|
163 |
title="Speech Recognition Comparison",
|
164 |
description="Input a paragraph, record your audio, and compare the transcription to the original text."
|
165 |
)
|