NousResearch/hermes-agent

Fixes for conversation history starting with assistant turn

Cluster 52160 · agent. Data as of

Nothing open on GitHub. Fix merged in #69340 on 22 Jul 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 #69340. Check it covers your case. No release data is tracked.
Tracker
The maintainers' tracker marks this resolved, deciding PR #69340. That is separate from the fix event.
Still open
Nothing open on GitHub.

Multiple fixes addressing cases where context compression or compaction leaves conversation histories beginning with an assistant or model message, causing API 400 errors across Anthropic and Gemini adapters. Patches include guarding, stripping, or prepending user turns to restore valid message ordering.

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.

  • #69340 fix(anthropic): guard leading-assistant transcripts after double compaction

    merged to main

    files: agent/anthropic_adapter.py, tests/agent/test_anthropic_adapter.py

2 PRs closed without merging

From the close comments: done elsewhere 1 · merged via another change 1

  • #52167 fix(compressor): pin summary role to user when only system prompt is protected (#52160) · done elsewhere → 8f4d195, #56197
  • #52276 fix(anthropic): prepend user turn when compaction leaves a leading assistant message · merged via another change → b6a2b70, #69340
Closed issues · 1
  • Closed#52160bug(adapter): HTTP 400 after double context compression — first message is assistant, not user
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

Subsystem
agent
Merged PRs
#69340
Closed issues
1
Attempts
2 PRs closed without merging
Fix link checked
22 Jul 2026

For your agent

The same facts, typed.