twmht's picture
Add CTranslate2 float32 conversion of MediaTek-Research/Breeze-ASR-26
09663bf verified
|
Raw History Blame Contribute Delete
4.59 kB
---
license: apache-2.0
language:
- nan
- zh
base_model: MediaTek-Research/Breeze-ASR-26
pipeline_tag: automatic-speech-recognition
library_name: ctranslate2
tags:
- automatic-speech-recognition
- whisper
- ctranslate2
- faster-whisper
- taiwanese-hokkien
- taigi
---
# Breeze-ASR-26 (CTranslate2, float32)
This is an unofficial CTranslate2 conversion of [MediaTek-Research/Breeze-ASR-26](https://huggingface.co/MediaTek-Research/Breeze-ASR-26), a Whisper-large-v2 model fine-tuned for Taiwanese Hokkien (Taigi). It is made for use with [faster-whisper](https://github.com/SYSTRAN/faster-whisper) and other CTranslate2 runtimes. It is not published or endorsed by MediaTek Research. The weights are unchanged and keep the original Apache-2.0 license.
The model transcribes Taigi speech into **Mandarin Chinese characters**, not Tâi-lô or Taigi orthography. See the original model card for the training data, benchmark and limitations.
## Conversion
```bash
ct2-transformers-converter --model MediaTek-Research/Breeze-ASR-26 \
--output_dir Breeze-ASR-26-ct2-float32 --quantization float32 \
--copy_files preprocessor_config.json
```
- ctranslate2 4.8.5, transformers 5.20.2.
- The original repository has no `tokenizer.json`. It was generated from the original tokenizer (`AutoTokenizer.from_pretrained(...).backend_tokenizer.save("tokenizer.json")`). The vocabulary has 51,865 entries, the same as Whisper large-v2.
- `model.bin` is about 6.2 GB. Use `compute_type="float16"` or `"int8_float16"` at load time to run it with less memory. These types are converted when the model loads, and they were not tested here.
## Usage
```python
from faster_whisper import WhisperModel
model = WhisperModel("twmht/Breeze-ASR-26-ct2-float32", device="cuda", compute_type="float16")
segments, info = model.transcribe(
"audio.wav",
language="zh",
beam_size=5,
no_repeat_ngram_size=8,
)
print("".join(s.text for s in segments))
```
Set `language="zh"`. The model has no Taigi language token, and the original model card uses Chinese as well.
### Repetition loops
On short clips, the original model sometimes repeats one phrase many times. In one test, a short single-word clip produced the same phrase about 50 times. Setting `no_repeat_ngram_size` removed every loop in the tests below. The value counts tokens, not characters, and a Chinese character often takes 1 to 2 tokens.
Tests with the Hugging Face transformers pipeline (float16, beam 5), not with this CTranslate2 model:
- 100 short Common Voice Taigi clips: loops dropped from 4 clips to 0 with `no_repeat_ngram_size` of 3, 4, 5, 6 or 8.
- 18 broadcast ads of about 30 seconds each (Executive Yuan public service announcements, Taigi audio against the official Mandarin script): mean CER was 0.392 with no setting, 0.377 with 4 and 0.316 with 8. With 4, the Mandarin versions of the same ads lost words in the middle (mean CER 0.117 to 0.192). With 8 they did not (0.097).
I recommend 8. Larger values were not tested. The value was not tuned for this CTranslate2 model.
## Verification
- With the same prompt (`<|startoftranscript|><|zh|><|transcribe|><|notimestamps|>`), float32 and greedy decoding, this model produced token-for-token identical output to the original Hugging Face model on 8 of 8 test clips (30-second ads).
- Through faster-whisper with default settings, the output is **not** identical to the Hugging Face pipeline. On the 18 ads (Taigi audio), faster-whisper float32 with `no_repeat_ngram_size=8` had a mean CER of 0.377, against 0.316 for the Hugging Face pipeline with the same setting. Greedy decoding on 36 clips gave a mean character similarity of 0.92 between the two, and a few clips ended earlier in faster-whisper. I did not find the cause. It may come from the faster-whisper pipeline (windowing, feature extraction or decoding options) rather than from the converted weights. Compare on your own data before you depend on exact output.
## Credits
Original model: [MediaTek-Research/Breeze-ASR-26](https://huggingface.co/MediaTek-Research/Breeze-ASR-26) (Apache-2.0). Please cite the original work:
```bibtex
@misc{lan2026breezetaigibenchmarksmodels,
title={Breeze Taigi: Benchmarks and Models for Taiwanese Hokkien Speech Recognition and Synthesis},
author={Yu-Siang Lan and Chia-Sheng Liu and Yi-Chang Chen and Po-Chun Hsu and Allyson Chiu and Shun-Wen Lin and Da-shan Shiu and Yuan-Fu Liao},
year={2026},
eprint={2603.19259},
archivePrefix={arXiv},
primaryClass={cs.CL},
url={https://arxiv.org/abs/2603.19259}
}
```