Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -11,7 +11,7 @@ diarization_pipe = Pipeline.from_pretrained("pyannote/speaker-diarization@2.1",
|
|
11 |
|
12 |
|
13 |
# Load the speech-to-text model (Whisper)
|
14 |
-
asr_pipe = pipeline("automatic-speech-recognition", model="
|
15 |
|
16 |
def transcribe_with_diarization(audio_path):
|
17 |
# Get speaker segments using the diarization model
|
@@ -51,9 +51,12 @@ def transcribe_with_diarization(audio_path):
|
|
51 |
|
52 |
iface = gr.Interface(
|
53 |
fn=transcribe_with_diarization,
|
54 |
-
inputs=
|
|
|
|
|
|
|
55 |
outputs="text",
|
56 |
-
title="Whisper
|
57 |
description="Real-time demo for Hindi speech recognition using a fine-tuned Whisper large model with speaker diarization.",
|
58 |
)
|
59 |
|
|
|
11 |
|
12 |
|
13 |
# Load the speech-to-text model (Whisper)
|
14 |
+
asr_pipe = pipeline("automatic-speech-recognition", model="openai/whisper-tiny")
|
15 |
|
16 |
def transcribe_with_diarization(audio_path):
|
17 |
# Get speaker segments using the diarization model
|
|
|
51 |
|
52 |
iface = gr.Interface(
|
53 |
fn=transcribe_with_diarization,
|
54 |
+
inputs=[
|
55 |
+
gr.File(label="Audio File"),
|
56 |
+
gr.Audio(source="microphone", type="filepath", filetype="wav")
|
57 |
+
],
|
58 |
outputs="text",
|
59 |
+
title="Whisper small Hindi with Speaker Diarization",
|
60 |
description="Real-time demo for Hindi speech recognition using a fine-tuned Whisper large model with speaker diarization.",
|
61 |
)
|
62 |
|