Downloads · 30 days
27
55% of all-time downloads
STIAMO/Xiaomi-CocktailASR-1-safetensors
Xiaomi-CocktailASR-1-safetensors is a automatic speech recognition model from STIAMO. Use it when you need speech turned into text. It is set up for transformers. The card lists the license as apache-2.0.
This repository provides the safetensors edition of Ease3/Xiaomi-CocktailASR-1, converted to 4-shard bfloat16 safetensors format (~16.5 GB total) with out-of-the-box support for INT8 mixed-precision quantization (bits…
Downloads · 30 days
27
55% of all-time downloads
All-time downloads
49
Public
Parameters
8.9B
17.8 GB on disk
Likes
1
Public
Click a slice to open those files.
.safetensors17.8 GB · 100%
From the Hugging Face model README
This repository provides the safetensors edition of Ease3/Xiaomi-CocktailASR-1, converted to 4-shard bfloat16 safetensors format (~16.5 GB total) with out-of-the-box support for INT8 mixed-precision quantization (bitsandbytes).
pytorch_model.bin zip archive. On Windows platforms running PyTorch, loading large .bin checkpoints causes a critical memory mapping access violation (0xC0000005) due to a PyTorch Windows mmap limitation. This safetensors version resolves the issue completely by using native pread block streaming.audio_encoder & lm_head in BF16, Qwen3-8B backbone in INT8), fitting comfortably in 9.99 GB VRAM with RTF < 0.5 on modern GPUs (e.g., RTX 5060 Ti / RTX 4080 / RTX 3090).pip install torch torchaudio transformers accelerate bitsandbytes soundfile
import torch
import soundfile as sf
import torchaudio
from transformers import AutoModel, BitsAndBytesConfig
# Windows-safe audio decoding
def _patched_load(audio, **kwargs):
wav, sr = sf.read(audio, dtype="float32")
t = torch.from_numpy(wav)
return (t.unsqueeze(0) if t.ndim == 1 else t.t()), sr
torchaudio.load = _patched_load
# Configure INT8 quantization (preserve Audio Encoder and LM Head in BF16)
quant_config = BitsAndBytesConfig(
load_in_8bit=True,
llm_int8_threshold=6.0,
llm_int8_skip_modules=[
"audio_encoder",
"audio_encoder.encoder",
"audio_encoder.in_proj",
"audio_encoder.out_proj",
"lm_head",
],
)
model = AutoModel.from_pretrained(
"STIAMO/Xiaomi-CocktailASR-1-safetensors",
trust_remote_code=True,
quantization_config=quant_config,
torch_dtype=torch.bfloat16,
device_map={"": 0},
low_cpu_mem_usage=True,
).eval()
# Standard Transcription
text = model("target.wav", "ref_speaker.wav", cot=False)
print("Transcription:", text)
# Chain-of-Thought (CoT) Transcription
text_cot = model("target.wav", "ref_speaker.wav", cot=True)
print("CoT Output:", text_cot)
| Metric | Measured Value | Note |
|---|---|---|
| Model VRAM Footprint | 9.99 GB | INT8 Qwen3 backbone + BF16 Data2Vec2 |
| Peak VRAM (Allocated) | 10.39 GB | Standard target inference |
| Peak VRAM (Reserved) | 11.19 GB | Standard target inference |
| Real-Time Factor (RTF) | 0.570 (6.9s audio) / 0.467 (27.6s audio) | >1.7x faster than real-time |
| Model Load Time | ~22 seconds | Fast streaming safetensors |
This model is distributed under the Apache License 2.0.
Original model by Xiaomi Research: