Faster-Whisper
Same models, different engine.
faster-whisper reimplements Whisper
on CTranslate2, an inference library
built for exactly this job, and its
project claims up to four times the
speed of the original at the same
accuracy, with less memory. This chapter
installs it and reports a head-to-head
the lab ran on the same clips, the same
machine, the same base model.
Installing
It is a Python library, not a command — you use it from a script. Into its own environment, so its dependencies never fight the original's:
python3 -m venv ~/faster-whisper-env
source ~/faster-whisper-env/bin/activate
pip install faster-whisper
The lab got faster-whisper 1.2.1 with
CTranslate2 4.8.3. Models come from a
different shelf: instead of OpenAI's
.pt files, faster-whisper downloads
converted models from Hugging Face (the
Systran conversions) on first use, so
the first load of base took 85 seconds
including the fetch; later loads took
about 4 seconds.
One real snag, kept because you may
hit it. The fresh install also pulled
in the newest PyAV library (version 19),
and the first transcription died with
TypeError: open() got an unexpected
keyword argument 'metadata_errors' —
PyAV had removed an argument
faster-whisper passes. Pinning the older
line fixed it:
pip install "av==16.0.0"
Chapter 14 tells the story; transcripts t06 and t09 hold the before and after.
The script
examples/transcribe-faster-whisper.py:
from faster_whisper import WhisperModel
model = WhisperModel("base", device="cpu",
compute_type="int8")
segments, info = model.transcribe("talk.mp3")
print(info.language, info.language_probability)
text = "".join(seg.text for seg in segments)
Two differences from chapter 8's API.
The model is loaded with an explicit
compute type — int8 on CPU is the
fast, lean choice. And transcribe
returns a lazy generator: nothing is
transcribed until something consumes
the segments, which is why the example
joins the text inside the timed section.
The comparison
Base model, lab machine, seconds (transcript t06; the original's figures are its command-line runs from chapter 5, startup included, which flatters nobody but is what a user actually waits):
| Clip | OpenAI Whisper | faster-whisper |
|---|---|---|
| JFK, 11 s | 21–35 | 3.4 |
| Gettysburg, 60 s | 77 | 10.9 |
| Spanish, 30 s | 77 | 4.2 |
The whole faster-whisper run — model load plus all three clips — took 26 seconds, less than the original's single run of the 60-second clip alone. On this machine the gap is roughly sevenfold on a minute of audio. Your mileage will vary with hardware; the direction has been consistent everywhere the lab could check.
And the text? Essentially identical —
including the mistakes. faster-whisper's
Gettysburg also says "Libravox" and "the
Gettysburg Addressed", because it is the
same base brain doing the hearing;
only the machinery around it is faster.
It also reports its language guess as a
probability (English 0.95 and 1.00,
Spanish 0.94 on the lab clips) — a
number the original keeps to itself,
and a genuinely useful one.
Which to use
- Learning, one-offs, subtitles from the command line: the original. Friendlier interface, every format one flag away.
- Folders, services, anything repeated or long: faster-whisper. The speed is the schedule.
- Either way: the model size still
decides accuracy. A faster engine does
not rescue
tiny's Spanish.
Check: run the example script on a clip you have already transcribed and confirm the words match the earlier output — faster, but the same transcript.