Chat: finish hiding compaction reminders (follow-up to #526) (bugfix) #542
All Vouch review confidence checks passed
Residual risk 0.22 = Change Risk (0.50) × (1 − Review Confidence (0.57)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.50 · 628 lines diff across 7 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.386
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #542"
general
weight: 0.35
Giton22
Follow-up to #526.
After a context compression, hermes-agent v0.23.4 often folds the task list into the last real user row instead of storing it as a row of its own. A reloaded chat showed it under the person's own prompt, under a bot's message and under a scheduled result. #526 hid a reminder only when its header was the row's first line, so it missed all of these. The three review fixes for #526 (9a83c52a, 9a757aa6, 5e3fb8c8) never reached master. This PR ports them, adapted to what the author added after the review.
| Before (master, v0.23.4) | After (v0.23.4) |
|---|---|
| <img src="https://raw.githubusercontent.com/Giton22/kyllene/9f7df5d5a833a9e76ee8b565ab41db0ffecb4eb1/before-v0234.png" width="300"> | <img src="https://raw.githubusercontent.com/Giton22/kyllene/9f7df5d5a833a9e76ee8b565ab41db0ffecb4eb1/after-v0234.png" width="300"> |
What each case fixes
scheduledResultWithCompactionReminderHeaderRemainsARoutine.-item follows the header (tools/todo_tool.pyformat_for_injectionnever writes the header alone). So a prompt that starts with the header and goes on in its own words stays./branch N. It now counts messages the way the chat shows them (taken fromhistoryToMessages). Reminder rows and a restatement whose original is loaded are skipped, and a reply's step after one of them adds to that reply. Before, the branch ended a message early.The ROADMAP line is ticked, and the "compaction reminders" row in
docs/bot-mode-integration.mdis updated.Dropped on purpose
The review fix hid every row flagged
compaction_inflight_task_restatement. That is left out. v0.23.4 writes the flag only on the standalone replay row, and that row always starts with the restatement header (agent/context_compressor.py). The same code removes the original row, so the replay is often the only copy. Master (36e79dcb) shows that copy without its header while its original isn't loaded, and hiding every flagged row would undo it. The test is rewritten to cover master's behaviour: a flagged restatement with the list folded into it shows as "Draft them" when it is the only copy, and is left out once its original is loaded.Testing
HistoryToMessagesTestgets three tests ported from the review fixes, one rewritten as above, plus a scheduled result with the list folded in.HistoryPagesTestandChatSessionTesteach get the ported test. On master, all of them fail.:shared:core:testAndroidHostTestpasses, and so does:desktopApp:compileKotlinJvm.state.db: the list folded into the prompt after a blank line, plus a standalone task-list row and an assistant step after it. Then I reloaded the chat.| Gateway | Mode | master | this branch |
|---|---|---|---|
| v0.23.4 | authority (webapp listener) | list shown under the prompt | prompt alone; the standalone row is hidden and its step joins the reply; a follow-up still sends and gets its reply |
| v0.23.4 | legacy (
hermes dashboard) | (same rows) | prompt alone || v0.22.0 | legacy (
hermes dashboard) | list shown under the prompt | prompt alone |v0.22.3 and v0.22.7 were not tested. The stored rows have the same columns as v0.22.0 and v0.23.4.
<details><summary>v0.22.0 legacy, and v0.23.4 legacy</summary>
| v0.22.0 before | v0.22.0 after | v0.23.4 legacy after |
|---|---|---|
| <img src="https://raw.githubusercontent.com/Giton22/kyllene/9f7df5d5a833a9e76ee8b565ab41db0ffecb4eb1/before-v0220-legacy.png" width="240"> | <img src="https://raw.githubusercontent.com/Giton22/kyllene/9f7df5d5a833a9e76ee8b565ab41db0ffecb4eb1/after-v0220-legacy.png" width="240"> | <img src="https://raw.githubusercontent.com/Giton22/kyllene/9f7df5d5a833a9e76ee8b565ab41db0ffecb4eb1/after-v0234-legacy.png" width="240"> |
</details>
Not checked on a device: pictures and bot messages with the list folded in. The fake model can't produce those rows, so unit tests cover them.
Created with Claude Opus 5.5 in Claude Code.