superpowers-mcp 5.1.2 → 6.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/README.md +22 -14
  2. package/README.zh-TW.md +27 -14
  3. package/out/server.js +2 -2
  4. package/package.json +1 -1
  5. package/skills/brainstorming/SKILL.md +5 -10
  6. package/skills/brainstorming/scripts/frame-template.html +25 -26
  7. package/skills/brainstorming/scripts/helper.js +107 -35
  8. package/skills/brainstorming/scripts/server.cjs +377 -30
  9. package/skills/brainstorming/scripts/start-server.sh +70 -9
  10. package/skills/brainstorming/scripts/stop-server.sh +66 -2
  11. package/skills/brainstorming/spec-document-reviewer-prompt.md +1 -1
  12. package/skills/brainstorming/visual-companion.md +29 -25
  13. package/skills/dispatching-parallel-agents/SKILL.md +9 -6
  14. package/skills/executing-plans/SKILL.md +2 -2
  15. package/skills/finishing-a-development-branch/SKILL.md +2 -12
  16. package/skills/receiving-code-review/SKILL.md +2 -2
  17. package/skills/requesting-code-review/SKILL.md +2 -2
  18. package/skills/requesting-code-review/code-reviewer.md +15 -11
  19. package/skills/subagent-driven-development/SKILL.md +206 -67
  20. package/skills/subagent-driven-development/implementer-prompt.md +30 -4
  21. package/skills/subagent-driven-development/scripts/review-package +44 -0
  22. package/skills/subagent-driven-development/scripts/sdd-workspace +22 -0
  23. package/skills/subagent-driven-development/scripts/task-brief +40 -0
  24. package/skills/subagent-driven-development/task-reviewer-prompt.md +188 -0
  25. package/skills/systematic-debugging/SKILL.md +1 -1
  26. package/skills/test-driven-development/SKILL.md +2 -2
  27. package/skills/using-git-worktrees/SKILL.md +9 -22
  28. package/skills/using-superpowers/SKILL.md +17 -72
  29. package/skills/using-superpowers/references/antigravity-tools.md +23 -0
  30. package/skills/using-superpowers/references/codex-tools.md +1 -21
  31. package/skills/using-superpowers/references/pi-tools.md +16 -0
  32. package/skills/writing-plans/SKILL.md +22 -0
  33. package/skills/writing-plans/plan-document-reviewer-prompt.md +1 -1
  34. package/skills/writing-skills/SKILL.md +52 -18
  35. package/skills/writing-skills/anthropic-best-practices.md +91 -91
  36. package/skills/writing-skills/persuasion-principles.md +3 -3
  37. package/skills/subagent-driven-development/code-quality-reviewer-prompt.md +0 -25
  38. package/skills/subagent-driven-development/spec-reviewer-prompt.md +0 -61
@@ -9,7 +9,7 @@ description: Use when creating new skills, editing existing skills, or verifying
9
9
 
10
10
  **Writing skills IS Test-Driven Development applied to process documentation.**
11
11
 
12
- **Personal skills live in agent-specific directories (`~/.claude/skills` for Claude Code, `~/.agents/skills/` for Codex)**
12
+ **Personal skills live in your runtime's skills directory**
13
13
 
14
14
  You write test cases (pressure scenarios with subagents), watch them fail (baseline behavior), write the skill (documentation), watch tests pass (agents comply), and refactor (close loopholes).
15
15
 
