Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -44,7 +44,11 @@ def translate_text(text, destination_language):
|
|
44 |
return translation[0]["translation_text"]
|
45 |
|
46 |
# Speech-to-text pipeline
|
47 |
-
speech_to_text = pipeline(
|
|
|
|
|
|
|
|
|
48 |
|
49 |
# Function to transcribe audio to text
|
50 |
def transcribe_audio(audio_file, destination_language):
|
|
|
44 |
return translation[0]["translation_text"]
|
45 |
|
46 |
# Speech-to-text pipeline
|
47 |
+
speech_to_text = pipeline(
|
48 |
+
"automatic-speech-recognition",
|
49 |
+
model="openai/whisper-small",
|
50 |
+
language="en"
|
51 |
+
)
|
52 |
|
53 |
# Function to transcribe audio to text
|
54 |
def transcribe_audio(audio_file, destination_language):
|