Spaces:
Sleeping
Sleeping
Download app.py from yousseftallal/test: direct link, hf CLI and curl.
- Browser
- Download file 373 Bytes
-
https://huggingface.co/spaces/yousseftallal/test/resolve/main/app.py
- Command line
-
hf download hf://spaces/yousseftallal/test/app.py
-
curl -L -o app.py https://huggingface.co/spaces/yousseftallal/test/resolve/main/app.py
373 Bytes
| """ | |
| Hugging Face Spaces entry point. | |
| Uses FastAPI + Uvicorn. If running locally with Flask preferred: | |
| set MQG_BACKEND=flask | |
| python -m multiq.cli serve | |
| """ | |
| import os | |
| BACKEND = os.getenv("MQG_BACKEND", "fastapi") | |
| if BACKEND == "flask": | |
| from multiq.api import create_app as _create | |
| app = _create() | |
| else: | |
| from multiq.fastapi_app import app # noqa: F401 | |