Spaces:
Running
Running
File size: 595 Bytes
ebe8bfa e645cd4 ebe8bfa e645cd4 ebe8bfa e645cd4 | 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 | ---
title: TextPhantom OCR API
emoji: "🪄"
colorFrom: indigo
colorTo: pink
sdk: docker
app_port: 7860
pinned: false
---
FastAPI backend for TextPhantom (Chrome extension).
## Endpoints
- `GET /health`
- `GET /version`
- `GET /warmup?lang=th`
- `POST /translate`
- `GET /translate/{job_id}`
- `POST /ai/resolve`
- `GET /ai/models`
- `POST /ws` (WebSocket)
## Environment
- `AI_API_KEY` (optional)
- `SERVER_MAX_WORKERS` (default: 15)
- `JOB_TTL_SEC` (default: 3600)
- `TP_DEBUG` (set to `1` to enable debug logs)
For Spaces on small CPU, setting `SERVER_MAX_WORKERS=2` is usually enough.
|