Audio Formats
On this page
Course updated November 3, 2026 for Voxtral TTS 3, based on the Migrate from Voxtral 2 guide and Mistral’s Text to Speech pages:
voxtral-mini-tts-2603, deprecated October 31, 2026 and removed April 30, 2027, is replaced in examples byvoxtral-mini-tts-3-0. Voxtral 2 predefined voices (gb_jane_neutral…) remain accepted; Voxtral 3 adds[emotion=…]and[pace=…]tags in text, theexpressivenesssetting, custom pronunciation (phoneme_hints), and 35 languages. Mistral recommends re-measuring latency after migration. Sources: Migrate from Voxtral 2 · Speech generation.
Choosing the Right Output Format
The response_format parameter accepts five values. This single-line choice matters far more than it seems: it determines audio quality, the size of files you store, the latency your users perceive, and compatibility with their players. A podcast delivered in PCM will be unplayable for half your audience; a voice agent in MP3 will lag two seconds behind every response. The table below gives the big picture, and the rest of this lesson explains when to use each format.
| Format | Compression | Quality | Streaming Latency | Primary Use Case |
|---|---|---|---|---|
| MP3 | Lossy | Good | ~2 seconds | General use, files |
| WAV | None (PCM) | Maximum | Medium | Post-production, audiobooks |
| PCM | None (raw) | Maximum | ~0.7 seconds | Real-time streaming |
| FLAC | Lossless | Maximum | Medium | Archiving, pro quality |
| Opus | Lossy | Very Good | Low | Streaming, VoIP, limited bandwidth |
The latencies in this table are rough orders of magnitude measured with Voxtral 2; re-measure them with Voxtral TTS 3, which produces mono audio at 24 kHz in all cases.
MP3: The Universal Standard
MP3 remains the most widespread format: every browser, phone, and player reads it natively, and it carries the ID3 metadata that podcast platforms require. Its compression is lossy, so quality is slightly lower than WAV, but the difference is rarely audible for speech. Its real drawback lies elsewhere: in streaming, the codec must accumulate data before producing its first frame, delaying the first sound by about two seconds. Choose this format for downloadable files, podcasts, or standard web integration—never for conversational use.
response = client.audio.speech.complete(
model="voxtral-mini-tts-3-0",
input="An MP3 file for standard use.",
voice_id=voice_id,
response_format="mp3",
)
WAV: Maximum Quality
WAV contains uncompressed PCM audio, delivering the best possible quality with zero loss. Since there is nothing to decode and audio editors universally recognize the format, it is the natural starting point for any post-production chain: you edit, equalize, and compress, then export to your desired distribution format. The trade-off is file size—about ten times that of an MP3—and the corresponding bandwidth requirements.
response = client.audio.speech.complete(
model="voxtral-mini-tts-3-0",
input="A WAV file for the best quality.",
voice_id=voice_id,
response_format="wav",
)
Reserve it for studio-quality audiobooks, archiving, and anything you plan to edit later.
PCM: The Real-Time Format
PCM (Pulse Code Modulation) is raw Float32 Little-Endian audio with no header or encapsulation. This bareness is both its strength and its weakness. Its strength: nothing to encode or decode, the first sound arrives in about 0.7 seconds, and received bytes write directly to the sound card. Its weakness: without a header, you must know and transmit the sample rate and format yourself—exactly why the pyaudio example in Lesson 10 explicitly declared paFloat32, one channel, and 24,000 Hz. Files are also very large, and no consumer player opens them directly.
response = client.audio.speech.complete(
model="voxtral-mini-tts-3-0",
input="Raw PCM for streaming.",
voice_id=voice_id,
response_format="pcm",
)
This is the format for real-time voice assistants, conversational agents, and WebRTC applications.
FLAC: Lossless Compression
FLAC reduces file size by 50% to 60% without touching a single sample: quality is rigorously identical to WAV, and you retain metadata. In practice, this is your archiving format: store your masters in FLAC, and you can regenerate an MP3 or Opus years later without suffering the double compression that degrades audio. It does require a decoder, making it less universal than MP3.
response = client.audio.speech.complete(
model="voxtral-mini-tts-3-0",
input="FLAC for lossless archiving.",
voice_id=voice_id,
response_format="flac",
)
Opus: The Modern Compromise
Opus is a codec designed for real-time communication, delivering excellent quality at very low bitrates. On a mobile app running on degraded 4G, it delivers clear voice where WAV would saturate the connection, with low streaming latency—higher than PCM, but far lower than MP3. Compatibility is uneven, however: not all players support it natively, and some require an OGG container.
response = client.audio.speech.complete(
model="voxtral-mini-tts-3-0",
input="Opus for efficient streaming.",
voice_id=voice_id,
response_format="opus",
)
This is the choice for VoIP, limited-bandwidth streaming, and mobile applications.
Deciding in One Minute
Facing a new project, decide in this order. If you are doing real-time streaming, choose PCM for minimum latency, or Opus if bandwidth matters as much as responsiveness. Otherwise, ask where the file will be played: in a browser, MP3 guarantees maximum compatibility. If it needs editing later, WAV gives you the easiest material to manipulate. If it must be archived without losing a decibel, FLAC compresses without sacrificing anything. And if the dominant constraint is a slow network, Opus offers the best quality-to-size ratio.
Key Takeaways
- MP3 is the default choice for universal compatibility
- PCM offers the lowest latency for real-time streaming (~0.7s)
- WAV provides the best uncompressed quality, ideal for post-production
- FLAC compresses without loss—same quality as WAV, smaller files
- Opus is the best quality-to-size compromise for networked applications