Post-compaction skill reminders present stale skill content as currently binding

Status Open
Reported on v2.1.220
Maintainer reply None cached
Activity 1 comment · opened Aug 2, 2026

What happened

In a long-running session, a project skill (.claude/skills/crucible/SKILL.md) was invoked
early on. Later, the skill file on disk was amended to add new mandatory review rules. The
session then went through several compactions.

After each compaction, the harness re-injected the skill text into context in a reminder
block that says the skill was invoked earlier and to "continue to apply ongoing behavioral
guidelines from these skills where still relevant." The injected text was the skill as it
read at invocation time, not the current file. There is no indication that the file has
changed since.

The model kept operating from the stale revision across roughly ten subsequent uses of the
skill and missed rules that had been added to the file. The miss was only caught when I
noticed the behavior didn't match what the skill now says.

Why this matters

A common pattern for long-running projects is to iterate on your own skill files as lessons
accumulate. This staleness silently defeats that: the harness presents the old text with
standing authority, so the more a session relies on the reminder (instead of re-invoking the
skill), the more the file's evolution is lost. Stale context after compaction is expected in
general; the bug is presenting it as currently binding with no invalidation signal.

Repro sketch

  1. Invoke a project skill.
  2. Edit that skill's SKILL.md to add a clearly checkable rule.
  3. Let the conversation compact.
  4. The post-compaction reminder contains the pre-edit skill text, with no note that the file

changed.

  1. The model follows the pre-edit text.

Possible fixes

Any of these would close it:

  • Re-read SKILL.md from disk when re-injecting after compaction.
  • Include a content hash or mtime at invocation, and on re-injection add a "this file has

changed since invocation; re-invoke to refresh" note when it no longer matches.

  • Weaken the "continue to apply" instruction for re-injected copies so the model treats them

as historical record rather than current authority.

Environment

  • Claude Code 2.1.220, Linux
  • Long-running session with multiple compactions
  • Observed with a project-scoped skill under .claude/skills/

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