Provide a small list of likely languages when possible. It improves accuracy and reduces latency.
How to use language detection ?
Choose thelanguage_config that matches your audio:
- One known language: Set
languagesto that language code (for example["en"]) and keepcode_switchingoff. - Unknown language from a small set: Pass the candidate languages you expect. A short list is usually more accurate and faster than searching all supported languages.
- Conversations that change languages: Enable code switching and provide a nonempty expected-language list.
- Detection vs translation: Language detection selects the spoken language for transcription. Translating the transcript into another language is a separate translation feature.
language_config.languages to search across all supported languages, or pass a constrained list:
language is returned on each utterance and can vary over time if you also enable code switching.
Tips
- Use supported languages to pick valid ISO 639-1 codes.
- Check model selection for language detection availability by model. Live transcription uses Solaria-1.
- Multiple languages or code switching can reduce partial transcript accuracy — keep the expected-language list focused, since fewer candidate languages make detection more reliable and partial transcripts more stable.
- Combine with
messages_config.receive_partial_transcriptsin real time to get immediate feedback. - For mixed-language conversations, enable code switching.