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
23 lines
537 B
Bash
Executable File
23 lines
537 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
set -ex
|
|
|
|
source ./setup.sh
|
|
|
|
# please visit
|
|
# https://k2-fsa.github.io/sherpa/onnx/tts/pretrained_models/kokoro.html
|
|
# to download more models
|
|
if [ ! -f ./kokoro-en-v0_19/model.onnx ]; then
|
|
curl -SL -O https://github.com/k2-fsa/sherpa-onnx/releases/download/tts-models/kokoro-en-v0_19.tar.bz2
|
|
tar xf kokoro-en-v0_19.tar.bz2
|
|
rm kokoro-en-v0_19.tar.bz2
|
|
fi
|
|
|
|
|
|
source ./setup-phonemize.sh
|
|
|
|
java \
|
|
-Dsherpa_onnx.native.path=$PWD/../build/lib \
|
|
-cp "$PHONEMIZE_CLASSPATH" \
|
|
NonStreamingTtsKokoroEnPhonemize.java
|