New skill: compound — capture learnings into docs/solutions/ after solving a problem
Author: JosefJezekCreated Jul 30, 2026Updated Sep 20, 2026
Summary
Add a new skill similar to /ce-compound from compound-engineering-plugin. This is the "knowledge-capture" closing loop: after a non-trivial problem is solved, the skill writes a structured doc to docs/solutions/ so the next time the same problem is hit, it takes minutes instead of hours.
Why
Solutions to non-trivial problems often live only in conversation/chat history and get lost. Teams end up re-solving the same problem multiple times. This skill closes that gap by capturing:
- Symptoms
- Root cause
- What didn't work (the most expensive part of the investigation)
- The working solution
- Why it works / prevention guidance
Reference implementation
See ce-compound skill doc: https://github.com/EveryInc/compound-engineering-plugin/blob/main/docs/skills/ce-compound.md
Key behaviors worth adapting:
- Two modes: Full (parallel research/cross-referencing, duplicate detection) vs Lightweight (single-pass, fewer tokens) — mode auto-selected based on context budget, not asked.
- Two tracks: Bug track (Symptoms → What Didn't Work → Solution → Why This Works → Prevention) vs Knowledge track (Context → Guidance → Why This Matters → When to Apply → Examples).
- Overlap detection: scores new learning against existing docs across problem statement, root cause, solution approach, referenced files, and prevention rules — updates an existing doc on high overlap instead of creating a duplicate.
- Discoverability check: ensures the project's instruction file (e.g.
AGENTS.md) actually referencesdocs/solutions/so future agent sessions know to check it. - Auto-invoke triggers: phrases like "that worked", "it's fixed", "problem solved" trigger the capture flow automatically.
- Grounding validation: verifies cited paths/commits/claims against the actual repo tree before finalizing the doc.
Suggested output artifact
docs/solutions/[category]/[filename].mdwith YAML frontmatter (module, tags, problem_type, etc.) for searchability.
Source: addyosmani/agent-skills