---
title: "Transcribe audio files with Whisper"
description: "Convert speech to text locally using OpenAI's open-source Whisper model—no API key needed."
url: "https://www.pixeltable.com/notebooks/audio-transcribe"
updated: "2026-10-13"
---

# Transcribe audio files with Whisper

Convert speech to text locally using OpenAI's open-source Whisper model—no API key needed.

- **Type:** Notebook
- **Group:** Audio

## How it works

You create a view with audio_splitter to break long files into segments, then add a computed column for transcription. Whisper runs locally on your machine—no API calls needed.

## What it covers

- Transcribe audio files locally with Whisper (no API key)
- Automatically segment long files
- Extract and transcribe audio from videos

## What it uses

- **Install:** `pip install pixeltable openai-whisper`
- **Pixeltable calls:** `audio.audio_splitter()`, `whisper.transcribe()`, `pxt.create_table()`, `pxt.create_view()`, `insert()`, `add_computed_column()`

## A look at the code

```python
# Add transcription column (runs locally - no API key needed)
segments.add_computed_column(
    transcription=whisper.transcribe(
        audio=segments.audio_segment,
        model='base.en',  # Options: tiny.en, base.en, small.en, medium.en, large
    )
)
```

## Open it

- **Open in Colab:** https://colab.research.google.com/github/pixeltable/pixeltable/blob/release/docs/release/howto/cookbooks/audio/audio-transcribe.ipynb
- **Docs page:** https://docs.pixeltable.com/howto/cookbooks/audio/audio-transcribe
- **Source on GitHub:** https://github.com/pixeltable/pixeltable/blob/release/docs/release/howto/cookbooks/audio/audio-transcribe.ipynb
