- models/hf-cache/ vendors Systran/faster-whisper-base (142MB, gitignored); engine spawn pins HF_HUB_CACHE there, so transcription works with a cold ~/.cache and fully offline - verified: HOME=/tmp/fakehome HF_HUB_OFFLINE=1 model loads and transcribes via the bundled cache alone - setup-standalone.sh: idempotent fresh-clone provisioning (local venv, model copy-or-download, engine boot smoke on :8123) — runs green - backend/README rewritten for the desktop bundled-lite reality (was pointing at a nonexistent root README/docs and a Postgres quickstart) Kotlin suite still green (gradlew test, 0 failures)
19 lines
749 B
Markdown
19 lines
749 B
Markdown
# S.H.O.N.A.R. backend (desktop bundled-lite)
|
|
|
|
FastAPI engine for SHONAR Desktop, running standalone on this machine:
|
|
SQLite + in-process queue, self-migrating on boot. No Postgres/Redis/Docker.
|
|
|
|
## Setup (this repo is self-contained)
|
|
|
|
```bash
|
|
cd backend
|
|
uv venv .venv && uv pip install -p .venv/bin/python -e ".[dev,faster-whisper]"
|
|
```
|
|
|
|
The app (DesktopState) creates this venv's env vars itself, including
|
|
`HF_HUB_CACHE=models/hf-cache` — the `base` faster-whisper model is vendored
|
|
under `models/hf-cache/` (gitignored; copy from any HF cache to reprovision).
|
|
|
|
Tests: `.venv/bin/python -m pytest` (SQLite by default; point
|
|
`SHONAR_TEST_DATABASE_URL` at Postgres to test that path) · Lint: `ruff check .`
|
|
· Migrations: `alembic upgrade head`
|