Open-XTTS-Trainer 发布完整训练套件
开发者 u/yashubhakt 发布 MPL-2.0 许可的 Open-XTTS-Trainer,可训练 XTTS v2 的 DVAE 音频分词器、GPT 文本模型和 Latent HiFi-GAN 声码器。其词表扩展功能可加入印地语、阿拉伯语、泰语和迪维希语等 Unicode 字符,项目还提供一键式 Colab 演示。开发者报告称,该工具已在 NVIDIA T4 上使用 LJSpeech 和一段 JFK 演讲完成收敛测试,但结果尚未得到独立验证。
该项目为 Coqui AI 关闭后适配 XTTS v2 新语言脚本提供了统一的开源方案,填补了组件训练流程分散的问题。
TL;DR: When Coqui AI shut down, they left XTTS v2 without official training code for the DVAE audio tokenizer and Latent HiFi-GAN vocoder, and fine-tuning new scripts (Arabic, Indic, etc.) broke on fixed vocabularies. I built Open-XTTS-Trainer — an open-source, modular 3-component training suite under MPL-2.0 with verified GPU loss convergence on real human speech and a 1-click Colab demo.
Why I Built This
XTTS v2 is one of the best local zero-shot TTS models we have, but training/adapting it has been painful since Coqui closed:
- Missing Component Recipes: Only GPT fine-tuning was commonly available. Stage 1 (DVAE) and Stage 3 (HiFi-GAN vocoder) training pipelines were either unreleased or fragmented.
- The Tokenizer Wall: XTTS was hardcoded for 17 languages. Feeding text with new Unicode scripts (Hindi, Arabic, Thai, Dhivehi, etc.) caused token out-of-vocab or matrix dimension crashes.
- Dependency Rot: Upgrading to modern PyTorch (2.4+) broke on missing
torchcodecand licensing prompts.
What’s in the Suite
- Stage 1 (Audio Tokenizer — DVAE): Full training & fine-tuning loop with Gumbel-Softmax codebook annealing and mel-spectrogram reconstruction loss.
- Stage 2 (Text & Vocab Extender — GPT): Scans a new language corpus, discovers unique Unicode glyphs, appends them to the tokenizer, and dynamically resizes the GPT embedding matrix without corrupting existing weights. Includes the autoregressive GPT training loop.
- Stage 3 (Neural Vocoder — Latent HiFi-GAN): Latent-conditioned vocoder training with Multi-Period (MPD) and Multi-Scale (MSD) discriminators and feature-matching loss.
- Dependency-Rot Free: Runs out-of-the-box on modern PyTorch (Python 3.10–3.13) without
torchcodecblocking.
#Open-XTTS-Trainer#XTTS v2#Coqui AI#DVAE#GPT#Latent HiFi-GAN#PyTorch#Google Colab#NVIDIA T4#LJSpeech