Installation · Quick Start · Models · Usage · FAQ · Demos
--debug to save voice samples at each processing stage to custom_voices/debug/fix-early-eos branch for testing and validationFile Modified: vibevoice/modular/modeling_vibevoice_inference.py
Delayed EOS Processing:
pending_finish_tags tensor to track samples that hit EOS but need to complete current audio chunkSilence Buffer:
torch.zeros_like() to create silent audio with matching chunk dimensionsAudio Gain Control & Trimming:
Files Modified:
vibevoice/modular/modeling_vibevoice_inference.py (EOS fix + silence buffer)main.py (audio gain control)Impact: Reduced audio truncation from ~60% to ~10%, with elimination of "cut off" feeling at audio endings, plus built-in audio editing capabilities.
A comprehensive Gradio interface for generating high-quality multi-speaker dialogue audio using VibeVoice models. This tool provides an intuitive web interface for creating conversational audio content with advanced features and controls.
The --lod flag enables a specialized worker-based architecture that provides true VRAM cleanup after each generation:
Traditional model unloading only marks GPU memory as "unreserved" but PyTorch's CUDA allocator holds onto it for performance. When you kill a process, the OS kernel forcibly reclaims all GPU allocations—this is the only reliable way to truly free PyTorch's reserved CUDA memory.
Recommended for: Systems with limited VRAM, running multiple AI services, or when you need guaranteed memory cleanup between generations.
VibeVoice includes AI-powered vocal isolation to automatically remove background music, noise, and other non-vocal audio from your voice samples. This results in cleaner voice cloning and more consistent output.
The vocal isolation feature uses the Mel-Band-Roformer model, a state-of-the-art audio source separation model. The implementation is based on the ComfyUI-MelBandRoFormer project.
Located in 🎤 Voice Input Settings accordion:
| Option | Default | Description |
|---|---|---|
| Isolate input voices | ✅ Enabled | Remove background music/noise using AI vocal isolation |
| Normalize voices | ❌ Disabled | Normalize volume levels across all voice samples |
When running with --debug, voice samples are saved to custom_voices/debug/ at each processing stage:
{speaker_name}_original.wav - Raw input before any processing{speaker_name}_isolated.wav - After vocal isolation (if enabled){speaker_name}_normalized.wav - After normalization (if enabled)This helps verify the vocal isolation quality and troubleshoot any issues.
The vocal isolation feature requires additional dependencies (installed automatically with pip install -e .):
pip install rotary-embedding-torch einops
# Basic usage
python main.py
# With load-on-demand mode (faster startup, true VRAM cleanup)
python main.py --lod
# With debug mode
python main.py --debug
# Custom port
python main.py --port 8080
# Use local OpenAI-compatible server
python main.py --lod --debug \
--script-ai-url "http://localhost:11434/v1" \
--script_ai_model "qwen2.5:7b-instruct" \
--script_ai_api_key ""
# Use offline mode for Hugging Face models
python main.py --lod --hf-offline
# Custom cache directory
python main.py --lod --hf-cache-dir "/path/to/cache"
.env-sample to .env and add your API keyscustom_voices/ directory (supports subdirectories)run_vibevoice.bat (easiest)python main.pyVibeVoice includes built-in audio editing capabilities directly in the player:
VibeVoice supports AI-powered script generation using OpenAI or compatible servers. You can configure this via CLI arguments or environment variables.
cp .env-sample .env.env: Add your API keys and preferred settingspython main.py# .env file
OPENAI_API_KEY=sk-your-openai-key-here
OPENAI_MODEL=gpt-4.1-mini # Optional: change default model
Support for local and third-party servers (Ollama, LM Studio, vLLM, etc.):
Via CLI (temporary):
# Local Ollama server
python main.py --lod --debug \
--script-ai-url "http://localhost:11434/v1" \
--script_ai_model "qwen2.5:7b-instruct" \
--script_ai-api-key ""
# Remote server with API key
python main.py --lod --debug \
--script-ai-url "https://api.example.com/v1" \
--script_ai_model "myorg/model-name" \
--script_ai-api-key "your-api-key"
# Google Gemini API
python main.py --lod --debug \
--script-ai-url "https://generativelanguage.googleapis.com/v1beta/openai" \
--script_ai_model "gemini-2.5-flash" \
--script_ai-api-key "your-gemini-api-key"
Via .env file (persistent):
# .env file
SCRIPT_AI_URL=http://localhost:11434/v1
SCRIPT_AI_MODEL=qwen2.5:7b-instruct
SCRIPT_AI_API_KEY=
# Optional: override default OpenAI model
OPENAI_MODEL=gpt-4.1-mini
Settings are applied in this order (later overrides earlier):
gpt-4.1-mini model, OpenAI platform.env file settings/v1/chat/completions endpointchoices[].message.content, choices[].text, and choices[].content/v1 if missingRun VibeVoice without internet access using cached models:
# Force offline mode
python main.py --lod --hf-offline
# Use custom cache directory
python main.py --lod --hf-offline --hf-cache-dir "/shared/cache"
# Environment variable (alternative)
export HF_HUB_OFFLINE=1
python main.py --lod
demo/voices/ (included with the project)custom_voices/ directorycustom_voices/characters/, custom_voices/narrators/)OpenAI Platform: Requires OPENAI_API_KEY in .env file
Custom Servers: API key optional (many local servers don't require one)
Example .env file:
# OpenAI platform (required for default)
OPENAI_API_KEY=sk-your-openai-key-here
# Custom server (optional)
SCRIPT_AI_URL=http://localhost:11434/v1
SCRIPT_AI_MODEL=qwen2.5:7b-instruct
SCRIPT_AI_API_KEY=
# Google Gemini API (alternative)
# SCRIPT_AI_URL=https://generativelanguage.googleapis.com/v1beta/openai
# SCRIPT_AI_MODEL=gemini-2.5-flash
# SCRIPT_AI_API_KEY=your-gemini-api-key
# Default model override (optional)
OPENAI_MODEL=gpt-4.1-mini
VibeVoice is a novel framework designed for generating expressive, long-form, multi-speaker conversational audio, such as podcasts, from text. It addresses significant challenges in traditional Text-to-Speech (TTS) systems, particularly in scalability, speaker consistency, and natural turn-taking.
A core innovation of VibeVoice is its use of continuous speech tokenizers (Acoustic and Semantic) operating at an ultra-low frame rate of 7.5 Hz. These tokenizers efficiently preserve audio fidelity while significantly boosting computational efficiency for processing long sequences. VibeVoice employs a next-token diffusion framework, leveraging a Large Language Model (LLM) to understand textual context and dialogue flow, and a diffusion head to generate high-fidelity acoustic details.
The model can synthesize speech up to 90 minutes long with up to 4 distinct speakers, surpassing the typical 1-2 speaker limits of many prior models.
Video Demo
We produced this video with Wan2.2. We sincerely appreciate the Wan-Video team for their great work.
English
Chinese
Cross-Lingual
Spontaneous Singing
Long Conversation with 4 people
For more examples, see the Project Page.
Try your own samples at Colab or Demo.
| Model | Context Length | Generation Length | Weight |
|---|---|---|---|
| VibeVoice-0.5B-Streaming | - | - | On the way |
| VibeVoice-1.5B | 64K | ~90 min | HF link |
| VibeVoice-7B-Preview | 32K | ~45 min | HF link |
Pick one of the paths below (Direct Install or Docker) and follow it start to finish. Most people should use the Direct Install.
Before you begin, make sure you have the following installed on your system:
| Requirement | Why you need it | How to check |
|---|---|---|
| Python 3.8+ | Runs the application | python --version (or python3 --version) |
| pip | Installs Python packages | pip --version (or pip3 --version) |
| Git | Clones the repository | git --version |
| ffmpeg | Processes audio files | ffmpeg -version |
| NVIDIA GPU + drivers (recommended) | Fast speech generation | nvidia-smi |
Python & pip — Download from python.org. On Linux you can use your package manager:
sudo apt update && sudo apt install python3 python3-pip python3-venv -y # Debian/Ubuntu
Git — Download from git-scm.com, or on Linux:
sudo apt update && sudo apt install git -y # Debian/Ubuntu
ffmpeg — Download from ffmpeg.org, or on Linux:
sudo apt update && sudo apt install ffmpeg -y # Debian/Ubuntu
NVIDIA drivers — Follow the NVIDIA driver install guide for your OS. VibeVoice can fall back to CPU or Apple Silicon (MPS) if no NVIDIA GPU is available, but generation will be significantly slower.
Open a terminal (Command Prompt or PowerShell on Windows) and run these commands one group at a time.
git clone https://github.com/microsoft/VibeVoice.git
cd VibeVoice
This downloads the source code and moves you into the project folder.
A virtual environment keeps VibeVoice's dependencies separate from the rest of your system so nothing conflicts.
Linux / macOS:
python3 -m venv venv
source venv/bin/activate
Windows (Command Prompt):
python -m venv venv
venv\Scripts\activate
Windows (PowerShell):
python -m venv venv
.\venv\Scripts\Activate.ps1
After activation your terminal prompt should show
(venv)at the beginning. All remaining commands assume the virtual environment is active.
PyTorch is the machine-learning framework VibeVoice is built on. Install the version that matches your hardware:
NVIDIA GPU (CUDA 12.1) — recommended:
pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu121
CPU only or Apple Silicon (MPS):
pip install torch torchvision torchaudio
Not sure which to pick? Run
nvidia-smi. If it prints GPU info, use the CUDA version. If it errors, use the CPU version. For other CUDA versions, see the PyTorch install matrix.
pip install -e .
This reads the project's pyproject.toml file and installs everything VibeVoice needs (transformers, gradio, librosa, openai, etc.). The -e ("editable") flag means Python uses the code right here in this folder, so any updates you git pull are picked up automatically.
FlashAttention2 speeds up the model on NVIDIA GPUs. It is not required — VibeVoice falls back to a compatible attention implementation automatically.
pip install flash-attn --no-build-isolation
Windows users: Building from source can be tricky. Pre-built wheels are available at sunsetcoder/flash-attention-windows.
The AI scriptwriter needs an LLM API key. Copy the sample config and edit it:
Linux / macOS:
cp .env-sample .env
nano .env # or open .env in any text editor
Windows:
copy .env-sample .env
notepad .env
Inside .env, replace your-open-ai-key with your actual API key. If you don't have an OpenAI key, you can use a free Google Gemini key — see the comments in .env-sample for details. AI script generation is optional; VibeVoice works without it.
python main.py
After a moment you'll see a local URL (usually http://localhost:7860). Open it in your browser and you're ready to go.
Tip: Add
--lodfor load-on-demand mode, which uses much less VRAM when idle:python main.py --lod
If something went wrong during install, you can run a quick sanity check:
python -c "import torch; print('PyTorch', torch.__version__); print('CUDA available:', torch.cuda.is_available())"
python -c "import vibevoice; print('VibeVoice package OK')"
Docker is useful if you want a pre-configured CUDA environment without installing drivers on the host.
# 1. Launch the NVIDIA PyTorch container (24.07 / 24.10 / 24.12 verified)
sudo docker run --privileged --net=host --ipc=host \
--ulimit memlock=-1:-1 --ulimit stack=-1:-1 \
--gpus all --rm -it nvcr.io/nvidia/pytorch:24.07-py3
# 2. Inside the container, clone and install
git clone https://github.com/microsoft/VibeVoice.git
cd VibeVoice
pip install -e .
# 3. (Optional) Install FlashAttention2 if not bundled in your container
pip install flash-attn --no-build-isolation
# 4. Configure your API key and run
cp .env-sample .env
# edit .env with your API key
python main.py
For Windows users, we provide a convenient batch script:
.env is configured with your API keyrun_vibevoice.bat to launchThe batch script will:
http://localhost:7590Load-on-Demand Mode: Edit
run_vibevoice.bat, comment outpython main.py, and uncommentpython main.py --lod.
VibeVoice supports multiple hardware configurations with automatic fallback:
We observed users may encounter occasional instability when synthesizing Chinese speech. We recommend:
# Make sure ffmpeg is installed (see Prerequisites above)
# For 1.5B model
python demo/gradio_demo.py --model_path microsoft/VibeVoice-1.5B
# For 7B model
python demo/gradio_demo.py --model_path WestZhang/VibeVoice-Large-pt
# We provide some LLM generated example scripts under demo/text_examples/ for demo
# 1 speaker
python demo/inference_from_file.py --model_path WestZhang/VibeVoice-Large-pt --txt_path demo/text_examples/1p_abs.txt --speaker_names Alice
# or more speakers
python demo/inference_from_file.py --model_path WestZhang/VibeVoice-Large-pt --txt_path demo/text_examples/2p_music.txt --speaker_names Alice Frank
A: Yes, it's a pretrained model without any post-training or benchmark-specific optimizations. In a way, this makes VibeVoice very versatile and fun to use.
A: As you can see from our demo page, the background music or sounds are spontaneous. This means we can't directly control whether they are generated or not. The model is content-aware, and these sounds are triggered based on the input text and the chosen voice prompt.
Here are a few things we've noticed:
In fact, we intentionally decided not to denoise our training data because we think it's an interesting feature for BGM to show up at just the right moment. You can think of it as a little easter egg we left for you.
A: We don't perform any text normalization during training or inference. Our philosophy is that a large language model should be able to handle complex user inputs on its own. However, due to the nature of the training data, you might still run into some corner cases.
A: Our training data doesn't contain any music data. The ability to sing is an emergent capability of the model (which is why it might sound off-key, even on a famous song like 'See You Again'). (The 7B model is more likely to exhibit this than the 1.5B).
A: The volume of Chinese data in our training set is significantly smaller than the English data. Additionally, certain special characters (e.g., Chinese quotation marks) may occasionally cause pronunciation issues.
A: The --lod (Load-on-Demand) mode uses a worker-based multiprocessing architecture that provides true VRAM cleanup. Traditional model unloading only marks GPU memory as "unreserved," but PyTorch's CUDA allocator holds onto it for performance. When you use --lod mode, each generation runs in a separate worker process that gets terminated after completion, forcing the OS to reclaim ALL GPU memory. This is the only reliable way to truly free reserved CUDA memory.
Use --lod mode when:
Potential for Deepfakes and Disinformation: High-quality synthetic speech can be misused to create convincing fake audio content for impersonation, fraud, or spreading disinformation. Users must ensure transcripts are reliable, check content accuracy, and avoid using generated content in misleading ways. Users are expected to use the generated content and to deploy the models in a lawful manner, in full compliance with all applicable laws and regulations in the relevant jurisdictions. It is best practice to disclose the use of AI when sharing AI-generated content.
English and Chinese only: Transcripts in languages other than English or Chinese may result in unexpected audio outputs.
Non-Speech Audio: The model focuses solely on speech synthesis and does not handle background noise, music, or other sound effects.
Overlapping Speech: The current model does not explicitly model or generate overlapping speech segments in conversations.
We do not recommend using VibeVoice in commercial or real-world applications without further testing and development. This model is intended for research and development purposes only. Please use responsibly.
We would like to thank the following contributors for their valuable work that enhanced VibeVoice's compatibility and performance:
These contributions have made VibeVoice more accessible across different hardware configurations and operating systems, ensuring a smoother experience for all users.
Python
99.7%
Installation · Quick Start · Models · Usage · FAQ · Demos
--debug to save voice samples at each processing stage to custom_voices/debug/fix-early-eos branch for testing and validationFile Modified: vibevoice/modular/modeling_vibevoice_inference.py
Delayed EOS Processing:
pending_finish_tags tensor to track samples that hit EOS but need to complete current audio chunkSilence Buffer:
torch.zeros_like() to create silent audio with matching chunk dimensionsAudio Gain Control & Trimming:
Files Modified:
vibevoice/modular/modeling_vibevoice_inference.py (EOS fix + silence buffer)main.py (audio gain control)Impact: Reduced audio truncation from ~60% to ~10%, with elimination of "cut off" feeling at audio endings, plus built-in audio editing capabilities.
A comprehensive Gradio interface for generating high-quality multi-speaker dialogue audio using VibeVoice models. This tool provides an intuitive web interface for creating conversational audio content with advanced features and controls.
The --lod flag enables a specialized worker-based architecture that provides true VRAM cleanup after each generation:
Traditional model unloading only marks GPU memory as "unreserved" but PyTorch's CUDA allocator holds onto it for performance. When you kill a process, the OS kernel forcibly reclaims all GPU allocations—this is the only reliable way to truly free PyTorch's reserved CUDA memory.
Recommended for: Systems with limited VRAM, running multiple AI services, or when you need guaranteed memory cleanup between generations.
VibeVoice includes AI-powered vocal isolation to automatically remove background music, noise, and other non-vocal audio from your voice samples. This results in cleaner voice cloning and more consistent output.
The vocal isolation feature uses the Mel-Band-Roformer model, a state-of-the-art audio source separation model. The implementation is based on the ComfyUI-MelBandRoFormer project.
Located in 🎤 Voice Input Settings accordion:
| Option | Default | Description |
|---|---|---|
| Isolate input voices | ✅ Enabled | Remove background music/noise using AI vocal isolation |
| Normalize voices | ❌ Disabled | Normalize volume levels across all voice samples |
When running with --debug, voice samples are saved to custom_voices/debug/ at each processing stage:
{speaker_name}_original.wav - Raw input before any processing{speaker_name}_isolated.wav - After vocal isolation (if enabled){speaker_name}_normalized.wav - After normalization (if enabled)This helps verify the vocal isolation quality and troubleshoot any issues.
The vocal isolation feature requires additional dependencies (installed automatically with pip install -e .):
pip install rotary-embedding-torch einops
# Basic usage
python main.py
# With load-on-demand mode (faster startup, true VRAM cleanup)
python main.py --lod
# With debug mode
python main.py --debug
# Custom port
python main.py --port 8080
# Use local OpenAI-compatible server
python main.py --lod --debug \
--script-ai-url "http://localhost:11434/v1" \
--script_ai_model "qwen2.5:7b-instruct" \
--script_ai_api_key ""
# Use offline mode for Hugging Face models
python main.py --lod --hf-offline
# Custom cache directory
python main.py --lod --hf-cache-dir "/path/to/cache"
.env-sample to .env and add your API keyscustom_voices/ directory (supports subdirectories)run_vibevoice.bat (easiest)python main.pyVibeVoice includes built-in audio editing capabilities directly in the player:
VibeVoice supports AI-powered script generation using OpenAI or compatible servers. You can configure this via CLI arguments or environment variables.
cp .env-sample .env.env: Add your API keys and preferred settingspython main.py# .env file
OPENAI_API_KEY=sk-your-openai-key-here
OPENAI_MODEL=gpt-4.1-mini # Optional: change default model
Support for local and third-party servers (Ollama, LM Studio, vLLM, etc.):
Via CLI (temporary):
# Local Ollama server
python main.py --lod --debug \
--script-ai-url "http://localhost:11434/v1" \
--script_ai_model "qwen2.5:7b-instruct" \
--script_ai-api-key ""
# Remote server with API key
python main.py --lod --debug \
--script-ai-url "https://api.example.com/v1" \
--script_ai_model "myorg/model-name" \
--script_ai-api-key "your-api-key"
# Google Gemini API
python main.py --lod --debug \
--script-ai-url "https://generativelanguage.googleapis.com/v1beta/openai" \
--script_ai_model "gemini-2.5-flash" \
--script_ai-api-key "your-gemini-api-key"
Via .env file (persistent):
# .env file
SCRIPT_AI_URL=http://localhost:11434/v1
SCRIPT_AI_MODEL=qwen2.5:7b-instruct
SCRIPT_AI_API_KEY=
# Optional: override default OpenAI model
OPENAI_MODEL=gpt-4.1-mini
Settings are applied in this order (later overrides earlier):
gpt-4.1-mini model, OpenAI platform.env file settings/v1/chat/completions endpointchoices[].message.content, choices[].text, and choices[].content/v1 if missingRun VibeVoice without internet access using cached models:
# Force offline mode
python main.py --lod --hf-offline
# Use custom cache directory
python main.py --lod --hf-offline --hf-cache-dir "/shared/cache"
# Environment variable (alternative)
export HF_HUB_OFFLINE=1
python main.py --lod
demo/voices/ (included with the project)custom_voices/ directorycustom_voices/characters/, custom_voices/narrators/)OpenAI Platform: Requires OPENAI_API_KEY in .env file
Custom Servers: API key optional (many local servers don't require one)
Example .env file:
# OpenAI platform (required for default)
OPENAI_API_KEY=sk-your-openai-key-here
# Custom server (optional)
SCRIPT_AI_URL=http://localhost:11434/v1
SCRIPT_AI_MODEL=qwen2.5:7b-instruct
SCRIPT_AI_API_KEY=
# Google Gemini API (alternative)
# SCRIPT_AI_URL=https://generativelanguage.googleapis.com/v1beta/openai
# SCRIPT_AI_MODEL=gemini-2.5-flash
# SCRIPT_AI_API_KEY=your-gemini-api-key
# Default model override (optional)
OPENAI_MODEL=gpt-4.1-mini
VibeVoice is a novel framework designed for generating expressive, long-form, multi-speaker conversational audio, such as podcasts, from text. It addresses significant challenges in traditional Text-to-Speech (TTS) systems, particularly in scalability, speaker consistency, and natural turn-taking.
A core innovation of VibeVoice is its use of continuous speech tokenizers (Acoustic and Semantic) operating at an ultra-low frame rate of 7.5 Hz. These tokenizers efficiently preserve audio fidelity while significantly boosting computational efficiency for processing long sequences. VibeVoice employs a next-token diffusion framework, leveraging a Large Language Model (LLM) to understand textual context and dialogue flow, and a diffusion head to generate high-fidelity acoustic details.
The model can synthesize speech up to 90 minutes long with up to 4 distinct speakers, surpassing the typical 1-2 speaker limits of many prior models.
Video Demo
We produced this video with Wan2.2. We sincerely appreciate the Wan-Video team for their great work.
English
Chinese
Cross-Lingual
Spontaneous Singing
Long Conversation with 4 people
For more examples, see the Project Page.
Try your own samples at Colab or Demo.
| Model | Context Length | Generation Length | Weight |
|---|---|---|---|
| VibeVoice-0.5B-Streaming | - | - | On the way |
| VibeVoice-1.5B | 64K | ~90 min | HF link |
| VibeVoice-7B-Preview | 32K | ~45 min | HF link |
Pick one of the paths below (Direct Install or Docker) and follow it start to finish. Most people should use the Direct Install.
Before you begin, make sure you have the following installed on your system:
| Requirement | Why you need it | How to check |
|---|---|---|
| Python 3.8+ | Runs the application | python --version (or python3 --version) |
| pip | Installs Python packages | pip --version (or pip3 --version) |
| Git | Clones the repository | git --version |
| ffmpeg | Processes audio files | ffmpeg -version |
| NVIDIA GPU + drivers (recommended) | Fast speech generation | nvidia-smi |
Python & pip — Download from python.org. On Linux you can use your package manager:
sudo apt update && sudo apt install python3 python3-pip python3-venv -y # Debian/Ubuntu
Git — Download from git-scm.com, or on Linux:
sudo apt update && sudo apt install git -y # Debian/Ubuntu
ffmpeg — Download from ffmpeg.org, or on Linux:
sudo apt update && sudo apt install ffmpeg -y # Debian/Ubuntu
NVIDIA drivers — Follow the NVIDIA driver install guide for your OS. VibeVoice can fall back to CPU or Apple Silicon (MPS) if no NVIDIA GPU is available, but generation will be significantly slower.
Open a terminal (Command Prompt or PowerShell on Windows) and run these commands one group at a time.
git clone https://github.com/microsoft/VibeVoice.git
cd VibeVoice
This downloads the source code and moves you into the project folder.
A virtual environment keeps VibeVoice's dependencies separate from the rest of your system so nothing conflicts.
Linux / macOS:
python3 -m venv venv
source venv/bin/activate
Windows (Command Prompt):
python -m venv venv
venv\Scripts\activate
Windows (PowerShell):
python -m venv venv
.\venv\Scripts\Activate.ps1
After activation your terminal prompt should show
(venv)at the beginning. All remaining commands assume the virtual environment is active.
PyTorch is the machine-learning framework VibeVoice is built on. Install the version that matches your hardware:
NVIDIA GPU (CUDA 12.1) — recommended:
pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu121
CPU only or Apple Silicon (MPS):
pip install torch torchvision torchaudio
Not sure which to pick? Run
nvidia-smi. If it prints GPU info, use the CUDA version. If it errors, use the CPU version. For other CUDA versions, see the PyTorch install matrix.
pip install -e .
This reads the project's pyproject.toml file and installs everything VibeVoice needs (transformers, gradio, librosa, openai, etc.). The -e ("editable") flag means Python uses the code right here in this folder, so any updates you git pull are picked up automatically.
FlashAttention2 speeds up the model on NVIDIA GPUs. It is not required — VibeVoice falls back to a compatible attention implementation automatically.
pip install flash-attn --no-build-isolation
Windows users: Building from source can be tricky. Pre-built wheels are available at sunsetcoder/flash-attention-windows.
The AI scriptwriter needs an LLM API key. Copy the sample config and edit it:
Linux / macOS:
cp .env-sample .env
nano .env # or open .env in any text editor
Windows:
copy .env-sample .env
notepad .env
Inside .env, replace your-open-ai-key with your actual API key. If you don't have an OpenAI key, you can use a free Google Gemini key — see the comments in .env-sample for details. AI script generation is optional; VibeVoice works without it.
python main.py
After a moment you'll see a local URL (usually http://localhost:7860). Open it in your browser and you're ready to go.
Tip: Add
--lodfor load-on-demand mode, which uses much less VRAM when idle:python main.py --lod
If something went wrong during install, you can run a quick sanity check:
python -c "import torch; print('PyTorch', torch.__version__); print('CUDA available:', torch.cuda.is_available())"
python -c "import vibevoice; print('VibeVoice package OK')"
Docker is useful if you want a pre-configured CUDA environment without installing drivers on the host.
# 1. Launch the NVIDIA PyTorch container (24.07 / 24.10 / 24.12 verified)
sudo docker run --privileged --net=host --ipc=host \
--ulimit memlock=-1:-1 --ulimit stack=-1:-1 \
--gpus all --rm -it nvcr.io/nvidia/pytorch:24.07-py3
# 2. Inside the container, clone and install
git clone https://github.com/microsoft/VibeVoice.git
cd VibeVoice
pip install -e .
# 3. (Optional) Install FlashAttention2 if not bundled in your container
pip install flash-attn --no-build-isolation
# 4. Configure your API key and run
cp .env-sample .env
# edit .env with your API key
python main.py
For Windows users, we provide a convenient batch script:
.env is configured with your API keyrun_vibevoice.bat to launchThe batch script will:
http://localhost:7590Load-on-Demand Mode: Edit
run_vibevoice.bat, comment outpython main.py, and uncommentpython main.py --lod.
VibeVoice supports multiple hardware configurations with automatic fallback:
We observed users may encounter occasional instability when synthesizing Chinese speech. We recommend:
# Make sure ffmpeg is installed (see Prerequisites above)
# For 1.5B model
python demo/gradio_demo.py --model_path microsoft/VibeVoice-1.5B
# For 7B model
python demo/gradio_demo.py --model_path WestZhang/VibeVoice-Large-pt
# We provide some LLM generated example scripts under demo/text_examples/ for demo
# 1 speaker
python demo/inference_from_file.py --model_path WestZhang/VibeVoice-Large-pt --txt_path demo/text_examples/1p_abs.txt --speaker_names Alice
# or more speakers
python demo/inference_from_file.py --model_path WestZhang/VibeVoice-Large-pt --txt_path demo/text_examples/2p_music.txt --speaker_names Alice Frank
A: Yes, it's a pretrained model without any post-training or benchmark-specific optimizations. In a way, this makes VibeVoice very versatile and fun to use.
A: As you can see from our demo page, the background music or sounds are spontaneous. This means we can't directly control whether they are generated or not. The model is content-aware, and these sounds are triggered based on the input text and the chosen voice prompt.
Here are a few things we've noticed:
In fact, we intentionally decided not to denoise our training data because we think it's an interesting feature for BGM to show up at just the right moment. You can think of it as a little easter egg we left for you.
A: We don't perform any text normalization during training or inference. Our philosophy is that a large language model should be able to handle complex user inputs on its own. However, due to the nature of the training data, you might still run into some corner cases.
A: Our training data doesn't contain any music data. The ability to sing is an emergent capability of the model (which is why it might sound off-key, even on a famous song like 'See You Again'). (The 7B model is more likely to exhibit this than the 1.5B).
A: The volume of Chinese data in our training set is significantly smaller than the English data. Additionally, certain special characters (e.g., Chinese quotation marks) may occasionally cause pronunciation issues.
A: The --lod (Load-on-Demand) mode uses a worker-based multiprocessing architecture that provides true VRAM cleanup. Traditional model unloading only marks GPU memory as "unreserved," but PyTorch's CUDA allocator holds onto it for performance. When you use --lod mode, each generation runs in a separate worker process that gets terminated after completion, forcing the OS to reclaim ALL GPU memory. This is the only reliable way to truly free reserved CUDA memory.
Use --lod mode when:
Potential for Deepfakes and Disinformation: High-quality synthetic speech can be misused to create convincing fake audio content for impersonation, fraud, or spreading disinformation. Users must ensure transcripts are reliable, check content accuracy, and avoid using generated content in misleading ways. Users are expected to use the generated content and to deploy the models in a lawful manner, in full compliance with all applicable laws and regulations in the relevant jurisdictions. It is best practice to disclose the use of AI when sharing AI-generated content.
English and Chinese only: Transcripts in languages other than English or Chinese may result in unexpected audio outputs.
Non-Speech Audio: The model focuses solely on speech synthesis and does not handle background noise, music, or other sound effects.
Overlapping Speech: The current model does not explicitly model or generate overlapping speech segments in conversations.
We do not recommend using VibeVoice in commercial or real-world applications without further testing and development. This model is intended for research and development purposes only. Please use responsibly.
We would like to thank the following contributors for their valuable work that enhanced VibeVoice's compatibility and performance:
These contributions have made VibeVoice more accessible across different hardware configurations and operating systems, ensuring a smoother experience for all users.
Python
99.7%