create-merlin-brain 5.0.1 → 5.3.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 (104) hide show
  1. package/README.md +38 -4
  2. package/bin/install.cjs +20 -0
  3. package/dist/server/server.d.ts.map +1 -1
  4. package/dist/server/server.js +75 -0
  5. package/dist/server/server.js.map +1 -1
  6. package/dist/server/tools/context.d.ts.map +1 -1
  7. package/dist/server/tools/context.js +60 -0
  8. package/dist/server/tools/context.js.map +1 -1
  9. package/dist/server/tools/project-picture.d.ts +17 -0
  10. package/dist/server/tools/project-picture.d.ts.map +1 -0
  11. package/dist/server/tools/project-picture.js +204 -0
  12. package/dist/server/tools/project-picture.js.map +1 -0
  13. package/dist/server/tools/types.d.ts +24 -0
  14. package/dist/server/tools/types.d.ts.map +1 -1
  15. package/files/CLAUDE.md +2 -0
  16. package/files/agents/challenger-academic.md +8 -0
  17. package/files/agents/challenger-arbiter.md +8 -0
  18. package/files/agents/challenger-insider.md +8 -0
  19. package/files/agents/code-organization-supervisor.md +8 -0
  20. package/files/agents/codex-planner.md +36 -9
  21. package/files/agents/context-guardian.md +8 -0
  22. package/files/agents/docs-keeper.md +8 -0
  23. package/files/agents/dry-refactor.md +8 -0
  24. package/files/agents/elite-code-refactorer.md +8 -0
  25. package/files/agents/hardening-guard.md +8 -0
  26. package/files/agents/implementation-dev.md +8 -0
  27. package/files/agents/merlin-access-control-reviewer.md +8 -0
  28. package/files/agents/merlin-api-designer.md +8 -0
  29. package/files/agents/merlin-codebase-mapper.md +8 -0
  30. package/files/agents/merlin-debugger.md +8 -0
  31. package/files/agents/merlin-dependency-auditor.md +8 -0
  32. package/files/agents/merlin-edge-case-hunter.md +8 -0
  33. package/files/agents/merlin-executor.md +8 -0
  34. package/files/agents/merlin-frontend.md +8 -0
  35. package/files/agents/merlin-input-validator.md +8 -0
  36. package/files/agents/merlin-integration-checker.md +8 -0
  37. package/files/agents/merlin-migrator.md +8 -0
  38. package/files/agents/merlin-milestone-auditor.md +8 -0
  39. package/files/agents/merlin-party-review.md +8 -0
  40. package/files/agents/merlin-performance.md +8 -0
  41. package/files/agents/merlin-planner.md +9 -1
  42. package/files/agents/merlin-researcher.md +8 -0
  43. package/files/agents/merlin-reviewer.md +8 -0
  44. package/files/agents/merlin-sast-reviewer.md +8 -0
  45. package/files/agents/merlin-secret-scanner.md +8 -0
  46. package/files/agents/merlin-security.md +8 -0
  47. package/files/agents/merlin-verifier.md +8 -0
  48. package/files/agents/merlin-work-verifier.md +8 -0
  49. package/files/agents/merlin.md +8 -0
  50. package/files/agents/ops-railway.md +8 -0
  51. package/files/agents/orchestrator-retrofit.md +8 -0
  52. package/files/agents/product-spec.md +8 -0
  53. package/files/agents/remotion.md +8 -0
  54. package/files/agents/system-architect.md +8 -0
  55. package/files/agents/tests-qa.md +8 -0
  56. package/files/commands/merlin/course-correct.md +8 -0
  57. package/files/commands/merlin/design-audit.md +92 -0
  58. package/files/commands/merlin/health.md +8 -0
  59. package/files/commands/merlin/next.md +8 -0
  60. package/files/commands/merlin/optimize.md +89 -0
  61. package/files/commands/merlin/polish.md +99 -0
  62. package/files/commands/merlin/quick.md +8 -0
  63. package/files/commands/merlin/readiness-gate.md +8 -0
  64. package/files/commands/merlin/redesign.md +108 -0
  65. package/files/hooks/session-start.sh +88 -2
  66. package/files/hooks/statusline.sh +9 -1
  67. package/files/loop/README.md +11 -0
  68. package/files/merlin/skills/SKILLS-INDEX.md +16 -1
  69. package/files/merlin/skills/TASK-OPTIMIZER.json +310 -0
  70. package/files/merlin/skills/coding/focus-mode.md +8 -0
  71. package/files/merlin/skills/design/emil-design-eng.md +31 -0
  72. package/files/merlin/skills/design/impeccable.md +36 -0
  73. package/files/merlin/skills/duo/offer.md +20 -7
  74. package/files/merlin/skills/duo/on.md +26 -17
  75. package/files/merlin/skills/duo/status.md +10 -3
  76. package/files/merlin/templates/DEBUG.md +11 -0
  77. package/files/merlin/templates/UAT.md +11 -0
  78. package/files/merlin/templates/phase-prompt.md +11 -0
  79. package/files/merlin/templates/project.md +11 -0
  80. package/files/merlin/templates/requirements.md +11 -0
  81. package/files/merlin/templates/roadmap.md +11 -0
  82. package/files/merlin/templates/state.md +11 -0
  83. package/files/merlin/templates/verification-report.md +11 -0
  84. package/files/merlin/workflows/execute-phase.md +11 -0
  85. package/files/merlin/workflows/plan-phase.md +11 -0
  86. package/files/merlin/workflows/progress.md +11 -0
  87. package/files/merlin/workflows/resume-project.md +11 -0
  88. package/files/merlin/workflows/verify-phase.md +11 -0
  89. package/files/merlin/workflows/verify-work.md +11 -0
  90. package/files/merlin-system-prompt.txt +35 -1
  91. package/files/rules/codex-routing.md +19 -0
  92. package/files/rules/duo-routing.md +109 -10
  93. package/files/rules/merlin-routing.md +40 -0
  94. package/files/scripts/codex-as.sh +5 -2
  95. package/files/scripts/design-intent-detect.sh +8 -0
  96. package/files/scripts/duo-badge.sh +3 -5
  97. package/files/scripts/duo-installed.sh +3 -3
  98. package/files/scripts/duo-mode-read.sh +30 -10
  99. package/files/scripts/duo-mode-write.sh +28 -3
  100. package/files/scripts/duo-pre-route.sh +2 -8
  101. package/files/scripts/install-design-skills.sh +86 -0
  102. package/files/scripts/merlin-codex.sh +84 -0
  103. package/files/scripts/task-optimize.sh +335 -0
  104. package/package.json +1 -1
