Three-tier skill organization for context-window economy
30+ skills load 40% context before any work starts. Router + bundles + atoms drop it under 10% and recover the planning budget.
What
Refactor a sprawling skill library into three layers: (1) one parent/router "mother" skill that owns the trigger surface and dispatches to children; (2) command-group skills bundling related families (for example office-skills bundling pptx + docx + pdf extraction); (3) atomic command scripts that do the actual work. The router loads ~5 KB of trigger metadata into context; the heavy SKILL.md content stays cold until needed.
Why it matters
A cohort participant managing 30+ accumulated skills was burning context to ~40 % saturation on session start before doing any work. Three-tier organization drops that to under 10 %, recovers the planning budget, and produces an auditable answer to "which skill fired and why?" via a launch hook.
End-to-end
- Inventory every SKILL.md you have. Tag each as router-candidate, group-candidate, or atomic.
- Group atomics by domain (office, code-review, research, content). Each group gets one parent SKILL.md whose body is a 20-line dispatch table.
- Author the top-level router skill. Its body is a one-line description per group plus trigger phrases. No business logic — just routing.
- Add a hook on skill-launch (
PreToolUseforSkillToolor equivalent) that appends the firing skill name + trigger phrase to~/.claude/skill-audit.log. Review weekly. - Replace direct invocation paths in your AGENTS.md with router-only references.
- Watch context-window startup cost in
claude --debugbefore/after. - On every new skill: decide layer first, write second.
Gotchas
- Group skills must not contain business logic — they only route. The moment a group skill "helps a little" you have a 4-tier mess and the hook log no longer maps to outcomes.
- Don't pre-load the audit hook into the router skill itself; log at the harness layer so the router stays cheap.
Tools
- Claude Code (or any agent CLI with skill loading)
- A
PreToolUsehook capable of logging tool calls - Existing skill library big enough to feel the pain (≥ 20)