/ Модель

Характеристики

Лицензия
Apache 2.0
Архитектура
TaDiCodec · dense
Библиотека
transformers
Опубликована
22 авг 2025

TaDiCodec

Обработка аудиоАудио → аудио3 профессии

TaDiCodec — компактный текстово-управляемый диффузионный кодек для токенизации и реконструкции речи и использования в системах речевого синтеза.

102скачиваний за 30 дней29лайковвеса обновлены2 сен 2025

Бенчмарки

Как модель справилась с задачами пользователей ailist и что о ней публикуют открытые лидерборды

Публичные оценки

Из открытых лидербордов. Сравнивайте результаты одного теста при одинаковых условиях — отсутствие оценки не значит, что модель хуже.

В подключённых источниках результатов для этой модели пока нет.

Что умеет модель

Описание составлено по карточке модели и метаданным Hugging Face

TaDiCodec — текстово-управляемый диффузионный аудиокодек и токенизатор речи, представленный авторами статьи TaDiCodec: Text-aware Diffusion Speech Tokenizer for Speech Language Modeling. Модель кодирует речь в компактные токены и восстанавливает аудио с помощью диффузионного автоэнкодера, в котором декодер использует текстовые подсказки. Обучение сквозное и одностадийное, без вспомогательных предварительно обученных моделей.

Кодек предназначен для токенизации и реконструкции речи, а также для использования в речевых языковых моделях и системах синтеза речи, включая zero-shot TTS с авторегрессионным и masked generative моделированием. Для речи с частотой 24 кГц заявлены частота токенов 6,25 Гц и битрейт 0,0875 кбит/с; авторы сообщают о качестве по метрикам WER, сходства голоса и естественности звучания. Репозиторий использует формат safetensors и библиотеку Transformers; лицензия — Apache-2.0. Карточка перечисляет английский, китайский, японский, французский, немецкий и корейский языки.

Сценарии применения

  • сжатие речи в токены для речевой языковой модели
  • реконструкция аудио из речевых токенов
  • подготовка компактного речевого представления для генерации речи
  • использование как токенизатора в zero-shot синтезе речи

Ограничения

Модель ориентирована на речевое аудио и описана как компонент речевых языковых моделей; README не приводит подробных результатов по отдельным языкам или сценариям применения.

Для каких профессий подходит3

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

🚀 TaDiCodec

This model was presented in the paper TaDiCodec: Text-aware Diffusion Speech Tokenizer for Speech Language Modeling. Project page: https://tadicodec.github.io/ GitHub Repository: https://github.com/HeCheng0625/Diffusion-Speech-Tokenizer

Abstract

Speech tokenizers serve as foundational components for speech language models, yet current designs exhibit several limitations, including: 1) dependence on multi-layer residual vector quantization structures or high frame rates, 2) reliance on auxiliary pre-trained models for semantic distillation, and 3) requirements for complex two-stage training processes. In this work, we introduce the Text-aware Diffusion Transformer Speech Codec (TaDiCodec), a novel approach designed to overcome these challenges. TaDiCodec employs end-to-end optimization for quantization and reconstruction through a diffusion autoencoder, while integrating text guidance into the diffusion decoder to enhance reconstruction quality and achieve optimal compression. TaDiCodec achieves an extremely low frame rate of 6.25 Hz and a corresponding bitrate of 0.0875 kbps with a single-layer codebook for 24 kHz speech, while maintaining superior performance on critical speech generation evaluation metrics such as Word Error Rate (WER), speaker similarity (SIM), and speech quality (UTMOS). Notably, TaDiCodec employs a single-stage, end-to-end training paradigm, and obviating the need for auxiliary pre-trained models. We also validate the compatibility of TaDiCodec in language model based zero-shot text-to-speech with both autoregressive modeling and masked generative modeling, demonstrating its effectiveness and efficiency for speech language modeling, as well as a significantly small reconstruction-generation gap. We will open source our code and model checkpoints. Audio samples are are available at https:/tadicodec.github.io/ . We release code and model checkpoints at https:/github.com/HeCheng0625/Diffusion-Speech-Tokenizer .

GitHub Stars arXiv Demo Python PyTorch Hugging Face

🤗 Pre-trained Models

📦 Model Zoo - Ready to Use!

Download our pre-trained models for instant inference

🎵 TaDiCodec

Model🤗 Hugging Face👷 Status
🚀 TaDiCodecHF✅
🚀 TaDiCodec-oldHF🚧

Note: TaDiCodec-old is the old version of TaDiCodec, the TaDiCodec-TTS-AR-Phi-3.5-4B is based on TaDiCodec-old.

🎤 TTS Models

ModelTypeLLM🤗 Hugging Face👷 Status
🤖 TaDiCodec-TTS-AR-Qwen2.5-0.5BARQwen2.5-0.5B-InstructHF✅
🤖 TaDiCodec-TTS-AR-Qwen2.5-3BARQwen2.5-3B-InstructHF✅
🤖 TaDiCodec-TTS-AR-Phi-3.5-4BARPhi-3.5-mini-instructHF🚧
🌊 TaDiCodec-TTS-MGMMGM-HF✅