@@ -0,0 +1,310 @@
1
+ {
2
+ "version": "1.0",
3
+ "default_agent": "implementation-dev",
4
+ "default_threshold": 25,
5
+ "skills": [
6
+ {
7
+ "id": "design/impeccable",
8
+ "path": "~/.claude/skills/impeccable/SKILL.md",
9
+ "triggers": [
10
+ "redesign", "make it pretty", "looks ugly", "make it beautiful", "the ui is bad",
11
+ "typography", "fonts", "font pairing", "font", "spacing", "alignment", "grid", "rhythm",
12
+ "color system", "oklch", "palette", "contrast", "design audit", "design review",
13
+ "design critique", "responsive design", "mobile broken", "container queries",
14
+ "fluid design", "dark mode", "light mode", "theme switching", "match stripe",
15
+ "match linear", "match vercel", "design quality", "design system", "loading state",
16
+ "empty state", "error state", "form polish", "ux writing", "labels", "error messages",
17
+ "copy", "looks bad", "ugly", "beautiful", "pretty", "visual", "visuals", "ui design",
18
+ "ui polish", "ui/ux", "ux design"
19
+ ],
20
+ "agent": "ui-builder",
21
+ "intent": "design",
22
+ "weight": 1.0,
23
+ "bundles_with": ["design/emil-design-eng"]
24
+ },
25
+ {
26
+ "id": "design/emil-design-eng",
27
+ "path": "~/.claude/skills/emil-design-eng/SKILL.md",
28
+ "triggers": [
29
+ "animate", "animation", "feels stiff", "add motion", "smoother", "polish",
30
+ "micro-interactions", "feels cheap", "easing", "transitions", "transitions are bad",
31
+ "gestures", "60fps", "premium feel", "make it feel premium", "stiff", "motion",
32
+ "micro-interaction", "microinteraction", "feel premium", "feel cheap"
33
+ ],
34
+ "agent": "animation-expert",
35
+ "intent": "animation-polish",
36
+ "weight": 1.0,
37
+ "bundles_with": ["design/impeccable"]
38
+ },
39
+ {
40
+ "id": "design/animation",
41
+ "path": "design/animation",
42
+ "triggers": [
43
+ "framer-motion", "framer motion", "gsap", "scroll trigger", "spring animation",
44
+ "enter exit animation", "lottie", "rive", "animejs", "anime.js"
45
+ ],
46
+ "agent": "animation-expert",
47
+ "intent": "animation",
48
+ "weight": 0.8
49
+ },
50
+ {
51
+ "id": "coding/react-patterns",
52
+ "path": "coding/react-patterns",
53
+ "triggers": [
54
+ "react", "react component", "jsx", "tsx", "usestate", "useeffect", "usecallback",
55
+ "usememo", "hook", "custom hook", "server component", "client component", "next.js",
56
+ "nextjs", "remix", "vite", "react hook", "react hooks", "use client", "use server"
57
+ ],
58
+ "agent": "merlin-frontend",
59
+ "intent": "react",
60
+ "weight": 1.0
61
+ },
62
+ {
63
+ "id": "coding/security-hardening",
64
+ "path": "coding/security-hardening",
65
+ "triggers": [
66
+ "auth", "authentication", "authorization", "oauth", "jwt", "owasp", "csrf", "xss",
67
+ "sql injection", "sqli", "input validation", "sanitize", "session", "rate limit",
68
+ "secret", "credentials", "harden", "security audit", "vulnerability", "exploit",
69
+ "security", "secure", "hardening", "security check", "security review", "pen test",
70
+ "penetration test"
71
+ ],
72
+ "agent": "hardening-guard",
73
+ "intent": "security",
74
+ "weight": 1.2,
75
+ "bundles_with": ["testing/tdd-workflow"]
76
+ },
77
+ {
78
+ "id": "coding/api-design",
79
+ "path": "coding/api-design",
80
+ "triggers": [
81
+ "api design", "rest api", "restful", "endpoint design", "openapi", "swagger",
82
+ "graphql schema", "graphql", "pagination", "api versioning", "express route",
83
+ "hono", "fastapi", "api endpoint", "trpc", "grpc"
84
+ ],
85
+ "agent": "merlin-api-designer",
86
+ "intent": "api",
87
+ "weight": 1.0
88
+ },
89
+ {
90
+ "id": "coding/performance",
91
+ "path": "coding/performance",
92
+ "triggers": [
93
+ "performance", "slow", "core web vitals", "lcp", "fid", "cls", "bundle size",
94
+ "lazy load", "code split", "lighthouse", "memory leak", "cpu", "optimize",
95
+ "optimization", "fast", "faster", "speed", "perf", "web vitals", "ttfb", "inp"
96
+ ],
97
+ "agent": "merlin-performance",
98
+ "intent": "performance",
99
+ "weight": 1.0
100
+ },
101
+ {
102
+ "id": "coding/accessibility",
103
+ "path": "coding/accessibility",
104
+ "triggers": [
105
+ "a11y", "accessibility", "wcag", "wcag compliance", "aria", "screen reader",
106
+ "keyboard navigation", "keyboard nav", "focus management", "alt text",
107
+ "contrast ratio", "accessible", "accessibility fixes", "accessibility audit",
108
+ "voiceover", "nvda", "jaws", "accessibility check"
109
+ ],
110
+ "agent": "hardening-guard",
111
+ "intent": "a11y",
112
+ "weight": 1.1,
113
+ "bundles_with": ["design/impeccable"]
114
+ },
115
+ {
116
+ "id": "coding/debug-mode",
117
+ "path": "coding/debug-mode",
118
+ "triggers": [
119
+ "bug", "crash", "error", "stack trace", "broken deploy", "broken build",
120
+ "not working", "fails", "exception", "investigate", "debug", "troubleshoot",
121
+ "reproduce", "debugging", "null pointer", "undefined", "type error", "runtime error"
122
+ ],
123
+ "agent": "merlin-debugger",
124
+ "intent": "debug",
125
+ "weight": 1.1
126
+ },
127
+ {
128
+ "id": "coding/verify",
129
+ "path": "coding/verify",
130
+ "triggers": [
131
+ "verify", "validate", "check if it works", "confirm", "smoke test", "qa",
132
+ "verification", "validation", "sanity check"
133
+ ],
134
+ "agent": "merlin-work-verifier",
135
+ "intent": "verify",
136
+ "weight": 0.9
137
+ },
138
+ {
139
+ "id": "testing/tdd-workflow",
140
+ "path": "testing/tdd-workflow",
141
+ "triggers": [
142
+ "test", "tests", "unit test", "tdd", "tdd workflow", "red green refactor",
143
+ "jest", "vitest", "pytest", "rspec", "test coverage", "write tests", "testing",
144
+ "test suite", "integration test", "e2e test", "end to end", "playwright",
145
+ "cypress", "mocha"
146
+ ],
147
+ "agent": "tests-qa",
148
+ "intent": "testing",
149
+ "weight": 1.1
150
+ },
151
+ {
152
+ "id": "devops/docker-containers",
153
+ "path": "devops/docker-containers",
154
+ "triggers": [
155
+ "docker", "dockerfile", "container", "docker-compose", "multi-stage build",
156
+ "multi-stage", "containerize", "kubernetes", "k8s", "helm", "docker image",
157
+ "container build", "docker build"
158
+ ],
159
+ "agent": "ops-railway",
160
+ "intent": "docker",
161
+ "weight": 1.1
162
+ },
163
+ {
164
+ "id": "automation/payments",
165
+ "path": "automation/payments",
166
+ "triggers": [
167
+ "stripe", "payment", "checkout", "subscription", "invoice", "billing",
168
+ "payment provider", "paddle", "lemonsqueezy", "lemon squeezy", "payments",
169
+ "payment integration", "subscription billing"
170
+ ],
171
+ "agent": "implementation-dev",
172
+ "intent": "payments",
173
+ "weight": 1.0
174
+ },
175
+ {
176
+ "id": "automation/webhooks",
177
+ "path": "automation/webhooks",
178
+ "triggers": [
179
+ "webhook", "webhooks", "http callback", "event delivery", "signature verification",
180
+ "payload", "webhook handler", "webhook endpoint"
181
+ ],
182
+ "agent": "implementation-dev",
183
+ "intent": "webhooks",
184
+ "weight": 0.9
185
+ },
186
+ {
187
+ "id": "communication/email-gmail",
188
+ "path": "communication/email-gmail",
189
+ "triggers": [
190
+ "gmail", "email send", "email read", "email draft", "gmail api", "mailbox",
191
+ "send email", "email automation", "email"
192
+ ],
193
+ "agent": "implementation-dev",
194
+ "intent": "email",
195
+ "weight": 0.9
196
+ },
197
+ {
198
+ "id": "communication/whatsapp",
199
+ "path": "communication/whatsapp",
200
+ "triggers": [
201
+ "whatsapp", "whatsapp business", "wa api", "whatsapp bot", "whatsapp api",
202
+ "whatsapp integration"
203
+ ],
204
+ "agent": "implementation-dev",
205
+ "intent": "whatsapp",
206
+ "weight": 0.9
207
+ },
208
+ {
209
+ "id": "communication/telegram",
210
+ "path": "communication/telegram",
211
+ "triggers": [
212
+ "telegram", "telegram bot", "bot api", "tg bot", "telegram api",
213
+ "telegram integration"
214
+ ],
215
+ "agent": "implementation-dev",
216
+ "intent": "telegram",
217
+ "weight": 0.9
218
+ },
219
+ {
220
+ "id": "data/google-sheets",
221
+ "path": "data/google-sheets",
222
+ "triggers": [
223
+ "google sheets", "spreadsheet", "sheets api", "sheets formula", "sheet automation",
224
+ "google sheet", "gsheets"
225
+ ],
226
+ "agent": "implementation-dev",
227
+ "intent": "sheets",
228
+ "weight": 0.9
229
+ },
230
+ {
231
+ "id": "research/brainstorm",
232
+ "path": "research/brainstorm",
233
+ "triggers": [
234
+ "brainstorm", "ideate", "explore ideas", "what if", "options", "approaches",
235
+ "brainstorming", "ideas", "explore options"
236
+ ],
237
+ "agent": "merlin-researcher",
238
+ "intent": "brainstorm",
239
+ "weight": 0.8
240
+ },
241
+ {
242
+ "id": "coding/focus-mode",
243
+ "path": "coding/focus-mode",
244
+ "triggers": [
245
+ "focus mode", "deep work", "no distractions", "focused", "concentrate"
246
+ ],
247
+ "agent": "implementation-dev",
248
+ "intent": "focus",
249
+ "weight": 0.7
250
+ },
251
+ {
252
+ "id": "coding/loop",
253
+ "path": "coding/loop",
254
+ "triggers": [
255
+ "loop", "autonomous", "auto mode", "keep going", "run continuously"
256
+ ],
257
+ "agent": "implementation-dev",
258
+ "intent": "loop",
259
+ "weight": 0.7
260
+ },
261
+ {
262
+ "id": "communication/dispatcher",
263
+ "path": "communication/dispatcher",
264
+ "triggers": [
265
+ "dispatch", "notify", "send notification", "alert", "message"
266
+ ],
267
+ "agent": "implementation-dev",
268
+ "intent": "dispatch",
269
+ "weight": 0.7
270
+ },
271
+ {
272
+ "id": "docs-keeper",
273
+ "path": "docs-keeper",
274
+ "triggers": [
275
+ "documentation", "docs", "readme", "jsdoc", "typedoc", "document", "api docs"
276
+ ],
277
+ "agent": "docs-keeper",
278
+ "intent": "docs",
279
+ "weight": 0.8
280
+ },
281
+ {
282
+ "id": "hardening-guard",
283
+ "path": "hardening-guard",
284
+ "triggers": [
285
+ "harden", "secure", "lock down", "production ready", "security hardening"
286
+ ],
287
+ "agent": "hardening-guard",
288
+ "intent": "hardening",
289
+ "weight": 0.9
290
+ },
291
+ {
292
+ "id": "code-organization-supervisor",
293
+ "path": "code-organization-supervisor",
294
+ "triggers": [
295
+ "organize code", "code organization", "file structure", "folder structure",
296
+ "project structure", "refactor structure"
297
+ ],
298
+ "agent": "code-organization-supervisor",
299
+ "intent": "organization",
300
+ "weight": 0.8
301
+ }
302
+ ],
303
+ "intent_overrides": {
304
+ "auth_security_combo": {
305
+ "match_all": ["auth", "production"],
306
+ "skills": ["coding/security-hardening", "testing/tdd-workflow"],
307
+ "agent": "hardening-guard"
308
+ }
309
+ }
310
+ }
@@ -9,6 +9,14 @@ source: builtin
9
9
  successRate: 0
