Agnostic Repo Mirror
One repo, many harnesses. Keep AGENTS.md as the canonical source of
truth, shrink CLAUDE.md to a thin import, serve one shared skills
directory through a link, and audit drift on a schedule. File-level
mirror, not memory handoff: unified-memory moves context between
agents, this skill keeps the repo surfaces identical.
When To Activate
- The user says same brain, stop choosing between harnesses, Claude plus Codex, repo agnostic, or skills in two places.
- Rules live in both
CLAUDE.mdandAGENTS.mdand already disagree. - Skills are duplicated under per-harness folders and fixes land in only one copy.
- A team adds a second harness to a repo that was Claude-only.
Layout
repo/
|-- AGENTS.md # canonical rules, edit here
|-- CLAUDE.md # thin import, do not extend
|-- .agents/
| `-- skills/ # canonical skills
`-- .claude/
`-- skills -> ../.agents/skills # link, not a copy
- Canonical content lives in exactly one place. Every other surface imports or links to it.
- No rule text is typed twice. Duplicated text is drift waiting to happen.
Workflow
1. Promote AGENTS.md to canon
- Move all durable rules into
AGENTS.md: identity, routing, model policy, tool policy, style, done criteria. - Delete harness-specific paths from the canon. Keep generic tokens
like
<repo>and<skills-dir>instead of per-tool paths. - Commit the canon before touching any import.
2. Shrink CLAUDE.md to an import
- Reduce
CLAUDE.mdto a short header plus one import line pointing at the canon:
@AGENTS.md
- Keep at most a small Claude-only appendix below the import for genuinely Claude-only behavior. Anything shared moves up.
- Rule: edits to shared behavior go to
AGENTS.md, never to the appendix.