Building an offline speech-to-text app with Flutter, FFI, whisper.cpp and FFmpeg
Описание и применение
Приложение Extracter позволяет преобразовывать любые аудио‑ и видеофайлы в текст полностью на устройстве, без загрузки в облако, используя Flutter, FFmpeg и whisper.cpp.
Задача
Transcribing audio or video locally without uploading to cloud services.
Результат
Extracter delivers line‑by‑line transcripts for any audio/video file on Android, iOS, and macOS, with no network usage after model download.
Рабочий процесс
- Select audio/video file
- FFmpeg decodes to 16 kHz mono PCM
- Whisper.cpp processes 30‑second windows fed in ~3‑minute chunks
- Native FFI plugin posts events (progress, segment, logs, DONE) to Dart
- Flutter UI streams segments line‑by‑line
- User can view history, export to TXT/SRT/VTT, or copy text
Доказательства
Cloud transcription is convenient until you have a recording you'd rather not upload: a lecture, a client call, a voice note.
Extracter, an open‑source Flutter app that turns any audio or video file into text entirely on the device.
The heavy lifting lives in a small FFI plugin, extracter_native, with one C ABI shared by every platform:
The app crashed with SIGSEGV, and the backtrace pointed at the line where the worker called the callback.
Posting to the port of a dead isolate just returns false, so nothing crashes.
- Дата записи: 2026-10-22T09:11:23.743Z