10
10
  usageCount: 0
11
11
  evolution: []
12
+ provenance:
13
+ upstream: gsd-build/get-shit-done
14
+ upstream_path: skills/focus-mode.md
15
+ upstream_commit: 9045c81
16
+ license: MIT
17
+ license_verification: confirmed
18
+ adapted: "2026-03-14"
19
+ changes: adapted from GSD skill pattern
12
20
  ---
13
21
  # Focus Mode (GSD)
14
22
  Work in Get Stuff Done mode. Make reasonable decisions without asking. Build quickly and show results. Only ask questions when truly blocked. Prefer action over deliberation. If two approaches seem equally valid, pick the simpler one and move on.
@@ -0,0 +1,31 @@
1
+ ---
2
+ id: emil-design-eng
3
+ name: Emil Design Engineering
4
+ domain: coding
5
+ category: design
6
+ tags: [design, ui, animation, polish, micro-interactions, easing, transforms, gestures, performance, accessibility]
7
+ triggers: [animate, animation, "feels stiff", "add motion", smoother, polish, "micro-interactions", "feels cheap", easing, transitions, gestures, "60fps", "premium feel"]
8
+ version: 1
9
+ source: external
10
+ upstream: emilkowalski/skill
11
+ license: unlicensed
12
+ install_path: ~/.claude/skills/emil-design-eng/SKILL.md
13
+ successRate: 0
14
+ usageCount: 0
15
+ evolution: []
16
+ ---
17
+ # Emil Design Engineering
18
+
19
+ Animation craft and UI polish from Emil Kowalski. Covers easing functions, transforms, gestures, micro-interactions, performance optimization, and accessibility (`prefers-reduced-motion`).
20
+
21
+ **Usage:** Read the full skill at `~/.claude/skills/emil-design-eng/SKILL.md` (installed via `npx --yes skills add emilkowalski/skill`).
22
+
23
+ If the file is missing, run: `npx --yes skills add emilkowalski/skill` or `bash ~/.claude/scripts/install-design-skills.sh`
24
+
25
+ This skill covers:
26
+ - Easing functions and animation timing
27
+ - CSS and JS transforms
28
+ - Gesture interactions and touch handling
29
+ - Micro-interactions and polish
30
+ - Performance (GPU compositing, will-change)
31
+ - Motion preferences and accessibility
@@ -0,0 +1,36 @@
1
+ ---
2
+ id: impeccable
3
+ name: Impeccable Design Language
4
+ domain: coding
5
+ category: design
6
+ tags: [design, ui, typography, color, spacing, motion, interaction, responsive, ux-writing, accessibility, dark-mode, oklch]
7
+ triggers: [redesign, "make it pretty", "looks ugly", typography, "color system", spacing, "design audit", accessibility, responsive, "dark mode", OKLCH, "fluid design", "design review", "UX writing", "design system", polish, "premium feel", professional]
8
+ version: 1
9
+ source: external
10
+ upstream: pbakaus/impeccable
11
+ license: Apache-2.0
12
+ install_path: ~/.claude/skills/impeccable/SKILL.md
13
+ successRate: 0
14
+ usageCount: 0
15
+ evolution: []
16
+ ---
17
+ # Impeccable Design Language
18
+
19
+ Comprehensive design language by Philipp Bakaus covering 7 design domains + 23 specialized commands for design critique, auditing, and refinement.
20
+
21
+ **Usage:** Read the full skill at `~/.claude/skills/impeccable/SKILL.md` (installed at setup via `install-design-skills.sh`).
22
+
23
+ If the file is missing, run: `bash ~/.claude/scripts/install-design-skills.sh`
24
+
25
+ This skill covers:
26
+ - Typography (scales, families, weights, line-height)
27
+ - Color theory (OKLCH, accessibility, dark-mode)
28
+ - Spatial design (spacing, grids, proportions)
29
+ - Motion design (timing, easing, interactions)
30
+ - Interaction design (states, feedback, patterns)
31
+ - Responsive design (breakpoints, fluid scaling)
32
+ - UX writing (copy, tone, clarity)
33
+
34
+ Commands include `/audit`, `/polish`, `/critique`, `/animate`, `/harden`, `/distill` and 17+ more.
35
+
36
+ Apache-2.0 license attribution preserved at `~/.claude/skills/impeccable/NOTICE.md`.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: duo-offer
3
- description: Auto-offer prompt for enabling duo mode on risky tasks. Invoked by duo-pre-route.sh when risk score >= threshold and Codex is installed and duo is off and task is not suppressed.
3
+ description: Auto-offer prompt for enabling duo mode on risky tasks. Invoked by duo-pre-route.sh when risk score >= threshold and duo is off and task is not suppressed.
4
4
  type: skill
