Cadence Architecture
February 26, 2026 ยท View on GitHub
Flow Overview
- Source normalization (
.epub/.mobi/.azw3->.epub) - Text extraction to chapter files (
content/ch_XXX.txt) - Chapter synthesis (
audio/ch_XXX.wav) - Word alignment (
content/ch_XXX.json) - Reader playback and chapter navigation in Qt UI
Main Components
qt/main_window.py- Library UI, player UI, runtime settings dialogs.
system/book_manager.py- Import orchestration, chapter extraction/synthesis/alignment flow.
adapters/supertonic_backend.py- TTS backend wrapper and chunked synthesis behavior.
system/whisperx_align_worker.py+system/whisperx_align_cli.py- Persistent worker and fallback single-run alignment paths.
system/runtime_settings.py- Runtime settings defaults and environment application.
Data Model (Library Book Folder)
library/<book>/metadata.jsonlibrary/<book>/source/*.epub(+ optional original source format)library/<book>/content/ch_XXX.txtlibrary/<book>/content/ch_XXX.jsonlibrary/<book>/audio/ch_XXX.wav
Runtime Settings
- Persisted in
cadence_settings.json - Player view preferences persisted in
player_settings.json