Spaces:
Sleeping
Sleeping
Valdimarb13
commited on
Commit
•
e46128d
1
Parent(s):
e75c9d7
Update app.py
Browse files
app.py
CHANGED
@@ -23,9 +23,9 @@ def get_audio(url):
|
|
23 |
return a
|
24 |
|
25 |
|
26 |
-
def
|
27 |
-
|
28 |
-
return
|
29 |
|
30 |
|
31 |
with gr.Blocks() as demo:
|
@@ -41,7 +41,7 @@ with gr.Blocks() as demo:
|
|
41 |
speech_button = gr.Button("Submit")
|
42 |
|
43 |
|
44 |
-
youtube_button.click(
|
45 |
speech_button.click(transcribe, inputs = input_speech, outputs = output_speech)
|
46 |
|
47 |
demo.launch()
|
|
|
23 |
return a
|
24 |
|
25 |
|
26 |
+
def get_text(url):
|
27 |
+
text = pipe(get_audio(url))["text"]
|
28 |
+
return text
|
29 |
|
30 |
|
31 |
with gr.Blocks() as demo:
|
|
|
41 |
speech_button = gr.Button("Submit")
|
42 |
|
43 |
|
44 |
+
youtube_button.click(get_text, inputs = input_text, outputs = output_text)
|
45 |
speech_button.click(transcribe, inputs = input_speech, outputs = output_speech)
|
46 |
|
47 |
demo.launch()
|