Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -14,8 +14,9 @@ default_lang = "en"
|
|
14 |
engines = { default_lang: Model(default_lang) }
|
15 |
|
16 |
def transcribe(audio):
|
17 |
-
|
18 |
-
|
|
|
19 |
return text
|
20 |
|
21 |
HF_TOKEN = os.environ.get("HF_TOKEN", None)
|
|
|
14 |
engines = { default_lang: Model(default_lang) }
|
15 |
|
16 |
def transcribe(audio):
|
17 |
+
lang = "en"
|
18 |
+
model = engines[lang]
|
19 |
+
text = model.stt_file(audio)[0]
|
20 |
return text
|
21 |
|
22 |
HF_TOKEN = os.environ.get("HF_TOKEN", None)
|