Audit your AGENTS.md, CLAUDE.md, and Cursor rules against the real repo
Agents follow the instructions you give them, even when those instructions are stale, contradictory, or wrong. Guard audits your context and rules files and keeps them aligned with the code they describe.
1 repo · setup in about 5 minutes · no card, no commitment
01
What AGENTS.md, CLAUDE.md, and Cursor rules are
These are the instruction files coding agents read before they touch your repo: AGENTS.md (tool-agnostic), CLAUDE.md (Claude Code), and .cursorrules or Cursor rules (Cursor). They tell the agent how to build, test, and behave in your codebase. New to them? Start with our AGENTS.md best practices guide. Get them right and agents act with context; let them drift and agents follow rules that are no longer true.
02
Agents do not remember the project by default
Teams often assume an agent remembers the product, the architecture, and the decisions from the last run. In practice, the agent works from whatever context the repository and tooling make available. If that context is thin, scattered, or stale, the agent guesses.
03
Context files rot faster than anyone updates them
An AGENTS.md or CLAUDE.md written on day one quietly stops matching the codebase by month two. That context rot makes the agent keep trusting rules that no longer reflect reality, confidently, and wrongly.
04
What Guard checks in your rules
Guard treats context files as code that can drift, waste context budget, create token burn, and break:
- Rules that contradict the actual codebase
- Conflicting instructions across AGENTS.md, CLAUDE.md, .cursorrules, Cursor rules, and repository instructions for AI agents
- Missing context that leaves agents guessing
- Secrets or sensitive paths leaked into rules files
- Stale conventions the team no longer follows
05
Aligned with the repo as it changes
As the code changes, the rules should too. Guard re-audits context files on a schedule and flags where they have drifted from the repo, so your agents work from instructions that are actually true. Trimming stale rules is also context budget optimization: less old context for the agent to read before it reaches the task in front of it.
06
Fixes you review
Drift and gaps come back as reviewable GitHub issues with rationale. When a fix is bounded and useful, Guard can open a pull request that updates the rules to match the code.
Quick questions
My AGENTS.md is fine. Why audit it?
Because it rots. A file written on day one quietly stops matching the code by month two, and agents keep trusting it, confidently and wrongly. The risk is drift, not the first draft.
Does it cover CLAUDE.md, .cursorrules, and Copilot instructions together?
Yes. Guard checks AGENTS.md, CLAUDE.md, .cursorrules, Cursor rules, and equivalent repo instructions, and flags where they conflict with each other or with the code.
What are context rot and token burn, in plain terms?
Stale or duplicated rules make an agent spend its limited context reading old instructions instead of the task in front of it. That wasted context budget is context rot; the cost of reading it is token burn.
Should rules live in one root file or per folder?
It depends on scope. Guard flags rules that belong closer to a subdirectory and instructions too broad to sit at the root, so each agent loads what is relevant.
Make sure your agents read the right rules.
Connect a repo and get your first context report in a few minutes. No card.
Enji Guard