whisper-multitrack
v0.1.1
Published
Transcribe multi-track recordings (e.g. Craig Discord meetings) with whisper.cpp — one speaker per track.
Maintainers
Readme
whisper-multitrack
Transcribe multi-track recordings — e.g. meetings recorded with the Craig Discord bot — or plain audio files, with whisper.cpp.
Each speaker's track is transcribed separately, so the transcript is automatically labelled per speaker, and all tracks are interleaved by timestamp into one readable document. Craig recording links are accepted directly: the multi-track FLAC archive is downloaded, unzipped into a temporary folder and transcribed.
Requirements
- Node.js >= 20
- ffmpeg on
PATH - whisper.cpp (
whisper-cli) onPATH - A whisper model and the Silero VAD model — see Models
unzip(needed for Craig links; if it is missing the built-intarfallback is used where available)
Install
npm install -g whisper-multitrackOr run it without installing:
npx whisper-multitrack --helpModels
Models are auto-detected in ./models and ~/.local/share/whisper-cpp/models, so anything downloaded with whisper.cpp's standard downloader just works:
whisper-cpp-download-model large-v3-turbo # or models/download-ggml-model.shThe Silero VAD model is also required (matching aTrain's defaults):
curl -L -o ggml-silero-v5.1.2.bin \
https://huggingface.co/ggml-org/whisper-vad/resolve/main/ggml-silero-v5.1.2.binIf either model is missing, the tool prints exactly what to download.
Usage
whisper-multitrack [options] <dir | file ... | craig-url>Transcribe a folder of per-speaker tracks (e.g. an extracted Craig zip):
whisper-multitrack ./recording-tracksTranscribe specific files, optionally overriding the speaker names:
whisper-multitrack Alice=1-alice.flac Bob=2-bob.flacTranscribe a Craig recording link directly:
whisper-multitrack "https://craig.horse/rec/XXXXXXXXXXXX?key=YYYY"Paragraph output with timestamps, written to a specific file:
whisper-multitrack --timestamps --merge=paragraphs --out=meeting.txt ./tracksTry it with npx
No install required — npx fetches the CLI and runs it in one go:
# a folder of tracks
npx -y whisper-multitrack ./recording-tracks
# paragraph output with timestamps, explicit output file
npx -y whisper-multitrack --timestamps --merge=paragraphs --out=transcript.txt ./tracks
# straight from a Craig recording URL
npx -y whisper-multitrack "https://craig.horse/rec/XXXXXXXXXXXX?key=YYYY"npx only provides the CLI itself — ffmpeg, whisper-cli and the models still need to be installed locally. The -y flag skips npx's first-run install prompt.
Options
| Option | Description |
| --- | --- |
| --timestamps | Prefix each line with a [hh:mm:ss] timestamp |
| --merge=lines | One line per cue (default) |
| --merge=paragraphs | Flowing text; paragraphs break on speaker change or a ≥ 2 s pause |
| --out=file | Transcript path (default: transcript.txt next to the audio, or transcript-<id>.txt in the current directory for Craig links) |
| -h, --help | Show help |
| -v, --version | Show version |
Environment variables
| Variable | Description |
| --- | --- |
| WHISPER_BIN | whisper.cpp binary (default: whisper-cli) |
| WHISPER_MODEL | whisper model path (default: auto-detected) |
| WHISPER_VAD_MODEL | Silero VAD model path (default: auto-detected) |
| WHISPER_LANG | Language (default: auto) |
| WHISPER_PROMPT | Initial prompt passed to whisper |
| WHISPER_THREADS | Number of threads (default: CPU cores − 1) |
| INCLUDE_TIMESTAMPS | 1 = same as --timestamps |
| MERGE_MODE | Same as --merge |
| OUTPUT | Same as --out |
How it works
- Every input track is converted to 16 kHz mono with ffmpeg and transcribed by
whisper-cliwith word timestamps and VAD, using aTrain's faster-whisper decoding settings. - Word timestamps are grouped into sentence-like segments (aTrain-style rules: pauses, sentence ends, a max duration), then all speakers' segments are interleaved by time.
- Speaker names come from file names (
1-alice_0.flac→alice_0), or fromName=filearguments.
Author
Svetlozar Argirov [email protected] Broken By Design
License
MIT