5
5
  subcommand: offer
6
6
  ---
@@ -13,9 +13,10 @@ You are executing the duo auto-offer flow. Follow every step in sequence.
13
13
 
14
14
  Run `~/.claude/scripts/duo-mode-read.sh`. If output is `enabled`, exit silently — duo is already on, no offer needed.
15
15
 
16
- ## Step 2 — Install gate
17
-
18
- Run `~/.claude/scripts/duo-installed.sh`. If exit code != 0, exit silently — do not mention duo or Codex.
16
+ ## Step 2 — Detect pair (informational only — never blocks the offer).
17
+ Run `~/.claude/scripts/codex-installed.sh`. Capture exit code.
18
+ If exit 0 PAIR=claude+codex
19
+ Else → PAIR=claude+claude
19
20
 
20
21
  ## Step 3 — Read context
21
22
 
@@ -95,8 +96,9 @@ Map reasons to human-readable category labels (never display raw file paths):
95
96
  - `keyword:ship`, `keyword:release`, `keyword:critical` → "release-critical"
96
97
  - `dep:package.json`, `dep:go.mod`, `dep:Cargo.toml`, `dep:requirements.txt` → "dependency changes"
97
98
 
98
- Display (show at most 3 categories, never raw paths):
99
+ Display (show at most 3 categories, never raw paths). Tailor the pair line to PAIR:
99
100
 
