01Context and problem
Turning a book into a listenable audiobook usually means uploading private reading material, waiting for the whole book to render, and losing control over voices, chapters and corrections. Whisperbook keeps import, attribution, synthesis, playback and export on the device.
02Ownership and contribution
Chakib designed and built the Android product end to end: document import and extraction, chapter preparation, explainable speaker attribution, local voice casting, progressive Supertonic 3 synthesis, Media3 playback, synchronized reading and offline MP3 export.
Responsibilities
- Built the Kotlin/Compose product surfaces and Woodland Paper Theatre design system.
- Implemented local EPUB/PDF extraction, bundled OCR fallback and durable per-book state.
- Integrated Supertonic 3 through sherpa-onnx with local voice previews and per-book or per-chapter casts.
- Built progressive chapter preparation, Media3 playback, read-along checkpoints and chapter continuation.
- Added cancellable offline MP3 export that reuses finalized narration and generates only missing audio.
03Architecture and data flow
A single-module Kotlin/Compose app copies the selected publication into private storage, extracts EPUB or PDF text, detects chapters and speakers, persists the library in Room, and prepares opening audio through WorkManager. Supertonic 3 generates finalized local WAV segments that Media3 can play progressively while later chapters continue preparing.
- Local EPUB or PDF
- Private extraction and chapter detection
- Speaker attribution and voice cast
- Progressive Supertonic 3 synthesis
- Media3 playback and synchronized passages
- Offline book-level MP3 export
04Engineering decisions
Remove runtime networking entirely.
The Android manifest has no INTERNET or ACCESS_NETWORK_STATE permission, so imported books, generated audio and listening history stay inside the device boundary.Alternative not selected: Requiring a hosted model, account or cloud fallback for core narration.
Stream finalized local segments instead of waiting for the whole book.
The opening chapter becomes listenable first while later chapters are prepared sequentially, without sacrificing cache, seek or restart behavior.Alternative not selected: Blocking playback until every chapter has been synthesized.
05Reliability, security and evaluation
- Room, DataStore and WorkManager persist library, settings and preparation checkpoints across restarts.
- Finalized WAV microsegments remain the common cache, playback and export representation.
- JVM and connected Android tests cover import, synthesis, playback, navigation, voice selection and chapter continuation on the production Compose surfaces.
06Outcome and status
Public v0.1 Android release for arm64 devices on Android 8.0 or newer. The app imports local EPUB/PDF files, narrates with bundled Supertonic 3 voices, supports English, French and Arabic book settings, keeps playback synchronized with passages, and exports one local MP3.
Technology groups
Android
Kotlin, Jetpack Compose, Room, DataStore, WorkManager
Audio
Supertonic 3, sherpa-onnx, Media3, AudioTrack, FFmpegKit
Documents
EPUB, PDF, ML Kit OCR, Storage Access Framework
07Proof and source material