Skip to content

feat: add local agent chat history panel - #106

Merged
howdeploy merged 3 commits into
howdeploy:mainfrom
Yt4aZaveta:codex/agent-chat-history
Sep 30, 2026
Merged

howdeploy merged 3 commits into
howdeploy:mainfrom
Yt4aZaveta:codex/agent-chat-history

Conversation

@Yt4aZaveta

@Yt4aZaveta Yt4aZaveta commented Sep 30, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Add an opt-in chat history panel so users can find an earlier agent conversation and continue it in CanvasTTY without opening a CLI session picker. Selecting an already open conversation focuses its existing terminal; selecting an exited conversation resumes it in the same card.

  • List locally available CanvasTTY agents in separate tabs. Read session metadata from Codex, Claude, OpenCode, Hermes, Grok, Qwen, Kimi, Pi, OMP, MiniMax and current Cursor CLI stores.
  • Group conversations by project, with collapsible groups and a collapse-all action. Collapsed groups keep their open conversations visible and hide inactive history rows. Filter by activity over 24 hours, 7 days or all sessions; filter changes apply immediately. Projects are initially collapsed except those with open sessions.
  • Search session titles and working-directory paths. Settings choose the current agent or all available agents, and the selected activity filter or all sessions.
  • Match the minimap appearance, default to the top-left corner, and support hover or click expansion. The header toggles the panel; typing in a terminal collapses it while terminal focus/mouse escape reports do not.
  • Show open/working session markers and preserve conversation IDs across metadata events, rename and restore settings. Repeated explicit focus requests return keyboard input to the terminal, including when the same card remains selected.
  • Load a per-launch OMP extension to report the exact conversation ID for ordinary launches, session switches and branches, plus working/idle status. Spawned OMP agents cannot replace the main terminal's identity. No global OMP configuration is modified.
  • Keep OpenCode activity timestamps in milliseconds and retain complete JSONL metadata records at the bounded reader's 64 KiB boundary. Read SQLite metadata off the main thread and return paginated metadata to the renderer.
  • Resolve data locations from the user's home and the CLI's own environment rules on macOS, Windows and Linux. Honor OpenCode's XDG_DATA_HOME, OMP's active profile and migrated XDG directories, and Pi's session-directory override. Qwen uses QWEN_RUNTIME_DIR / QWEN_HOME and reads both current projects and legacy tmp layouts without duplicate sessions. Windows environment names are case-insensitive and UNC paths are preserved. Hermes reuses the same platform-specific home resolver as terminal launch.

The panel is disabled by default. Enable it in Settings.

Verification

  • npm test: 1,253 passed, 0 failed, 2 skipped (1,255 total), on macOS arm64.
  • npm run test:even: 47 passed, 0 failed.
  • npm run build: passed, including Node and renderer TypeScript checks.
  • npm run audit:secrets: passed for repository source and the built application bundle.
  • Adapter fixtures cover activity timestamps, renamed titles in long Claude/Pi conversations, Qwen/OMP metadata, Kimi local workspaces, MiniMax SQLite metadata and Cursor sidecars. Terminal regression tests cover metadata identity, exact resume, fresh restart and preference for a running card.
  • HUD regression coverage exercises collapsed active rows, exited rows and terminal focus. OMP extension integration uses the real runtime gateway and terminal manager to cover ordinary launches, same-project conversation isolation, working/idle status, session switches, branches and subagent isolation. Installed OMP 18.4.4 loaded the extension and reported a new session ID in isolated headless RPC mode without model requests.
  • History-location tests exercise the service against real temporary stores and check path resolution for simulated macOS, Windows and Linux homes, environment precedence, Windows UNC paths, OMP profile/XDG adoption, and both Qwen layouts. These run in the existing Linux/Windows CI test suites; simulated platform cases do not replace native GUI testing.
  • Native CI results are pending. The upstream fork-PR workflow requires action before it runs; dispatching the existing CI in the new fork returned a workflow-not-found error despite the YAML being present on its default branch.
  • Installed r11 macOS GUI: immediate Codex/OpenCode activity filtering, search, collapse-all, active Codex markers, Hermes open markers, mouse and Tab/Enter focus return, collapse on unsent terminal input, and in-place resume after a test Hermes session exited. The installed application bundle's SHA-256 matched its DMG. The test card and unsent text were removed afterwards.
  • The r12 arm64 package passed codesign --verify --deep --strict; its DMG passed hdiutil verify. R12 contains the additional Cursor adapter and the JSONL boundary correction, verified by fixtures/build rather than a new installed-GUI run. The later data-location, collapsed-active-row and OMP lifecycle fixes have source/test/build validation and are not included in that DMG.

Limitations

  • Devin and Antigravity remain explicitly unsupported for history listing. Their tabs report that limitation rather than presenting an existing history as empty.
  • Additional history adapters were verified against provider source/distributions and synthetic stores; except for the OMP startup check above, their CLIs were not exercised in live session tests. Older Cursor databases without metadata sidecars produce a skipped-record warning. Older Qwen JSON stores remain unverified.
  • Storage overrides must be available to CanvasTTY in its launch environment. Paths configured only in another shell's startup files, provider-loaded .env files or per-project settings are not automatically discovered. Local history does not scan remote/WSL/container stores.
  • Search covers titles and working-directory paths, not full conversation bodies. No transcript bodies are sent to the renderer.
  • Brief transition flicker and hover-only timing were not independently measured; search-scope settings and live Grok sessions were not exercised in GUI. Native Windows and Linux GUI behavior remain unverified.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants