agentleFS
tmussertmusser/ai-engineering-skills/skills/context-check/SKILL.md

context-check

Skill6 starsChanged 3 months agoMITView on GitHub

Detect context drift, rehydration loops, hypothesis sprawl, scope creep, active-mode loss, and durable-state gaps. Recommend the smallest corrective action.

3 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

2 rules. 0 are common, 2 are distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 3 edited versions we read keep these.

  • 2

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Keep sessions cheap, bounded, and durable.

    line 10
  2. Distinctive:

    Keep FREEZE NOW limited to facts, decisions, assumptions, IDs, files, tests, active modes, current hypothesis, and next verification that …

    line 47

“Common” is measured: kept by at least 6 in 10 of the 3 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Context Check

Purpose

Keep sessions cheap, bounded, and durable. Detect distortion early and recommend minimal correction.

When to use

Passive guardrail. Speak only on medium/high risk (or when explicitly invoked).

Low risk: stay silent unless explicitly invoked. If explicitly invoked on low risk, output one line: CONTEXT RISK: low — continue.

Trigger on repeated facts, scope/hypothesis changes, multiple debug hypotheses, handoff pressure, or active modes that may need to persist.

Inputs

  • Current conversation
  • Durable state files if present
  • Current task, phase, loop, and active modes if known
  • Current debugging hypothesis if debugging
  • Where to record the result when the check is medium/high risk

Workflow

  1. Scan for risk signals (repeated premises, history restatement, scope drift, hypothesis sprawl, weak durable state, active-mode loss).
  2. Assign risk: low / medium / high.
  3. Recommend exactly one best move. For medium/high risk, prefer: scope-freeze | update durable state | handoff | diagnose-loop | restart. Use continue only for explicit low-risk checks.
  4. Record where to persist the result when the risk is medium/high: RECORD IN: HANDOFF.md | VERIFY.md | SPEC.md | none.
  5. On medium/high risk, output the structured block. Recommend restart only when context is actively corrupting decisions.

Output format (medium/high only):

CONTEXT RISK: medium
TRIGGER: repeated premise repair on X
BEST MOVE: handoff | scope-freeze | update PLAN.md | etc.
FREEZE NOW: [key facts/decisions/modes/hypothesis]
NEXT ACTION: ...
RECORD IN: HANDOFF.md | VERIFY.md | SPEC.md | none

Keep FREEZE NOW limited to facts, decisions, assumptions, IDs, files, tests, active modes, current hypothesis, and next verification that must survive.

Outputs

  • Concise risk assessment
  • One recommended action
  • Minimal freeze list when needed

Success looks like

  • Low risk → no output (unless explicitly invoked), work continues cleanly.
  • Medium risk → quick state update prevents drift.
  • High risk → handoff or restart before more damage.

Example (medium risk):

CONTEXT RISK: medium
TRIGGER: scope subtly expanding
BEST MOVE: scope-freeze
FREEZE NOW: only modify files in /src/featureX

Stop conditions

  • Next action is clear.
  • Durable state holds necessary facts.
  • One active hypothesis (if debugging).
  • Active modes captured for persistence.

Anti-patterns

  • Triggering on normal long conversations.
  • Producing checklists instead of one action.
  • Full thread summaries.
  • Letting multiple debug hypotheses coexist.
  • Assuming modes survive without writing them down.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.