H-6763: Add temporary Brunch ask shim for Voice preview - #9507
H-6763: Add temporary Brunch ask shim for Voice preview#9507kostandinang wants to merge 3 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
3 Skipped Deployments
|
PR SummaryMedium Risk Overview The new tool returns Integration and transcript tests now cover pending ask, answer resume, persisted history, and the full probe flow ( Reviewed by Cursor Bugbot for commit 252b9db. Bugbot is set up for automated code reviews on this repo. Configure here. |
8993c8b to
b423a10
Compare
b423a10 to
185dd5d
Compare
185dd5d to
880213f
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 880213f. Configure here.
Temporary Voice-preview compatibility shim. This does not complete Mission 3 or Mission 4 and does not provide durable elicitation or canvas writes. Migrate or remove it after Mission 4 lands. Amp-Thread-ID: https://ampcode.com/threads/T-01a06317-621a-71b3-bcf1-16befbbdd6ff Co-authored-by: Amp <amp@ampcode.com>
Temporary Voice-preview compatibility shim. This does not complete Mission 3 or Mission 4 and does not provide durable elicitation or canvas writes. Migrate or remove it after Mission 4 lands. Amp-Thread-ID: https://ampcode.com/threads/T-01a06317-621a-71b3-bcf1-16befbbdd6ff Co-authored-by: Amp <amp@ampcode.com>
Reconstruct persisted brunch_ask parts with the same dynamic-tool shape as the live stream so reloaded Voice sessions retain pending questions. Co-authored-by: Cursor <cursoragent@cursor.com>
ab1d301 to
252b9db
Compare


🌟 What is the purpose of this PR?
Mount the real
brunch_askclient tool on Brunch's currentChatAgentso the existing Petrinaut Voice preview and widget can receive real Brunch questions and return answers through the existing client-tool resume path.This PR only enables real Brunch questions and Voice/widget answers. The independently useful Voice interaction improvements are separated into #9512.
🔗 Related links
🚫 Blocked by
🔍 What does this change?
brunch_askclient tool using the canonicalASK_TOOL_NAMEandAskInput; it returns{ awaiting: "client" }withterminate: true.ChatAgent, registers it as client-executed for AI SDK projection, and instructs the agent to ask one concise interview question per turn, wait for the correlated result, treat{ answer }as the user's answer, and never claim a canvas modification.client-tool-resultsignal path inpetrinaut-chat.ts; no specialized ask-admission protocol is restored.ping,readPetrinautDoc, pendingbrunch_ask, browser{ answer }submission, and continuation of the same persisted Flue conversation.🏗️ Agent notes
Imperative: Unblock Voice interview testing against the real Brunch endpoint now, without waiting for the durable Mission 4 architecture.
Throughline: Petrinaut AI SDK
/api/chat→ productionChatAgent→ pendingbrunch_askclient tool → existingclient-tool-resultsignal → the same Flue conversation continues.Proof: The integration test observes the real agent emit
brunch_ask, projects it asinput-availablewithoutproviderExecutedor a server output, submits{ answer }, and observes the next turn plus persisted history. ExistingpingandreadPetrinautDocchecks remain.Constraints: No
useElicitation, elicitor agents, ask-admission protocol, sweeps, folds, completion accounting, capture-store wiring, canvas mutation, or canonical-speech changes. The interviewer tool history is exactlyactivate_skill,ping,readPetrinautDoc, andbrunch_ask.Fog-line: This shim deliberately does not decide the durable elicitation or canvas-write architecture. Mission 4 owns that boundary.
Stop or reorient: Migrate the shim to the Mission 4 architecture, or remove it in favor of that architecture, after Mission 4 lands.
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:
package.json; Turborepo derives the edge without aturbo.jsonchangeThis is intentionally not durable elicitation. It does not write captures or the Petrinaut canvas, and it must not survive Mission 4 unchanged.
🐾 Next steps
🛡 What tests cover this?
yarn workspace @apps/brunch-agent test:unit— 10 files, 42 testsyarn workspace @apps/brunch-agent lint:tscyarn workspace @apps/brunch-agent lint:eslint— 0 errors; 8 pre-existing warnings in untouched filesyarn workspace @apps/brunch-agent buildgit diff --check❓ How to test this?
📹 Demo
Not recorded.