NousResearch/hermes-agent

Surface switch causes unnecessary system prompt rebuild and cache miss

Cluster 104414. Data as of

Nothing open on GitHub. Fix merged in #105844 on 9 Sep 2026. Check it covers your case.

The short answer

0open issues
0open PRs
4items grouped
Known?
Yes. 4 related items grouped here, 1 issue already closed.
Fix event
A fix was merged to main in PR #105844. Check it covers your case. No release data is tracked.
Tracker
The maintainers' tracker marks this resolved, deciding PR #105844. That is separate from the fix event.
Still open
Nothing open on GitHub.

A bug where switching between desktop and TUI surfaces invalidates the stored system prompt, triggering a full rebuild and losing prompt-cache hits on large contexts. The members include the bug report and related fix attempts addressing this cache inefficiency.

Open issues0

No open issues.

Open PRs0

No open pull requests.

Fixes on record

Merged to main. A stamp counts the issues a fix is linked to.

  • #105844 Surface switch (desktop↔TUI) no longer rebuilds the system prompt and re-prefills the request (#104414, salvage #104494)

    merged to main

    files: agent/conversation_loop.py, agent/surface_switch.py, agent/system_prompt.py, agent/turn_context.py, tests/agent/test_system_prompt_restore.py, tools/mcp_tool_agent.py, website/docs/developer-guide/prompt-assembly.md

2 PRs closed without merging

From the close comments: duplicate 1 · merged via another change 1

  • #104484 fix(agent): ignore surface/cwd drift when reusing stored system prompt · duplicate → #104494, #104414
  • #104494 fix(agent): a surface switch must not re-prefill the whole request (#104414) · merged via another change → a54945f, 4e30306, #105844
Closed issues · 1
  • Closed#104414[Bug]: Surface switch (desktop↔TUI) makes stored system prompt 'stale' → full rebuild → 100% prompt-cache miss (200K+) across restart/resume
How this cluster was grouped
  • Link evidence (structural links throughout): every member is connected by structural evidence: shared changed files, or a closing/superseded reference.
  • Pairwise link density 0.50: the share of item pairs that carry a link, counting a structural link in full and a relevance-only link at 0.36. 1.00 means every pair is linked.

Pick up a Lab task

Check whether a fix covers the open issues here, with your own agent. Bring back evidence for maintainers.

Open the Lab

At a glance

Merged PRs
#105844
Closed issues
1
Attempts
2 PRs closed without merging
Fix link checked
9 Sep 2026

For your agent

The same facts, typed.