VoxCPM2
Synthesize expressive 48 kHz speech across 30 languages using OpenBMB’s VoxCPM2 text-to-speech model.
VoxCPM2 is a 2B-parameter multilingual speech model supporting voice cloning, transcript-assisted Ultimate Cloning, and natural-language Voice Design. TomoriBot connects to the official voxcpm Python library through the server in servers/tts/voxcpm2/, running the official unquantized openbmb/VoxCPM2 BF16 checkpoint comfortably within 16 GB of VRAM.
License
Section titled “License”VoxCPM2 code and model weights are released under Apache-2.0, including commercial use subject to the license terms. TomoriBot does not redistribute the weights; the installer downloads them from the official Hugging Face repository.
Official upstream resources:
Supported languages
Section titled “Supported languages”VoxCPM2 officially supports 30 languages without requiring a language tag:
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, and Vietnamese.
OpenBMB also documents several Chinese dialects. TomoriBot may still send a language field for compatibility with the common TTS contract, but VoxCPM2 detects the language from the synthesis text and the wrapper does not force a language tag.
Voice modes
Section titled “Voice modes”Use Auto and Plain markup for cloning and voice design. A reference transcript enables Ultimate Cloning; a delivery instruction takes precedence and omits the transcript for that request.
Hardware and runtime
Section titled “Hardware and runtime”Recommended starting point:
- Python 3.10-3.12 (required by both installers)
- NVIDIA GPU with 8 GB VRAM or more for the official BF16 runtime (12-16 GB gives comfortable headroom), or Apple Silicon with sufficient unified memory for the 2B model
- CPU is supported as a fallback but is substantially slower
When running on CUDA, VOXCPM2_OPTIMIZE=1 (the default) compiles the model with torch.compile and Triton: the first start takes about 2-3 minutes while PyTorch compiles the model, later starts take under a minute with cached kernels, and synthesis runs roughly 2.5-3x faster than uncompiled while using about 2 GB more system memory. If Triton is missing on a CUDA setup, rerun the installer or set VOXCPM2_OPTIMIZE=0.
On non-CUDA devices (CPU and Apple Silicon mps), the wrapper leaves the VOXCPM2_OPTIMIZE Triton guard inactive so startup does not require Triton, and VOXCPM2_LOAD_DENOISER=0 keeps the CPU-bound denoiser disabled by default.
Installation
Section titled “Installation”The server pins the current stable voxcpm 2.0.3 package and downloads openbmb/VoxCPM2 into the normal Hugging Face cache. Run the installer for your OS from the TomoriBot repository root:
The PowerShell installer runs natively (WSL is not required) and installs CUDA-enabled PyTorch 2.10 (cu128) plus triton-windows for VOXCPM2_OPTIMIZE=1:
.\servers\tts\voxcpm2\install-voxcpm2.ps1.\servers\tts\voxcpm2\.venv\Scripts\python.exe servers\tts\voxcpm2\server.pyOn a CPU-only machine without an NVIDIA GPU, pass -Cpu:
.\servers\tts\voxcpm2\install-voxcpm2.ps1 -CpuIf native Windows PyTorch ever needs a manual CUDA reinstall or driver realignment:
.\servers\tts\voxcpm2\.venv\Scripts\pip.exe install --force-reinstall torch==2.10.0 torchaudio==2.10.0 --index-url https://download.pytorch.org/whl/cu128.\servers\tts\voxcpm2\.venv\Scripts\pip.exe install "triton-windows>=3.6,<3.7"bash servers/tts/voxcpm2/install-voxcpm2.shservers/tts/voxcpm2/.venv/bin/python servers/tts/voxcpm2/server.pyStandard Linux PyPI torch wheels include CUDA support and Triton for VOXCPM2_OPTIMIZE=1. Set VOXCPM2_OPTIMIZE=0 before starting server.py if you run uncompiled or on CPU.
Ensure Python 3.10-3.12 is active (for example PYTHON_BIN=python3.12), then run the shell installer:
bash servers/tts/voxcpm2/install-voxcpm2.shservers/tts/voxcpm2/.venv/bin/python servers/tts/voxcpm2/server.pyWith VOXCPM2_DEVICE=auto, upstream voxcpm uses Apple Silicon mps when available or cpu otherwise. If you hit an unsupported MPS operator on your macOS/PyTorch version, start with VOXCPM2_DEVICE=cpu (slower) or VOXCPM2_OPTIMIZE=0. You may need brew install ffmpeg if audio tooling in the environment requests it.
The first setup downloads several gigabytes of model weights. To install the Python environment without prefetching the model (so voxcpm downloads the checkpoint on first server start instead), set VOXCPM2_PREFETCH=0:
$env:VOXCPM2_PREFETCH = "0".\servers\tts\voxcpm2\install-voxcpm2.ps1VOXCPM2_PREFETCH=0 bash servers/tts/voxcpm2/install-voxcpm2.shVOXCPM2_PREFETCH=0 bash servers/tts/voxcpm2/install-voxcpm2.shAfter setup, bun run launch --voxcpm2 starts the server together with TomoriBot. The default endpoint is http://127.0.0.1:8016.
Register in TomoriBot
Section titled “Register in TomoriBot”Run /providers, choose Add New Custom Endpoint, and configure the Speech endpoint:
- Capability:
Speech - API Compatibility:
tts-clone - Endpoint URL:
http://127.0.0.1:8016 - Voice Source Mode:
Auto - Script Markup:
Plain - Supports Instruct:
Yes
After saving the connection, select it and use its model dropdown to add a Speech model. Then open /config > Models > Switch Models and select the VoxCPM2 speech model.
Auto is recommended because the same server supports reference-audio cloning and Voice Design. You do not need separate VoxCPM2 processes for the two modes.
Persona voice cloning
Section titled “Persona voice cloning”For a persona that should clone an existing speaker:
- Prepare a clean reference clip with one speaker and little or no background music. Upstream treats 5 to 30 seconds as the practical range.
- Open
/configunder Models > TTS Parameters & Voices and upload the clip. - Add the exact transcript of the reference clip when available. VoxCPM2 uses it for Ultimate Cloning and can reproduce more of the reference rhythm, emotion, and style.
- Open
/configunder Persona > Voice, choose the persona, and assign the saved sample.
If no transcript is stored, VoxCPM2 still performs normal reference-audio cloning.
Persona voice design
Section titled “Persona voice design”For a persona that should be created from a written voice description instead of a sample:
- Open
/configunder Persona > Voice and choose VoiceDesign. - Choose the persona.
- Enter a natural-language description such as
Young adult woman, soft warm voice, relaxed pace, slightly playful delivery.
For a cloned voice, one-off delivery instructions take precedence over the reference transcript.
Environment variables
Section titled “Environment variables”| Variable | Default | Purpose |
|---|---|---|
VOXCPM2_MODEL_ID | openbmb/VoxCPM2 | Hugging Face model ID or local model directory |
VOXCPM2_DEVICE | auto | Runtime device: auto, cuda, cuda:N, cpu, or mps |
VOXCPM2_OPTIMIZE | 1 | Compile the model with torch.compile on CUDA; needs Triton, and the server stops at startup without it |
VOXCPM2_LOAD_DENOISER | 0 | Load the optional upstream denoiser; disabled by default to save memory |
VOXCPM2_CFG_VALUE | 2.0 | Guidance strength |
VOXCPM2_INFERENCE_TIMESTEPS | 10 | Flow-matching inference steps; more can improve quality at the cost of speed |
VOXCPM2_MAX_LEN | 4096 | Maximum generation length |
VOXCPM2_NORMALIZE | 0 | Enable upstream text normalization |
VOXCPM2_RETRY_BADCASE | 1 | Enable upstream retry behavior for abnormal generations |
VOXCPM2_RETRY_BADCASE_MAX_TIMES | 3 | Maximum automatic retries |
VOXCPM2_RETRY_BADCASE_RATIO_THRESHOLD | 6.0 | Upstream bad-case length threshold |
VOXCPM2_PREFETCH | 1 | Installer only: download the model during setup |
VOXCPM2_PORT | 8016 | VoxCPM2 local server port |
TOMORI_TTS_HOST | 127.0.0.1 | Local server bind address; see Network access |
Reference audio must be a non-empty WAV container of at most 10 MB decoded, which the wrapper checks before writing a temporary file.