agent: lumotia-rebrand — docs, scripts, root config, residuals
Phase 9 of the rebrand cascade. Sweep covers everything the Phase 8
frontend pass deliberately skipped: docs/, root markdown, scripts,
Cargo.toml descriptions, code comments that survived earlier
word-boundary sed, plus a handful of identifiers caught on the final
verify pass.
transcription-app changes:
- README.md, HANDOVER.md, KNOWN-ISSUES.md, run.sh — magnotia/Magnotia
-> lumotia/Lumotia.
- docs/ — sweep across all subdirs except docs/handovers/ (preserved
as immutable audit trail). Includes architecture-map references
to magnotia_core::*, magnotia_storage::*, etc. now pointing at
lumotia_*; dev-setup.md tracing output examples (lumotia_startup
target); brief/ + superpowers/ + issues/ + whisper-ecosystem/ +
audit/.
- Cargo.toml descriptions on 9 crates (core, audio, cloud-providers,
hotkey, llm, mcp, plus referenced others).
- crates/core/src/{error,hardware,recommendation,paths}.rs +
crates/audio/src/wav.rs + crates/llm/src/model_manager.rs +
crates/cloud-providers/src/keystore.rs + crates/mcp/src/lib.rs —
doc comments and a model-manager user-agent string.
- Caught on final pass: BroadcastChannel("magnotia_task_sync") -> ...
("lumotia_task_sync"); magnotia_locale i18n localStorage key
renamed + migration shim added; CSS keyframe names
magnotiaPulse / magnotiaBar / magnotiaFade renamed in the design-
system kit; magnotia_viewer_item / magnotia_viewer_mode handoff
keys renamed in HistoryPage + viewer/+page.svelte; src/assets/
wordmark.svg text.
- src-tauri/src/lib.rs comment cleanup ("magnotia era" was sed'd
to "lumotia era" earlier — restored).
Preserved (intentional):
- crates/core/src/paths.rs — keeps "magnotia" / "Magnotia" / ".magnotia"
legacy detection strings in legacy_and_target_paths() so the
migration shim can still find user data from the magnotia era.
- src/lib/stores/{page,focusTimer}.svelte.ts + src/lib/i18n/index.ts
— migration call sites reference the legacy magnotia keys
deliberately.
- docs/handovers/ — historical audit trail.
cargo build --workspace passes. npm run check: 0 errors / 0 warnings
(3958 files). cargo test --workspace: 339 pass / 0 fail.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -35,7 +35,7 @@ lib tests and moves on; no new code.
|
||||
|
||||
The backlog groups itself into four natural phases. Each phase lands as
|
||||
a sequence of small, one-concern commits, with `cargo test --workspace
|
||||
--lib && cargo build -p magnotia && npm run check` green at every commit
|
||||
--lib && cargo build -p lumotia && npm run check` green at every commit
|
||||
boundary. At the end of each phase we pause for review before the next.
|
||||
|
||||
### Phase A.1 — Pre-emptive patches (no new UX surface)
|
||||
@@ -43,7 +43,7 @@ boundary. At the end of each phase we pause for review before the next.
|
||||
| Seq | Item | Effect | Depends on |
|
||||
|---|---|---|---|
|
||||
| 1 | **#2**: pre-approve `http://127.0.0.1:*` in Tauri capabilities for LLM | Adds `http:default-scope-127.0.0.1` style capability + widens `connect-src` CSP to localhost | — |
|
||||
| 2 | **#6**: guard `whisper-rs-sys` + `tokenizers` on Windows | Audit: Magnotia doesn't link `tokenizers` directly; we add a `#[cfg(all(target_os = "windows"))]` compile-time assert in `magnotia-transcription/build.rs` that fails the build if anything in the tree pulls in `tokenizers` on Windows | — |
|
||||
| 2 | **#6**: guard `whisper-rs-sys` + `tokenizers` on Windows | Audit: Lumotia doesn't link `tokenizers` directly; we add a `#[cfg(all(target_os = "windows"))]` compile-time assert in `lumotia-transcription/build.rs` that fails the build if anything in the tree pulls in `tokenizers` on Windows | — |
|
||||
| 3 | **#7**: CPU feature detection + non-AVX2 fallback surface | Extend `crates/core/src/hardware.rs` with `CpuFeatures` (avx2, avx512, fma, sse4_2) via `std::is_x86_feature_detected!` at runtime; surface as part of `RuntimeCapabilities`; when AVX2 is absent, emit a `warning` log + `runtime-warning` event so the frontend can show a banner | #1 |
|
||||
| 4 | **#1**: detect and surface active compute device | Extend `RuntimeCapabilities` with an `ActiveComputeDevice` struct (`kind: "cuda" \| "vulkan" \| "metal" \| "cpu"`, `label: String`, `reason: Option<String>`). For Whisper, read the first `whisper_print_system_info` line via a shim in `whisper_rs_backend`; reason is filled on any CPU fallback (e.g., "Vulkan loader not found") | #7 |
|
||||
| 5 | **#8**: checksum + resumable model downloads; retain audio on failure | Port the `crates/llm/src/model_manager.rs` pattern (SHA256 verify, `.part` file resume, `ResumeUnsupported` error) into `crates/transcription/src/model_manager.rs::download_file`. The existing code already does incremental SHA256 and range resume but lacks (a) validation of an **existing full file** before re-downloading, (b) ResumeUnsupported signalling, (c) test coverage parity. Retaining audio on failure is already covered in `commands/live.rs` via `save_audio` — add an explicit retry-friendly error classification so the frontend can render "Retry transcription" (a B surface, but the error enum ships here) | — |
|
||||
@@ -52,14 +52,14 @@ boundary. At the end of each phase we pause for review before the next.
|
||||
|
||||
**Commit boundary:** `cargo test --workspace --lib` (must include new
|
||||
tests for checksum resume + CPU feature detect + active-device shim),
|
||||
`cargo build -p magnotia`, `npm run check`. Then **stop for review.**
|
||||
`cargo build -p lumotia`, `npm run check`. Then **stop for review.**
|
||||
|
||||
### Phase A.2 — Engine abstraction (#13, #19)
|
||||
|
||||
| Seq | Item | Effect | Depends on |
|
||||
|---|---|---|---|
|
||||
| 8 | **#13 (engine trait)**: `magnotia-transcription` already has `LocalEngine` and a `SpeechBackend` enum over `transcribe-rs` adapter + `WhisperRsBackend`. This is a 90% version of Handy's `transcribe-rs` pattern. We lift it one more inch: replace the enum with a public `Transcriber` trait (`load`, `transcribe_sync`, `capabilities`) + blanket impls for the existing two backends, and gate `WhisperRsBackend` behind the `whisper` feature so non-Whisper builds compile without pulling `whisper-rs-sys` | — |
|
||||
| 9 | **#19**: progressive WAV write during live capture | Extend `commands/live.rs` to stream captured mono-16kHz samples directly into a `.wav` in the session folder via `magnotia_audio::WavWriter::append`. Replace the in-memory `kept_audio: Vec<f32>` when `save_audio` is on with a disk-backed writer; on crash, the partial file is a playable WAV. Commits the `commands/live.rs` frame-size bookkeeping untouched | #13 (uses `Transcriber::capabilities().sample_rate`) |
|
||||
| 8 | **#13 (engine trait)**: `lumotia-transcription` already has `LocalEngine` and a `SpeechBackend` enum over `transcribe-rs` adapter + `WhisperRsBackend`. This is a 90% version of Handy's `transcribe-rs` pattern. We lift it one more inch: replace the enum with a public `Transcriber` trait (`load`, `transcribe_sync`, `capabilities`) + blanket impls for the existing two backends, and gate `WhisperRsBackend` behind the `whisper` feature so non-Whisper builds compile without pulling `whisper-rs-sys` | — |
|
||||
| 9 | **#19**: progressive WAV write during live capture | Extend `commands/live.rs` to stream captured mono-16kHz samples directly into a `.wav` in the session folder via `lumotia_audio::WavWriter::append`. Replace the in-memory `kept_audio: Vec<f32>` when `save_audio` is on with a disk-backed writer; on crash, the partial file is a playable WAV. Commits the `commands/live.rs` frame-size bookkeeping untouched | #13 (uses `Transcriber::capabilities().sample_rate`) |
|
||||
|
||||
**Commit boundary:** tests (`transcriber_trait_is_object_safe`,
|
||||
`wav_writer_survives_crash`), build, check. **Stop for review.**
|
||||
@@ -105,7 +105,7 @@ repetition detector. **Stop for review.**
|
||||
| `commands::models::get_runtime_capabilities` | **Extend** | Add `active_compute_device`, `cpu_features`, `parallel_mode_available` fields |
|
||||
| `commands::live::evaluate_speech_gate` | **Replace** with VAD-gated chunker, keep RMS version as a cheap fallback when VAD ONNX model missing |
|
||||
| `commands::live::run_live_session` | **Extend** | Switch buffer ownership to `streaming::StreamingSession`, keep the `cpal` plumbing |
|
||||
| `crates/transcription/src/model_manager::download_file` | **Extend** | Harden to match `magnotia-llm`'s resume + sha behaviour, add `ResumeUnsupported` arm |
|
||||
| `crates/transcription/src/model_manager::download_file` | **Extend** | Harden to match `lumotia-llm`'s resume + sha behaviour, add `ResumeUnsupported` arm |
|
||||
| `crates/transcription/src/whisper_rs_backend::transcribe_sync` | **Extend** | Surface `no_speech_prob` + `avg_logprob` per segment |
|
||||
| `crates/transcription/src/local_engine::SpeechBackend` | **Replace** with public `Transcriber` trait |
|
||||
| `crates/transcription/src/concurrency` | **Extend** | Already a stub; add GPU guard wrapper |
|
||||
@@ -225,7 +225,7 @@ behind `runtimeCapabilities.parallelModeAvailable`.
|
||||
## Test strategy
|
||||
|
||||
- Every phase ends green on `cargo test --workspace --lib && cargo
|
||||
build -p magnotia && npm run check`.
|
||||
build -p lumotia && npm run check`.
|
||||
- `phase4-systems-f7d0` never regresses the 116 existing lib tests. If
|
||||
a test starts failing and the cause is an A change, it's fixed
|
||||
in-phase, not deferred.
|
||||
@@ -266,5 +266,5 @@ behind `runtimeCapabilities.parallelModeAvailable`.
|
||||
- One concern per commit. Subject line `feat(A.2):`, `fix(A.1):`, etc.,
|
||||
referencing the phase so the reviewer can group them.
|
||||
- Commit message body states which brief-item the commit closes.
|
||||
- `cargo test --workspace --lib && cargo build -p magnotia && npm run check`
|
||||
- `cargo test --workspace --lib && cargo build -p lumotia && npm run check`
|
||||
green before every commit, per the rules of engagement.
|
||||
|
||||
Reference in New Issue
Block a user