Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -139,22 +139,22 @@ demo = gr.Blocks()
|
|
| 139 |
with demo:
|
| 140 |
audio_file = gr.inputs.Audio(source="microphone", type="filepath")
|
| 141 |
text = gr.Textbox(label="Speech to Text")
|
| 142 |
-
label = gr.Label()
|
| 143 |
-
saved = gr.Textbox(label="Saved")
|
| 144 |
-
savedAll = gr.Textbox(label="SavedAll")
|
| 145 |
TTSchoice = gr.inputs.Radio( label="Pick a Text to Speech Model", choices=MODEL_NAMES, )
|
| 146 |
audio = gr.Audio(label="Output", interactive=False)
|
| 147 |
|
| 148 |
b1 = gr.Button("Recognize Speech")
|
| 149 |
-
b2 = gr.Button("Classify Sentiment")
|
| 150 |
-
b3 = gr.Button("Save Speech to Text")
|
| 151 |
-
b4 = gr.Button("Retrieve All")
|
| 152 |
b5 = gr.Button("Read It Back Aloud")
|
| 153 |
|
| 154 |
b1.click(speech_to_text, inputs=audio_file, outputs=text)
|
| 155 |
-
b2.click(text_to_sentiment, inputs=text, outputs=label)
|
| 156 |
-
b3.click(upsert, inputs=text, outputs=saved)
|
| 157 |
-
b4.click(selectall, inputs=text, outputs=savedAll)
|
| 158 |
b5.click(tts, inputs=[text,TTSchoice], outputs=audio)
|
| 159 |
|
| 160 |
demo.launch(share=True)
|
|
|
|
| 139 |
with demo:
|
| 140 |
audio_file = gr.inputs.Audio(source="microphone", type="filepath")
|
| 141 |
text = gr.Textbox(label="Speech to Text")
|
| 142 |
+
#label = gr.Label()
|
| 143 |
+
#saved = gr.Textbox(label="Saved")
|
| 144 |
+
#savedAll = gr.Textbox(label="SavedAll")
|
| 145 |
TTSchoice = gr.inputs.Radio( label="Pick a Text to Speech Model", choices=MODEL_NAMES, )
|
| 146 |
audio = gr.Audio(label="Output", interactive=False)
|
| 147 |
|
| 148 |
b1 = gr.Button("Recognize Speech")
|
| 149 |
+
#b2 = gr.Button("Classify Sentiment")
|
| 150 |
+
#b3 = gr.Button("Save Speech to Text")
|
| 151 |
+
#b4 = gr.Button("Retrieve All")
|
| 152 |
b5 = gr.Button("Read It Back Aloud")
|
| 153 |
|
| 154 |
b1.click(speech_to_text, inputs=audio_file, outputs=text)
|
| 155 |
+
#b2.click(text_to_sentiment, inputs=text, outputs=label)
|
| 156 |
+
#b3.click(upsert, inputs=text, outputs=saved)
|
| 157 |
+
#b4.click(selectall, inputs=text, outputs=savedAll)
|
| 158 |
b5.click(tts, inputs=[text,TTSchoice], outputs=audio)
|
| 159 |
|
| 160 |
demo.launch(share=True)
|