2026-08-04 17:26:15 +02:00
# llama.cpp TTS
2025-01-10 13:16:16 +01:00
2026-08-04 17:26:15 +02:00
This is a tool to demonstrate audio generation capability in llama.cpp via `libmtmd` . It was added via PR [#26254 ](https://github.com/ggml-org/llama.cpp/pull/26254 )
2025-01-10 13:16:16 +01:00
2026-08-04 17:26:15 +02:00
Note: this tool used to serve as a demo for OuteTTS, but it was converted to a more model-agnostic tool.
2025-01-10 13:16:16 +01:00
2026-08-04 17:26:15 +02:00
## Common usage
2025-01-10 13:16:16 +01:00
2026-08-04 17:26:15 +02:00
Simple usage:
```sh
llama-tts -hf ggml-org/Qwen3-TTS-12Hz-1.7B-Base-GGUF -p "Hello world" --output out.wav
2025-01-10 13:16:16 +01:00
```
2026-08-04 17:26:15 +02:00
Common params:
- Sampling params such as `--top-k` , `--top-p` , `--temp` , etc.
- `-n <number_of_frames>` limits the output length, e.g. `-n 500` . Note that how many milliseconds each frame represents varies by model
- Core inference params such as `-ngl` , `-b` , `-ub` , etc.
2025-01-10 13:16:16 +01:00
2026-08-04 17:26:15 +02:00
## Qwen3-TTS
2025-01-10 13:16:16 +01:00
2026-08-04 17:26:15 +02:00
Available params:
- `--tts-lang` can be `zh` , `en` , `de` , `it` , `pt` , `es` , `ja` , `ko` , `fr` , `ru` (default: `en` )
- `--tts-speaker-file` should point to a speaker reference audio file (wav, mp3)
2025-01-15 05:44:38 +01:00
2026-08-04 17:26:15 +02:00
Example usage:
2025-01-15 05:44:38 +01:00
2026-08-04 17:26:15 +02:00
```sh
llama-tts -hf ggml-org/Qwen3-TTS-12Hz-1.7B-Base-GGUF \
-p "Hello world" \
--tts-lang english \
--tts-speaker-file speaker.mp3 \
--output out.wav
2025-01-15 05:44:38 +01:00
```