Sonny George commited on
Commit
324fd38
·
1 Parent(s): 36554e3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -4
app.py CHANGED
@@ -1,18 +1,20 @@
1
  from transformers import pipeline
2
  import gradio as gr
3
 
4
- pipe = pipeline(model="sonnygeorge/whisper-tiny-papi")
 
5
 
6
  def transcribe(audio):
7
  text = pipe(audio)["text"]
8
  return text
9
 
 
10
  iface = gr.Interface(
11
- fn=transcribe,
12
- inputs=gr.Audio(type="filepath"),
13
  outputs="text",
14
  title="Whisper Tiny Papiamentu",
15
  description="Realtime demo for Papiamentu speech recognition using a fine-tuned Whisper tiny model.",
16
  )
17
 
18
- iface.launch()
 
1
  from transformers import pipeline
2
  import gradio as gr
3
 
4
+ pipe = pipeline(model="sonnygeorge/whisper-tiny-papi")
5
+
6
 
7
  def transcribe(audio):
8
  text = pipe(audio)["text"]
9
  return text
10
 
11
+
12
  iface = gr.Interface(
13
+ fn=transcribe,
14
+ inputs=gr.Audio(),
15
  outputs="text",
16
  title="Whisper Tiny Papiamentu",
17
  description="Realtime demo for Papiamentu speech recognition using a fine-tuned Whisper tiny model.",
18
  )
19
 
20
+ iface.launch()