openai/whisper
Systems
The whisper package decomposes into a handful of internal modules, each with a clear scope. This section documents them one by one. Most are a single file.
At a glance
graph TD
audio[audio<br/>whisper/audio.py] --> transcribe
tokenizer[tokenizer<br/>whisper/tokenizer.py] --> transcribe
tokenizer --> decoding
model[model<br/>whisper/model.py] --> decoding
decoding[decoding<br/>whisper/decoding.py] --> transcribe
timing[timing<br/>whisper/timing.py] --> transcribe
triton[triton_ops<br/>whisper/triton_ops.py] --> timing
transcribe[transcribe<br/>whisper/transcribe.py] --> writers
writers[output writers<br/>whisper/utils.py]
norm[normalizers<br/>whisper/normalizers/]normalizers does not sit on the inference path — it is used for post-hoc evaluation (paper-style WER scoring).
Pages
| Subsystem | Source | Page |
|---|---|---|
| Audio frontend | whisper/audio.py |
Audio processing |
| Transformer model | whisper/model.py |
Model |
| Decoding and sampling (window-level) | whisper/decoding.py |
Decoding |
| Long-form transcription loop | whisper/transcribe.py |
Transcribe |
| Word-level timing via DTW | whisper/timing.py, triton_ops.py |
Timing |
| Tokenizer | whisper/tokenizer.py |
Tokenizer |
| Output writers (txt/vtt/srt/tsv/json) | whisper/utils.py |
Output writers |
| Text normalization (eval only) | whisper/normalizers/ |
Normalizers |
Reading order
If you are new to the codebase, the most useful order is:
- Audio processing — what the model eats.
- Tokenizer — how text is represented.
- Model — the actual neural network.
- Decoding — how a single 30 s window is decoded.
- Transcribe — how an arbitrary file is processed.
- Timing — how word timestamps are produced.
- Output writers — how results are serialized.
- Normalizers — only relevant if you are doing paper-style evaluation.
Built by Factory AutoWiki from public repository content. It is a generated preview for codebase exploration, not source-maintained documentation.