Text-to-SpeechShared concepts

Language mixing

How Soniox Text-to-Speech follows language changes naturally within one utterance while using the selected language for overall delivery.

Overview

Real-world text often includes foreign names, international addresses, technical terminology, and phrases from multiple languages. Soniox Text-to-Speech follows these language changes naturally within one continuous utterance with no need to split the text or stitch audio together.

You still select a primary language with the language field. That choice sets the overall delivery and a light accent bias for the voice, while embedded words and phrases from other languages are pronounced in a natural way.

How language mixing works

Pass mixed-language text in a single request or stream session, and set language to the main language of the text or to the language you want the speech to sound like.

{
  "model": "tts-rt-v2",
  "language": "en",
  "voice": "Adrian",
  "text": "Please deliver the package to Calle de Alcalá 45 in Madrid, attention Señora García."
}

In this example, English is the primary language, so delivery follows English prosody. Spanish place names and titles are still pronounced naturally within the same utterance.

Choosing the language

The language field remains required. Use it for either:

  • Main language of the text — best when most of the content is in one language and only a few words or phrases come from others.
  • Desired delivery language — best when you want the voice to sound as if it belongs to that language community, even if the written text is mostly something else.

Sending the same text with a different language changes how the whole utterance sounds. Compare the example above with:

{
  "model": "tts-rt-v2",
  "language": "es",
  "voice": "Adrian",
  "text": "Please deliver the package to Calle de Alcalá 45 in Madrid, attention Señora García."
}

Here the text is still mostly English, but Spanish now drives the delivery, so the speaker sounds Hispanic — a light accent bias rather than a heavy accent. The same idea works in the other direction: Spanish text with "language": "en" leans toward an English-speaking delivery while still handling Spanish words naturally.

Don't pick language based on a few embedded words. It biases the accent of the entire utterance, not just those words. Foreign names, addresses, and terms are handled correctly without changing language.

Every voice works with all supported languages, so you can keep the same speaker while changing language or mixing languages in the input.