101
+ If PAIR == claude+codex:
100
102
  ```
101
103
  ⟡🔮 MERLIN › This task looks risky (score <SCORE>/100).
102
104
  • Areas: <comma-separated categories>
@@ -107,13 +109,24 @@ Reply: yes (enable duo) · no (solo) · skip session · never
107
109
  (default = solo if you don't reply explicitly)
108
110
  ```
109
111
 
112
+ If PAIR == claude+claude:
113
+ ```
114
+ ⟡🔮 MERLIN › This task looks risky (score <SCORE>/100).
115
+ • Areas: <comma-separated categories>
116
+ • Workflow: <workflow or "general">
117
+ Twin-Claude pair would tag-team this (sequential write + review with decider gate).
118
+
119
+ Reply: yes (enable duo) · no (solo) · skip session · never
120
+ (default = solo if you don't reply explicitly)
121
+ ```
122
+
110
123
  ## Step 7 — Parse user reply (case-insensitive)
111
124
 
112
125
  Wait for the user's response, then:
113
126
 
114
127
  | Reply contains | Action |
115
128
  |---|---|
116
- | `yes` / `enable duo` / `do it` | Call `~/.claude/scripts/duo-mode-write.sh on "auto-offer accepted: <reasons>"` then set `DUO_OFFER_OUTCOME=yes` |
129
+ | `yes` / `enable duo` / `do it` | Call `~/.claude/scripts/duo-mode-write.sh on "auto-offer accepted: <reasons>" "$PAIR"` then set `DUO_OFFER_OUTCOME=yes` |
117
130
  | `skip session` / `skip this session` | Set `session_skip:true` in duo-suppress.json (atomic, flock), set `DUO_OFFER_OUTCOME=skip-session` |
