Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -27,3 +27,10 @@ async def tts(text: str = Query(..., min_length=1)):
|
|
| 27 |
], input=text.encode("utf-8"))
|
| 28 |
|
| 29 |
return FileResponse(output_path, media_type="audio/wav", filename="speech.wav")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 27 |
], input=text.encode("utf-8"))
|
| 28 |
|
| 29 |
return FileResponse(output_path, media_type="audio/wav", filename="speech.wav")
|
| 30 |
+
|
| 31 |
+
|
| 32 |
+
# 👇 Add this so Hugging Face can boot correctly
|
| 33 |
+
if __name__ == "__main__":
|
| 34 |
+
import uvicorn
|
| 35 |
+
uvicorn.run(app, host="0.0.0.0", port=7860)
|
| 36 |
+
|