Repository navigation
fix(talk): cancel realtime output without aborting the turn - #119211
vincentkoc wants to merge 4 commits into
Conversation
|
Codex review: found issues before merge. Reviewed August 7, 2026, 8:43 PM ET / August 8, 2026, 00:43 UTC. ClawSweeper reviewWhat this changesThe PR separates realtime audio-output cancellation from destructive Talk-turn cancellation and attempts to fence stale playback clears. Regression provenancePossible regression — probable (reviewed change; failure trace). No predecessor PR is attributed. Merge readiness⛔ Blocked by patch quality or review findings - 9 items remain Keep open: this maintainer-owned stacked PR addresses a real current-main Talk bug, but two previously reported P1 cancellation races remain on its exact head. Priority: P1 Review scores
Verification
How this fits togetherControl UI and native relay clients send Talk cancellation requests to the Gateway relay, which controls provider audio and preserves or aborts agent work. The relay must clear only the playback generation that originated the cancellation. flowchart LR
Client[Web and native relay clients]
Gateway[Gateway Talk handler]
Relay[Realtime relay session]
Identity[Turn and output identity]
Provider[Voice provider clear callback]
Playback[Current audio playback]
Agent[Agent consult]
Client --> Gateway --> Relay --> Identity
Identity --> Provider
Identity --> Playback
Relay --> Agent
Before merge
Findings
Agent review detailsSecurityNone. PR surfaceSource +70, Tests +208. Total +278 across 9 files. View PR surface stats
Review metrics
Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Carry immutable playback identity from every client through cancellation, retain one correlation record per delayed provider clear, and cover the two-cancel/two-delayed-clear sequence before rebasing the stack. Do we have a high-confidence way to reproduce the issue? Yes — source establishes the two-cancel/two-delayed-clear order that corrupts playback correlation, although this read-only review did not execute it. Is this the best way to solve the issue? No — separating output cancellation from turn cancellation is the right owner boundary, but the patch must preserve identity per delayed callback and for every relay client. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 480e0c006067. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (10 earlier review cycles; latest 8 shown)
|
7fc2084 to
61521c6
Compare
aa406c2 to
2ccdbbc
Compare
61521c6 to
5c943f5
Compare
2ccdbbc to
c2cf34a
Compare
c2cf34a to
560fb4e
Compare
5c943f5 to
297c5a0
Compare
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
🦞🧹 I asked ClawSweeper to review this item again. |
bd4fae7 to
0f6dc93
Compare
1053f88 to
0627843
Compare
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
0627843 to
40d01a2
Compare
0f6dc93 to
e6a6030
Compare
e6a6030 to
069f48f
Compare
|
@clawsweeper re-review |
|
🦞👀 Command router queued. I will update this comment with the next step. |
Punchcard-Session: cobalt-cedar-timber-04 Punchcard-Session: calm-cedar-river-aa
Punchcard-Session: cobalt-cedar-timber-04 Punchcard-Session: calm-cedar-river-aa
Punchcard-Session: cobalt-cedar-timber-04 Punchcard-Session: calm-cedar-river-aa
Punchcard-Session: calm-cedar-river-aa
49632fe to
8bae3a8
Compare
069f48f to
aa5d583
Compare
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
Superseded by the consolidated draft #121894. The replacement keeps output cancellation generation-scoped while combining it with the authoritative relay-event and durable consult-ownership fixes, with current focused, SDK, build, Android, and mock-Gateway proof. |
What Problem This Solves
talk.realtime.cancelOutputused the full turn-cancellation path. Barge-in or playback stop could abort the active agent consult and destroy turn state instead of only stopping assistant audio. A delayed provider completion could also clear playback belonging to a newer output generation.Why This Change Was Made
Output cancellation now owns only provider response truncation and client playback clearing.
cancelTurnremains the explicit destructive operation for the whole turn. The UI sends the authoritative playbackturnId, and the relay fences delayed clears by both turn and monotonic output generation.User Impact
Users can interrupt spoken output and continue the same realtime conversation without losing active agent or tool work. Stale cancellation and completion events cannot clear newer playback.
Evidence
aa5d5838f609b56d1dc8b943b0bca17a969e4653.git diff --checkand private-data scan: clean.Stack
Depends on #112818.
Punchcard-Session: calm-cedar-river-aa