fireredtts3-mnn
FireRedTTS3(零样本语音克隆 / 多语言 TTS)的 MNN 部署:ONNX → MNN int8 量化, 纯 CPU、无 torch 依赖,相比 fp32 基线约 4 倍加速。
一键运行(uvx)
uvx fireredtts3-mnn
首次运行自动从 Hugging Face 下载模型权重(~12GB)与 MNN 产物(int8,~5GB), 然后启动 HTTP TTS 服务:
POST /tts
{
"text": "今天天气很好,我们一起去公园散步吧。",
"prompt_text": "参考音频对应的文本",
"prompt_audio_b64": "<参考音频 wav 的 base64>",
"prompt_audio_sr": 16000,
"language": "Chinese" # 可选,默认 Chinese
}
-> {"audio_b64": "<合成 wav base64>", "sample_rate": 24000}
GET /health
单次合成(不启动服务):
uvx fireredtts3-mnn --text "你好世界" --prompt-wav ref.wav --prompt-text "参考文本" --out gen.wav
模型目录
默认缓存到 ~/.cache/fireredtts3-mnn:
weights/官方权重(来自FireRedTeam/FireRedTTS3)mnn/转换产物(11 个 MNN:campp / redae 编解码 / qwen3 prefill+step(KV cache) / patch_encoder / dit / 线性头,int8 量化)
可用 FIREREDTTS3_MNN_REPO 环境变量覆盖产物仓库,HF_ENDPOINT 走镜像。
转换流程(复现)
# 1) PyTorch -> ONNX(export_onnx.py,见仓库 scripts/)
# 2) ONNX -> MNN(MNNConvert,--weightQuantBits 8 或 mnnquant 全量 int8)
# 3) 校准数据:make_calib.py 用真实管线 dump 中间张量
说明
- 语言标签支持 README 所列 24 种语言与 21 种中文方言(如
ZH_Sichuan) - 未提供参考音频时使用静音 prompt(语音克隆效果依赖参考音频质量)
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
fireredtts3_mnn-0.1.0.tar.gz
(11.0 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file fireredtts3_mnn-0.1.0.tar.gz.
File metadata
- Download URL: fireredtts3_mnn-0.1.0.tar.gz
- Upload date:
- Size: 11.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via:
uv/0.12.5 {"installer":{"name":"uv","version":"0.12.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7ddfd08db02ac97f0831a2e735ec847f7648eab55a4d4056cb60bed8d65e80cc
|
|
| MD5 |
d678abd9bb064eae7ae0c76731cb2277
|
|
| BLAKE2b-256 |
6d76cc614f3a90377361261cf93e923ca1e78313dced3eb05343cd9dea4afdd8
|
File details
Details for the file fireredtts3_mnn-0.1.0-py3-none-any.whl.
File metadata
- Download URL: fireredtts3_mnn-0.1.0-py3-none-any.whl
- Upload date:
- Size: 14.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via:
uv/0.12.5 {"installer":{"name":"uv","version":"0.12.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e45882161f0dd1dc3a971367e3068e8729670c37740eaa31d7ee8f1866bd473b
|
|
| MD5 |
6e830bc53f499f4dfd0dcec1bd4b792e
|
|
| BLAKE2b-256 |
b7c9dbdd83687decad4cf675b71179d9583ef1a37bdf471983bfeb6349cb85e4
|