INNER CODE UNIT · Python
get_model_status_endpoint
devnen/Kitten-TTS-Server · server.py:283
async def get_model_status_endpoint():
"""Returns the current download/loading progress for model switching."""
return engine.get_download_status()
# --- API Endpoint for Initial UI Data ---
@app.get("/api/ui/initial-data", tags=["UI Helpers"])
async def get_ui_initial_data():
"""
Provides all necessary initial data for the UI to render,
including configuration, file lists, presets, and model information.
"""
logger.info("Request received for /api/ui/initial-data.")
try:
full_config = get_full_config_for_template()
# Get model information for UI
model_info = engine.get_model_info()