Skill Stack Deduplication
Every concept has exactly one canonical location. Files reference that location instead of copying content.
Reference Hierarchy
CLAUDE.md (permanent directives, verification standards)
|
foundation-skill/SKILL.md (canonical methodology)
|
extension-skill/SKILL.md (unique execution steps, output templates)
|
agents/agent-name.md (persona, behavior, skill delegation)
|
commands/command-name.md (invocation guide: usage, when to use)
Each layer only contains content unique to its responsibility. Reference up, don't copy.
Layer Responsibilities
| Layer | Contains | Does NOT Contain |
|---|---|---|
| CLAUDE.md | Permanent directives, verification standards | Skill-specific methodology |
| Foundation Skill | Canonical methodology | Agent behavior, invocation details |
| Extension Skill | Unique execution steps, output templates | Foundation methodology, agent persona |
| Agent | Persona, behavior rules, context sensitivity | Methodology details, output templates |
| Command | Usage, "what it does", "when to use" | Full methodology, benefits lists |
Forbidden Patterns
Copy-pasting methodology across files — if the same process steps appear in both an agent and a skill, the agent must reference the skill instead.
Redefining CLAUDE.md directives — permanent rules (Reality Filter labels, verification standards) belong only in CLAUDE.md. Other files use a one-line reference:
# WRONG: Re-listing verification labels in agent file
**Verification Labeling System**:
- [Verified] - Direct content from the analyzed document
- [Inference] - Derived from observable patterns...
# RIGHT: One-line reference
Follow CLAUDE.md "AI Response Accuracy & Verification Standards" for verification labeling.
Quick Decision Tree
- Methodology/process steps -> Skill file (canonical source)
- Persona/behavior/context rules -> Agent file
- Invocation syntax/when-to-use -> Command file
- Permanent rules/verification standards -> CLAUDE.md
- Already defined elsewhere -> Reference it, don't copy it
Deduplication Audit Process
- Count lines across all files in the stack:
wc -l agent.md skill/SKILL.md command.md - Identify overlap by grepping for repeated phrases across files
- Assign responsibility per the layer table above
- Rewrite each file keeping only its unique content + references
- Verify cross-references resolve to existing files
- Confirm no methodology lost — only deduplicated
Source: ngpestelos/skills — distributed by TomeVault.