simulate(tui): refresh summary before writing the run report#874
Closed
theomonnom wants to merge 6 commits into
Closed
simulate(tui): refresh summary before writing the run report#874theomonnom wants to merge 6 commits into
theomonnom wants to merge 6 commits into
Conversation
- SDK/protocol logs written to stderr during the alt-screen session all spilled into the terminal when the TUI exited; discard them like the console and perf commands do (the agent log and run report carry the diagnostics). - The run summary, which carries the chat transcripts, could land after the TUI's last poll; refetch once at exit so the report file includes the transcripts, and say explicitly when they aren't available yet.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Chat transcripts ride on the run summary (
run.Summary.ChatHistory), which the summarize job produces after the simulations finish. If you quit right as jobs completed, the report was written from a pre-summary snapshot and silently omitted the transcripts. The TUI now refetches the run once at exit when the summary is missing, and the report says explicitly when transcripts aren't available yet.Note: quitting before summarize completes still can't include transcripts — the server only attaches ChatHistory with the summary. Decoupling transcripts from summarize (serving them per-job as soon as each simulation completes) would be the structural fix, in agent-service.