README.md
| 1 | --- |
| 2 | license: mit |
| 3 | language: |
| 4 | - ar |
| 5 | - da |
| 6 | - de |
| 7 | - el |
| 8 | - en |
| 9 | - es |
| 10 | - fi |
| 11 | - fr |
| 12 | - he |
| 13 | - hi |
| 14 | - it |
| 15 | - ja |
| 16 | - ko |
| 17 | - ms |
| 18 | - nl |
| 19 | - no |
| 20 | - pl |
| 21 | - pt |
| 22 | - ru |
| 23 | - sv |
| 24 | - sw |
| 25 | - tr |
| 26 | - zh |
| 27 | pipeline_tag: text-to-speech |
| 28 | tags: |
| 29 | - text-to-speech |
| 30 | - speech |
| 31 | - speech-generation |
| 32 | - voice-cloning |
| 33 | - multilingual-tts |
| 34 | library_name: chatterbox |
| 35 | --- |
| 36 | |
| 37 | <img width="800" alt="cb-big2" src="https://github.com/user-attachments/assets/bd8c5f03-e91d-4ee5-b680-57355da204d1" /> |
| 38 | |
| 39 | <h1 style="font-size: 32px">Chatterbox TTS</h1> |
| 40 | |
| 41 | <div style="display: flex; align-items: center; gap: 12px"> |
| 42 | <a href="https://resemble-ai.github.io/chatterbox_demopage/"> |
| 43 | <img src="https://img.shields.io/badge/listen-demo_samples-blue" alt="Listen to Demo Samples" /> |
| 44 | </a> |
| 45 | <a href="https://huggingface.co/spaces/ResembleAI/Chatterbox"> |
| 46 | <img src="https://huggingface.co/datasets/huggingface/badges/resolve/main/open-in-hf-spaces-sm.svg" alt="Open in HF Spaces" /> |
| 47 | </a> |
| 48 | <a href="https://podonos.com/resembleai/chatterbox"> |
| 49 | <img src="https://static-public.podonos.com/badges/insight-on-pdns-sm-dark.svg" alt="Insight on Podos" /> |
| 50 | </a> |
| 51 | </div> |
| 52 | |
| 53 | <div style="display: flex; align-items: center; gap: 8px;"> |
| 54 | <span style="font-style: italic;white-space: pre-wrap">Made with ❤️ by</span> |
| 55 | <img width="100" alt="resemble-logo-horizontal" src="https://github.com/user-attachments/assets/35cf756b-3506-4943-9c72-c05ddfa4e525" /> |
| 56 | </div> |
| 57 | |
| 58 | **09/04 🔥 Introducing Chatterbox Multilingual in 23 Languages!** |
| 59 | |
| 60 | We're excited to introduce **Chatterbox** and **Chatterbox Multilingual**, [Resemble AI's](https://resemble.ai) production-grade open source TTS models. Chatterbox Multilingual supports **Arabic, Danish, German, Greek, English, Spanish, Finnish, French, Hebrew, Hindi, Italian, Japanese, Korean, Malay, Dutch, Norwegian, Polish, Portuguese, Russian, Swedish, Swahili, Turkish, Chinese** out of the box. Licensed under MIT, Chatterbox has been benchmarked against leading closed-source systems like ElevenLabs, and is consistently preferred in side-by-side evaluations. |
| 61 | |
| 62 | Whether you're working on memes, videos, games, or AI agents, Chatterbox brings your content to life. It's also the first open source TTS model to support **emotion exaggeration control**, a powerful feature that makes your voices stand out. Try it now on our [Hugging Face Gradio app.](https://huggingface.co/spaces/ResembleAI/Chatterbox) |
| 63 | |
| 64 | If you like the model but need to scale or tune it for higher accuracy, check out our competitively priced TTS service (<a href="https://resemble.ai">link</a>). It delivers reliable performance with ultra-low latency of sub 200ms—ideal for production use in agents, applications, or interactive media. |
| 65 | |
| 66 | # Key Details |
| 67 | - Multilingual, zero-shot TTS supporting 23 languages |
| 68 | - SoTA zeroshot English TTS |
| 69 | - 0.5B Llama backbone |
| 70 | - Unique exaggeration/intensity control |
| 71 | - Ultra-stable with alignment-informed inference |
| 72 | - Trained on 0.5M hours of cleaned data |
| 73 | - Watermarked outputs |
| 74 | - Easy voice conversion script |
| 75 | - [Outperforms ElevenLabs](https://podonos.com/resembleai/chatterbox) |
| 76 | |
| 77 | # Tips |
| 78 | - **General Use (TTS and Voice Agents):** |
| 79 | - The default settings (`exaggeration=0.5`, `cfg=0.5`) work well for most prompts. |
| 80 | - If the reference speaker has a fast speaking style, lowering `cfg` to around `0.3` can improve pacing. |
| 81 | |
| 82 | - **Expressive or Dramatic Speech:** |
| 83 | - Try lower `cfg` values (e.g. `~0.3`) and increase `exaggeration` to around `0.7` or higher. |
| 84 | - Higher `exaggeration` tends to speed up speech; reducing `cfg` helps compensate with slower, more deliberate pacing. |
| 85 | |
| 86 | |
| 87 | ***Note:*** Ensure that the reference clip matches the specified language tag. Otherwise, language transfer outputs may inherit the accent of the reference clip’s language. |
| 88 | ***To mitigate this, set the CFG weight to 0.*** |
| 89 | |
| 90 | |
| 91 | # Installation |
| 92 | ``` |
| 93 | pip install chatterbox-tts |
| 94 | ``` |
| 95 | |
| 96 | |
| 97 | # Usage |
| 98 | ```python |
| 99 | import torchaudio as ta |
| 100 | from chatterbox.tts import ChatterboxTTS |
| 101 | |
| 102 | model = ChatterboxTTS.from_pretrained(device="cuda") |
| 103 | |
| 104 | text = "Ezreal and Jinx teamed up with Ahri, Yasuo, and Teemo to take down the enemy's Nexus in an epic late-game pentakill." |
| 105 | wav = model.generate(text) |
| 106 | ta.save("test-1.wav", wav, model.sr) |
| 107 | |
| 108 | # If you want to synthesize with a different voice, specify the audio prompt |
| 109 | AUDIO_PROMPT_PATH="YOUR_FILE.wav" |
| 110 | wav = model.generate(text, audio_prompt_path=AUDIO_PROMPT_PATH) |
| 111 | ta.save("test-2.wav", wav, model.sr) |
| 112 | ``` |
| 113 | |
| 114 | # Multilingual Quickstart |
| 115 | ```python |
| 116 | import torchaudio as ta |
| 117 | from chatterbox.mtl_tts import ChatterboxMultilingualTTS |
| 118 | |
| 119 | multilingual_model = ChatterboxMultilingualTTS.from_pretrained(device="cuda") |
| 120 | |
| 121 | french_text = "Bonjour, comment ça va? Ceci est le modèle de synthèse vocale multilingue Chatterbox, il prend en charge 23 langues." |
| 122 | wav_french = multilingual_model.generate(french_text, language_id="fr") |
| 123 | ta.save("test-french.wav", wav_french, model.sr) |
| 124 | |
| 125 | chinese_text = "你好,今天天气真不错,希望你有一个愉快的周末。" |
| 126 | wav_chinese = multilingual_model.generate(chinese_text, language_id="zh") |
| 127 | ta.save("test-chinese.wav", wav_chinese, model.sr) |
| 128 | ``` |
| 129 | See `example_tts.py` for more examples. |
| 130 | |
| 131 | |
| 132 | # Acknowledgements |
| 133 | - [Cosyvoice](https://github.com/FunAudioLLM/CosyVoice) |
| 134 | - [HiFT-GAN](https://github.com/yl4579/HiFTNet) |
| 135 | - [Llama 3](https://github.com/meta-llama/llama3) |
| 136 | |
| 137 | # Built-in PerTh Watermarking for Responsible AI |
| 138 | |
| 139 | Every audio file generated by Chatterbox includes [Resemble AI's Perth (Perceptual Threshold) Watermarker](https://github.com/resemble-ai/perth) - imperceptible neural watermarks that survive MP3 compression, audio editing, and common manipulations while maintaining nearly 100% detection accuracy. |
| 140 | |
| 141 | # Disclaimer |
| 142 | Don't use this model to do bad things. Prompts are sourced from freely available data on the internet. |