118
131
  | `never` | Add intent fingerprint to `never_for_intents` (FIFO cap 20, with timestamp), set `DUO_OFFER_OUTCOME=never` |
119
132
  | `no` / anything else / silence | Add task_hash to `task_hashes_declined` (FIFO cap 100), set `DUO_OFFER_OUTCOME=no` |
@@ -149,7 +162,7 @@ EOF
149
162
  Append to `~/.claude/merlin-state/duo-decisions.log` (create if missing, JSONL):
150
163
 
151
164
  ```json
152
- {"ts":"<ISO8601>","event":"offer","score":<N>,"reasons":[...],"response":"<yes|no|skip-session|never|silent>","action":"<enable|solo|suppress-session|suppress-intent|suppress-task>"}
165
+ {"ts":"<ISO8601>","event":"offer","score":<N>,"reasons":[...],"response":"<yes|no|skip-session|never|silent>","action":"<enable|solo|suppress-session|suppress-intent|suppress-task>","pair":"<claude+codex|claude+claude>"}
153
166
  ```
154
167
 
155
168
  ## Step 9 — Continue
@@ -2,29 +2,23 @@
2
2
 
3
3
  ## Steps
4
4
 
5
- **Step 1 — Check install gate.**
6
- ```bash
7
- ~/.claude/scripts/duo-installed.sh
8
- EXIT_CODE=$?
9
- ```
5
+ **Step 1 — Check current state.**
6
+ Run `~/.claude/scripts/duo-mode-read.sh`. If output is `enabled`, duo is already on — skip to Step 4 to show current confirmation and stop.
10
7
 
