Gztavo commited on
Commit
78f4d87
1 Parent(s): cd58f6d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -8
app.py CHANGED
@@ -1,10 +1,7 @@
1
- from transformers import pipeline
2
  import gradio as gr
 
3
 
4
  modelo = pipeline("automatic-speech-recognition", model="facebook/wav2vec2-large-xlsr-53-spanish")
5
- titulo = "Audio2Text"
6
- descripcion = "Graba un audio en castellano y envíalo para obtener la transcripción"
7
-
8
 
9
  def transcribe(audio):
10
  text = modelo(audio)["text"]
@@ -12,8 +9,6 @@ def transcribe(audio):
12
 
13
  gr.Interface(
14
  fn=transcribe,
15
- inputs=gr.Audio(source="microphone", type="filepath"),
16
- outputs=["textbox"],
17
- title = titulo,
18
- description = descripcion
19
  ).launch()
 
 
1
  import gradio as gr
2
+ from transformers import pipeline
3
 
4
  modelo = pipeline("automatic-speech-recognition", model="facebook/wav2vec2-large-xlsr-53-spanish")
 
 
 
5
 
6
  def transcribe(audio):
7
  text = modelo(audio)["text"]
 
9
 
10
  gr.Interface(
11
  fn=transcribe,
12
+ inputs=[gr.Audio(source="microphone", type="filepath")],
13
+ outputs=["textbox"]
 
 
14
  ).launch()