Skip to main content
The assistant-api decouples audio transcription from provider-specific logic through a transformer layer. Every STT provider implements the same generic interface. The factory resolves the provider string at call time.

Transformer Interface

Every STT provider implements Transformers[UserAudioPacket]:
UserAudioPacket.Audio contains raw PCM 16-bit mono 16kHz bytes. All providers receive this same format — resampling from 8kHz telephony audio is handled upstream.

Factory Function

The factory switches on the provider string. To add a new provider, add a case to this switch.

Provider Identifiers


Supported STT Providers


Provider Pages

Deepgram

Nova-2/Nova-3, WebSocket streaming

Google Cloud

100+ languages, Neural Speech

Azure

Neural Speech, 140+ languages

AssemblyAI

Speaker diarization, real-time

Rev.ai

Real-time streaming

Sarvam AI

Indian languages

Configure Your Own

Implement the Transformers interface