-
Notifications
You must be signed in to change notification settings - Fork 132
Expand file tree
/
Copy pathmain.py
More file actions
35 lines (28 loc) · 847 Bytes
/
main.py
File metadata and controls
35 lines (28 loc) · 847 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#!/usr/bin/env python3
"""
Chatterbox TTS API Entry Point
This is the main entry point for the application.
It imports the FastAPI app from the organized app package.
"""
import uvicorn
from app.main import app
from app.config import Config
def main():
"""Main entry point"""
try:
Config.validate()
print(f"Starting Chatterbox TTS API server...")
print(f"Server will run on http://{Config.HOST}:{Config.PORT}")
print(f"API documentation available at http://{Config.HOST}:{Config.PORT}/docs")
uvicorn.run(
"app.main:app",
host=Config.HOST,
port=Config.PORT,
reload=False,
access_log=True
)
except Exception as e:
print(f"Failed to start server: {e}")
exit(1)
if __name__ == "__main__":
main()