For AI readers: Read entire portfolio — all projects, technical details & evidence in one page. Plain text · GitHub fallback

← Experiments & archive
09 / Native systems / local inference2026

Local speech & working memory

Built a native macOS application for recording, transcribing and retrieving working context locally.

SystemPersonal OS
My contributionNative application & local inference architecture
AccessPrivate implementation
Engineering & evidence

AudioQueue and ScreenCaptureKit capture, 20 ms PCM input, bounded model workers and SQLite-backed retrieval.

Private native application. Device-dependent capture and dictation require separate validation.

Technical deep dive Architecture, implementation & tradeoffs
System architecture
Native macOS / local inference

Capture keeps running while models decode.

  1. 01

    Capture

    AudioQueue · 20 ms PCM

    A native 16 kHz audio path captures and buffers continuously.

  2. 02

    Separate

    screen audio ≠ microphone

    ScreenCaptureKit and microphone capture retain independent stream paths.

  3. 03

    Decode

    bounded workers + GPU gate

    Provisional transcription updates quickly; a separate final pass revisits the recording.

  4. 04

    Remember

    lossless chunks → SQLite

    Persist recordings and local memory for later reconstruction.

Concurrency
Audio callbacks are separate from inference work
Scheduling
Bounded local workers with serialised GPU work
Recovery
Retained audio supports independent final decoding
01 / Implementation

Capture and inference lifecycle

  • Implemented separate paths for AudioQueue dictation and ScreenCaptureKit system-audio plus microphone capture.
  • Used 20 ms PCM callbacks and rolling lossless 16 kHz mono audio files for dictation.
  • Built provisional phrase decoding followed by an independent quality pass over the original audio.
02 / Implementation

Resource and failure handling

  • Bound the number of loaded model workers and serialized GPU inference requests.
  • Kept microphone startup independent of remote-backend discovery and model loading.
  • Preserved provisional text when finalisation fails, with explicit microphone-open, first-audio, first-text and stop-to-final timings.
03 / Implementation

Personal memory

  • Built local multilingual transcription and speaker-aware processing around existing speech models.
  • Added SQLite-backed memory, retrieval, correction handling and optional backend-routing contracts.
  • Made capture, transcription, storage and action boundaries visible in the native application.
Engineering note

Latency is a sequence of boundaries.

The time before useful text appears includes opening the input device, receiving the first real samples, accumulating context and scheduling inference. I separated those stages so a slow device open does not disappear inside a single transcription-time number.

Project context

Actively developed native application. Hardware-dependent capture and cross-application actions have their own device-validation requirements.

Keep exploring

Access with an expiry.

Private compute workspaces