Transcript is jumpy while an agent streams: passed rows change, live text vanishes, Write rows have no path #210

Closed
opened 2026-10-18 14:51:32 -04:00 by cmoriarty · 0 comments
Owner

Seen on run 79 (Aurora Links, fastllm, opencode 2), 2026-10-18. The step transcript is hard to follow while an agent works:

  • Rows that have already scrolled past change. A row the operator has read is redrawn, moves, or gains content after newer rows have appeared below it.
  • The view jumps. Text that was on screen disappears suddenly. In the screenshots, a long live block of the model checking its working (green containment for holes 1–9, wind dominance for holes 2 and 3) is on screen. When the part ends it is replaced by the short line "Now the nine hole definitions in src/assets/holes/:" and everything above it shifts.
  • Tool rows say only Write. Seven Write rows in a row, with no file name, so the operator cannot tell what was written until a row is opened, if then.

Likely causes (from reading the code, not yet confirmed)

  1. Live text becomes something else when it settles. opencode 2 settles a part only when it ends (osf/agent/v2.py, braid#177). Until then the console draws the deltas as a live piece. When a long reasoning part settles it collapses into a one-line "Thought" disclosure (Reasoning.tsx), so a screenful of text disappears in one frame and the list below shifts up.
  2. Only one live part per session. useSessionDeltas keeps one {partId, text} per session, and Transcript.tsx (~lines 200–250) draws one live piece per agent. When the next part starts streaming, the previous part's text leaves the live tail before its settled row has arrived through the log. Text vanishes, then reappears higher up as a settled row, which reads as rows above changing.
  3. The live piece is pinned after the step's last settled line. Each settled row (a tool call, a step-finish) is inserted above the live text, so the live text moves down and the follow-the-tail scroll fires on every insert. Settled rows arrive in bursts while live text streams continuously.
  4. Rows change height after they are measured. The list is virtualized (virtua VList). A tool row that gains its input or result, or a reasoning row that collapses, changes height, and virtua corrects the scroll offset, producing jumps away from the tail too.
  5. Tool labels. format.ts labels the write tool Write with no path. Either opencode 2 sends the tool input only when the call settles, or the label never includes input.filePath. Check which.

To look into

  • Record a live opencode 2 session with long reasoning and several writes (tools/record_opencode2.py), and replay it in the browser lane to reproduce the jumps.
  • Keep a part's live text on screen until its settled row is drawn, then swap in place, at the same position and similar height, so nothing appears to vanish. For reasoning, collapse after a short delay or only once the operator has scrolled past it.
  • Show the tool's target (path, command) in the row title as soon as it is known.
  • Check whether derived part ids (part_id(message, kind, ordinal)) from the live stream and from a backfill ever disagree on opencode 2. That would redraw old rows as new ones.
  • Add a browser spec: while text streams, rows above the live tail keep their position and content.

Overall - I would like to update our opencode coding agent pane in Braid to align as closely as possible to how opencode v2 CLI client looks and feels. I was just using the opencode v2 CLI, and I noticed that the edit tasks show the code diff, which would be nice to have in braid. I'm guessing there are a lot of visual features of opencode v2 that should be implemented for braid. I think this may require a live session with opencode itself, taking screenshots and using vision to try and reproduce it accurately in a web browser. Also though, it is worth reading the new v2 documentation closely, perhaps there is a better way entirely to integrate a fully functioning opencode client in the browser, different from how we did it with opencode v1.

Seen on run 79 (Aurora Links, fastllm, opencode 2), 2026-10-18. The step transcript is hard to follow while an agent works: - **Rows that have already scrolled past change.** A row the operator has read is redrawn, moves, or gains content after newer rows have appeared below it. - **The view jumps.** Text that was on screen disappears suddenly. In the screenshots, a long live block of the model checking its working (green containment for holes 1–9, wind dominance for holes 2 and 3) is on screen. When the part ends it is replaced by the short line "Now the nine hole definitions in src/assets/holes/:" and everything above it shifts. - **Tool rows say only `Write`.** Seven `Write` rows in a row, with no file name, so the operator cannot tell what was written until a row is opened, if then. ## Likely causes (from reading the code, not yet confirmed) 1. **Live text becomes something else when it settles.** opencode 2 settles a part only when it ends (`osf/agent/v2.py`, braid#177). Until then the console draws the deltas as a live piece. When a long `reasoning` part settles it collapses into a one-line "Thought" disclosure (`Reasoning.tsx`), so a screenful of text disappears in one frame and the list below shifts up. 2. **Only one live part per session.** `useSessionDeltas` keeps one `{partId, text}` per session, and `Transcript.tsx` (~lines 200–250) draws one live piece per agent. When the next part starts streaming, the previous part's text leaves the live tail before its settled row has arrived through the log. Text vanishes, then reappears higher up as a settled row, which reads as rows above changing. 3. **The live piece is pinned after the step's last settled line.** Each settled row (a tool call, a step-finish) is inserted above the live text, so the live text moves down and the follow-the-tail scroll fires on every insert. Settled rows arrive in bursts while live text streams continuously. 4. **Rows change height after they are measured.** The list is virtualized (`virtua` `VList`). A tool row that gains its input or result, or a reasoning row that collapses, changes height, and virtua corrects the scroll offset, producing jumps away from the tail too. 5. **Tool labels.** `format.ts` labels the write tool `Write` with no path. Either opencode 2 sends the tool input only when the call settles, or the label never includes `input.filePath`. Check which. ## To look into - Record a live opencode 2 session with long reasoning and several writes (`tools/record_opencode2.py`), and replay it in the browser lane to reproduce the jumps. - Keep a part's live text on screen until its settled row is drawn, then swap in place, at the same position and similar height, so nothing appears to vanish. For reasoning, collapse after a short delay or only once the operator has scrolled past it. - Show the tool's target (path, command) in the row title as soon as it is known. - Check whether derived part ids (`part_id(message, kind, ordinal)`) from the live stream and from a backfill ever disagree on opencode 2. That would redraw old rows as new ones. - Add a browser spec: while text streams, rows above the live tail keep their position and content. Overall - I would like to update our opencode coding agent pane in Braid to align as closely as possible to how opencode v2 CLI client looks and feels. I was just using the opencode v2 CLI, and I noticed that the edit tasks show the code diff, which would be nice to have in braid. I'm guessing there are a lot of visual features of opencode v2 that should be implemented for braid. I think this may require a live session with opencode itself, taking screenshots and using vision to try and reproduce it accurately in a web browser. Also though, it is worth reading the new v2 documentation closely, perhaps there is a better way entirely to integrate a fully functioning opencode client in the browser, different from how we did it with opencode v1.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
cmoriarty/braid#210
No description provided.