This repo contains all the files that Tonetta's processing server is currently running.
scp -r -i C:\Users\jdjoh\.ssh\tonetta [email protected]:~/joeyMain [email protected]:~/serverFiles .The repo is private. First add your server's SSH public key as a deploy key on GitHub (repo → Settings → Deploy keys), then:
git clone [email protected]:TonettaSupport/ServerBackup.git
cd ServerBackupCreate a .env file in the ServerBackup directory:
nano .envAdd:
SUPABASE_URL=your_supabase_url
SUPABASE_SERVICE_KEY=your_service_key
chmod +x run_server.sh && ./run_server.shThis will automatically create a virtual environment, install all dependencies, configure audio, and launch the server in the background.
To monitor logs:
tail -f server.logTo stop the server:
pkill -f newmain.pyThe server runs two Whisper models simultaneously: a tiny model for low-latency live transcription and a larger model for final post-call transcription. The branch you deploy determines the final model size.
| Branch | Live Model | Final Model | Notes |
|---|---|---|---|
main |
tiny |
small (default) or $WHISPER_MODEL_PATH |
Stable, lower resource usage |
Better-Transcription |
tiny |
large-v3-turbo |
Higher accuracy, needs more RAM/VRAM |
All models run in int8 quantized mode on CPU, or float16 if a CUDA GPU is detected.
Both branches force DEVICE = "cpu" by default for stability. Here's what you need to run without lag:
| Branch / Config | Min RAM | Recommended RAM | Min CPUs | Notes |
|---|---|---|---|---|
main (tiny + small) |
4 GB | 6–8 GB | 4 vCPUs | Comfortable on budget VPS |
Better-Transcription (tiny + large-v3-turbo) |
8 GB | 12–16 GB | 8 vCPUs | Slower than realtime below 8 vCPUs |
Custom large-v3 via env var |
12 GB | 16+ GB | 8 vCPUs | Highest accuracy, highest cost |
Transcription speed note: On CPU with
int8,smallprocesses audio at roughly 3–5x realtime (fast).large-v3-turboruns at ~1–2x realtime on a strong CPU — meaning a 10-minute call may take 5–10 minutes to finish transcribing. Plan queue capacity accordingly. The 30-minute call hard cap skips transcription entirely to avoid timeout.
Set DEVICE = "cuda" in newmain.py (line 48) to enable GPU mode. Models switch to float16 automatically.
| Model Loaded | VRAM Required | Recommended GPU | Speed vs Realtime |
|---|---|---|---|
tiny (live) |
~0.5 GB | Any NVIDIA GPU | ~30x faster |
small |
~1.5 GB | GTX 1060 6GB+ | ~10–15x faster |
large-v3-turbo |
~5–6 GB | RTX 3060 12GB / RTX 4000 Ada 20GB | ~5–8x faster |
large-v3 |
~8–10 GB | RTX 3090 / A100 40GB | ~4–6x faster |
tiny + large-v3-turbo (both loaded) |
~6–7 GB | RTX 3080 10GB+ | — |
The RTX 4000 Ada (20 GB VRAM) deployed on the production server handles
tiny+large-v3-turbocomfortably with headroom to spare.
- CPU: 4 vCPUs
- RAM: 6 GB
- Disk: 5 GB free (Whisper model cache + audio temp files)
- OS: Ubuntu 20.04+ with PulseAudio (required for system audio capture)
- Python: 3.10+
- ffmpeg: Required for audio mixing
- GPU: NVIDIA RTX 3080 10GB or better (VRAM is the bottleneck, not CUDA cores)
- CPU: 8 vCPUs
- RAM: 16 GB system RAM
- Disk: 15 GB free
- CUDA: 11.8+ with matching PyTorch build
These run alongside Whisper and add minor overhead:
- FastAPI + Uvicorn — negligible, ~100 MB RAM
- librosa (pitch/WPM analysis) — CPU-bound, spikes briefly per call, ~200–400 MB RAM during processing
- OpenAI API (GPT-4o for
/practice, TTS-1 for speech) — cloud calls, no local GPU needed - Supabase — cloud DB, no local resources