11
- **Step 2 — Gate failed (Codex not installed).**
12
- If exit code != 0:
13
- ```bash
14
- ~/.claude/scripts/duo-mode-write.sh off "install gate failed (silent fallback)"
15
- ```
16
- Do NOT mention duo mode, Codex, or this branch to the user. Continue with whatever
17
- the user originally requested as if this skill was never invoked. Stop here.
8
+ **Step 2 — Detect pair.**
9
+ Run `~/.claude/scripts/codex-installed.sh`. If exit 0 PAIR=claude+codex. Else → PAIR=claude+claude.
18
10
 
19
- **Step 3 — Gate passed. Enable duo.**
11
+ **Step 3 — Enable duo with pair.**
20
12
  ```bash
21
- ~/.claude/scripts/duo-mode-write.sh on "<user's phrase that triggered enable>"
13
+ ~/.claude/scripts/duo-mode-write.sh on "<user's phrase that triggered enable>" "$PAIR"
22
14
  BADGE=$(~/.claude/scripts/duo-badge.sh)
23
15
  ```
24
16
 
25
- **Step 4 — Emit confirmation.**
17
+ **Step 4 — Emit confirmation tailored to pair.**
18
+
19
+ If PAIR == claude+codex:
26
20
  ```
27
- ⟡🔮↔🔮 MERLIN·DUO › Duo mode enabled.
21
+ ⟡🔮↔🔮 MERLIN·DUO › Duo mode enabled (Claude + Codex).
28
22
  • Parallel: planning, docs, code review, tests
29
23
  • Sequential: code write/modify (codex writes → claude reviews → decider gates)
30
24
  • Verification stays with Claude
@@ -33,7 +27,22 @@ BADGE=$(~/.claude/scripts/duo-badge.sh)
33
27
  Try: "plan the next phase" to see dual-planning.
34
28
  ```
35
29
 
36
- **Step 5 Codex-mode coexistence check.**
30
+ If PAIR == claude+claude:
31
+ ```
32
+ ⟡🔮↔🔮 MERLIN·DUO › Duo mode enabled (twin-Claude — Codex not installed).
33
+ Two Claude specialists tag-team your work:
34
+ • Parallel planning: merlin-planner + challenger-academic → arbiter
35
+ • Parallel review: code-review + merlin-reviewer → arbiter
36
+ • Parallel testing: tests-qa + merlin-edge-case-hunter → arbiter
37
+ • Sequential code: implementation-dev writes → code-review reviews → decider gates
38
+ • Verification stays with Claude
39
+ • Auto-expires in 24h
40
+ (Install Codex if you want claude+codex pairing instead.)
41
+ ```
42
+
43
+ **Step 5 — Codex-mode coexistence check (claude+codex pair only).**
44
+ Skip this step if PAIR == claude+claude.
45
+
37
46
  ```bash
38
47
  python3 -c "
39
48
  import json, os, sys
@@ -12,11 +12,13 @@ state_path = os.path.expanduser("~/.claude/merlin-state/duo-mode.json")
12
12
  try:
13
13
  data = json.load(open(state_path))
14
14
  except:
15
- data = {"enabled": False, "sinceISO": None, "lastToggleReason": None}
15
+ data = {"enabled": False, "sinceISO": None, "lastToggleReason": None, "pair": None}
16
16
 
17
17
  enabled = data.get("enabled", False)
18
18
  since_iso = data.get("sinceISO")
19
19
  reason = data.get("lastToggleReason") or "never enabled"
20
+ # Legacy state: if enabled but no pair field, default to claude+codex
21
+ pair = data.get("pair") or ("claude+codex" if enabled else None)
20
22
 
21
23
  age_str = ""
22
24
  status_label = "OFF"
@@ -30,6 +32,7 @@ if enabled and since_iso:
30
32
  if delta > timedelta(hours=24):
31
33
  expired = True
32
34
  status_label = "AUTO-EXPIRED"
35
+ pair = None
33
36
  else:
34
37
  status_label = "ON"
35
38
  total_s = int(delta.total_seconds())
@@ -37,18 +40,20 @@ if enabled and since_iso:
37
40
  except:
38
41
  expired = True
39
42
  status_label = "AUTO-EXPIRED"
43
+ pair = None
40
44
 
41
45
  print(f"status={status_label}")
42
46
  print(f"since={since_iso or 'n/a'}")
43
47
  print(f"age={age_str or 'n/a'}")
44
48
  print(f"reason={reason}")
45
49
  print(f"expired={expired}")
50
+ print(f"pair={pair or 'none'}")
46
51
  PYEOF
47
52
  ```