@@ -21,7 +21,7 @@ You write test cases (pressure scenarios with subagents), watch them fail (basel
21
21
 
22
22
  ## What is a Skill?
23
23
 
24
- A **skill** is a reference guide for proven techniques, patterns, or tools. Skills help future Claude instances find and apply effective approaches.
24
+ A **skill** is a reference guide for proven techniques, patterns, or tools. Skills help future agents find and apply effective approaches.
25
25
 
26
26
  **Skills are:** Reusable techniques, patterns, tools, reference guides
27
27
 
@@ -55,7 +55,7 @@ The entire skill creation process follows RED-GREEN-REFACTOR.
55
55
  **Don't create for:**
56
56
  - One-off solutions
57
57
  - Standard practices well-documented elsewhere
58
- - Project-specific conventions (put in CLAUDE.md)
58
+ - Project-specific conventions (put in your instructions file)
59
59
  - Mechanical constraints (if it's enforceable with regex/validation, automate it—save documentation for judgment calls)
60
60
 
61
61
  ## Skill Types
@@ -99,7 +99,7 @@ skills/
99
99
  - `description`: Third-person, describes ONLY when to use (NOT what it does)
100
100
  - Start with "Use when..." to focus on triggering conditions
101
101
  - Include specific symptoms, situations, and contexts
102
- - **NEVER summarize the skill's process or workflow** (see CSO section for why)
102
+ - **NEVER summarize the skill's process or workflow** (see SDO section for why)
103
103
  - Keep under 500 characters if possible
104
104
 
105
105
  ```markdown
@@ -137,13 +137,13 @@ Concrete results
137
137
  ```
138
138
 
139
139
 
140
- ## Claude Search Optimization (CSO)
140
+ ## Skill Discovery Optimization (SDO)
141
141
 
142
- **Critical for discovery:** Future Claude needs to FIND your skill
142
+ **Critical for discovery:** Future agents need to FIND your skill
143
143
 
144
144
  ### 1. Rich Description Field
145
145
 
146
- **Purpose:** Claude reads description to decide which skills to load for a given task. Make it answer: "Should I read this skill right now?"
146
+ **Purpose:** Your agent reads the description to decide which skills to load for a given task. Make it answer: "Should I read this skill right now?"
147
147
 
148
148
  **Format:** Start with "Use when..." to focus on triggering conditions
149
149
 
@@ -151,14 +151,14 @@ Concrete results
151
151
 
152
152
  The description should ONLY describe triggering conditions. Do NOT summarize the skill's process or workflow in the description.
153
153
 
154
- **Why this matters:** Testing revealed that when a description summarizes the skill's workflow, Claude may follow the description instead of reading the full skill content. A description saying "code review between tasks" caused Claude to do ONE review, even though the skill's flowchart clearly showed TWO reviews (spec compliance then code quality).
154
+ **Why this matters:** Testing revealed that when a description summarizes the skill's workflow, an agent may follow the description instead of reading the full skill content. A description saying "code review between tasks" caused an agent to do ONE review, even though the skill's flowchart clearly showed TWO reviews (spec compliance then code quality).
155
155
 
156
- When the description was changed to just "Use when executing implementation plans with independent tasks" (no workflow summary), Claude correctly read the flowchart and followed the two-stage review process.
156
+ When the description was changed to just "Use when executing implementation plans with independent tasks" (no workflow summary), the agent correctly read the flowchart and followed the two-stage review process.
157
157
 
158
- **The trap:** Descriptions that summarize workflow create a shortcut Claude will take. The skill body becomes documentation Claude skips.
158
+ **The trap:** Descriptions that summarize workflow create a shortcut agents will take. The skill body becomes documentation agents skip.
159
159
 
160
160
  ```yaml
161
- # ❌ BAD: Summarizes workflow - Claude may follow this instead of reading skill
161
+ # ❌ BAD: Summarizes workflow - agents may follow this instead of reading skill
162
162
  description: Use when executing plans - dispatches subagent per task with code review between tasks
163
163
 
164
164
  # ❌ BAD: Too much process detail
@@ -198,7 +198,7 @@ description: Use when using React Router and handling authentication redirects
198
198
 
199
199
  ### 2. Keyword Coverage
200
200
 
201
- Use words Claude would search for:
201
+ Use words an agent would search for:
202
202
  - Error messages: "Hook timed out", "ENOTEMPTY", "race condition"
203
203
  - Symptoms: "flaky", "hanging", "zombie", "pollution"
204
204
  - Synonyms: "timeout/hang/freeze", "cleanup/teardown/afterEach"
@@ -275,7 +275,7 @@ wc -w skills/path/SKILL.md
275
275
  - `creating-skills`, `testing-skills`, `debugging-with-logs`
276
276
  - Active, describes the action you're taking
277
277
 
278
- ### 4. Cross-Referencing Other Skills
278
+ ### 5. Cross-Referencing Other Skills
279
279
 
280
280
  **When writing documentation that references other skills:**
281
281
 
@@ -313,7 +313,7 @@ digraph when_flowchart {
313
313
  - Linear instructions → Numbered lists
314
314
  - Labels without semantic meaning (step1, helper2)
315
315
 
316
- See @graphviz-conventions.dot for graphviz style rules.
316
+ See `graphviz-conventions.dot` in this directory for graphviz style rules.
317
317
 
318
318
  **Visualizing for your human partner:** Use `render-graphs.js` in this directory to render a skill's flowcharts to SVG:
319
319
  ```bash
@@ -456,10 +456,29 @@ Different skill types need different test approaches:
456
456
 
457
457
  **All of these mean: Test before deploying. No exceptions.**
458
458
 
459
+ ## Match the Form to the Failure
460
+
461
+ Before writing guidance, classify the baseline failure. The form that bulletproofs one failure type measurably backfires on another.
462
+
463
+ | Baseline failure | Right form | Wrong form |
464
+ |---|---|---|
465
+ | Skips/violates a rule under pressure (knows better, does it anyway) | Prohibition + rationalization table + red flags (see Bulletproofing below) | Soft guidance ("prefer...", "consider...") |
466
+ | Complies, but output has the wrong shape (bloated prompt, buried verdict, restated spec) | Positive recipe or contract: state what the output IS — its parts, in order | Prohibition list ("don't restate", "never narrate") |
467
+ | Omits a required element from something they already produce | Structural: REQUIRED field or slot in the template they fill in | Prose reminders near the template |
468
+ | Behavior should depend on a condition | Conditional keyed to an observable predicate ("if the brief exists, reference it") | Unconditional rule + exemption clauses |
469
+
470
+ **Why prohibitions backfire on shaping problems:** in head-to-head wording tests on dispatch-prompt guidance, the prohibition arm produced more unwanted content than the recipe arm — and trended worse than the no-guidance control. Micro-test your own case rather than assuming. A recipe leaves nothing to negotiate: the output matches the stated shape or it doesn't.
471
+
472
+ **Rules for whichever form you pick:**
473
+ - **No nuance clauses.** "Don't X unless it matters" reopens the negotiation — appending a single nuance clause to a winning recipe degraded it from consistent to noisy in the same wording tests. Express a real exception as its own conditional on an observable predicate.
474
+ - **Exemption clauses don't scope.** "This limit doesn't apply to code blocks" still suppresses code blocks. If part of the output must be exempt, restructure so the rule can't reach it.
475
+
459
476
  ## Bulletproofing Skills Against Rationalization
460
477
 
461
478
  Skills that enforce discipline (like TDD) need to resist rationalization. Agents are smart and will find loopholes when under pressure.
462
479
 
480
+ **Scope:** this toolkit is for discipline failures — an agent that knows the rule and skips it under pressure. For wrong-shaped output or omitted elements, prohibition-based bulletproofing backfires; use the forms in Match the Form to the Failure instead.
481
+
463
482
  **Psychology note:** Understanding WHY persuasion techniques work helps you apply them systematically. See persuasion-principles.md for research foundation (Cialdini, 2021; Meincke et al., 2025) on authority, commitment, scarcity, social proof, and unity principles.
464
483
 
465
484
  ### Close Every Loophole Explicitly
@@ -522,7 +541,7 @@ Make it easy for agents to self-check when rationalizing:
522
541
  **All of these mean: Delete code. Start over with TDD.**
523
542
  ```
524
543
 
525
- ### Update CSO for Violation Symptoms
544
+ ### Update SDO for Violation Symptoms
526
545
 
527
546
  Add to description: symptoms of when you're ABOUT to violate the rule:
528
547
 
@@ -553,7 +572,19 @@ Run same scenarios WITH skill. Agent should now comply.
553
572
 
554
573
  Agent found new rationalization? Add explicit counter. Re-test until bulletproof.
555
574
 
556
- **Testing methodology:** See @testing-skills-with-subagents.md for the complete testing methodology:
575
+ ### Micro-Test Wording Before Full Scenarios
576
+
577
+ Full pressure-scenario runs are the final gate, but they are slow and expensive per iteration. Verify the wording itself first with micro-tests:
578
+
579
+ 1. **One fresh-context sample per call** — a raw API call, or a single-shot subagent if you don't have API access. System prompt = the realistic context the guidance will live in (the full skill or prompt template, not the guidance in isolation); user message = a task that tempts the failure.
580
+ 2. **Always include a no-guidance control.** If the control doesn't exhibit the failure, there is nothing to fix — stop, don't author the guidance.
581
+ 3. **5+ reps per variant.** Single samples lie.
582
+ 4. **Manually read every flagged match.** Score programmatically if you like, but template echoes and quoted counter-examples masquerade as hits; automated counts alone overstate both failure and success.
583
+ 5. **Variance is a metric.** When guidance lands, reps converge on the same shape. Five different interpretations across five reps means the wording isn't binding — tighten the form before adding words.
584
+
585
+ Micro-tests verify wording; they do not replace pressure scenarios for discipline skills.
586
+
587
+ **Testing methodology:** See [testing-skills-with-subagents.md](testing-skills-with-subagents.md) for the complete testing methodology:
557
588
  - How to write pressure scenarios
558
589
  - Pressure types (time, sunk cost, authority, exhaustion)
559
590
  - Plugging holes systematically
@@ -595,7 +626,7 @@ Deploying untested skills = deploying untested code. It's a violation of quality
595
626
 
596
627
  ## Skill Creation Checklist (TDD Adapted)
597
628
 
598
- **IMPORTANT: Use TodoWrite to create todos for EACH checklist item below.**
629
+ **IMPORTANT: Create a todo for EACH checklist item below.**
599
630
 
600
631
  **RED Phase - Write Failing Test:**
601
632
  - [ ] Create pressure scenarios (3+ combined pressures for discipline skills)
@@ -610,6 +641,8 @@ Deploying untested skills = deploying untested code. It's a violation of quality
610
641
  - [ ] Keywords throughout for search (errors, symptoms, tools)
611
642
  - [ ] Clear overview with core principle
612
643
  - [ ] Address specific baseline failures identified in RED
644
+ - [ ] Guidance form matches the failure type (see Match the Form to the Failure)
645
+ - [ ] For behavior-shaping guidance: wording micro-tested against a no-guidance control (5+ reps, every flagged match read manually) — N/A for pure reference skills
613
646
  - [ ] Code inline OR link to separate file
614
647
  - [ ] One excellent example (not multi-language)
615
648
  - [ ] Run scenarios WITH skill - verify agents now comply
@@ -634,9 +667,10 @@ Deploying untested skills = deploying untested code. It's a violation of quality
634
667
 
635
668
  ## Discovery Workflow
636
669
 
637
- How future Claude finds your skill:
670
+ How future agents find your skill:
638
671
 
639
672
  1. **Encounters problem** ("tests are flaky")
673
+ 2. **Searches skills** (greps descriptions, browses categories)
640
674
  3. **Finds SKILL** (description matches)
641
675
  4. **Scans overview** (is this relevant?)
642
676
  5. **Reads patterns** (quick reference table)