🔧 Quick Model Usage

# 🤗 Load from Hugging Face
from models.tts.tadicodec.inference_tadicodec import TaDiCodecPipline
from models.tts.llm_tts.inference_llm_tts import TTSInferencePipeline
from models.tts.llm_tts.inference_mgm_tts import MGMInferencePipeline

# Load TaDiCodec tokenizer, it will automatically download the model from Hugging Face for the first time
tokenizer = TaDiCodecPipline.from_pretrained("amphion/TaDiCodec")

# Load AR TTS model, it will automatically download the model from Hugging Face for the first time  
tts_model = TTSInferencePipeline.from_pretrained("amphion/TaDiCodec-TTS-AR-Qwen2.5-3B")

# Load MGM TTS model, it will automatically download the model from Hugging Face for the first time
tts_model = MGMInferencePipeline.from_pretrained("amphion/TaDiCodec-TTS-MGM")

🚀 Quick Start

Installation

# Clone the repository
git clone https://github.com/HeCheng0625/Diffusion-Speech-Tokenizer.git
cd Diffusion-Speech-Tokenizer

# Install dependencies
bash env.sh

Basic Usage

Please refer to the use_examples folder for more detailed usage examples.

Speech Tokenization and Reconstruction

# Example: Using TaDiCodec for speech tokenization
import torch
import soundfile as sf
from models.tts.tadicodec.inference_tadicodec import TaDiCodecPipline

device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
pipe = TaDiCodecPipline.from_pretrained(ckpt_dir="./ckpt/TaDiCodec", device=device)

# Text of the prompt audio
prompt_text = "In short, we embarked on a mission to make America great again, for all Americans."
# Text of the target audio
target_text = "But to those who knew her well, it was a symbol of her unwavering determination and spirit."

# Input audio path of the prompt audio
prompt_speech_path = "./use_examples/test_audio/trump_0.wav"
# Input audio path of the target audio
speech_path = "./use_examples/test_audio/trump_1.wav"

rec_audio = pipe(
    text=target_text,
    speech_path=speech_path,
    prompt_text=prompt_text,
    prompt_speech_path=prompt_speech_path
)
sf.write("./use_examples/test_audio/trump_rec.wav", rec_audio, 24000)

Zero-shot TTS with TaDiCodec

import torch
import soundfile as sf
from models.tts.llm_tts.inference_llm_tts import TTSInferencePipeline
# from models.tts.llm_tts.inference_mgm_tts import MGMInferencePipeline

device = torch.device("cuda" if torch.cuda.is_available() else "cpu")

# Create AR TTS pipeline
pipeline = TTSInferencePipeline.from_pretrained(
    tadicodec_path="./ckpt/TaDiCodec",
    llm_path="./ckpt/TaDiCodec-TTS-AR-Qwen2.5-3B",
    device=device,
)

# Inference on single sample, you can also use the MGM TTS pipeline
audio = pipeline(
    text="但是 to those who 知道 her well, it was a 标志 of her unwavering 决心 and spirit.",   # code-switching cases are supported
    prompt_text="In short, we embarked on a mission to make America great again, for all Americans.",
    prompt_speech_path="./use_examples/test_audio/trump_0.wav",
)

sf.write("./use_examples/test_audio/lm_tts_output.wav", audio, 24000)

📚 Citation

If you find this repository useful, please cite our paper:

TaDiCodec:

@article{tadicodec2025,
  title={TaDiCodec: Text-aware Diffusion Speech Tokenizer for Speech Language Modeling},
  author={Yuancheng Wang, Dekun Chen, Xueyao Zhang, Junan Zhang, Jiaqi Li, Zhizheng Wu},
  journal={arXiv preprint},
  year={2025},
  url={https://arxiv.org/abs/2508.16790}
}

Amphion:

@inproceedings{amphion,
    author={Xueyao Zhang and Liumeng Xue and Yicheng Gu and Yuancheng Wang and Jiaqi Li and Haorui He and Chaoren Wang and Ting Song and Xi Chen and Zihao Fang and Haopeng Chen and Junan Zhang and Tze Ying Tang and Lexiao Zou and Mingxuan Wang and Jun Han and Kai Chen and Haizhou Li and Zhizheng Wu},
    title={Amphion: An Open-Source Audio, Music and Speech Generation Toolkit},
    booktitle={{IEEE} Spoken Language Technology Workshop, {SLT} 2024},
    year={2024}
}

MaskGCT:

@inproceedings{wang2024maskgct,
  author={Wang, Yuancheng and Zhan, Haoyue and Liu, Liwei and Zeng, Ruihong and Guo, Haotian and Zheng, Jiachen and Zhang, Qiang and Zhang, Xueyao and Zhang, Shunsi and Wu, Zhizheng},
  title={MaskGCT: Zero-Shot Text-to-Speech with Masked Generative Codec Transformer},
  booktitle    = {{ICLR}},
  publisher    = {OpenReview.net},
  year         = {2025}
}

🙏 Acknowledgments

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · transformers

Нельзя запустить

Обработка «аудио → аудио» пока не поддерживается.

Ревизия весов
e93c666

0 моделей