mirror of
https://github.com/k2-fsa/sherpa-onnx.git
synced 2026-11-10 21:11:03 +08:00
Fixes #3731 espeak-ng and piper-phonemize are no longer built into sherpa-onnx. Text frontends are now: - **lexicon** — built in, no extra dependency - **phonemize** — phonemize outside sherpa-onnx (e.g. [piper-phonemize](https://github.com/csukuangfj/piper-phonemize)) and pass the result in. That library is GPL, so it stays optional: sherpa-onnx is GPL-free after this PR. ## API - `SherpaOnnxGenerationConfig` gains `phoneme_codepoints` and `tokens` (mutually exclusive alternatives to `text`) - `data_dir` on the TTS model configs is deprecated and ignored; the ABI slot is kept - all bindings updated: C/C++, Python, Java, Kotlin, Go, Rust, C#, Swift, Pascal, Dart/Flutter, node-addon, WASM, HarmonyOS
Introduction
This directory contains examples for how to use the TTS (text to speech) APIs.
| Directory | Description |
|---|---|
| run-piper.sh | It shows how to use models from piper for text to speech. |
| run-piper-playback.sh | It shows how to use models from piper for text to speech. It plays the generated audio as it is still generating. |
| run-zipvoice-zh-en.sh | It shows how to use ZipVoice Chinese/English zero-shot TTS for text to speech. |