FE-1722: Improve Brunch Voice controls - #9747
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
1 Skipped Deployment
|
PR SummaryMedium Risk Overview The host contract and website sessions now thread session-local speaker state (not persisted; reset each new session). Live mutes the shared capture track without stopping playback or tearing down media on Stop; Realtime keeps existing mic gating and adds the same speaker APIs on remote audio. Status precedence is unchanged—Speaking still reflects provider output when the speaker is muted or volume is zero. Docs, mission pointers, Storybook scenarios, and broad unit tests cover dock behavior, lifecycle guards (no controls after session end), and the existing Live Stop → Reviewed by Cursor Bugbot for commit 5746995. Bugbot is set up for automated code reviews on this repo. Configure here. |
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
c860d30 to
089a4fb
Compare
|
Semgrep found 1 A hardcoded API Key is identified. Store it properly in an environment variable. |
lunelson
left a comment
There was a problem hiding this comment.
Two non-blocking follow-ups:
-
FE-1722 asks for Storybook coverage of keyboard focus, Escape dismissal, and reduced motion. The new stories cover pointer interaction and narrow layout, while focus/Escape are covered only by the unit test and reduced motion has no Storybook scenario. Please consider adding those Storybook interactions so the stated verification remains reproducible.
-
libs/@hashintel/brunch-agent/MISSION.mdlines 16–18 cite49ffd6836a..bdc699c923, but neither commit is an ancestor of this PR head after the rebase. Please replace the range with current commits or remove the volatile hashes.
Co-authored-by: Cursor <cursoragent@cursor.com>
|
Addressed the pragmatic review follow-ups in 5746995:
|
lunelson
left a comment
There was a problem hiding this comment.
Re-reviewed the follow-up. The stale mission references are fixed, and Storybook now covers keyboard opening, focus placement, Escape dismissal, and focus return. The remaining reduced-motion coverage suggestion is non-blocking.
🌟 What is the purpose of this PR?
This PR makes Brunch Voice controls easier to understand and use. The microphone
button stays in the main dock, while speaker mute and volume sit in a compact,
headerless Audio options popover with an icon toggle, slider, and percentage.
Stop appears only while Brunch is responding and remains separate from End, so
stopping a response does not disconnect a Live session.
The change keeps the existing capture, transcript, and work-ownership rules
intact. Automated tests cover the control behavior; real microphone, speaker,
and headphone behavior still needs a short manual check on physical hardware.
🔗 Related links
🚫 Blocked by
🔍 What does this change?
options popover.
available only for Realtime, below a visual divider.
Stop remains neutral and End remains red.
changes visibility only.
patch changeset.
🏗️ Agent notes
Status
FE-1722 is based directly on
mainafter foundation PR #9745 merged. It is thebottom entry in GitHub stack #9750, with follow-up PR #9748 above it.
Deterministic verification is complete. Physical audio routing and quality
remain an owner-held browser check.
Imperative
Make an active Brunch Voice session compact and predictable without changing
who owns capture, canonical work, or playback.
Throughline
create a second capture or silence playback.
Voice session starts.
calls
LiveBrunchBridge.stopResponse()and keeps media connected.work.
patient listening, and 500 ms output hold remain in place.
Proof
passed.
passed.
keyboard activation, Escape dismissal, and focus restoration. Reduced-motion
handling is implemented, but no per-story emulation is claimed.
These checks prove deterministic control behavior. They do not prove audible
routing, conversational quality, or behavior on every physical device.
Constraints
delegation policy, provider pinning, canonical Brunch authority, and Realtime
response ownership.
Speaking status.
state, history, or admission.
admissible.
Fog-line
Physical audio routing, subjective volume behavior, conversational quality,
natural turn boundaries, and real-device narrow-layout usability remain manual
observations.
Stop or reorient
Stop if microphone mute creates or replaces capture, silences output, or
changes admission; if speaker controls affect capture or canonical work; if
Stop disconnects Voice; if End cancels canonical work; if Show/Hide changes
anything beyond visibility; or if Realtime-only controls appear in Live.
Deferred
Device switching, voice and speed selection, helmet animation, and persistent
speaker settings remain out of scope. Follow-up work is recorded in
MISSION.next.md.Pre-Merge Checklist 🚀
🚢 Has this modified a publishable library?
This PR:
📜 Does this require a change to the docs?
The changes in this PR:
🕸️ Does this require a change to the Turbo Graph?
The changes in this PR:
physical hardware yet.
issue; the development Storybook and interaction checks pass.
🐾 Next steps
speaker settings separately.
🛡 What tests cover this?
❓ How to test this?
yarn workspace @hashintel/petrinaut devand open Storybook athttp://localhost:6006.stories. Confirm Live uses the compact speaker row, while Realtime places
its provider-specific actions below a divider.
have consistent visual weight, and that Stop remains separate from End.
should remain visible in both.
frame. Use Escape to close the popover and confirm focus returns to Audio
options.
📹 Demo
A typical Voice control flow:
percentage in one compact row.
existing actions below a subtle divider.
beside the consistently sized microphone and End controls.
Try the provider-specific and narrow-width variants under
Editor / AI Assistant in Storybook.