From compound-engineering
Documents a recently solved problem via parallel subagents, assembling a single structured Markdown file with YAML frontmatter in docs/solutions/.
npx claudepluginhub gvkhosla/compound-engineering-pi --plugin compound-engineering[optional: brief context about the fix]workflows/# /compound Coordinate multiple subagents working in parallel to document a recently solved problem. ## Purpose Captures problem solutions while context is fresh, creating structured documentation in `docs/solutions/` with YAML frontmatter for searchability and future reference. Uses parallel subagents for maximum efficiency. **Why "compound"?** Each documented solution compounds your team's knowledge. The first time you solve a problem takes research. Document it, and the next occurrence takes minutes. Knowledge compounds. ## Usage ## Execution Strategy: Two-Phase Orchestration <c...
/documentCaptures solved problems as searchable documentation for future reference. Invoke with arguments to document specific solutions or issues.
/compoundCaptures 5-phase post-mortem from conversation, debug, and commits; writes structured solution doc to docs/solutions/{track}/{category}/{slug}.md with frontmatter, overlap detection, and per-category locks.
/beads-compoundDocuments a recently solved problem by coordinating subagents to capture context, solutions, preventions, and links, writing structured entries to .beads/memory/knowledge.jsonl.
/compoundReflects on the current session to extract key learnings, heuristics, friction points, and tacit knowledge for improving future interactions. States if none found.
/compoundProposes learnings from completed sprints in clean-ups, backlog tasks, and CLAUDE.md buckets; applies user-approved items. Batches multiples via --all, --oldest, or picker.
/compoundExecutes the learnship compound workflow to capture the current solution as a structured document in .planning/solutions/.
Share bugs, ideas, or general feedback.
Coordinate multiple subagents working in parallel to document a recently solved problem.
Captures problem solutions while context is fresh, creating structured documentation in docs/solutions/ with YAML frontmatter for searchability and future reference. Uses parallel subagents for maximum efficiency.
Why "compound"? Each documented solution compounds your team's knowledge. The first time you solve a problem takes research. Document it, and the next occurrence takes minutes. Knowledge compounds.
/workflows:compound # Document the most recent fix
/workflows:compound [brief context] # Provide additional context hint
<critical_requirement> Only ONE file gets written - the final documentation.
Phase 1 subagents return TEXT DATA to the orchestrator. They must NOT use Write, Edit, or create any files. Only the orchestrator (Phase 2) writes the final documentation file. </critical_requirement>
<parallel_tasks>
Launch these subagents IN PARALLEL. Each returns text data to the orchestrator.
docs/solutions/ for related documentationdocs/solutions/ category</parallel_tasks>
<sequential_tasks>
WAIT for all Phase 1 subagents to complete before proceeding.
The orchestrating agent (main conversation) performs these steps:
mkdir -p docs/solutions/[category]/docs/solutions/[category]/[filename].md</sequential_tasks>
WAIT for Phase 2 to complete before proceeding.
<parallel_tasks>
Based on problem type, optionally invoke specialized agents to review the documentation:
performance-oraclesecurity-sentineldata-integrity-guardiancora-test-reviewerkieran-rails-reviewer + code-simplicity-reviewer</parallel_tasks>
Organized documentation:
docs/solutions/[category]/[filename].mdCategories auto-detected from problem:
| ❌ Wrong | ✅ Correct |
|---|---|
Subagents write files like context-analysis.md, solution-draft.md | Subagents return text data; orchestrator writes one final file |
| Research and assembly run in parallel | Research completes → then assembly runs |
| Multiple files created during workflow | Single file: docs/solutions/[category]/[filename].md |
✓ Documentation complete
Subagent Results:
✓ Context Analyzer: Identified performance_issue in brief_system
✓ Solution Extractor: 3 code fixes
✓ Related Docs Finder: 2 related issues
✓ Prevention Strategist: Prevention strategies, test suggestions
✓ Category Classifier: `performance-issues`
Specialized Agent Reviews (Auto-Triggered):
✓ performance-oracle: Validated query optimization approach
✓ kieran-rails-reviewer: Code examples meet Rails standards
✓ code-simplicity-reviewer: Solution is appropriately minimal
✓ every-style-editor: Documentation style verified
File created:
- docs/solutions/performance-issues/n-plus-one-brief-generation.md
This documentation will be searchable for future reference when similar
issues occur in the Email Processing or Brief System modules.
What's next?
1. Continue workflow (recommended)
2. Link related documentation
3. Update other references
4. View documentation
5. Other
This creates a compounding knowledge system:
The feedback loop:
Build → Test → Find Issue → Research → Improve → Document → Validate → Deploy
↑ ↓
└──────────────────────────────────────────────────────────────────────┘
Each unit of engineering work should make subsequent units of work easier—not harder.
<auto_invoke> <trigger_phrases> - "that worked" - "it's fixed" - "working now" - "problem solved" </trigger_phrases>
<manual_override> Use /workflows:compound [context] to document immediately without waiting for auto-detection. </manual_override> </auto_invoke>
compound-docs skill
Based on problem type, these agents can enhance documentation:
/research [topic] - Deep investigation (searches docs/solutions/ for patterns)/workflows:plan - Planning workflow (references documented solutions)