# NousResearch/hermes-agent · System prompt lost during mid-session route commits

## Open now

- Nothing open on GitHub.

A bug causes the stored system prompt to be nulled out when route commits occur mid-session, triggering a warning and unnecessary rebuild. Several fixes address preserving the system prompt across route commits, plus a related safeguard against deleting git-tracked files.

## TL;DR

- 5 member(s): 0 open issue(s), 1 closed issue(s), 0 open PR(s), 2 merged PR(s), 2 PR(s) closed without merging.
- A fix was merged to main in PR #124167. Verify it addresses your case.
- **Recommended:** read PR #124167 (and any competing PRs below) before filing. Confirm the merged change covers your symptom.

## Maintainer resolution verdict

- Internal-tracker verdict over this cluster's issue members: `unresolved`. This is distinct from the fix status above. Weigh it yourself.

## How this cluster was grouped

- Link evidence (`STRUCTURAL_SPANNING`): every member is connected by structural evidence: shared changed files, or a closing/superseded reference.
- Pairwise link density `0.50`: the share of member 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.

## Closed / duplicate issues

- #121840: \[Bug\] Mid-session route commits null the stored system prompt; next turn logs the "is null / investigate update_system_prompt" WARNING for a deliberate DB write, and rebuilds from scratch

## Prior & competing PRs

- **#124167: fix(state): route commits keep the stored system prompt**. merged to main · fix tier `verified`
  - maintainer direction: category `merged`; implication `superseded`
  - files: `agent/conversation_compression.py`, `contributors/emails/[redacted:email]`, `hermes_state_sessions.py`, `hermes_state_usage.py`, `tests/agent/test_system_prompt_switch_invalidation.py`, `tests/hermes_cli/test_session_system_prompt_dedup.py`
- **#124281: fix(disk-cleanup): never delete git-tracked files, even when HERMES_HOME is a checkout**. merged to main · fix tier `verified`
  - maintainer direction: category `merged`; implication `superseded`
  - files: `contributors/emails/[redacted:email]`, `hermes_cli/source_check.py`, `plugins/disk-cleanup/disk_cleanup.py`, `tests/plugins/test_disk_cleanup_plugin.py`
- **#121843: fix(state): stop nulling the stored system prompt on route commits**. closed without merge
  - maintainer direction: category `implemented_elsewhere`; implication `superseded`; refs `f14626243e66`, `#124281`
- **#121907: fix(state): preserve system prompts across route commits**. closed without merge
  - maintainer direction: category `merged_via`; implication `superseded`; refs `#121843`, `#124167`, `#124167`

## Fix status

- Merged to main in PR #124167 (cited above). No release data is tracked. Verify downstream.
- Fix last verified (merged) `2026-09-26`.
