Update app.py
Browse files
app.py
CHANGED
@@ -43,11 +43,11 @@ interface = gr.Interface(
|
|
43 |
fn=pronunciation_evaluator,
|
44 |
inputs=[
|
45 |
gr.Audio(type="filepath", label="Record your pronunciation"),
|
46 |
-
gr.State(value=initial_sentence)
|
47 |
],
|
48 |
outputs=[
|
49 |
"text",
|
50 |
-
gr.
|
51 |
],
|
52 |
title="Pronunciation Evaluator",
|
53 |
description="Record yourself pronouncing the given sentence and receive feedback. A new sentence will be provided after each evaluation."
|
|
|
43 |
fn=pronunciation_evaluator,
|
44 |
inputs=[
|
45 |
gr.Audio(type="filepath", label="Record your pronunciation"),
|
46 |
+
gr.State(value=initial_sentence) # Holds the current sentence
|
47 |
],
|
48 |
outputs=[
|
49 |
"text",
|
50 |
+
gr.State() # The new sentence will be stored as the state for the next input
|
51 |
],
|
52 |
title="Pronunciation Evaluator",
|
53 |
description="Record yourself pronouncing the given sentence and receive feedback. A new sentence will be provided after each evaluation."
|