How do you implement offline speech recognition with Whisper models?
OpenAI's Whisper models can run entirely offline using whisper.cpp (C/C++ implementation) or faster-whisper (CTranslate2-based Python). Setup involves: download the model (tiny: 39MB to large-v3: 1.5GB), quantize to INT8 for 2x speed improvement with minimal quality loss, and configure for your hardware. For real-time transcription, use the tiny or base model with Voice Activity Detection (VAD) to process only speech segments. Key optimizations: use beam search with beamsize=5 for accuracy or greedy decoding for speed, enable conditiononprevioustext for long-form audio, implement chunked processing with 30-second windows and 5-second overlap for seamless transcription. On modern CPUs, the base model processes audio at 10-15x real-time; with GPU acceleration, large-v3 achieves 5-8x real-time.