48
53
 
49
54
  **Step 2 — Check Codex install gate.**
50
55
  ```bash
51
- ~/.claude/scripts/duo-installed.sh 2>/dev/null && echo "gate=pass" || echo "gate=fail"
56
+ ~/.claude/scripts/codex-installed.sh 2>/dev/null && echo "gate=pass" || echo "gate=fail"
52
57
  ```
53
58
 
54
59
  **Step 3 — Parse duo-suppress.json.**
@@ -74,6 +79,7 @@ Use the values above to emit ONE of these formats:
74
79
  If status=ON:
75
80
  ```
76
81
  ⟡🔮↔🔮 MERLIN·DUO › Duo: ON · since {sinceISO} · age {hh:mm} · reason: {lastToggleReason}
82
+ Pair: {claude+codex|claude+claude}
77
83
  ```
78
84
 
79
85
  If status=OFF:
@@ -88,7 +94,8 @@ If status=AUTO-EXPIRED:
88
94
 
89
95
  Then append install gate and suppression lines:
90
96
  ```
91
- Codex install gate: ✓ pass (or fail — duo would silent-fallback to solo)
97
+ Codex install gate: ✓ pass (claude+codex pair available) [when gate=pass]
98
+ Codex install gate: ✗ fail (duo runs as twin-Claude pair) [when gate=fail]
92
99
  Session skip: {true|false}
93
100
  Suppressed intents: {N} (if N > 0, add: — run Skill("merlin:duo", args="unsuppress") to clear)
94
101
  Recently declined task hashes: {N}
@@ -1,3 +1,14 @@
1
+ ---
2
+ provenance:
3
+ upstream: gsd-build/get-shit-done
4
+ upstream_path: templates/DEBUG.md
5
+ upstream_commit: 9045c81
6
+ license: MIT
7
+ license_verification: confirmed
8
+ adapted: "2026-03-14"
9
+ changes: adapted from GSD planning template
10
+ ---
11
+
1
12
  # Debug Template
2
13
 
3
14
  Template for `.planning/debug/[slug].md` — active debug session tracking.
@@ -1,3 +1,14 @@
1
+ ---
2
+ provenance:
3
+ upstream: gsd-build/get-shit-done
4
+ upstream_path: templates/UAT.md
5
+ upstream_commit: 9045c81
6
+ license: MIT
7
+ license_verification: confirmed
8
+ adapted: "2026-03-14"
9
+ changes: adapted from GSD planning template
10
+ ---
11
+
1
12
  # UAT Template
2
13
 
3
14
  Template for `.planning/phases/XX-name/{phase}-UAT.md` — persistent UAT session tracking.
@@ -1,3 +1,14 @@
1
+ ---
2
+ provenance:
3
+ upstream: gsd-build/get-shit-done
4
+ upstream_path: templates/phase-prompt.md
5
+ upstream_commit: 9045c81
6
+ license: MIT
7
+ license_verification: confirmed
8
+ adapted: "2026-03-14"
9
+ changes: adapted from GSD planning template
10
+ ---
11
+
1
12
  # Phase Prompt Template
2
13
 
3
14
  Template for `.planning/phases/XX-name/{phase}-{plan}-PLAN.md` - executable phase plans optimized for parallel execution.
@@ -1,3 +1,14 @@
1
+ ---
2
+ provenance:
3
+ upstream: gsd-build/get-shit-done
4
+ upstream_path: templates/project.md
5
+ upstream_commit: 9045c81
6
+ license: MIT
7
+ license_verification: confirmed
8
+ adapted: "2026-03-14"
9
+ changes: adapted from GSD planning template
10
+ ---
11
+
1
12
  # PROJECT.md Template
2
13
 
3
14
  Template for `.planning/PROJECT.md` — the living project context document.
@@ -1,3 +1,14 @@
1
+ ---
2
+ provenance:
3
+ upstream: gsd-build/get-shit-done
4
+ upstream_path: templates/requirements.md
5
+ upstream_commit: 9045c81
6
+ license: MIT
7
+ license_verification: confirmed
8
+ adapted: "2026-03-14"
9
+ changes: adapted from GSD planning template
10
+ ---
11
+
1
12
  # Requirements Template
2
13
 
3
14
  Template for `.planning/REQUIREMENTS.md` — checkable requirements that define "done."