Pijush2023 commited on
Commit
20478b4
·
verified ·
1 Parent(s): 9716d67

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -4
app.py CHANGED
@@ -872,10 +872,8 @@ with gr.Blocks(theme='Pijush2023/scikit-learn-pijush') as demo:
872
  clear_button.click(fn=clear_textbox, inputs=None, outputs=chat_input)
873
 
874
  audio_input = gr.Audio(sources=["microphone"], streaming=True, type='numpy')
875
- # audio_input.stream(transcribe_function, inputs=[state, audio_input], outputs=[state, chat_input], api_name="voice_query_to_text")
876
- audio_input.stream(transcribe_function, inputs=[state, audio_input], outputs=[state, chat_input], api_name="voice_query_to_text").then(
877
- fn=clear_textbox, inputs=None, outputs=chat_input
878
- )
879
 
880
  gr.Markdown("<h1 style='color: red;'>Map</h1>", elem_id="location-markdown")
881
  location_output = gr.HTML()
 
872
  clear_button.click(fn=clear_textbox, inputs=None, outputs=chat_input)
873
 
874
  audio_input = gr.Audio(sources=["microphone"], streaming=True, type='numpy')
875
+ audio_input.stream(transcribe_function, inputs=[state, audio_input], outputs=[state, chat_input], api_name="voice_query_to_text")
876
+
 
 
877
 
878
  gr.Markdown("<h1 style='color: red;'>Map</h1>", elem_id="location-markdown")
879
  location_output = gr.HTML()