Repository navigation
feat(voice): add optional local dictation with microphone feedback - #96
Draft
angel1411337-del wants to merge 1 commit into
Draft
angel1411337-del wants to merge 1 commit into
angel1411337-del wants to merge 1 commit into
Conversation
angel1411337-del
force-pushed
the
feat/voice-dictation
branch
from
November 12, 2026 02:10
13f7d3b to
27cb7be
Compare
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KowAZudvkUiQS623fiB331
angel1411337-del
force-pushed
the
feat/voice-dictation
branch
from
November 12, 2026 08:32
27cb7be to
42a3398
Compare
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What and why
This adds optional native dictation that uses a local whisper.cpp executable and model the user selects. Nothing is downloaded and no audio leaves the computer. Recording becomes active only after real microphone samples arrive. Setup includes device selection and separate microphone and recognizer checks. The panel shows startup, level and time, processing, review and actionable failures, including errors when there is no data for five seconds or the stream stalls.
Provider-independent core and runtime crates (
crates/voice-core,crates/voice-runtime) own bounded audio, coalesced previews, cancellation and subprocess cleanup. Transcripts are reviewed by default and inserted as one Undo/Redo transaction. Page, revision and cursor tickets prevent stale automatic insertion. Before changing the page, insertion checks the unchanged upstream serialization, and it keeps rejected words for review.The feature is off by default (
cargo build -p notecraft --features voice). The default app dependency tree excludes CPAL and the capture runtime. This pull request does not change the formats or Markdown implementation and does not depend on another pull request; it also builds and passes its UI tests on top of #92 (literal text). On today'smain, the serializer cannot keep some punctuation literal, so those words are refused and stay editable and copyable in review. With #92, words it can keep literal are inserted exactly. Multiline insertion requires a paragraph end or appending, and refuses cases that would shift indexed layout. English and pseudo catalogs are supplied; other locales fall back to English. Only trusted executables should be selected. Temporary-file cleanup is best effort, not secure erasure.Quality level L3 (see SKILLS/nc-devx/SKILL.md)
main(4286f7b) and has no merge commits: one commitcargo xtask cipasses locally on Rust 1.97 (see below); the pinned 1.99.1 run is this pull request's CIcoveragejob's warnings are read;cargo xtask coverage --updateis inthis pull request if coverage rose (to read once CI has run)
docs/commands.md(voice.*),docs/how-to/dictate.md,docs/how-to/README.md,docs/gaps.md,docs/feature-parity.md,docs/architecture.md,README.mdCommandSpecwith a test: thevoice.*commands, with engine tests for origin and redactioncargo xtask demo-checkpassesassets/ordocs/images/: noneHow it was checked
On the current
main(4286f7b), with Rust 1.97.0 locally (this environment could not download the pinned 1.99.1; GitHub CI runs it):cargo xtask cipassed: fmt, clippy, tests (983 passed, 0 failed, 2 existing manual large-fixture tests ignored), i18n-audit, layers, assets, docs, text, demo-check.cargo build --workspace --lockedalso passed.cargo build -p notecraft --features voice --lockedpassed.cargo test -p notecraft-ui-egui --features voice --lib): 307 tests passed, including 36 voice tests.-D warnings(craft-voice-runtime/microphone,notecraft/voice) passed.pageedit::Caretwith..Default::default(), because fix(editor): preserve literal Markdown text across saves and edits #92 adds a field to it.*literal*,[a](b),C:\notes\page,----) no longer assume today's serializer refuses them. With fix(editor): preserve literal Markdown text across saves and edits #92,*literal*goes in exactly as said in both page formats. Either way, each test checks that the words are kept exactly and undo in one step, or are refused with the draft, page, file and Undo history unchanged.Audio evidence, from the earlier run on
a71a3c6(thevoice-coreandvoice-runtimesources are byte-identical in this branch):whisper-cliwithggml-tiny.en-q5_1transcribed whisper.cpp'ssamples/jfk.wavrecording through this runtime'stranscribeexample, giving the expected sentence.Not checked, and needing separate verification:
voiceCI job, which runs for the first time on this pull request.Exact manual acceptance steps are in
docs/how-to/dictate.md.Written with AI assistance (Codex and Claude), reviewed and tested as above.
🤖 Generated with Claude Code
https://claude.ai/code/session_01KowAZudvkUiQS623fiB331