Integrate WhisperLiveKit core components
mainTo use WhisperLiveKit without its bundled frontend or FastAPI server, you can interact directly with the core runtime components. The primary server boundary is defined by two methods in the AudioProcessor class:
- Incoming Audio: Use
AudioProcessor.process_audio()to ingest incoming audio bytes. - Outgoing Updates: Use the async generator returned by
AudioProcessor.create_tasks()to receiveFrontDataJSON updates.
Runtime Layers
- Transport: Any ASGI/WebSocket server (e.g.,
whisperlivekit/basic_server.py) that accepts audio over WebSocket (MediaRecorder WebM or raw PCM chunks) and streams JSON updates. - Audio Processing:
whisperlivekit/audio_processor.pyhandles audio buffering, transcription orchestration, diarization, translation, and FFmpeg/PCM input. - Engines:
whisperlivekit/core.pyand related modules load models (SimulStreaming or LocalAgreement) and expose theTranscriptionEngine. - Frontends: Optional UI layers (Web or Chrome Extension) that feed the WebSocket endpoint.