@hecer/yoke 1.6.0 → 1.6.1

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 (103) hide show
  1. package/.claude-plugin/plugin.json +13 -13
  2. package/.codex-plugin/plugin.json +7 -7
  3. package/CHANGELOG.md +294 -288
  4. package/README.md +874 -874
  5. package/TODOS.md +5 -5
  6. package/agents/docs.toml +6 -6
  7. package/agents/implementer.toml +6 -6
  8. package/agents/reviewer.toml +6 -6
  9. package/agents/security.toml +6 -6
  10. package/bench/README.md +86 -86
  11. package/bench/RESULTS.md +35 -35
  12. package/bench/output-compaction.mjs +65 -65
  13. package/bench/result-schema.mjs +12 -12
  14. package/bench/results/claude-2026-07-27T18-03-26.json +50 -50
  15. package/bench/results/codex-unavailable-1785175418318.json +15 -15
  16. package/bench/results/gemini-2026-07-27T18-03-44.json +46 -46
  17. package/bench/run-matrix.mjs +26 -26
  18. package/bench/run.mjs +106 -106
  19. package/canon/AGENTS.md +30 -30
  20. package/canon/context/DECISIONS.md +4 -4
  21. package/canon/context/GLOSSARY.md +11 -11
  22. package/canon/context/KNOWLEDGE.md +4 -4
  23. package/canon/context/PROJECT.md +15 -15
  24. package/canon/loop/loop-spec.md +65 -65
  25. package/canon/loop/prd.schema.md +43 -43
  26. package/canon/manifest.yaml +59 -59
  27. package/canon/policy/gates.md +7 -7
  28. package/canon/policy/roles.md +9 -9
  29. package/canon/skills/ATTRIBUTION.md +99 -99
  30. package/canon/skills/authoring-prd/SKILL.md +58 -58
  31. package/canon/skills/brainstorming/SKILL.md +164 -164
  32. package/canon/skills/codebase-design/DEEPENING.md +15 -15
  33. package/canon/skills/codebase-design/DESIGN-IT-TWICE.md +12 -12
  34. package/canon/skills/codebase-design/SKILL.md +39 -39
  35. package/canon/skills/dispatching-parallel-agents/SKILL.md +182 -182
  36. package/canon/skills/document-release/SKILL.md +302 -302
  37. package/canon/skills/domain-modeling/ADR-FORMAT.md +19 -19
  38. package/canon/skills/domain-modeling/CONTEXT-FORMAT.md +39 -39
  39. package/canon/skills/domain-modeling/SKILL.md +35 -35
  40. package/canon/skills/executing-plans/SKILL.md +70 -70
  41. package/canon/skills/finishing-a-development-branch/SKILL.md +200 -200
  42. package/canon/skills/health/SKILL.md +177 -177
  43. package/canon/skills/maintaining-context/SKILL.md +34 -34
  44. package/canon/skills/minimal-code/SKILL.md +21 -21
  45. package/canon/skills/no-ai-slop/SKILL.md +103 -103
  46. package/canon/skills/no-ai-slop/eval.md +43 -43
  47. package/canon/skills/plan-ceo-review/SKILL.md +541 -541
  48. package/canon/skills/plan-eng-review/SKILL.md +362 -362
  49. package/canon/skills/receiving-code-review/SKILL.md +213 -213
  50. package/canon/skills/requesting-code-review/SKILL.md +105 -105
  51. package/canon/skills/resolving-merge-conflicts/SKILL.md +18 -18
  52. package/canon/skills/retro/SKILL.md +397 -397
  53. package/canon/skills/review/SKILL.md +246 -246
  54. package/canon/skills/ship/SKILL.md +691 -691
  55. package/canon/skills/subagent-driven-development/SKILL.md +277 -277
  56. package/canon/skills/systematic-debugging/SKILL.md +296 -296
  57. package/canon/skills/tdd/SKILL.md +371 -371
  58. package/canon/skills/unslop-ui/SKILL.md +34 -34
  59. package/canon/skills/using-git-worktrees/SKILL.md +218 -218
  60. package/canon/skills/verification-before-completion/SKILL.md +139 -139
  61. package/canon/skills/visual-verification/SKILL.md +54 -54
  62. package/canon/skills/workflow/SKILL.md +22 -22
  63. package/canon/skills/writing-for-agents/SKILL-MECHANICS.md +27 -27
  64. package/canon/skills/writing-for-agents/SKILL.md +42 -42
  65. package/canon/skills/writing-plans/SKILL.md +152 -152
  66. package/canon/skills/writing-skills/SKILL.md +655 -655
  67. package/canon/skills/yoke-retrofit/SKILL.md +26 -26
  68. package/canon/skills/yoke-workflow/SKILL.md +20 -20
  69. package/canon/tools/codex-rtk-hook.mjs +35 -35
  70. package/canon/tools/graphify.md +3 -3
  71. package/canon/tools/playwright-mcp.md +3 -3
  72. package/canon/tools/rtk.md +7 -7
  73. package/canon/tools/serena.md +6 -6
  74. package/dist/agents/process.js +3 -0
  75. package/dist/loop/watchdog.js +1 -1
  76. package/dist/prd/command.js +17 -17
  77. package/dist/retrofit/planners/claude.js +14 -14
  78. package/dist/retrofit/preserve.js +2 -2
  79. package/docs/MIGRATING-TO-1.0.md +33 -33
  80. package/docs/MIGRATING-TO-1.1.md +27 -27
  81. package/docs/MIGRATING-TO-1.4.md +70 -70
  82. package/docs/PUBLISHING.md +91 -91
  83. package/docs/superpowers/plans/2026-06-28-baustein-e-context-layer.md +981 -981
  84. package/docs/superpowers/plans/2026-06-29-baustein-f-routing.md +258 -258
  85. package/docs/superpowers/plans/2026-06-29-baustein-g-loop-observability.md +1006 -1006
  86. package/docs/superpowers/plans/2026-06-29-baustein-h-loop-robustness.md +374 -374
  87. package/docs/superpowers/plans/2026-06-30-baustein-i-visual-design-verification.md +450 -450
  88. package/docs/superpowers/plans/2026-07-02-baustein-k-zero-to-100-bootstrap.md +1024 -1024
  89. package/docs/superpowers/plans/2026-07-02-baustein-m-flow-smoke-proofs.md +574 -574
  90. package/docs/superpowers/plans/2026-08-13-gauntlet-quality-loop.md +537 -537
  91. package/docs/superpowers/plans/2026-08-16-artifact-backed-output-compaction.md +329 -329
  92. package/docs/superpowers/specs/2026-06-28-baustein-e-context-layer-design.md +146 -146
  93. package/docs/superpowers/specs/2026-06-29-baustein-f-routing-design.md +106 -106
  94. package/docs/superpowers/specs/2026-06-29-baustein-g-loop-observability-design.md +186 -186
  95. package/docs/superpowers/specs/2026-06-29-baustein-h-loop-robustness-design.md +113 -113
  96. package/docs/superpowers/specs/2026-06-30-baustein-i-visual-design-verification-design.md +98 -98
  97. package/docs/superpowers/specs/2026-07-02-baustein-k-zero-to-100-bootstrap-design.md +200 -200
  98. package/docs/superpowers/specs/2026-07-02-baustein-m-flow-smoke-proofs-design.md +155 -155
  99. package/docs/superpowers/specs/2026-08-13-gauntlet-quality-loop-design.md +422 -422
  100. package/docs/superpowers/specs/2026-08-16-artifact-backed-output-compaction-design.md +166 -166
  101. package/gemini-extension.json +6 -6
  102. package/hooks/hooks.json +19 -19
  103. package/package.json +87 -87
