"""FastAPI / Gradio Server entry point. Provides `create_app()` which returns the configured `gradio.Server` instance with all HTTP routes and Gradio API endpoints registered. The actual routes are defined in `code/server/routes.py`. """ from __future__ import annotations from typing import Any def create_app() -> Any: """Create and return the configured Gradio Server app instance. This is a thin wrapper around `code.server.routes.get_app()` that triggers all the route decorators when the routes module is first imported. """ from code.server.routes import get_app # noqa: F401 (import has side effects) return get_app() def get_app() -> Any: """Backward-compatible alias for create_app().""" return create_app() __all__ = ["create_app", "get_app"]