Measured on a 93-request session after #106: 7 of the 8 largest cache writes sat exactly 8 turns apart (requests 17,25,...,73), each re-writing the whole history (reads 3295 = prefix only), ~345k extra write tokens vs ~1.4M fewer read tokens. A boundary change rewrites the cache from the first changed result on, so stepping every 8 turns costs more than it saves at these context sizes.
Agent keeps mask_boundary; it only moves forward, and only when the estimated target boundary moved AND the context is above compact_at / 3. Below that, no masking at all (no cache breaks). Reset on session replace / fork / clear / compaction.
mask_old_results(msgs, boundary) is now a pure function of the boundary; target_boundary keeps the 8-turn rule as the target.
The boundary used is stored on each assistant session entry (mask); hx stats replays exactly that (older files: stepwise rule).
Tests: no masking below the threshold, boundary monotone and recorded above it, no compaction side effects.
The /3 factor is a guess; re-check the cache-write outlier list in hx stats after the next long session.
Measured on a 93-request session after #106: 7 of the 8 largest cache writes sat exactly 8 turns apart (requests 17,25,...,73), each re-writing the whole history (reads 3295 = prefix only), ~345k extra write tokens vs ~1.4M fewer read tokens. A boundary change rewrites the cache from the first changed result on, so stepping every 8 turns costs more than it saves at these context sizes.
- `Agent` keeps `mask_boundary`; it only moves forward, and only when the estimated target boundary moved AND the context is above `compact_at / 3`. Below that, no masking at all (no cache breaks). Reset on session replace / fork / clear / compaction.
- `mask_old_results(msgs, boundary)` is now a pure function of the boundary; `target_boundary` keeps the 8-turn rule as the target.
- The boundary used is stored on each assistant session entry (`mask`); `hx stats` replays exactly that (older files: stepwise rule).
- Tests: no masking below the threshold, boundary monotone and recorded above it, no compaction side effects.
The `/3` factor is a guess; re-check the cache-write outlier list in `hx stats` after the next long session.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Measured on a 93-request session after #106: 7 of the 8 largest cache writes sat exactly 8 turns apart (requests 17,25,...,73), each re-writing the whole history (reads 3295 = prefix only), ~345k extra write tokens vs ~1.4M fewer read tokens. A boundary change rewrites the cache from the first changed result on, so stepping every 8 turns costs more than it saves at these context sizes.
Agentkeepsmask_boundary; it only moves forward, and only when the estimated target boundary moved AND the context is abovecompact_at / 3. Below that, no masking at all (no cache breaks). Reset on session replace / fork / clear / compaction.mask_old_results(msgs, boundary)is now a pure function of the boundary;target_boundarykeeps the 8-turn rule as the target.mask);hx statsreplays exactly that (older files: stepwise rule).The
/3factor is a guess; re-check the cache-write outlier list inhx statsafter the next long session.