reels-app/app
Sebastjan Artič 5c53a27d33 Add Groq Whisper API integration (200x faster than local CPU)
Pipeline:
- New transcribe_with_groq() function uses Groq's whisper-large-v3-turbo
- 30s audio transcribed in ~0.5s (vs 30s+ on CPU)
- Same quality as local Whisper (it's the same OpenAI model)
- Cloudflare bypass via custom User-Agent header
- 24MB upload limit guard with auto-fallback to local
- Language auto-detect works (Groq returns full lang name, mapped to ISO codes)

Default whisper_provider='auto':
- If GROQ_API_KEY is set → use Groq (200x faster)
- Otherwise → fallback to local faster-whisper
- Strict 'groq' mode: no fallback (returns empty if Groq fails)
- Strict 'local' mode: skip Groq entirely

CLI: --whisper-provider {auto,groq,local}
API: whisper_provider field in StartJobIn

Cost: $0.04/h with whisper-large-v3-turbo ($0.002 per 200s song)
2026-04-29 11:08:15 +00:00
..
main.py Add Groq Whisper API integration (200x faster than local CPU) 2026-04-29 11:08:15 +00:00