OpenBMB/VoxCPM
๐ https://github.com/OpenBMB/VoxCPM โVoxCPM2: Tokenizer-Free TTS for Multilingual Speech Generation, Creative Voice Design, and True-to-Life Cloning English | ไธญๆ ๐ Join our community for discussion and support! Feishu | Discord | ๐ MiniCPM Wiki VoxCPM is a tokenizer-free Text-to-Speech system that directly generates continuous speech representations via an end-to-end diffusion autoregressive architecture , bypassing discrete tokenization to achieve highly natural and expressive synthesis. VoxCPM2 is the latest major release โ a 2B parameter model trained on over 2 million hours of multilingual speech data, now supporting 30 languages , Voice Design , Controllable Voice Cloning , and 48kHz studio-quality audio output. Built on a MiniCPM-4 backbone. โจ Highlights ๐ 30-Language Multilingual โ Input text in any of the 30 supported languages and synthesize directly, no language tag needed ๐จ Voice Design โ Create a brand-new voice from a natural-language description alone (gender, age, tone, emotion, pace โฆ), no reference audio required ๐๏ธ Controllable Cloning โ Clone any voice from a short reference clip, with optional style guidance to steer emotion, pace, and expression while preserving the original timbre ๐๏ธ Ultimate Cloning โ Reproduce every vocal nuance: provide both reference audio and its transcript, and the model continues seamlessly from the reference, faithfully preserving every vocal detail โ timbre, rhythm, emotion, and style (same as VoxCPM1.5) ๐ 48kHz High-Quality Audio โ Accepts 16kHz reference audio and directly outputs 48kHz studio-quality audio via AudioVAE V2's asymmetric encode/decode design, with built-in super-resolution โ no external upsampler needed ๐ง Context-Aware Synthesis โ Automatically infers appropriate prosody and expressiveness from text content โก Real-Time Streaming โ RTF as low as ~0.3 on NVIDIA RTX 4090, and ~0.13 accelerated by Nano-vLLM or vLLM-Omni โ official vLLM omni-modal serving for VoxCPM2 with PagedAttention and an OpenAI-compatible API ๐ Fully Open-Source & Commercial-Ready โ Weights and code released under the Apache-2.0 license, free for commercial use ๐ Supported Languages (30) Arabic, Burmese, Chinese, Danish, Dutch, English, Finnish, French, German, Greek, Hebrew, Hindi, Indonesian, Italian, Japanese, Khmer, Korean, Lao, Malay, Norwegian, Polish, Portuguese, Russian, Spanish, Swahili, Swedish, Tagalog, Thai, Turkish, Vietnamese Chinese Dialect: ๅๅท่ฉฑ, ็ฒต่ช, ๅณ่ช, ๆฑๅ่ฉฑ, ๆฒณๅ่ฉฑ, ้่ฅฟ่ฉฑ, ๅฑฑๆฑ่ฉฑ, ๅคฉๆดฅ่ฉฑ, ้ฉๅ่ฉฑ News [2026.04] ๐ฅ We release VoxCPM2 โ 2B, 30 languages, Voice Design & Controllable Voice Cloning, 48kHz audio output! Weights | Docs | Playground | Technical Report [2025.12] ๐ Open-source VoxCPM1.5 weights with SFT & LoRA fine-tuning. ( ๐ #1 GitHub Trending ) [2025.09] ๐ฅ Release VoxCPM Technical Report . [2025.09] ๐ Open-source VoxCPM-0.5B weights ( ๐ #1 HuggingFace Trending ) Contents Quick Start Installation Python API CLI Usage Web Demo Production Deployment On-Device Inference (llama.cpp-omni) Models & Versions Performance Fine-tuning Documentation Ecosystem & Community Risks and Limitations Citation ๐ Quick Start Installation pip install voxcpm Requirements: Python โฅ 3.10 (<3.13), PyTorch โฅ 2.5.0, CUDA โฅ 12.0. See Quick Start Docs for details. Python API ๐ฃ๏ธ Text-to-Speech from voxcpm import VoxCPM import soundfile as sf model = VoxCPM . from_pretrained ( "openbmb/VoxCPM2" , load_denoiser = False , ) wav = model . generate ( text = "VoxCPM2 is the current recommended release for realistic multilingual speech synthesis." , cfg_value = 2.0 , inference_timesteps = 10 , seed = 42 , ) sf . write ( "demo.wav" , wav , model . tts_model . sample_rate ) print ( "saved: demo.wav" ) If you prefer downloading from ModelScope first, you can use: pip install modelscope from modelscope import snapshot_download snapshot_download ( "OpenBMB/VoxCPM2" , local_dir = './pretrained_models/VoxCPM2' ) # specify the local directory to save the model from voxcpm import VoxCPM import soundfile as sf model = VoxCPM . from_pretrained ( "./pretrained_models/VoxCPM2" , load_denoiser = False ) wav = model . generate ( text = "VoxCPM2 is the current recommended release for realistic multilingual speech synthesis." , cfg_value = 2.0 , inference_timesteps = 10 , seed = 42 , ) sf . write ( "demo.wav" , wav , model . tts_model . sample_rate ) ๐จ Voice Design Create a voice from a natural-language description โ no reference audio needed. Format: put the description in parentheses at the start of text (e.g. "(your voice description)The text to synthesize." ): wav = model . generate ( text = "(A young woman, gentle and sweet voice)Hello, welcome to VoxCPM2!" , cfg_value = 2.0 , inference_timesteps = 10 , seed = 42 , ) sf . write ( "voice_design.wav" , wav , model . tts_model . sample_rate ) ๐๏ธ Controllable Voice Cloning Upload a reference audio. The model clones the timbre, and you can still use control instructions to adjust speed, emotion, or style. wav = model . generate ( text = "This is a cloned voice generated by VoxCPM2." , reference_wav_path = "path/to/voice.wav" , ) sf . write ( "clone.wav" , wav , model . tts_model . sample_rate ) wav = model . generate ( text = "(slightly faster, cheerful tone)This is a cloned voice with style control." , reference_wav_path = "path/to/voice.wav" , cfg_value = 2.0 , inference_timesteps = 10 , seed = 42 , ) sf . write ( "controllable_clone.wav" , wav , model . tts_model . sample_rate ) ๐๏ธ Ultimate Cloning Provide both the reference audio and its exact transcript for audio-continuation-based cloning with every vocal nuance reproduced. For maximum cloning similarity, pass the same reference clip to both reference_wav_path and prompt_wav_path as shown below: wav = model . generate ( text = "This is an ultimate cloning demonstration using VoxCPM2." , prompt_wav_path = "path/to/voice.wav" , prompt_text = "The transcript of the reference audio." , reference_wav_path = "path/to/voice.wav" , # optional, for better simliarity ) sf . write ( "hifi_clone.wav" , wav , model . tts_model . sample_rate ) ๐ Streaming API import numpy as np chunks = [] for chunk in model . generate_streaming ( text = "Streaming text to speech is easy with VoxCPM!" , ): chunks . append ( chunk ) wav = np . concatenate ( chunks ) sf . write ( "streaming.wav" , wav , model . tts_model . sample_rate ) CLI Usage # Voice design (no reference audio needed) voxcpm design \ --text " VoxCPM2 brings studio-quality multilingual speech synthesis. " \ --output out.wav # Controllable voice cloning with style control voxcpm design \ --text " VoxCPM2 brings studio-quality multilingual speech synthesis. " \ --control " Young female voice, warm and gentle, slightly smiling " \ --seed 42 \ --output out.wav # Voice cloning (reference audio) voxcpm clone \ --text " This is a voice cloning demo. " \ --reference-audio path/to/voice.wav \ --output out.wav # Ultimate cloning (prompt audio + transcript) voxcpm clone \ --text " This is a voice cloning demo. " \ --prompt-audio path/to/voice.wav \ --prompt-text " reference transcript " \ --reference-audio path/to/voice.wav \ # optional, for better simliarity --output out.wav # Batch processing voxcpm batch --input examples/input.txt --output-dir outs # Optional post-generation timestamps with stable-ts pip install " voxcpm[timestamps] " voxcpm design \ --text " VoxCPM2 brings studio-quality multilingual speech synthesis. " \ --output out.wav \ --timestamps \ --timestamp-level word \ --timestamp-language en # Character timestamps are best-effort and are derived from word alignment voxcpm design \ --text " ๆญก่ฟไฝฟ็จ VoxCPM2ใ " \ --output out.wav \ --timestamps \ --timestamp-level char \ --timestamp-language zh # Help voxcpm --help Web Demo python app.py --port 8808 # then open in browser: http://localhost:8808 Use --device to choose the runtime device: python app.py --device auto Supported values are auto , cpu , mps , cuda , and cuda:N . On Apple Silicon Macs, auto uses MPS when available.
ๅ งๅฎน็บๆถ้็ถๆฅๆๅ็ repo ๆ่ฟฐๅๆ๏ผๅฎๆด่ณ่จ่ซ่ฆ GitHub ๅ้ ใ