| services: | |
| - type: web | |
| name: dialingua-api | |
| runtime: python | |
| plan: free | |
| region: frankfurt | |
| buildCommand: pip install -r requirements.txt | |
| # Single worker. The free tier has 512 MB and 0.1 CPU; a second worker | |
| # would load a second copy of the model and OOM immediately. | |
| startCommand: uvicorn app:app --host 0.0.0.0 --port $PORT --workers 1 | |
| healthCheckPath: /health | |
| envVars: | |
| - key: PYTHON_VERSION | |
| value: "3.11" | |
| - key: BKV_MODEL | |
| value: Lordkiki/dialingua-bkv2eng-web | |
| # Cache the model on the persistent-ish disk between restarts so a cold | |
| # start is not also a 233 MB download. | |
| - key: HF_HOME | |
| value: /opt/render/project/.cache/huggingface | |
| # Set this to your site's domain once it has one. "*" is fine for a | |
| # public read-only API but lets any page call it. | |
| - key: ALLOWED_ORIGINS | |
| value: "*" | |