pan93412/realtime-asr-v2

A real-time Automatic Speech Recognition (ASR) experiment

Python

0

7 commits

updated Jul 25, 2026

See the code

README

realtime-asr-v2

A real-time Automatic Speech Recognition (ASR) experiment built for Cursor Meetup Taipei (June 2025), originally intended to power bilingual subtitles during the talk.

This is the second iteration. v1 was built on Google Cloud Speech-to-Text and Google Translation APIs. v2 replaces the cloud pipeline with MediaTek Research's Breeze-ASR-25, a Whisper-based model fine-tuned for Mandarin and Taiwanese Hokkien. In concept it is similar to Typeless — audio in, transcript out — but without any downstream cleanup model.

How it works

The program runs a continuous loop:

  1. Records from the default microphone until 1 second of silence is detected.
  2. Feeds the captured waveform into the Breeze-ASR-25 pipeline (running locally via transformers).
  3. Prints the transcribed text and processing time, then loops back to step 1.

On Apple Silicon, inference runs on the MPS backend. On other machines it falls back to CPU.

Requirements

  • Python 3.13+
  • uv
  • A working microphone
  • ~1.5 GB disk space for the model weights (downloaded on first run)

Usage

uv sync
uv run python3 main.py

The first run downloads the Breeze-ASR-25 model weights from Hugging Face. All subsequent runs are fully offline.

Press Ctrl+C to stop.

Branches

BranchNotes
masterOriginal experiment files, committed as-is
workingVerified to compile and run on Apple M3 Max

Dependencies

PackagePurpose
torch + torchaudioTensor ops and audio resampling
transformersBreeze-ASR-25 model and Whisper pipeline
pyaudioMicrophone capture
numpyAudio buffer manipulation
asr
mac
microphone
mps
realtime
whisper

pan93412/realtime-asr-v2

A real-time Automatic Speech Recognition (ASR) experiment

Python

0

7 commits

updated Jul 25, 2026

See the code

README

realtime-asr-v2

A real-time Automatic Speech Recognition (ASR) experiment built for Cursor Meetup Taipei (June 2025), originally intended to power bilingual subtitles during the talk.

This is the second iteration. v1 was built on Google Cloud Speech-to-Text and Google Translation APIs. v2 replaces the cloud pipeline with MediaTek Research's Breeze-ASR-25, a Whisper-based model fine-tuned for Mandarin and Taiwanese Hokkien. In concept it is similar to Typeless — audio in, transcript out — but without any downstream cleanup model.

How it works

The program runs a continuous loop:

  1. Records from the default microphone until 1 second of silence is detected.
  2. Feeds the captured waveform into the Breeze-ASR-25 pipeline (running locally via transformers).
  3. Prints the transcribed text and processing time, then loops back to step 1.

On Apple Silicon, inference runs on the MPS backend. On other machines it falls back to CPU.

Requirements

  • Python 3.13+
  • uv
  • A working microphone
  • ~1.5 GB disk space for the model weights (downloaded on first run)

Usage

uv sync
uv run python3 main.py

The first run downloads the Breeze-ASR-25 model weights from Hugging Face. All subsequent runs are fully offline.

Press Ctrl+C to stop.

Branches

BranchNotes
masterOriginal experiment files, committed as-is
workingVerified to compile and run on Apple M3 Max

Dependencies

PackagePurpose
torch + torchaudioTensor ops and audio resampling
transformersBreeze-ASR-25 model and Whisper pipeline
pyaudioMicrophone capture
numpyAudio buffer manipulation
asr
mac
microphone
mps
realtime
whisper