feat(tui): /resume — pick up a saved session in the fullscreen TUI - #562
Draft
justrach wants to merge 1 commit into
Draft
feat(tui): /resume — pick up a saved session in the fullscreen TUI#562justrach wants to merge 1 commit into
justrach wants to merge 1 commit into
Conversation
…een TUI /resume opens a searchable picker over .graff/sessions (the same store and metadata the line REPL's /resume and /sessions read): base — title (age), newest first, fuzzy filter, Enter loads. /resume <name> skips the picker. The load extracts the saved conversation's user/assistant text turns (plain strings and structured text blocks; tool traffic skipped) into the transcript, so the next turn resends them as model-visible history, and re-applies the session's saved model through the /model switch path. Plumbing follows the /compact seam: engine.g_sessions_fn/g_resume_fn set from tui_launch, implemented in src/tui_resume.zig; picker UI in TUI/resume.zig mirrors the model picker. /resume is guarded behind the mid-turn #521 gate, and its notices force the agent screen so they are never hidden behind the welcome pane. Verified end-to-end under a pty against a real session fixture: picker renders base/title/age, Enter loads 3 turns including an anthropic-style text-block message, and the resumed rows paint. Co-Authored-By: Codegraff <blackfloofie@codegraff.com>
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.
This is the first slice of harness parity: every peer pager (Claude
-c/-r, Codexresume, Pi/resume, OpenCode session attach) lets you close the TUI and pick the session back up. Graff’s line REPL already had/save//resume; the fullscreen TUI started a fresh transcript.Rebase of #538 onto current
main(clickable panels, paint, Gemini effort)./resumeopens a searchable picker over.graff/sessions(title + age, newest first);/resume <name>loads directly. User/assistant text lands in the transcript, the saved model is re-applied, andhistoryChanged(.reset)seeds the next turn from the resumed conversation.Still not in this slice (follow-ups): tool_use/tool_result blocks, TUI
/save, session name in the top bar, same-named model seats under two providers.zig build tui-test -Dtest-filter="resume"13/13.