Repository navigation
Description
Context
Part of #3690. Prerequisite: #3692, which supplies the VoiceField (compact shape), VoiceNotice and the D1–D8 stories, signed off. This issue is integration only: it maps the use-dictation.ts state onto those components and removes the current dictation chrome.
State mapping
| State | Driven by | Exit |
|---|---|---|
| D1 Ready | idle | tap leads to D2/D3; hold leads to Start (#3693) |
| D2 Waiting for access | permission prompt pending | granted leads to D3; denied leads to D7; Cancel leads to D1 |
| D3 Listening | capturing; level from the real input; partial and final text |
✓ leads to D5 |
| D4 Quiet | capturing with no speech | speech returns to D3; 30 s silence timeout (V3) leads to D6, or D1 if empty |
| D5 Finishing | stop requested, awaiting the final text | final text leads to D6 |
| D6 Review | plain editable composer text, caret at end; no uncertain-word mark or hint-line cue (later M2 ruling on #3727) | Send / edit / mic |
| D7 Mic blocked | permission denied | tapping the mic retries |
| D8 Stopped | provider or transport failure; the text so far is kept | Try again / Dismiss |
Acceptance criteria
- Uses the ui-kit: voice components and stories for every dictation, Start and live state #3692 components unchanged. No new visual design here.
- Every state is reachable in app browser tests with a local speech double, and matches its ui-kit: voice components and stories for every dictation, Start and live state #3692 story.
- Text heard so far is never lost on D7 or D8. Uncertainty is never fabricated.
- Nothing is sent without an explicit Send. The later D6 ruling keeps editable text plain; uncertainty is never invented or inserted into an editable field.
- The old dictation UI is removed.
Scope and exclusions
Wire the approved dictation state mapping plus the signed-off D0, Dc, Dx and destination forms below, using the existing kit components unchanged. The source driver is useDictation (packages/ui-react/src/voice/use-dictation.ts:27); kit owners are VoiceField (packages/ui-kit/src/voice/VoiceField.tsx:52) and VoiceNotice (packages/ui-kit/src/voice/VoiceNotice.tsx:32).
Out of scope: new component visuals, provider selection infrastructure, live-conversation behavior, permission/consent changes, new confidence claims, and changes to speech contracts. #3727 owns the real Composer mic slot and D6 form.
Approved behavior
V3 (maintainer, 2026-11-08): stop after 30 s of silence, go to D6 when words exist and D1 when empty. K1/K2 and all missing disclosure/connecting forms are approved in the final sign-off below. M2 on #3727 supersedes the original uncertain-word D6 mock: review is plain editable text with no honesty mark or hint-line cue; the mic is named Dictate more.
Source: final design sign-off.
Design sign-off: dictation disclosure in the voice field (final, K1 and K2 folded in)
Signed off. The brief above stands as drawn, and K1 and K2 match its recommendations. This is the consolidated spec for the integration.
ui-kit components (all reused unchanged): compact VoiceField (label.meta), VoiceNotice, VoiceControlButton. Stories: #3738 (prerequisite).
Uses the ui-kit components unchanged; no new visual design here. Any visual change goes back to #3738 and its stories.
Flow: tap mic → D0 (first take) → Dc → D2 (if prompted) → D3 → D4/D5 → D6
| Form | Component | Copy | Focus / notes |
|---|---|---|---|
| D0 first take | VoiceNotice tone="you" icon="mic" live="polite" |
Start dictation · "Your words are sent to {destination} to be written down. The audio isn’t kept." · Cancel / Start dictation | K1: focus on Start dictation. Cancel and Esc return focus to the mic. Shown before any session request or mic access. Recorded only after a successful write |
| Dc connecting | compact VoiceField tone="idle" meter="none", label {loading, "Connecting", meta, spin} |
VoiceText placeholder="Not listening yet" · trailing Cancel dictation |
Grey, 84px. Never says "Listening" before the mic is open |
| D3–D5 destination | label.meta |
"to Google Gemini" · "via Deepgram" · Chrome: "browser speech · audio goes to Google" · other browsers: "browser speech · sent by your browser" (K2) | One line, 84px kept. The meta ellipsizes first. Same meta in Dc |
| Dx no service | VoiceNotice tone="idle" icon="attention" |
Choose a dictation service · "Dictation needs a service. Pick one in Settings." · Cancel / Open Settings | No mic, no meter |
| Dx service gone | same | Your dictation service isn’t available · "{Service} isn’t offered here any more. Choose another in Settings." · Cancel / Open Settings |
Acceptance additions for this issue
- The destination is named (D0 or the Dc meta) before any audio leaves the browser. Browser test: no
getUserMediabefore D0 is accepted, and none before Dc renders. - Storage failure on the acknowledgement shows D0 again next take.
- The old dictation sheet is removed only once these forms are wired.
No open questions remain. This stays blocked by #3738, #3708, #3709 and #3727.
Current dependencies
No active blocker (2026-11-10).
Delivered prerequisites: #3692 through #3718, #3708 through #3717 (723280e), and #3709 through #3724 (8752570). Their source is on inspected main. The signed-off design is settled; #3738's stories and #3727's Composer support are both delivered (see below). Do not restore a design prerequisite merely because the approved kit implementation is not merged yet.
Verification
Use actual app browser tests with a local speech double for every D-state and additional form, including no session request/getUserMedia before D0 acknowledgement, no listening claim in Dc, persisted acknowledgement failure, preserved text on failure, the 30 s silence boundary, explicit Send and both themes at 320px/desktop. Retain state/focus/consent mutation receipts and required pinned-browser proof.
Contract impact
Integration uses the existing dictation contract. Any separately exposed supported API change must be assessed and documented in its owning component; no new API or ruling is inferred here.
Triage 2026-11-08 at main 8752570331ffebdbb9233196412781f6cd71f3d9: Folded the final signed-off specification and later rulings into this body, removed obsolete open questions, and reconciled actual delivered and open prerequisites. Existing ownership, draft work and release attribution are preserved.
2026-11-10 triage at main d79eeed0a: both former blockers are satisfied and moved out of the Blocked by line. #3727 is closed as completed through #3742 (squash fb999b8ba). #3738 is closed as completed after the maintainer's 2026-11-09 design sign-off; its stories and baselines are on main through #3741 (squash c3908ae7a). Merge order still follows #3693's PR #3761, as recorded in the comments; that is sequencing, not a declared blocker.


Activity
[-]ui-react: dictation states D1–D8 on the voice field[/-][+]ui-react: wire dictation (D1–D8) to the voice field components[/+]schlessera commentedon Nov 8, 2026
Decision (maintainer, 2026-11-08): see the rulings on #3690; this issue's body now states the chosen branch.
needs: decisionremoved. Blocked by #3692 (and, for #3698, by #3616/#3617) until its signed-off components exist.schlessera commentedon Nov 8, 2026
Unblocked: #3692 is closed, so
scripts/sync-project.tsis removing theblockedlabel.schlessera commentedon Nov 8, 2026
Claimed (token
wi-3694-5b2d). Intended branch:feat/3694-dictation-voice-field, frommain(#3693 is blocked by #3727 and produced no branch).Collision note: draft PRs #3717 and #3724 also edit
use-dictation.ts,dictation-capture.ts,voice-state.ts,dictation-sheet.tsxandcomposer.tsx.20 remaining items
test(ui-kit): voice stories for dictation disclosure and the live fie…
schlessera commentedon Nov 9, 2026
Unblocked: both declared blockers are closed. #3727 merged in #3742, and #3738 was signed off and closed on 2026-11-09. Its earlier blockers #3708 and #3709 are also closed.
schlessera commentedon Nov 9, 2026
Claimed (token
wi-3694-c41e). Branch:feat/3694-dictation-voice-field, from mainfb999b8. I'll rebase onto #3693 (PR #3761) when it lands and build on its tap→dictation entry.Path collisions: PRs #3761, #3735 and #3758 also edit
packages/ui-react/src/components/chat/composer.tsx, and #3761 also editscomposer-view.tsx.feat(ui-react): dictate in the voice field and remove the dictation s…
feat(ui-react): dictate in the voice field and remove the dictation s…
schlessera commentedon Nov 9, 2026
Status (claim
wi-3694-c41e): implementation done in draft #3772; waiting on #3761 to merge.#3772 builds on #3761's tap-to-dictation entry, so it includes #3761's commits and can't merge first. On the maintainer's ruling, I'm not taking #3761 over or folding it in.
ca994fe, current with feat(ui-react): tap the composer mic to dictate, hold it to open Start #3761's head and main through test(ui-react): pin the clock in the digest slot-timer tests (#3801) #3802. Hosted draft heavy feedback passed every category atd4deab6; the only change since is a merge of feat(ui-react): tap the composer mic to dictate, hold it to open Start #3761's branch, and the dictation suite passes 42/42 on it. Main is green.git merge origin/mainintofeat/3694-dictation-voice-field, then rerunbun run check:pr --base origin/main. Replace the PR's receipt, push, then runbun scripts/collisions.ts --json --pr 3772andbun scripts/integrate.ts confirm 3772 --issues schlessera/brain-kit#3694.schlessera commentedon Nov 9, 2026
Decision (maintainer, 2026-11-09): the first-take "Start dictation" card uses per-service wording for what happens to the audio.
Make this change in PR #3772 before it lands. The other three choices listed in #3772's body stand: the "Dictate more · " mic name, "Review in composer" writing to the draft, and Escape cancelling a take that isn't finishing.
schlessera commentedon Nov 10, 2026
2026-11-10 triage at main
d79eeed0a: theBlocked by #3738, #3727line named two closed issues, and both outputs exist. #3727 closed through #3742 (squashfb999b8ba). #3738 closed as completed after the maintainer's 2026-11-09 sign-off, and its stories and baselines are on main through #3741 (squashc3908ae7a). I moved both into a dated historical note and updated the stale "still waits" sentence. There is no open blocker. Merging after #3761 is sequencing, not a declared blocker. Labels are unchanged.fix(ui-react): say what happens to the audio per service on the first…
feat(ui-react): dictate in the voice field and remove the dictation s…
schlessera commentedon Nov 10, 2026
Delivered in #3772, squash
96ba8a7c8636ab0a2bdac9f9427eab8d5dd02829on main (milestone 0.45.0).7497c2cover base462afad. Each state is compared with its story in the dictation suite. Mutation receipts are in the PR body.