Local transcription of voicebot calls and phone recordings into timed turns with speaker labels. Audio stays on your machine.
pip install transcripyfrom transcripy import transcribe
result = transcribe(
"call.wav",
language="en",
speakers=True,
channel_labels=("agent", "customer"),
hotwords="TranscriPy, Acme",
initial_prompt="A voicebot call about the TranscriPy product.",
)
for turn in result.turns():
print(f"[{turn.speaker}] {turn.text}")transcripy call.wav \
--language en \
--speakers \
--channel-labels agent,customer \
--hotwords "TranscriPy, Acme" \
--prompt "A voicebot call about the TranscriPy product." \
-o call.json- Stereo call recordings where each party has a channel (agent / customer)
- Mono mixed calls when you install the optional diarization extra
- Offline / self-hosted pipelines that must not upload audio to a cloud ASR API
The public contract is simple: one media file in, a Transcript with segments, turns, and optional per-word timings out. Export as text, SRT, VTT, or JSON.
- Python 3.10+
faster-whisper(installed with the package)ffmpegonPATHfor video containers and stereo channel split- Optional NVIDIA CUDA for
--device cuda - Optional Hugging Face token for mono speaker diarization (see below)
Stereo (recommended for voicebots). --speakers (or speakers=True) splits the two channels and labels them with --channel-labels / channel_labels. Default labels are left and right.
Mono. The same flag runs pyannote and assigns each segment the speaker with the largest time overlap. Overlapping speech and similar voices reduce quality; this is not WhisperX-level alignment.
pip install "transcripy[diarize]"- Accept the user agreements for
pyannote/speaker-diarization-3.1andpyannote/segmentation-3.0. - Create a Hugging Face access token.
- Export it as
HF_TOKEN(orHUGGING_FACE_HUB_TOKEN).
| Setting | Default | Notes |
|---|---|---|
model |
large-v3 |
Pass a smaller Whisper name (medium, small, tiny) to trade quality for speed |
language |
auto-detect | Prefer an ISO code such as en or pl for call center audio |
word_timestamps |
on | Disable with --no-word-timestamps / word_timestamps=False |
device |
cpu |
Use cuda when a GPU is available |
Compared with WhisperX: TranscriPy focuses on a small call-recording API and reliable stereo channel labels. WhisperX is stronger when you need batched GPU throughput and forced word alignment on mixed mono audio.
- Live / streaming microphone transcription
- Hosted cloud ASR
- Production HTTP API (the
api/folder in this repo is experimental; not shipped in the wheel) - High-throughput batched GPU pipelines
- Subtitle tooling for films as the primary use case
pip install transcripy # library + CLI
pip install "transcripy[diarize]" # + pyannote for mono speakers
pip install "transcripy[dev]" # tests and the experimental server depsgit clone https://github.com/niewolski/TranscriPy.git
cd TranscriPy
python -m venv .venv
source .venv/bin/activate
pip install -e ".[dev]"
pytestSee CONTRIBUTING.md. Model weight notices are in NOTICE.