Skip to main content

Whisper Cheatsheet

Whisper is OpenAI's open-source general-purpose speech recognition model. It supports transcription and translation across 100+ languages, offers model sizes from tiny to large, runs on CPU or GPU, and outputs in txt/vtt/srt/tsv/json formats.

Updated: 2026-07-20·20 commands

Quick Start

``bash # Install pip install openai-whisper

# Basic transcription whisper recording.mp3

# Specify model and language whisper meeting.mp3 --model small --language zh

# Translate Chinese audio to English whisper chinese_speech.mp3 --task translate

# Generate SRT subtitles whisper video_audio.mp3 --model base --output_format srt --output_dir ./subtitles

# GPU accelerated transcription whisper long_podcast.mp3 --model medium --device cuda --fp16 True `

Model Sizes

Whisper offers five pre-trained models trading speed for accuracy: tiny (39M params, ~1GB VRAM), base (74M, ~1GB), small (244M, ~2GB), medium (769M, ~5GB), large (1.5B, ~10GB). Models are downloaded automatically on first use.

Transcription & Translation

Two task modes: transcribe (speech to text in original language) and translate (speech to English text). Use --language to hint the source language for better accuracy. For bilingual audio, Whisper auto-detects.

Output Formats

Whisper supports multiple output formats. Use --output_format to choose: txt (plain text, default), vtt (WebVTT subtitles), srt (SubRip subtitles), tsv (tab-separated values with timestamps), json (full metadata including segments and word-level timestamps). Use all to generate all formats at once.

Advanced Options

--initial_prompt guides style or domain-specific terminology. --temperature controls sampling randomness (0 = deterministic). --condition_on_previous_text` improves long-form coherence. Batch transcribe multiple files with shell glob patterns.

Startup & Modes(20)

CommandLevel
whisper --help
Show Whisper CLI help
Basic
whisper audio.mp3
Transcribe audio file to text (basic usage)
Basic
whisper audio.mp3 --model
Specify Whisper model size
Basic
whisper audio.mp3 --model tiny
Use smallest model (fastest, least accurate)
Basic
whisper audio.mp3 --model large
Use largest model (slowest, most accurate)
Basic
whisper audio.mp3 --language
Specify audio language (improves accuracy)
Intermediate
whisper audio.mp3 --task transcribe
Transcription task (default, keeps original language)
Basic
whisper audio.mp3 --task translate
Translation task (translates any language to English)
Basic
whisper audio.mp3 --output_format
Specify output format (txt/vtt/srt/tsv/json/all)
Intermediate
whisper audio.mp3 --output_dir
Specify output directory
Basic
whisper audio.mp3 --device
Specify inference device (cpu/cuda)
Intermediate
whisper audio.mp3 --fp16
Enable half-precision inference (GPU acceleration)
Intermediate
whisper audio.mp3 --verbose
Show verbose output (with timestamps and confidence)
Basic
whisper audio.mp3 --temperature
Set sampling temperature (0-1, default 0)
Intermediate
whisper audio.mp3 --initial_prompt
Set initial prompt (guides style or corrects terms)
Expert
whisper audio.mp3 --condition_on_previous_text
Use previous text for better coherence
Intermediate
pip install openai-whisper
Install Whisper
Basic
pip install openai-whisper[audio]
Install Whisper (with audio dependencies)
Basic
whisper --model small audio.mp3
Transcribe with small model (speed-quality balance)
Basic
whisper dir/*.mp3
Batch transcribe all audio files in a directory
Intermediate

FAQ

This cheatsheet is compiled from official tool documentation. Last updated: 2026-07-20.