Downloads · 30 days
192
11% of all-time downloads
marksverdhai/vibevoice-7b-bnb-8bit
vibevoice-7b-bnb-8bit is a text-to-speech model from marksverdhai. Use it when you need text read aloud. It is set up for transformers. The card lists the license as apache-2.0.
Pre-quantized 8-bit version of VibeVoice-7B using bitsandbytes LLM.int8() quantization.
Downloads · 30 days
192
11% of all-time downloads
All-time downloads
1.8K
Public
Parameters
9.3B
12.2 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors12.2 GB · 100%
How the weights are stored.
I86.5B · 70%
From the Hugging Face model README
Pre-quantized 8-bit version of VibeVoice-7B using bitsandbytes LLM.int8() quantization.
| Precision | VRAM | Model Size |
|---|---|---|
| Full (bf16) | ~17 GB | ~14 GB |
| INT8 (this model) | ~11.4 GB | ~11.3 GB |
| INT4 (bnb-4bit) | ~6.2 GB | ~4.2 GB |
Saves ~5.6 GB VRAM compared to full precision.
This model uses a hybrid quantization approach:
The following modules are kept in full precision because LLM.int8() causes numerical instability in audio generation:
acoustic_tokenizer - Audio encoder/decoder VAE
semantic_tokenizer - Semantic audio encoder
prediction_head - Diffusion head for audio generation
acoustic_connector - Bridge between LM and acoustic features
semantic_connector - Bridge between LM and semantic features
lm_head - Text output head
This is why the model uses more VRAM than a fully-quantized INT8 model would.
from transformers import BitsAndBytesConfig
from vibevoice.modular.modeling_vibevoice_inference import VibeVoiceForConditionalGenerationInference
from vibevoice.processor.vibevoice_processor import VibeVoiceProcessor
import torch
# The model already has quantization config embedded
model = VibeVoiceForConditionalGenerationInference.from_pretrained(
"marksverdhai/vibevoice-7b-bnb-8bit",
device_map={"": 0},
torch_dtype=torch.bfloat16,
)
processor = VibeVoiceProcessor.from_pretrained("marksverdhai/vibevoice-7b-bnb-8bit")
# Generate speech
model.eval()
model.set_ddpm_inference_steps(num_steps=10)
inputs = processor(
text=["Speaker 1: Hello, this is a test of the quantized model."],
padding=True,
return_tensors="pt",
return_attention_mask=True,
)
for k, v in inputs.items():
if torch.is_tensor(v):
inputs[k] = v.to("cuda:0")
with torch.no_grad():
outputs = model.generate(
**inputs,
cfg_scale=1.3,
tokenizer=processor.tokenizer,
generation_config={"do_sample": False},
is_prefill=False,
)
audio = outputs.speech_outputs[0] # 24kHz audio tensor
# With voice reference
inputs = processor(
text=["Speaker 1: Hello in a cloned voice!"],
voice_samples=[["path/to/reference.wav"]],
padding=True,
return_tensors="pt",
return_attention_mask=True,
)
# Important: Set is_prefill=True for voice cloning
outputs = model.generate(
**inputs,
cfg_scale=1.3,
tokenizer=processor.tokenizer,
is_prefill=True, # Required for voice cloning!
)
from models.vibevoice import VibeVoiceModel
model = VibeVoiceModel(
model_path="marksverdhai/vibevoice-7b-bnb-8bit",
device="cuda:0",
quantization="bnb-8bit",
)
model.load()
audio, sr = model.generate(
text="Hello world!",
speaker_name="alloy",
)
During testing, we discovered that fully quantizing all modules with LLM.int8() produced pure noise instead of speech. The root cause:
NF4 (4-bit) doesn't have this issue because it always dequantizes to bfloat16 before computation.
The model is saved with this configuration:
BitsAndBytesConfig(
load_in_8bit=True,
llm_int8_skip_modules=[
"acoustic_tokenizer",
"semantic_tokenizer",
"prediction_head",
"acoustic_connector",
"semantic_connector",
"lm_head",
],
)
Apache 2.0 (same as base model)
@misc{vibevoice7b-int8,
title={VibeVoice-7B INT8 Quantized},
author={marksverdhei},
year={2025},
publisher={HuggingFace},
url={https://huggingface.co/marksverdhai/vibevoice-7b-bnb-8bit}
}