Commit cdc0c5c
Consolidate 4 skills into 1 with progressive disclosure
Merge codebase-memory-exploring, codebase-memory-tracing,
codebase-memory-quality, and codebase-memory-reference into a single
codebase-memory skill with a references/ directory.
Motivation:
- Each skill registered a separate description entry that Claude scans
at session startup. 4 skills = 4 description entries consuming listing
space when 1 would suffice with a broader trigger phrase set.
- The 4 skills had overlapping content (gotchas, tips) scattered across
files with no single source of truth.
- Per Anthropic's Agent Skills best practices and official spec
(agentskills.io), skills should use progressive disclosure: a concise
SKILL.md (<500 lines, <5000 tokens) loaded on activation, with
detailed reference material in separate files loaded on demand.
What changed:
- assets/skills/: 4 separate skill directories replaced by 1
codebase-memory/ directory with references/ subdirectory
- SKILL.md (54 lines): decision matrix, quick workflows, consolidated
gotchas section — everything an agent needs to pick the right tool
- references/exploring.md: codebase exploration workflows
- references/tracing.md: call chain tracing, impact analysis, cross-service
- references/quality.md: dead code, fan-out/fan-in, change coupling
- references/tool-reference.md: all 14 tools, edge types, Cypher syntax,
regex patterns
- cli.c: embedded skill content consolidated into single string with
decision matrix, all workflows, and gotchas
- cli.h: CBM_SKILL_COUNT 4 → 1
- test_cli.c: updated to test single consolidated skill covering all
capabilities
The consolidated gotchas section surfaces the 5 most common mistakes
(search_graph vs query_graph for edges, 200-row cap, exact name
requirement, direction="both" for cross-service, pagination) in the
main SKILL.md where the agent reads them before encountering issues.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>1 parent f7315b9 commit cdc0c5c
10 files changed
Lines changed: 321 additions & 413 deletions
File tree
- cmd/codebase-memory-mcp/assets/skills
- codebase-memory-exploring
- codebase-memory-tracing
- codebase-memory
- references
- src/cli
- tests
Lines changed: 0 additions & 90 deletions
This file was deleted.
Lines changed: 0 additions & 125 deletions
This file was deleted.
Lines changed: 54 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
Lines changed: 61 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
0 commit comments