# NousResearch/hermes-agent · Fix reasoning token estimates in preflight compression

## Open now

- Nothing open on GitHub.

These items address a bug where reasoning_details content was incorrectly included in preflight token estimates, causing compression to trigger too early on thinking models. Fixes also touch compression index clamping, failure cooldown, and user-query preservation.

## TL;DR

- 4 member(s): 0 open issue(s), 1 closed issue(s), 0 open PR(s), 1 merged PR(s), 2 PR(s) closed without merging.
- A fix was merged to main in PR #75884. Verify it addresses your case.
- **Recommended:** read PR #75884 (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: `resolved` · deciding PR(s): `pr-75884`. 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

- #73298: \[Bug\]: Preflight token estimate counts reasoning_details envelope at chars/4 — compression fires at ~27% of real usage on thinking models

## Prior & competing PRs

- **#75884: fix(compression): index clamps, persisted failure cooldown, user-query preservation, thinking-token estimates**. merged to main · fix tier `verified`
  - maintainer direction: category `merged`
  - files: `agent/context_compressor.py`, `agent/model_metadata.py`, `contributors/emails/[redacted:email]`, `gateway/run.py`, `tests/agent/test_budget_reasoning_details_exclusion.py`, `tests/agent/test_compressor_tail_cut_oob_fix.py`, `tests/agent/test_compressor_zero_user_guard.py`, `tests/gateway/test_session_hygiene.py`
- **#73306: fix: exclude reasoning_details from preflight token estimate (#73298)**. closed without merge
  - maintainer direction: category `merged_via`; implication `superseded`; refs `#75884`, `#51800`, `#73298`
- **#103447: fix: exclude reasoning_details from preflight token estimate (#73298)**. closed without merge
  - maintainer direction: category `implemented_elsewhere`; implication `superseded`; refs `#73306`, `#75884`, `#73298`

## Fix status

- Merged to main in PR #75884 (cited above). No release data is tracked. Verify downstream.
- Fix last verified (merged) `2026-08-01`.
- Subsystem: `agent`
