plugins/autonomous-dev/skills/content-allocation/SKILL.md
One topic, one home. Routes content to its canonical store (CLAUDE.md, PROJECT.md, MEMORY.md, docs/, memory/) and audits for duplication. TRIGGER when: auditing CLAUDE.md/PROJECT.md/MEMORY.md sizes, deduplicating docs, applying the content-allocation pattern to a new repo, running /align --content. DO NOT TRIGGER when: implementing features, writing tests, routine code edits, debugging.
npx skillsauth add akaszubski/autonomous-dev content-allocationInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
A methodology for keeping project context lean and unambiguous. Every piece of content has exactly one canonical home; every other appearance is a one-line pointer.
Core rule: If a piece of content lives in two places, one of them is wrong. The canonical store owns the content; every other location is a one-line pointer to it.
Why this matters:
CLAUDE.md and MEMORY.md are loaded every turn. Every line there has compounding cost across the project's lifetime.The pattern works in three moves:
See: docs/RUNBOOK.md).The canonical stores in a typical Claude Code project, in load-order:
| Store | Loaded | Owns | Does NOT own |
|-------|--------|------|--------------|
| ~/.claude/CLAUDE.md (global) | every turn, every repo | Assistant default behaviour; user's machines, SSH, session history queries | Anything project-specific |
| CLAUDE.md (project root) | every turn, this repo | Hard rules, gates, canonical paths, pointers, top-N gotchas | Vision, purpose, architecture, history, current state, deep reference |
| .claude/PROJECT.md | session start | Purpose, GOALS, SCOPE, CONSTRAINTS, alignment criteria, project philosophy | Behaviour rules; operational sequences; full architecture diagrams; current state |
| memory/MEMORY.md + memory/*.md | MEMORY auto-loaded; files retrievable | Durable lessons (with why), findings, calibration, active state | Hard rules; full architecture |
| docs/RUNBOOK.md | on demand | Operational sequences (periodic maintenance, batch finalize, resumes, common queries) | Architecture; rules |
| docs/architecture/*.md | on demand | High-level system architecture, layers, diagrams, ADRs | Behaviour rules; deep component internals |
| docs/<TOPIC>.md (per-domain) | on demand | Deep reference per topic (testing, security, hooks, libraries) | Behaviour; vision |
| Plugin user-facing docs/*.md | on demand | Shipped-with-plugin reference (commands, troubleshooting) | Maintainer-internal flows |
| GitHub issues | on reference | Current/open/closed work, decision threads | Anything else |
If a topic spans two stores: the narrative lives in PROJECT.md or docs/; the rule lives in CLAUDE.md; both reference each other as 1-line pointers.
When you have new content to place, walk this 9-step ordered list and stop at the first match:
CLAUDE.md Critical Rules section..claude/PROJECT.md.memory/feedback_*.md (+ one-line index entry in MEMORY.md).memory/finding_*.md (+ index entry).docs/RUNBOOK.md.docs/<REGISTRY>.md. User-facing command catalogue → plugin's docs/COMMANDS.md.docs/<TOPIC>.md if catalogued.docs/<TOPIC>.md (e.g. HOOK-COMPOSITION.md, SECURITY.md).docs/TROUBLESHOOTING.md.If you reach step 9 without a match, the content is probably scratch work or belongs in a GitHub issue.
Auto-loaded files have hard ceilings. Exceed them and you pay the cost every turn.
| File | Target | Hard ceiling | Why |
|------|--------|--------------|-----|
| CLAUDE.md | ≤100 lines | 200 | Loaded every turn. A size-validation hook should warn above 200. |
| .claude/PROJECT.md | ≤150 lines | 200 | Loaded at session start. Above 200 = operational drift, not architecture. |
| MEMORY.md | ≤150 lines | 200 | Often truncated above 200 when auto-loaded. |
| memory/*.md (individual) | 1–3 KB | 3 KB | >3 KB usually means it should be promoted to a docs/ page. |
Rules of thumb:
MEMORY.md entries should be ≤150 chars per line. If you cannot summarise a finding in one line, the underlying file needs splitting.CLAUDE.md. Global covers cross-repo assistant defaults; project covers this repo only.Run after major refactors or every ~10 sessions:
memory/ for content now in CLAUDE.md or PROJECT.md. Compress duplicates to pointers.RESOLVED, DONE, SUPERSEDED markers, or session_*_outcomes.md files older than 7 days.MEMORY.md index entry or get deleted.The table above is the default. Adapt it to the repo you are applying it to:
Use the table as-is. The pattern was developed for code repos with a normal docs/ tree and a Claude Code plugin installed.
docs/RUNBOOK.md to the primary store for operational content; demote PROJECT.md to a brief overview.memory/ mostly holds incident postmortems rather than feature findings.docs/runbooks/*.md subtree for per-service playbooks.CLAUDE.md should be short — usually just pointers to docs/ indexes.docs/ as the primary store; memory/ is small and reserved for editorial decisions ("we chose X writing style because Y").PROJECT.md may be omitted entirely if the repo has no goal beyond "collect notes."When in doubt, ask: "Which file would a new collaborator open first to answer this question?" That file is the canonical home.
/align --content Uses This SkillThe /align --content command runs a 4-phase workflow that operationalises this skill:
CLAUDE.md, PROJECT.md, MEMORY.md, all memory/*.md, and the top-level docs/ listing.--dry-run skips this and only emits the plan.--auto accepts all proposals that fall below a risk threshold (e.g. compressions and deletions); content moves between tiers still require explicit approval.The skill is the methodology; the command is the workflow runner; the template (templates/CONTENT_ALLOCATION.md) is the drop-in artefact for repos that want a local copy of the routing rules.
FORBIDDEN:
CLAUDE.md without first asking: "Does this change behaviour every turn?" — if no, route to memory or docs.CLAUDE.md exceed 200 lines or MEMORY.md exceed 200 lines without a hygiene sweep.~/.claude/CLAUDE.md and project CLAUDE.md.PROJECT.md and CLAUDE.md — pick one and use a pointer from the other.REQUIRED:
MEMORY.md index entry MUST be ≤150 chars and point to its source file.docs/./align --content PROPOSE phase MUST list the canonical home for each move.docs/development
GenAI-first testing with structural assertions, congruence validation, and tier-based test structure. Use when writing tests, setting up test infrastructure, or validating coverage. TRIGGER when: test, pytest, coverage, TDD, test patterns, congruence, validation. DO NOT TRIGGER when: production code implementation, documentation, config-only changes.
testing
Prompt engineering patterns for writing agent prompts and skill files — constraint budgets, register shifting, HARD GATE patterns, anti-personas. Use when writing or reviewing agents/*.md or skills/*/SKILL.md. TRIGGER when: agent prompt, skill file, prompt engineering, model-tier compensation, HARD GATE, prompt quality. DO NOT TRIGGER when: user-facing docs, README, CHANGELOG, config files.
testing
7-step planning workflow for pre-implementation design. Enforced by plan_gate hook, critiqued by plan-critic agent. Use when creating plans, design documents, or architecture decisions before implementation. TRIGGER when: plan, planning, /plan, design document, architecture decision. DO NOT TRIGGER when: implementation, coding, testing.
testing
JSON persistence, atomic writes, file locking, crash recovery, and state versioning patterns. Use when implementing stateful libraries or features requiring persistent state. TRIGGER when: state persistence, atomic write, file locking, crash recovery, checkpoint. DO NOT TRIGGER when: stateless utilities, pure functions, config reads, documentation.