Spaces:
Running
Running
Update speech_api.py
Browse files- speech_api.py +1 -1
speech_api.py
CHANGED
@@ -56,7 +56,7 @@ async def text_to_speech(request: TTSRequest):
|
|
56 |
raise HTTPException(status_code=500, detail=str(e))
|
57 |
|
58 |
@router.post("/asr")
|
59 |
-
async def speech_to_text(file: UploadFile = File(...), source_language: str = "
|
60 |
try:
|
61 |
audio_content = await file.read()
|
62 |
asr_result = client.asr(audio_content, source_language=source_language)
|
|
|
56 |
raise HTTPException(status_code=500, detail=str(e))
|
57 |
|
58 |
@router.post("/asr")
|
59 |
+
async def speech_to_text(file: UploadFile = File(...), source_language: str = "en"):
|
60 |
try:
|
61 |
audio_content = await file.read()
|
62 |
asr_result = client.asr(audio_content, source_language=source_language)
|