How marlinspike/whisper_transcribe_video works
Main Components
a) External Services:
• YouTube Data Source
• Azure OpenAI Service (Whisper Model)
b) Application Components:
• Main Application Controller (app.py)
• Audio Processing Engine (audio_engine.py)
• File Download Manager (file_downloader.py)
• Batch Processing System (batch_processor.py)
c) Storage Components:
• Working Directory (temporary storage)
• Output Directory (transcription storage)
• Configuration (.env)
┌─ Input Sources ─┐ ┌─ Core Processing ─┐ ┌─ External Services ─┐
• YouTube URLs │ │ - File Downloader │ │ - Azure OpenAI │
• Local Files │──►│ - Audio Engine │◄──►│ (Whisper) │
• Batch CSV │ │ - Batch Processor │ └───────────────────┘
• ┘ └────────────────────┘
• ┌─ Storage ─┐
• Working Dir │
• ┴─────────────────►│ - Output Dir │
• ┘
Process Flow Representation
a) Input Processing Flow:
• YouTube URL/Local File/CSV → File Downloader
• File Downloader → Working Directory
b) Processing Flow:
• Working Directory → Audio Engine
• Audio Engine → Azure OpenAI Whisper
• Azure OpenAI Whisper → Audio Engine
• Audio Engine → Output Directory
c) Batch Processing Flow:
• CSV File → Batch Processor
• Batch Processor → File Downloader
• Batch Processor → Audio Engine
Important Details
a) File Processing Stages:
• Download Stage
• Audio Splitting Stage (with configurable splits)
• Transcription Stage
• Cleanup Stage
b) Configuration Elements:
• Environment Variables
• Split Configuration
• API Endpoints
Technical Specifications to Note
• FFmpeg dependency for audio processing
• Python 3.11+ requirement
• Azure OpenAI Whisper model location (North Central region)
• File format support (Audio/Video)