Whisper Transcriber CLI is a specialized Python tool designed to run OpenAI's state-of-the-art speech recognition models on legacy and cooling-constrained hardware.
Standard Whisper implementations often utilize 100% of available CPU resources, which can lead to thermal throttling or overheating on older systems (such as 1st Gen Intel Core i7s). This tool solves that problem by providing granular control over CPU thread usage, allowing users to balance transcription speed with hardware safety. It offers a simple command-line interface for processing local audio/video files with custom output naming and model selection.
A hardware-friendly command-line tool for transcribing audio using OpenAI's Whisper model.
This tool is a Python wrapper around OpenAI Whisper designed with legacy hardware and temperature management in mind. It allows users to limit CPU thread usage to prevent overheating on older processors (e.g., 1st Gen Intel i7) while delivering state-of-the-art transcription accuracy.
- π₯ CPU Protection: Manually limit the number of CPU threads to prevent 100% load and overheating on older systems.
- π§ Model Flexibility: Support for all Whisper models (
tiny,base,small,medium,large) to balance speed vs. accuracy. - π Custom Output: Easily specify the output filename for your transcripts.
- π οΈ Simple CLI: Clean and easy-to-use command-line interface using
argparse. - π₯οΈ CPU Optimized: Configured to run on CPU by default (no CUDA/GPU requirement), making it accessible for any machine.
Before running the script, ensure you have the following installed:
- Python 3.8 or higher.
- FFmpeg: Required by Whisper to process audio files.
- Ubuntu/Debian:
sudo apt update && sudo apt install ffmpeg - Windows: Install via Chocolatey (
choco install ffmpeg) or download from ffmpeg.org. - MacOS:
brew install ffmpeg
- Ubuntu/Debian:
-
Clone the repository:
git clone https://github.com/YOUR_USERNAME/whisper-transcriber.git cd whisper-transcriber -
Create a virtual environment (Recommended):
python -m venv venv # Windows: .\venv\Scripts\activate # Linux/Mac: source venv/bin/activate
-
Install dependencies:
pip install openai-whisper torch
Run the script from your terminal providing the audio file as an argument.
python main.py [AUDIO_FILE] [OPTIONS]| Argument | Short | Default | Description |
|---|---|---|---|
file |
- | Required | Path to the input audio/video file. |
--model |
-m |
small |
Whisper model size (tiny, base, small, medium, large). |
--threads |
-t |
4 |
Number of CPU threads to use. Lower this value to reduce CPU load/heat. |
--output |
-o |
None |
Custom name for the output .txt file (without extension). |
1. Basic Transcription (Default Settings):
Uses the small model and limits to 4 threads.
python main.py interview.wav2. High Accuracy Mode:
Uses the medium model for better precision (slower).
python main.py lecture.mp3 --model medium3. Safe Mode for Old Hardware (Low Heat): Uses only 2 threads to keep the CPU cool.
python main.py long_recording.mkv --threads 24. Custom Output Filename:
Saves the transcript as meeting_notes.txt instead of recording_001.txt.
python main.py recording_001.wav --output meeting_notesThis project is licensed under the MIT License.
Disclaimer: This project uses OpenAI's Whisper model. Please refer to OpenAI's Model Card for more details on limitations and usage.