@@ -1,182 +1,182 @@
1
- ---
2
- name: dispatching-parallel-agents
3
- description: Use when facing 2+ independent tasks that can be worked on without shared state or sequential dependencies
4
- ---
5
-
6
- # Dispatching Parallel Agents
7
-
8
- ## Overview
9
-
10
- You delegate tasks to specialized agents with isolated context. By precisely crafting their instructions and context, you ensure they stay focused and succeed at their task. They should never inherit your session's context or history — you construct exactly what they need. This also preserves your own context for coordination work.
11
-
12
- When you have multiple unrelated failures (different test files, different subsystems, different bugs), investigating them sequentially wastes time. Each investigation is independent and can happen in parallel.
13
-
14
- **Core principle:** Dispatch one agent per independent problem domain. Let them work concurrently.
15
-
16
- ## When to Use
17
-
18
- ```dot
19
- digraph when_to_use {
20
- "Multiple failures?" [shape=diamond];
21
- "Are they independent?" [shape=diamond];
22
- "Single agent investigates all" [shape=box];
23
- "One agent per problem domain" [shape=box];
24
- "Can they work in parallel?" [shape=diamond];
25
- "Sequential agents" [shape=box];
26
- "Parallel dispatch" [shape=box];
27
-
28
- "Multiple failures?" -> "Are they independent?" [label="yes"];
29
- "Are they independent?" -> "Single agent investigates all" [label="no - related"];
30
- "Are they independent?" -> "Can they work in parallel?" [label="yes"];
31
- "Can they work in parallel?" -> "Parallel dispatch" [label="yes"];
32
- "Can they work in parallel?" -> "Sequential agents" [label="no - shared state"];
33
- }
34
- ```
35
-
36
- **Use when:**
37
- - 3+ test files failing with different root causes
38
- - Multiple subsystems broken independently
39
- - Each problem can be understood without context from others
40
- - No shared state between investigations
41
-
42
- **Don't use when:**
43
- - Failures are related (fix one might fix others)
44
- - Need to understand full system state
45
- - Agents would interfere with each other
46
-
47
- ## The Pattern
48
-
49
- ### 1. Identify Independent Domains
50
-
51
- Group failures by what's broken:
52
- - File A tests: Tool approval flow
53
- - File B tests: Batch completion behavior
54
- - File C tests: Abort functionality
55
-
56
- Each domain is independent - fixing tool approval doesn't affect abort tests.
57
-
58
- ### 2. Create Focused Agent Tasks
59
-
60
- Each agent gets:
61
- - **Specific scope:** One test file or subsystem
62
- - **Clear goal:** Make these tests pass
63
- - **Constraints:** Don't change other code
64
- - **Expected output:** Summary of what you found and fixed
65
-
66
- ### 3. Dispatch in Parallel
67
-
68
- ```typescript
69
- // In Claude Code / AI environment
70
- Task("Fix agent-tool-abort.test.ts failures")
71
- Task("Fix batch-completion-behavior.test.ts failures")
72
- Task("Fix tool-approval-race-conditions.test.ts failures")
73
- // All three run concurrently
74
- ```
75
-
76
- ### 4. Review and Integrate
77
-
78
- When agents return:
79
- - Read each summary
80
- - Verify fixes don't conflict
81
- - Run full test suite
82
- - Integrate all changes
83
-
84
- ## Agent Prompt Structure
85
-
86
- Good agent prompts are:
87
- 1. **Focused** - One clear problem domain
88
- 2. **Self-contained** - All context needed to understand the problem
89
- 3. **Specific about output** - What should the agent return?
90
-
91
- ```markdown
92
- Fix the 3 failing tests in src/agents/agent-tool-abort.test.ts:
93
-
94
- 1. "should abort tool with partial output capture" - expects 'interrupted at' in message
95
- 2. "should handle mixed completed and aborted tools" - fast tool aborted instead of completed
96
- 3. "should properly track pendingToolCount" - expects 3 results but gets 0
97
-
98
- These are timing/race condition issues. Your task:
99
-
100
- 1. Read the test file and understand what each test verifies
101
- 2. Identify root cause - timing issues or actual bugs?
102
- 3. Fix by:
103
- - Replacing arbitrary timeouts with event-based waiting
104
- - Fixing bugs in abort implementation if found
105
- - Adjusting test expectations if testing changed behavior
106
-
107
- Do NOT just increase timeouts - find the real issue.
108
-
109
- Return: Summary of what you found and what you fixed.
110
- ```
111
-
112
- ## Common Mistakes
113
-
114
- **❌ Too broad:** "Fix all the tests" - agent gets lost
115
- **✅ Specific:** "Fix agent-tool-abort.test.ts" - focused scope
116
-
117
- **❌ No context:** "Fix the race condition" - agent doesn't know where
118
- **✅ Context:** Paste the error messages and test names
119
-
120
- **❌ No constraints:** Agent might refactor everything
121
- **✅ Constraints:** "Do NOT change production code" or "Fix tests only"
122
-
123
- **❌ Vague output:** "Fix it" - you don't know what changed
124
- **✅ Specific:** "Return summary of root cause and changes"
125
-
126
- ## When NOT to Use
127
-
128
- **Related failures:** Fixing one might fix others - investigate together first
129
- **Need full context:** Understanding requires seeing entire system
130
- **Exploratory debugging:** You don't know what's broken yet
131
- **Shared state:** Agents would interfere (editing same files, using same resources)
132
-
133
- ## Real Example from Session
134
-
135
- **Scenario:** 6 test failures across 3 files after major refactoring
136
-
137
- **Failures:**
138
- - agent-tool-abort.test.ts: 3 failures (timing issues)
139
- - batch-completion-behavior.test.ts: 2 failures (tools not executing)
140
- - tool-approval-race-conditions.test.ts: 1 failure (execution count = 0)
141
-
142
- **Decision:** Independent domains - abort logic separate from batch completion separate from race conditions
143
-
144
- **Dispatch:**
145
- ```
146
- Agent 1 → Fix agent-tool-abort.test.ts
147
- Agent 2 → Fix batch-completion-behavior.test.ts
148
- Agent 3 → Fix tool-approval-race-conditions.test.ts
149
- ```
150
-
151
- **Results:**
152
- - Agent 1: Replaced timeouts with event-based waiting
153
- - Agent 2: Fixed event structure bug (threadId in wrong place)
154
- - Agent 3: Added wait for async tool execution to complete
155
-
156
- **Integration:** All fixes independent, no conflicts, full suite green
157
-
158
- **Time saved:** 3 problems solved in parallel vs sequentially
159
-
160
- ## Key Benefits
161
-
162
- 1. **Parallelization** - Multiple investigations happen simultaneously
163
- 2. **Focus** - Each agent has narrow scope, less context to track
164
- 3. **Independence** - Agents don't interfere with each other
165
- 4. **Speed** - 3 problems solved in time of 1
166
-
167
- ## Verification
168
-
169
- After agents return:
170
- 1. **Review each summary** - Understand what changed
171
- 2. **Check for conflicts** - Did agents edit same code?
172
- 3. **Run full suite** - Verify all fixes work together
173
- 4. **Spot check** - Agents can make systematic errors
174
-
175
- ## Real-World Impact
176
-
177
- From debugging session (2025-10-03):
178
- - 6 failures across 3 files
179
- - 3 agents dispatched in parallel
180
- - All investigations completed concurrently
181
- - All fixes integrated successfully
182
- - Zero conflicts between agent changes
1
+ ---
2
+ name: dispatching-parallel-agents
3
+ description: Use when facing 2+ independent tasks that can be worked on without shared state or sequential dependencies
4
+ ---
5
+
6
+ # Dispatching Parallel Agents
7
+
8
+ ## Overview
9
+
10
+ You delegate tasks to specialized agents with isolated context. By precisely crafting their instructions and context, you ensure they stay focused and succeed at their task. They should never inherit your session's context or history — you construct exactly what they need. This also preserves your own context for coordination work.
11
+
12
+ When you have multiple unrelated failures (different test files, different subsystems, different bugs), investigating them sequentially wastes time. Each investigation is independent and can happen in parallel.
13
+
14
+ **Core principle:** Dispatch one agent per independent problem domain. Let them work concurrently.
15
+
16
+ ## When to Use
17
+
18
+ ```dot
19
+ digraph when_to_use {
20
+ "Multiple failures?" [shape=diamond];
21
+ "Are they independent?" [shape=diamond];
22
+ "Single agent investigates all" [shape=box];
23
+ "One agent per problem domain" [shape=box];
24
+ "Can they work in parallel?" [shape=diamond];
25
+ "Sequential agents" [shape=box];
26
+ "Parallel dispatch" [shape=box];
27
+
28
+ "Multiple failures?" -> "Are they independent?" [label="yes"];
29
+ "Are they independent?" -> "Single agent investigates all" [label="no - related"];
30
+ "Are they independent?" -> "Can they work in parallel?" [label="yes"];
31
+ "Can they work in parallel?" -> "Parallel dispatch" [label="yes"];
32
+ "Can they work in parallel?" -> "Sequential agents" [label="no - shared state"];
33
+ }
34
+ ```
35
+
36
+ **Use when:**
37
+ - 3+ test files failing with different root causes
38
+ - Multiple subsystems broken independently
39
+ - Each problem can be understood without context from others
40
+ - No shared state between investigations
41
+
42
+ **Don't use when:**
43
+ - Failures are related (fix one might fix others)
44
+ - Need to understand full system state
45
+ - Agents would interfere with each other
46
+
47
+ ## The Pattern
48
+
49
+ ### 1. Identify Independent Domains
50
+
51
+ Group failures by what's broken:
52
+ - File A tests: Tool approval flow
53
+ - File B tests: Batch completion behavior
54
+ - File C tests: Abort functionality
55
+
56
+ Each domain is independent - fixing tool approval doesn't affect abort tests.
57
+
58
+ ### 2. Create Focused Agent Tasks
59
+
60
+ Each agent gets:
61
+ - **Specific scope:** One test file or subsystem
62
+ - **Clear goal:** Make these tests pass
63
+ - **Constraints:** Don't change other code
64
+ - **Expected output:** Summary of what you found and fixed
65
+
66
+ ### 3. Dispatch in Parallel
67
+
68
+ ```typescript
69
+ // In Claude Code / AI environment
70
+ Task("Fix agent-tool-abort.test.ts failures")
71
+ Task("Fix batch-completion-behavior.test.ts failures")
72
+ Task("Fix tool-approval-race-conditions.test.ts failures")
73
+ // All three run concurrently
74
+ ```
75
+
76
+ ### 4. Review and Integrate
77
+
78
+ When agents return:
79
+ - Read each summary
80
+ - Verify fixes don't conflict
81
+ - Run full test suite
82
+ - Integrate all changes
83
+
84
+ ## Agent Prompt Structure
85
+
86
+ Good agent prompts are:
87
+ 1. **Focused** - One clear problem domain
88
+ 2. **Self-contained** - All context needed to understand the problem
89
+ 3. **Specific about output** - What should the agent return?
90
+
91
+ ```markdown
92
+ Fix the 3 failing tests in src/agents/agent-tool-abort.test.ts:
93
+
94
+ 1. "should abort tool with partial output capture" - expects 'interrupted at' in message
95
+ 2. "should handle mixed completed and aborted tools" - fast tool aborted instead of completed
96
+ 3. "should properly track pendingToolCount" - expects 3 results but gets 0
97
+
98
+ These are timing/race condition issues. Your task:
99
+
100
+ 1. Read the test file and understand what each test verifies
101
+ 2. Identify root cause - timing issues or actual bugs?
102
+ 3. Fix by:
103
+ - Replacing arbitrary timeouts with event-based waiting
104
+ - Fixing bugs in abort implementation if found
105
+ - Adjusting test expectations if testing changed behavior
106
+
107
+ Do NOT just increase timeouts - find the real issue.
108
+
109
+ Return: Summary of what you found and what you fixed.
110
+ ```
111
+
112
+ ## Common Mistakes
113
+
114
+ **❌ Too broad:** "Fix all the tests" - agent gets lost
115
+ **✅ Specific:** "Fix agent-tool-abort.test.ts" - focused scope
116
+
117
+ **❌ No context:** "Fix the race condition" - agent doesn't know where
118
+ **✅ Context:** Paste the error messages and test names
119
+
120
+ **❌ No constraints:** Agent might refactor everything
121
+ **✅ Constraints:** "Do NOT change production code" or "Fix tests only"
122
+
123
+ **❌ Vague output:** "Fix it" - you don't know what changed
124
+ **✅ Specific:** "Return summary of root cause and changes"
125
+
126
+ ## When NOT to Use
127
+
128
+ **Related failures:** Fixing one might fix others - investigate together first
129
+ **Need full context:** Understanding requires seeing entire system
130
+ **Exploratory debugging:** You don't know what's broken yet
131
+ **Shared state:** Agents would interfere (editing same files, using same resources)
132
+
133
+ ## Real Example from Session
134
+
135
+ **Scenario:** 6 test failures across 3 files after major refactoring
136
+
137
+ **Failures:**
138
+ - agent-tool-abort.test.ts: 3 failures (timing issues)
139
+ - batch-completion-behavior.test.ts: 2 failures (tools not executing)
140
+ - tool-approval-race-conditions.test.ts: 1 failure (execution count = 0)
141
+
142
+ **Decision:** Independent domains - abort logic separate from batch completion separate from race conditions
143
+
144
+ **Dispatch:**
145
+ ```
146
+ Agent 1 → Fix agent-tool-abort.test.ts
147
+ Agent 2 → Fix batch-completion-behavior.test.ts
148
+ Agent 3 → Fix tool-approval-race-conditions.test.ts
149
+ ```
150
+
151
+ **Results:**
152
+ - Agent 1: Replaced timeouts with event-based waiting
153
+ - Agent 2: Fixed event structure bug (threadId in wrong place)
154
+ - Agent 3: Added wait for async tool execution to complete
155
+
156
+ **Integration:** All fixes independent, no conflicts, full suite green
157
+
158
+ **Time saved:** 3 problems solved in parallel vs sequentially
159
+
160
+ ## Key Benefits
161
+
162
+ 1. **Parallelization** - Multiple investigations happen simultaneously
163
+ 2. **Focus** - Each agent has narrow scope, less context to track
164
+ 3. **Independence** - Agents don't interfere with each other
165
+ 4. **Speed** - 3 problems solved in time of 1
166
+
167
+ ## Verification
168
+
169
+ After agents return:
170
+ 1. **Review each summary** - Understand what changed
171
+ 2. **Check for conflicts** - Did agents edit same code?
172
+ 3. **Run full suite** - Verify all fixes work together
173
+ 4. **Spot check** - Agents can make systematic errors
174
+
175
+ ## Real-World Impact
176
+
177
+ From debugging session (2025-10-03):
178
+ - 6 failures across 3 files
179
+ - 3 agents dispatched in parallel
180
+ - All investigations completed concurrently
181
+ - All fixes integrated successfully
182
+ - Zero conflicts between agent changes