@rune-kit/rune 2.8.0 → 2.11.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 (287) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +68 -34
  3. package/agents/adversary.md +27 -0
  4. package/agents/architect.md +19 -29
  5. package/agents/asset-creator.md +18 -4
  6. package/agents/audit.md +25 -4
  7. package/agents/autopsy.md +19 -4
  8. package/agents/ba.md +35 -0
  9. package/agents/brainstorm.md +31 -4
  10. package/agents/browser-pilot.md +21 -4
  11. package/agents/coder.md +21 -29
  12. package/agents/completion-gate.md +20 -4
  13. package/agents/constraint-check.md +18 -4
  14. package/agents/context-engine.md +22 -4
  15. package/agents/context-pack.md +32 -0
  16. package/agents/cook.md +41 -4
  17. package/agents/db.md +19 -4
  18. package/agents/debug.md +33 -4
  19. package/agents/dependency-doctor.md +20 -4
  20. package/agents/deploy.md +27 -4
  21. package/agents/design.md +22 -4
  22. package/agents/doc-processor.md +27 -0
  23. package/agents/docs-seeker.md +19 -4
  24. package/agents/docs.md +31 -0
  25. package/agents/fix.md +37 -4
  26. package/agents/git.md +29 -0
  27. package/agents/hallucination-guard.md +20 -4
  28. package/agents/incident.md +21 -4
  29. package/agents/integrity-check.md +18 -4
  30. package/agents/journal.md +19 -4
  31. package/agents/launch.md +32 -4
  32. package/agents/logic-guardian.md +26 -11
  33. package/agents/marketing.md +23 -4
  34. package/agents/mcp-builder.md +26 -0
  35. package/agents/neural-memory.md +30 -0
  36. package/agents/onboard.md +22 -4
  37. package/agents/perf.md +21 -4
  38. package/agents/plan.md +29 -4
  39. package/agents/preflight.md +22 -4
  40. package/agents/problem-solver.md +20 -4
  41. package/agents/rescue.md +23 -4
  42. package/agents/research.md +19 -4
  43. package/agents/researcher.md +19 -29
  44. package/agents/retro.md +32 -0
  45. package/agents/review-intake.md +20 -4
  46. package/agents/review.md +32 -4
  47. package/agents/reviewer.md +20 -28
  48. package/agents/safeguard.md +19 -4
  49. package/agents/sast.md +18 -4
  50. package/agents/scaffold.md +41 -0
  51. package/agents/scanner.md +19 -28
  52. package/agents/scope-guard.md +18 -4
  53. package/agents/scout.md +23 -4
  54. package/agents/sentinel-env.md +26 -0
  55. package/agents/sentinel.md +33 -4
  56. package/agents/sequential-thinking.md +20 -4
  57. package/agents/session-bridge.md +24 -4
  58. package/agents/skill-forge.md +22 -4
  59. package/agents/skill-router.md +26 -4
  60. package/agents/slides.md +24 -0
  61. package/agents/surgeon.md +19 -4
  62. package/agents/team.md +30 -4
  63. package/agents/test.md +36 -4
  64. package/agents/trend-scout.md +17 -4
  65. package/agents/verification.md +20 -4
  66. package/agents/video-creator.md +20 -4
  67. package/agents/watchdog.md +19 -4
  68. package/agents/worktree.md +17 -4
  69. package/commands/rune.md +168 -168
  70. package/compiler/__tests__/analytics.test.js +370 -0
  71. package/compiler/adapters/openclaw.js +2 -2
  72. package/compiler/analytics.js +385 -0
  73. package/compiler/bin/rune.js +68 -2
  74. package/compiler/dashboard.js +883 -0
  75. package/compiler/transforms/branding.js +1 -1
  76. package/contexts/dev.md +34 -34
  77. package/contexts/research.md +43 -43
  78. package/contexts/review.md +55 -55
  79. package/extensions/ai-ml/PACK.md +88 -88
  80. package/extensions/ai-ml/skills/ai-agents.md +172 -172
  81. package/extensions/ai-ml/skills/code-sandbox.md +187 -187
  82. package/extensions/ai-ml/skills/deep-research.md +146 -146
  83. package/extensions/ai-ml/skills/embedding-search.md +66 -66
  84. package/extensions/ai-ml/skills/fine-tuning-guide.md +74 -74
  85. package/extensions/ai-ml/skills/llm-architect.md +125 -125
  86. package/extensions/ai-ml/skills/llm-integration.md +64 -64
  87. package/extensions/ai-ml/skills/prompt-patterns.md +72 -72
  88. package/extensions/ai-ml/skills/rag-patterns.md +66 -66
  89. package/extensions/ai-ml/skills/web-extraction.md +114 -114
  90. package/extensions/analytics/PACK.md +92 -92
  91. package/extensions/analytics/skills/ab-testing.md +72 -72
  92. package/extensions/analytics/skills/dashboard-patterns.md +83 -83
  93. package/extensions/analytics/skills/data-validation.md +68 -68
  94. package/extensions/analytics/skills/funnel-analysis.md +81 -81
  95. package/extensions/analytics/skills/sql-patterns.md +57 -57
  96. package/extensions/analytics/skills/statistical-analysis.md +79 -79
  97. package/extensions/analytics/skills/tracking-setup.md +71 -71
  98. package/extensions/backend/PACK.md +104 -104
  99. package/extensions/backend/skills/api-patterns.md +84 -84
  100. package/extensions/backend/skills/async-pipeline.md +193 -193
  101. package/extensions/backend/skills/auth-patterns.md +97 -97
  102. package/extensions/backend/skills/background-jobs.md +133 -133
  103. package/extensions/backend/skills/caching-patterns.md +108 -108
  104. package/extensions/backend/skills/cli-generation.md +133 -133
  105. package/extensions/backend/skills/database-patterns.md +87 -87
  106. package/extensions/backend/skills/middleware-patterns.md +104 -104
  107. package/extensions/chrome-ext/PACK.md +93 -93
  108. package/extensions/chrome-ext/skills/cws-preflight.md +143 -143
  109. package/extensions/chrome-ext/skills/cws-publish.md +104 -104
  110. package/extensions/chrome-ext/skills/ext-ai-integration.md +251 -251
  111. package/extensions/chrome-ext/skills/ext-messaging.md +139 -139
  112. package/extensions/chrome-ext/skills/ext-storage.md +133 -133
  113. package/extensions/chrome-ext/skills/mv3-scaffold.md +164 -164
  114. package/extensions/content/PACK.md +96 -96
  115. package/extensions/content/skills/blog-patterns.md +88 -88
  116. package/extensions/content/skills/cms-integration.md +131 -131
  117. package/extensions/content/skills/content-scoring.md +107 -107
  118. package/extensions/content/skills/i18n.md +83 -83
  119. package/extensions/content/skills/mdx-authoring.md +137 -137
  120. package/extensions/content/skills/reference.md +1014 -1014
  121. package/extensions/content/skills/seo-patterns.md +67 -67
  122. package/extensions/content/skills/video-repurpose.md +153 -153
  123. package/extensions/devops/PACK.md +101 -101
  124. package/extensions/devops/skills/chaos-testing.md +67 -67
  125. package/extensions/devops/skills/ci-cd.md +75 -75
  126. package/extensions/devops/skills/docker.md +58 -58
  127. package/extensions/devops/skills/edge-serverless.md +163 -163
  128. package/extensions/devops/skills/infra-as-code.md +158 -158
  129. package/extensions/devops/skills/kubernetes.md +110 -110
  130. package/extensions/devops/skills/monitoring.md +57 -57
  131. package/extensions/devops/skills/server-setup.md +64 -64
  132. package/extensions/devops/skills/ssl-domain.md +42 -42
  133. package/extensions/ecommerce/PACK.md +116 -116
  134. package/extensions/ecommerce/skills/cart-system.md +79 -79
  135. package/extensions/ecommerce/skills/inventory-mgmt.md +102 -102
  136. package/extensions/ecommerce/skills/order-management.md +126 -126
  137. package/extensions/ecommerce/skills/payment-integration.md +472 -472
  138. package/extensions/ecommerce/skills/shopify-dev.md +69 -69
  139. package/extensions/ecommerce/skills/subscription-billing.md +93 -93
  140. package/extensions/ecommerce/skills/tax-compliance.md +117 -117
  141. package/extensions/gamedev/PACK.md +142 -142
  142. package/extensions/gamedev/skills/asset-pipeline.md +74 -74
  143. package/extensions/gamedev/skills/audio-system.md +129 -129
  144. package/extensions/gamedev/skills/camera-system.md +87 -87
  145. package/extensions/gamedev/skills/ecs.md +98 -98
  146. package/extensions/gamedev/skills/game-loops.md +72 -72
  147. package/extensions/gamedev/skills/input-system.md +199 -199
  148. package/extensions/gamedev/skills/multiplayer.md +180 -180
  149. package/extensions/gamedev/skills/particles.md +105 -105
  150. package/extensions/gamedev/skills/physics-engine.md +89 -89
  151. package/extensions/gamedev/skills/scene-management.md +146 -146
  152. package/extensions/gamedev/skills/threejs-patterns.md +90 -90
  153. package/extensions/gamedev/skills/webgl.md +71 -71
  154. package/extensions/mobile/PACK.md +106 -106
  155. package/extensions/mobile/skills/app-store-connect.md +152 -152
  156. package/extensions/mobile/skills/app-store-prep.md +66 -66
  157. package/extensions/mobile/skills/deep-linking.md +109 -109
  158. package/extensions/mobile/skills/flutter.md +60 -60
  159. package/extensions/mobile/skills/ios-build-pipeline.md +142 -142
  160. package/extensions/mobile/skills/native-bridge.md +66 -66
  161. package/extensions/mobile/skills/ota-updates.md +97 -97
  162. package/extensions/mobile/skills/push-notifications.md +111 -111
  163. package/extensions/mobile/skills/react-native.md +82 -82
  164. package/extensions/saas/PACK.md +116 -116
  165. package/extensions/saas/skills/billing-integration.md +200 -200
  166. package/extensions/saas/skills/feature-flags.md +130 -130
  167. package/extensions/saas/skills/multi-tenant.md +103 -103
  168. package/extensions/saas/skills/onboarding-flow.md +139 -139
  169. package/extensions/saas/skills/subscription-flow.md +95 -95
  170. package/extensions/saas/skills/team-management.md +144 -144
  171. package/extensions/security/PACK.md +99 -99
  172. package/extensions/security/skills/api-security.md +140 -140
  173. package/extensions/security/skills/compliance.md +68 -68
  174. package/extensions/security/skills/owasp-audit.md +64 -64
  175. package/extensions/security/skills/pentest-patterns.md +77 -77
  176. package/extensions/security/skills/secret-mgmt.md +65 -65
  177. package/extensions/security/skills/supply-chain.md +65 -65
  178. package/extensions/trading/PACK.md +80 -80
  179. package/extensions/trading/skills/chart-components.md +55 -55
  180. package/extensions/trading/skills/experiment-loop.md +125 -125
  181. package/extensions/trading/skills/fintech-patterns.md +47 -47
  182. package/extensions/trading/skills/indicator-library.md +58 -58
  183. package/extensions/trading/skills/quant-analysis.md +111 -111
  184. package/extensions/trading/skills/realtime-data.md +58 -58
  185. package/extensions/trading/skills/trade-logic.md +104 -104
  186. package/extensions/ui/PACK.md +130 -130
  187. package/extensions/ui/skills/a11y-audit.md +91 -91
  188. package/extensions/ui/skills/animation-patterns.md +127 -106
  189. package/extensions/ui/skills/component-patterns.md +100 -75
  190. package/extensions/ui/skills/design-decision.md +108 -108
  191. package/extensions/ui/skills/design-system.md +68 -68
  192. package/extensions/ui/skills/landing-patterns.md +155 -155
  193. package/extensions/ui/skills/palette-picker.md +173 -173
  194. package/extensions/ui/skills/react-health.md +90 -90
  195. package/extensions/ui/skills/type-system.md +125 -125
  196. package/extensions/ui/skills/web-vitals.md +153 -153
  197. package/extensions/zalo/PACK.md +145 -145
  198. package/extensions/zalo/skills/zalo-oa-mcp.md +317 -317
  199. package/extensions/zalo/skills/zalo-oa-messaging.md +429 -429
  200. package/extensions/zalo/skills/zalo-oa-setup.md +236 -236
  201. package/extensions/zalo/skills/zalo-oa-webhook.md +189 -189
  202. package/extensions/zalo/skills/zalo-personal-messaging.md +194 -194
  203. package/extensions/zalo/skills/zalo-personal-setup.md +153 -153
  204. package/extensions/zalo/skills/zalo-rate-guard.md +219 -219
  205. package/hooks/auto-format/index.cjs +48 -48
  206. package/hooks/context-watch/index.cjs +95 -68
  207. package/hooks/hooks.json +111 -111
  208. package/hooks/metrics-collector/index.cjs +86 -42
  209. package/hooks/post-session-reflect/index.cjs +189 -153
  210. package/hooks/pre-compact/index.cjs +95 -95
  211. package/hooks/run-hook.cmd +1 -1
  212. package/hooks/secrets-scan/index.cjs +100 -100
  213. package/hooks/session-start/index.cjs +71 -65
  214. package/hooks/typecheck/index.cjs +65 -65
  215. package/package.json +63 -63
  216. package/references/ui-pro-max-data/LICENSE-UI-PRO-MAX +21 -21
  217. package/references/ui-pro-max-data/charts.csv +26 -26
  218. package/references/ui-pro-max-data/colors.csv +161 -161
  219. package/references/ui-pro-max-data/styles.csv +68 -68
  220. package/references/ui-pro-max-data/typography.csv +74 -74
  221. package/references/ui-pro-max-data/ui-reasoning.csv +162 -162
  222. package/references/ui-pro-max-data/ux-guidelines.csv +99 -99
  223. package/skills/adversary/SKILL.md +283 -283
  224. package/skills/asset-creator/SKILL.md +157 -157
  225. package/skills/audit/SKILL.md +148 -2
  226. package/skills/autopsy/SKILL.md +335 -259
  227. package/skills/autopsy/references/repo-analysis-patterns.md +113 -0
  228. package/skills/ba/SKILL.md +72 -2
  229. package/skills/brainstorm/SKILL.md +342 -341
  230. package/skills/browser-pilot/SKILL.md +168 -168
  231. package/skills/constraint-check/SKILL.md +165 -165
  232. package/skills/context-engine/SKILL.md +404 -404
  233. package/skills/cook/SKILL.md +917 -834
  234. package/skills/cook/references/output-format.md +33 -0
  235. package/skills/db/SKILL.md +273 -272
  236. package/skills/debug/SKILL.md +465 -443
  237. package/skills/dependency-doctor/SKILL.md +265 -235
  238. package/skills/deploy/SKILL.md +274 -231
  239. package/skills/design/DESIGN-REFERENCE.md +365 -365
  240. package/skills/design/SKILL.md +589 -482
  241. package/skills/doc-processor/SKILL.md +254 -254
  242. package/skills/docs/SKILL.md +374 -373
  243. package/skills/docs-seeker/SKILL.md +177 -177
  244. package/skills/fix/SKILL.md +330 -308
  245. package/skills/git/SKILL.md +339 -339
  246. package/skills/graft/SKILL.md +352 -0
  247. package/skills/graft/references/challenge-framework.md +98 -0
  248. package/skills/graft/references/mode-decision.md +44 -0
  249. package/skills/hallucination-guard/SKILL.md +219 -219
  250. package/skills/incident/SKILL.md +254 -251
  251. package/skills/integrity-check/SKILL.md +169 -169
  252. package/skills/journal/SKILL.md +240 -238
  253. package/skills/launch/SKILL.md +344 -342
  254. package/skills/logic-guardian/SKILL.md +251 -251
  255. package/skills/marketing/SKILL.md +290 -245
  256. package/skills/mcp-builder/SKILL.md +425 -423
  257. package/skills/mcp-builder/references/auto-discovery-pattern.md +169 -0
  258. package/skills/neural-memory/SKILL.md +362 -362
  259. package/skills/onboard/SKILL.md +404 -403
  260. package/skills/perf/SKILL.md +346 -346
  261. package/skills/plan/SKILL.md +433 -370
  262. package/skills/plan/references/feature-map.md +84 -0
  263. package/skills/preflight/SKILL.md +415 -396
  264. package/skills/problem-solver/SKILL.md +380 -284
  265. package/skills/rescue/SKILL.md +474 -450
  266. package/skills/retro/SKILL.md +5 -1
  267. package/skills/review/SKILL.md +612 -535
  268. package/skills/review-intake/SKILL.md +249 -249
  269. package/skills/safeguard/SKILL.md +200 -200
  270. package/skills/sast/SKILL.md +190 -190
  271. package/skills/scaffold/SKILL.md +328 -286
  272. package/skills/scope-guard/SKILL.md +180 -162
  273. package/skills/scout/SKILL.md +263 -263
  274. package/skills/sentinel/SKILL.md +382 -353
  275. package/skills/sentinel-env/SKILL.md +254 -254
  276. package/skills/sequential-thinking/SKILL.md +234 -234
  277. package/skills/session-bridge/SKILL.md +543 -397
  278. package/skills/skill-forge/SKILL.md +581 -539
  279. package/skills/skill-router/{skill.md → SKILL.md} +30 -2
  280. package/skills/surgeon/SKILL.md +215 -215
  281. package/skills/team/SKILL.md +556 -514
  282. package/skills/test/SKILL.md +614 -587
  283. package/skills/trend-scout/SKILL.md +145 -145
  284. package/skills/verification/SKILL.md +326 -325
  285. package/skills/video-creator/SKILL.md +201 -201
  286. package/skills/watchdog/SKILL.md +168 -168
  287. package/skills/worktree/SKILL.md +140 -140
@@ -1,284 +1,380 @@
1
- ---
2
- name: problem-solver
3
- description: "Structured reasoning frameworks for complex problems. 14 analytical frameworks, 12 cognitive bias detectors, 10 decomposition methods, 8 mental models, and 6 communication patterns. McKinsey-grade problem solving for AI coding assistants."
4
- metadata:
5
- author: runedev
6
- version: "0.3.0"
7
- layer: L3
8
- model: sonnet
9
- group: reasoning
10
- tools: "Read, Glob, Grep"
11
- ---
12
-
13
- # problem-solver
14
-
15
- ## Purpose
16
-
17
- Structured reasoning utility for problems that resist straightforward analysis. Receives a problem statement, detects cognitive biases, selects the appropriate analytical framework, applies it step-by-step with evidence, and returns ranked solutions with a communication structure. Stateless — no memory between calls.
18
-
19
- Inspired by McKinsey problem-solving methodology and cognitive science research on decision-making errors.
20
-
21
- ## Calls (outbound)
22
-
23
- None — pure L3 reasoning utility.
24
-
25
- ## Called By (inbound)
26
-
27
- - `debug` (L2): complex bugs that resist standard debugging
28
- - `brainstorm` (L2): structured frameworks for creative exploration
29
- - `plan` (L2): complex architecture decisions with many trade-offs
30
- - `ba` (L2): requirement analysis when scope is ambiguous
31
-
32
- ## Execution
33
-
34
- ### Input
35
-
36
- ```
37
- problem: string — clear statement of the problem to analyze
38
- context: string — (optional) relevant background, constraints, symptoms observed
39
- goal: string — (optional) desired outcome or success criteria
40
- mode: string — (optional) "analyze" | "decide" | "decompose" | "communicate"
41
- ```
42
-
43
- ### Step 1 — Receive and Classify
44
-
45
- Read the `problem` and `context` inputs. Restate the problem in one sentence to confirm understanding.
46
-
47
- Classify the problem type:
48
-
49
- | Type | Signal Words | Primary Approach |
50
- |------|-------------|-----------------|
51
- | Root cause / diagnostic | "why", "broken", "failing", "declining" | 5 Whys, Fishbone, Root Cause |
52
- | Decision / choice | "should I", "choose", "compare", "vs" | Decision Frameworks (Step 3b) |
53
- | Decomposition | "break down", "understand", "structure" | Decomposition Methods (Step 3c) |
54
- | Creative / stuck | "stuck", "no ideas", "exhausted options" | SCAMPER, Collision-Zone, Inversion |
55
- | Architecture / scale | "design", "architecture", "will it scale" | First Principles, Scale Game |
56
-
57
- ### Step 2Bias Check (ALWAYS RUN)
58
-
59
- <HARD-GATE>
60
- NEVER skip bias detection. Every problem has biases — explicitly address them.
61
- This is the #1 value-add from structured reasoning. Without it, solutions are just dressed-up gut feelings.
62
- </HARD-GATE>
63
-
64
- Scan the problem statement and context for bias indicators. Check the top 6 most dangerous biases:
65
-
66
- | Bias | Detection Question | Debiasing Strategy |
67
- |------|-------------------|-------------------|
68
- | **Confirmation Bias** | Have we actively sought evidence AGAINST our preferred option? Are we explaining away contradictory data? | Assign devil's advocate. Explicitly seek disconfirming evidence. Require equal analysis of all options. |
69
- | **Anchoring Effect** | Would our evaluation change if we saw options in a different order? Is the first number/proposal dominating? | Generate evaluation criteria BEFORE seeing options. Score independently before group discussion. |
70
- | **Sunk Cost Fallacy** | If we were starting fresh today with zero prior investment, would we still choose this? Are we justifying by pointing to past spend? | Evaluate each option as if starting fresh (zero-based). Separate past investment from forward-looking decision. |
71
- | **Status Quo Bias** | Are we holding the current state to the SAME standard as alternatives? Would we actively choose the status quo if starting from scratch? | Explicitly include status quo as an option evaluated with same rigor. Calculate the cost of inaction. |
72
- | **Overconfidence** | What is our confidence level, and what is it based on? Have we been right about similar predictions before? | Use pre-mortem to stress-test. Track calibration. Seek outside perspectives. |
73
- | **Planning Fallacy** | Are our estimates based on best-case assumptions? Have similar projects in the past taken longer or cost more? | Use reference class forecasting compare to actual outcomes of similar past efforts rather than bottom-up estimates. |
74
-
75
- Additional biases to check when relevant:
76
- - **Framing Effect**: Would our preference change if framed as a gain vs. a loss?
77
- - **Availability Heuristic**: Are we basing estimates on vivid anecdotes rather than systematic data?
78
- - **Groupthink**: Has anyone expressed strong disagreement? Are we reaching consensus suspiciously fast?
79
- - **Loss Aversion**: Are we avoiding an option primarily because of what we might lose, rather than evaluating the full picture?
80
- - **Survivorship Bias**: Are we only looking at successful cases? Who tried this approach and failed?
81
- - **Recency Bias**: Are we extrapolating from the last few data points instead of looking at 5-10 years of data?
82
-
83
- **Output**: List 2-3 biases most likely to affect THIS specific problem, with their debiasing strategy. Weave these warnings into the analysis.
84
-
85
- ### Step 3a Select Analytical Framework
86
-
87
- Choose the framework based on what is unknown about the problem:
88
-
89
- | Situation | Framework |
90
- |-----------|-----------|
91
- | Root cause unknown symptoms clear | **5 Whys** |
92
- | Multiple potential causes from different domains | **Fishbone (Ishikawa)** |
93
- | Standard assumptions need challenging | **First Principles** |
94
- | Creative options needed for known problem | **SCAMPER** |
95
- | Must prioritize among known solutions | **Impact Matrix** |
96
- | Conventional approaches exhausted, need breakthrough | **Collision-Zone Thinking** |
97
- | Feeling forced into "the only way" | **Inversion Exercise** |
98
- | Same pattern appearing in 3+ places | **Meta-Pattern Recognition** |
99
- | Complexity spiraling, growing special cases | **Simplification Cascades** |
100
- | Unsure if approach survives production scale | **Scale Game** |
101
- | High-stakes irreversible decision — need to find blind spots | **Pre-Mortem** |
102
- | Need to determine how much analysis effort is warranted | **Reversibility Filter** |
103
- | Quantifiable outcomes with estimable probabilities | **Expected Value Calculation** |
104
- | Key assumptions uncertain, need to know what flips the decision | **Sensitivity Analysis** |
105
-
106
- State which framework was selected and why.
107
-
108
- ### Step 3b Decision Frameworks (when mode = "decide")
109
-
110
- When the problem is a decision/choice, use these specialized frameworks:
111
-
112
- **Reversibility Filter** (always apply first):
113
- - Is this a one-way door (irreversible) or two-way door (reversible)?
114
- - Two-way door decide quickly, set review date, iterate
115
- - One-way door invest in thorough analysis, use other frameworks
116
- - Proportional effort: analysis depth should match reversibility
117
-
118
- **Weighted Criteria Matrix** (multi-option comparison):
119
- 1. List all options
120
- 2. Define 3-5 evaluation criteria (max 5 more causes choice overload)
121
- 3. Assign weights (must sum to 100)
122
- 4. Score each option 1-5 on each criterion
123
- 5. Calculate weighted scores
124
- 6. Run sensitivity: which weight changes would flip the decision?
125
-
126
- **Pros-Cons-Fixes** (binary or few-option, quick):
127
- 1. List pros and cons for each option
128
- 2. For each con: can it be fixed, mitigated, or is it permanent?
129
- 3. Re-evaluate with fixable cons addressed
130
- 4. Decide based on remaining permanent trade-offs
131
-
132
- **Pre-Mortem** (high-stakes, irreversible):
133
- 1. Assume the decision has already failed catastrophically (12 months later)
134
- 2. List what went wrong (work backward)
135
- 3. Categorize by likelihood and severity
136
- 4. Develop mitigation plans for high-risk failures
137
-
138
- **Expected Value** (quantifiable outcomes):
139
- 1. List possible outcomes for each option
140
- 2. Estimate probability of each
141
- 3. Estimate value (monetary or utility) of each
142
- 4. Calculate EV = Σ(probability × value)
143
- 5. Choose highest EV adjusted for risk tolerance
144
-
145
- ### Step 3c Decomposition Methods (when mode = "decompose")
146
-
147
- When the problem needs structuring before analysis:
148
-
149
- | Method | When to Use | Pattern |
150
- |--------|------------|---------|
151
- | **Issue Tree** | Don't have a hypothesis yet, exploring | Root Question → Sub-questions (why/what) → deeper |
152
- | **Hypothesis Tree** | Have domain expertise, need speed | Hypothesis Conditions that must be true → Evidence needed |
153
- | **Profitability Tree** | Business performance problem | Profit → Revenue (Price × Volume) → Costs (Fixed + Variable) |
154
- | **Process Flow** | Operational/efficiency problem | Step 1 → Step 2 → ... → find bottleneck |
155
- | **Systems Map** | Complex with feedback loops | Variables causal links (+/-) reinforcing/balancing loops |
156
- | **Customer Journey** | User/customer problem | Awareness Consideration Purchase Experience Retention |
157
-
158
- All decompositions MUST pass the MECE test:
159
- - **ME** (Mutually Exclusive): branches don't overlap
160
- - **CE** (Collectively Exhaustive): branches cover all possibilities
161
-
162
- ### Step 4 — Apply Framework
163
-
164
- Execute the selected framework with discipline. For each framework, follow the steps defined in Step 3a/3b/3c.
165
-
166
- At each step, apply the bias debiasing strategies identified in Step 2.
167
-
168
- ### Step 5 Apply Mental Models
169
-
170
- Cross-check the framework output against relevant mental models:
171
-
172
- | Model | Core Question | When It Helps |
173
- |-------|--------------|---------------|
174
- | **Second-Order Thinking** | "And then what?" — consequences of consequences | Decisions with delayed effects |
175
- | **Bayesian Updating** | How should we update our beliefs given this new evidence? | When new data arrives during analysis |
176
- | **Margin of Safety** | What buffer do we need for things going wrong? | Planning timelines, budgets, capacity |
177
- | **Opportunity Cost** | What's the best alternative we're giving up? | Resource allocation, project prioritization |
178
- | **Occam's Razor** | Among competing explanations, prefer the simplest | Multiple possible root causes |
179
- | **Leverage Points** | Where does small effort produce large effect? | System redesign, process improvement |
180
- | **Hanlon's Razor** | Never attribute to malice what can be explained by incompetence or misaligned incentives | Organizational problems, team conflicts |
181
- | **Regression to the Mean** | Is this extreme result likely to revert to average? | After exceptional performance (good or bad) |
182
-
183
- Apply 1-2 most relevant models. State which and why.
184
-
185
- ### Step 6 Generate Solutions
186
-
187
- From the framework output, derive 2-3 actionable solutions. For each:
188
- - Describe what to do concretely
189
- - Estimate impact: high / medium / low
190
- - Estimate effort: high / medium / low
191
- - State any preconditions or risks
192
- - Note which biases might affect evaluation of this solution
193
-
194
- Rank solutions by impact/effort ratio.
195
-
196
- ### Step 7 Select Communication Structure
197
-
198
- Choose how to present the analysis based on audience:
199
-
200
- | Audience | Pattern | Format |
201
- |----------|---------|--------|
202
- | Executive / senior | **Pyramid Principle** | Lead with recommendation → support with 3 arguments → evidence |
203
- | Mixed / unfamiliar | **SCR** | Situation (context) → Complication (tension) → Resolution (recommendation) |
204
- | Technical / peers | **Day-1 Answer** | State best hypothesis → list evidence for/against → confidence level |
205
- | Quick update | **BLUF** | Bottom Line Up Front → background → details → action required |
206
-
207
- Structure the output report using the selected pattern.
208
-
209
- ## Constraints
210
-
211
- - MUST run bias check (Step 2) for EVERY problem the bias layer IS the differentiator
212
- - Never skip the framework the structure is the value
213
- - Use Sonnet, not Haikureasoning depth matters
214
- - If problem is underspecified, state assumptions explicitly before proceeding
215
- - Do not produce more than 3 recommended solutions — prioritize quality over quantity
216
- - Max 5 evaluation criteria in Weighted Matrix — more causes choice overload
217
- - Decompositions MUST pass MECE test — no overlapping or missing branches
218
-
219
- ## Output Format
220
-
221
- ```
222
- ## Analysis: [Problem Statement]
223
- - **Type**: [root cause / decision / decomposition / creative / architecture]
224
- - **Framework**: [chosen framework and reason]
225
- - **Confidence**: high | medium | low
226
-
227
- ### Bias Warnings
228
- - ⚠️ [Bias 1]: [how it might affect this analysis] → [debiasing action taken]
229
- - ⚠️ [Bias 2]: [how it might affect this analysis] → [debiasing action taken]
230
-
231
- ### Reasoning Chain
232
- 1. [step with evidence or reasoning]
233
- 2. [step with evidence or reasoning]
234
- 3. [step with evidence or reasoning]
235
- ...
236
-
237
- ### Mental Model Cross-Check
238
- - [Model applied]: [insight gained]
239
-
240
- ### Root Cause / Core Finding
241
- [what the framework reveals as the fundamental issue or conclusion]
242
-
243
- ### Recommended Solutions (ranked)
244
- 1. **[Solution Name]** — Impact: high/medium/low | Effort: high/medium/low
245
- [concrete description of what to do]
246
- ⚠️ Bias risk: [which bias might make us over/under-value this]
247
- 2. **[Solution Name]** Impact: high/medium/low | Effort: high/medium/low
248
- [concrete description of what to do]
249
- 3. **[Solution Name]** Impact: high/medium/low | Effort: high/medium/low
250
- [concrete description of what to do]
251
-
252
- ### Next Action
253
- [single most important immediate step]
254
- ```
255
-
256
- ## Sharp Edges
257
-
258
- | Failure Mode | Severity | Mitigation |
259
- |---|---|---|
260
- | Skipping bias check and jumping to framework | CRITICAL | HARD-GATE: Step 2 is mandatory — biases ARE the value-add |
261
- | Skipping the framework and jumping to solutions | CRITICAL | Solutions without structured analysis are guesses |
262
- | Proceeding with underspecified problem | HIGH | Step 1: restate in one sentence — if ambiguous, state interpretation |
263
- | Producing more than 3 solutions | MEDIUM | Max 3 ranked prioritize quality over quantity |
264
- | Framework mismatch (5 Whys for a creative problem) | MEDIUM | Use selection table match framework to "what is unknown" |
265
- | Weighted Matrix with > 5 criteria | MEDIUM | Choice overload max 5 criteria, focus on what matters |
266
- | Pre-Mortem without debiasing strategies | MEDIUM | Pre-Mortem reveals risks MUST include mitigation plans |
267
- | Decomposition failing MECE test | HIGH | Every branch must be ME (no overlap) and CE (no gaps) |
268
- | Ignoring second-order effects in recommendations | MEDIUM | Apply Second-Order Thinking: "and then what?" |
269
- | Presenting analysis without communication structure | LOW | Step 7: match output pattern to audience |
270
-
271
- ## Done When
272
-
273
- - Problem restated in one sentence (understanding confirmed)
274
- - Bias check completed — 2-3 biases identified with debiasing strategies
275
- - Framework selected with explicit reason stated
276
- - Framework applied step-by-step with evidence at each step
277
- - Mental models cross-checked (1-2 relevant models applied)
278
- - 2-3 solutions ranked by impact/effort ratio with bias risk noted
279
- - Next Action identified (single most important immediate step)
280
- - Analysis Report emitted with communication structure
281
-
282
- ## Cost Profile
283
-
284
- ~500-1500 tokens input, ~800-1500 tokens output. Sonnet for reasoning quality. Opus recommended for high-stakes irreversible decisions.
1
+ ---
2
+ name: problem-solver
3
+ description: "Structured reasoning frameworks for complex problems. 19 analytical frameworks, 12 cognitive bias detectors, 10 decomposition methods, 10 mental models, Cynefin domain classification, ethical dimension check, and 6 communication patterns. McKinsey-grade problem solving for AI coding assistants."
4
+ metadata:
5
+ author: runedev
6
+ version: "0.4.0"
7
+ layer: L3
8
+ model: sonnet
9
+ group: reasoning
10
+ tools: "Read, Glob, Grep"
11
+ ---
12
+
13
+ # problem-solver
14
+
15
+ ## Purpose
16
+
17
+ Structured reasoning utility for problems that resist straightforward analysis. Receives a problem statement, detects cognitive biases, selects the appropriate analytical framework, applies it step-by-step with evidence, and returns ranked solutions with a communication structure. Stateless — no memory between calls.
18
+
19
+ Inspired by McKinsey problem-solving methodology and cognitive science research on decision-making errors.
20
+
21
+ ## Calls (outbound)
22
+
23
+ None — pure L3 reasoning utility.
24
+
25
+ ## Called By (inbound)
26
+
27
+ - `debug` (L2): complex bugs that resist standard debugging
28
+ - `brainstorm` (L2): structured frameworks for creative exploration
29
+ - `plan` (L2): complex architecture decisions with many trade-offs
30
+ - `ba` (L2): requirement analysis when scope is ambiguous
31
+
32
+ ## Execution
33
+
34
+ ### Input
35
+
36
+ ```
37
+ problem: string — clear statement of the problem to analyze
38
+ context: string — (optional) relevant background, constraints, symptoms observed
39
+ goal: string — (optional) desired outcome or success criteria
40
+ mode: string — (optional) "analyze" | "decide" | "decompose" | "communicate"
41
+ ```
42
+
43
+ ### Step 1 — Receive and Classify
44
+
45
+ Read the `problem` and `context` inputs. Restate the problem in one sentence to confirm understanding.
46
+
47
+ Classify the problem type:
48
+
49
+ | Type | Signal Words | Primary Approach |
50
+ |------|-------------|-----------------|
51
+ | Root cause / diagnostic | "why", "broken", "failing", "declining" | 5 Whys, Fishbone, Root Cause |
52
+ | Decision / choice | "should I", "choose", "compare", "vs" | Decision Frameworks (Step 3b) |
53
+ | Decomposition | "break down", "understand", "structure" | Decomposition Methods (Step 3c) |
54
+ | Creative / stuck | "stuck", "no ideas", "exhausted options" | SCAMPER, Collision-Zone, Inversion |
55
+ | Architecture / scale | "design", "architecture", "will it scale" | First Principles, Scale Game |
56
+
57
+ ### Step 1.5Domain Classification (Cynefin)
58
+
59
+ Before selecting a framework, classify the problem's complexity domain. This determines HOW MUCH analysis is warranted and WHICH class of frameworks applies.
60
+
61
+ | Domain | Signal | Framework Class | Analysis Depth |
62
+ |--------|--------|----------------|----------------|
63
+ | **Clear** (obvious) | Best practice exists, cause-effect obvious, "just do X" | Direct action — no framework needed | Minimal — act immediately |
64
+ | **Complicated** (expert analysis) | Cause-effect discoverable through analysis, multiple right answers exist | Analytical frameworks (5 Whys, Fishbone, SWOT, Weighted Matrix) | Moderate — structured analysis |
65
+ | **Complex** (emergent) | Cause-effect only visible in retrospect, no right answer — only better probes | Probe-sense-respond (Pre-Mortem, Systems Map, Sensitivity Analysis, PESTLE) | Deep — experiment and iterate |
66
+ | **Chaotic** (crisis) | No cause-effect, need to stabilize first | Act-sense-respond triage, then analyze | Immediate — stabilize before analyzing |
67
+ | **Confused** (don't know which domain) | Can't classify → decompose until sub-problems land in a known domain | Decomposition first (Issue Tree, MECE) → re-classify each branch | Meta — decompose then classify |
68
+
69
+ **Output**: State the domain and justify in one sentence. If Confused, decompose before proceeding.
70
+
71
+ **Why this matters**: Applying Complicated-domain tools (deep analysis) to a Clear problem wastes effort. Applying Clear-domain tools ("just do X") to a Complex problem creates false confidence. Match the tool to the terrain.
72
+
73
+ ### Step 2Bias Check (ALWAYS RUN)
74
+
75
+ <HARD-GATE>
76
+ NEVER skip bias detection. Every problem has biases explicitly address them.
77
+ This is the #1 value-add from structured reasoning. Without it, solutions are just dressed-up gut feelings.
78
+ </HARD-GATE>
79
+
80
+ Scan the problem statement and context for bias indicators. Check the top 6 most dangerous biases:
81
+
82
+ | Bias | Detection Question | Debiasing Strategy |
83
+ |------|-------------------|-------------------|
84
+ | **Confirmation Bias** | Have we actively sought evidence AGAINST our preferred option? Are we explaining away contradictory data? | Assign devil's advocate. Explicitly seek disconfirming evidence. Require equal analysis of all options. |
85
+ | **Anchoring Effect** | Would our evaluation change if we saw options in a different order? Is the first number/proposal dominating? | Generate evaluation criteria BEFORE seeing options. Score independently before group discussion. |
86
+ | **Sunk Cost Fallacy** | If we were starting fresh today with zero prior investment, would we still choose this? Are we justifying by pointing to past spend? | Evaluate each option as if starting fresh (zero-based). Separate past investment from forward-looking decision. |
87
+ | **Status Quo Bias** | Are we holding the current state to the SAME standard as alternatives? Would we actively choose the status quo if starting from scratch? | Explicitly include status quo as an option evaluated with same rigor. Calculate the cost of inaction. |
88
+ | **Overconfidence** | What is our confidence level, and what is it based on? Have we been right about similar predictions before? | Use pre-mortem to stress-test. Track calibration. Seek outside perspectives. |
89
+ | **Planning Fallacy** | Are our estimates based on best-case assumptions? Have similar projects in the past taken longer or cost more? | Use reference class forecasting — compare to actual outcomes of similar past efforts rather than bottom-up estimates. |
90
+
91
+ Additional biases to check when relevant:
92
+ - **Framing Effect**: Would our preference change if framed as a gain vs. a loss?
93
+ - **Availability Heuristic**: Are we basing estimates on vivid anecdotes rather than systematic data?
94
+ - **Groupthink**: Has anyone expressed strong disagreement? Are we reaching consensus suspiciously fast?
95
+ - **Loss Aversion**: Are we avoiding an option primarily because of what we might lose, rather than evaluating the full picture?
96
+ - **Survivorship Bias**: Are we only looking at successful cases? Who tried this approach and failed?
97
+ - **Recency Bias**: Are we extrapolating from the last few data points instead of looking at 5-10 years of data?
98
+
99
+ **Steel Manning** (apply when evaluating competing options):
100
+ Before dismissing any option, construct the STRONGEST possible version of the argument for it. If you can't articulate why a smart, informed person would choose it, you haven't understood it yet. Steel Manning prevents strawman dismissals and forces genuine evaluation.
101
+
102
+ **Output**: List 2-3 biases most likely to affect THIS specific problem, with their debiasing strategy. If comparing options, include a steel-manned case for the option you're least inclined toward. Weave these warnings into the analysis.
103
+
104
+ ### Step 3a Select Analytical Framework
105
+
106
+ Choose the framework based on what is unknown about the problem:
107
+
108
+ | Situation | Framework |
109
+ |-----------|-----------|
110
+ | Root cause unknown symptoms clear | **5 Whys** |
111
+ | Multiple potential causes from different domains | **Fishbone (Ishikawa)** |
112
+ | Standard assumptions need challenging | **First Principles** |
113
+ | Creative options needed for known problem | **SCAMPER** |
114
+ | Must prioritize among known solutions | **Impact Matrix** |
115
+ | Conventional approaches exhausted, need breakthrough | **Collision-Zone Thinking** |
116
+ | Feeling forced into "the only way" | **Inversion Exercise** |
117
+ | Same pattern appearing in 3+ places | **Meta-Pattern Recognition** |
118
+ | Complexity spiraling, growing special cases | **Simplification Cascades** |
119
+ | Unsure if approach survives production scale | **Scale Game** |
120
+ | High-stakes irreversible decision need to find blind spots | **Pre-Mortem** |
121
+ | Need to determine how much analysis effort is warranted | **Reversibility Filter** |
122
+ | Quantifiable outcomes with estimable probabilities | **Expected Value Calculation** |
123
+ | Key assumptions uncertain, need to know what flips the decision | **Sensitivity Analysis** |
124
+ | Need holistic internal + external assessment of a project/product/strategy | **SWOT Analysis** |
125
+ | Decision depends on macro-environment factors beyond your control | **PESTLE Analysis** |
126
+ | Competitive landscape unclear, need to assess market position | **Porter's Five Forces** |
127
+ | Need a rough estimate with very little data | **Fermi Estimation** |
128
+ | Problem involves ethical trade-offs or stakeholder harm | **Ethical Reasoning** (→ Step 5.5) |
129
+
130
+ State which framework was selected and why.
131
+
132
+ **SWOT Analysis** (holistic assessment):
133
+ 1. **Strengths**: Internal advantages what do we do well? What assets do we have?
134
+ 2. **Weaknesses**: Internal disadvantages where are we vulnerable? What do we lack?
135
+ 3. **Opportunities**: External factors we could exploit — trends, market gaps, timing
136
+ 4. **Threats**: External factors that could harm us — competitors, regulation, tech shifts
137
+ 5. Cross-reference: How can Strengths exploit Opportunities? How do Weaknesses amplify Threats?
138
+ 6. Prioritize: Which quadrant demands immediate action?
139
+
140
+ **PESTLE Analysis** (macro-environment scan):
141
+ When the problem is influenced by forces beyond the project/org:
142
+
143
+ | Factor | Key Questions |
144
+ |--------|-------------|
145
+ | **Political** | Government policy, regulation changes, political stability, trade restrictions? |
146
+ | **Economic** | Market conditions, inflation, exchange rates, funding climate, customer spending? |
147
+ | **Social** | Demographics, cultural trends, user behavior shifts, workforce expectations? |
148
+ | **Technological** | New tech, disruption risk, automation, platform shifts, AI impact? |
149
+ | **Legal** | Compliance requirements, IP, data privacy (GDPR/CCPA), licensing, liability? |
150
+ | **Environmental** | Sustainability expectations, carbon footprint, resource scarcity, ESG pressure? |
151
+
152
+ For each factor: rate impact (high/medium/low) and timeline (imminent/near-term/long-term). Focus analysis on high-impact factors only.
153
+
154
+ **Porter's Five Forces** (competitive position):
155
+ 1. **Threat of New Entrants**: How easy is it for competitors to enter? (barriers: capital, tech, brand, network effects)
156
+ 2. **Bargaining Power of Suppliers**: How much leverage do your dependencies have? (few suppliers = high power)
157
+ 3. **Bargaining Power of Buyers**: Can customers easily switch? (low switching cost = high power)
158
+ 4. **Threat of Substitutes**: What alternatives exist outside your direct market?
159
+ 5. **Competitive Rivalry**: How intense is competition? (many similar players = high rivalry)
160
+ Rate each force: strong / moderate / weak. Strongest forces dictate strategy.
161
+
162
+ **Fermi Estimation** (order-of-magnitude reasoning):
163
+ When data is scarce but a rough estimate is needed:
164
+ 1. Break the unknown into estimable sub-components
165
+ 2. Estimate each component using common knowledge or reference classes
166
+ 3. Multiply/combine to get the overall estimate
167
+ 4. Sanity-check: does the result pass the smell test? Off by 10x?
168
+ 5. State confidence range: "between X and Y, best estimate Z"
169
+ Goal: be within an order of magnitude (10x), not precise. Useful for sizing markets, estimating effort, or validating claims.
170
+
171
+ ### Step 3b — Decision Frameworks (when mode = "decide")
172
+
173
+ When the problem is a decision/choice, use these specialized frameworks:
174
+
175
+ **Reversibility Filter** (always apply first):
176
+ - Is this a one-way door (irreversible) or two-way door (reversible)?
177
+ - Two-way door decide quickly, set review date, iterate
178
+ - One-way door invest in thorough analysis, use other frameworks
179
+ - Proportional effort: analysis depth should match reversibility
180
+
181
+ **Weighted Criteria Matrix** (multi-option comparison):
182
+ 1. List all options
183
+ 2. Define 3-5 evaluation criteria (max 5 more causes choice overload)
184
+ 3. Assign weights (must sum to 100)
185
+ 4. Score each option 1-5 on each criterion
186
+ 5. Calculate weighted scores
187
+ 6. Run sensitivity: which weight changes would flip the decision?
188
+
189
+ **Pros-Cons-Fixes** (binary or few-option, quick):
190
+ 1. List pros and cons for each option
191
+ 2. For each con: can it be fixed, mitigated, or is it permanent?
192
+ 3. Re-evaluate with fixable cons addressed
193
+ 4. Decide based on remaining permanent trade-offs
194
+
195
+ **Pre-Mortem** (high-stakes, irreversible):
196
+ 1. Assume the decision has already failed catastrophically (12 months later)
197
+ 2. List what went wrong (work backward)
198
+ 3. Categorize by likelihood and severity
199
+ 4. Develop mitigation plans for high-risk failures
200
+
201
+ **Expected Value** (quantifiable outcomes):
202
+ 1. List possible outcomes for each option
203
+ 2. Estimate probability of each
204
+ 3. Estimate value (monetary or utility) of each
205
+ 4. Calculate EV = Σ(probability × value)
206
+ 5. Choose highest EV adjusted for risk tolerance
207
+
208
+ **Regret Minimization** (life-scale or career-scale decisions):
209
+ 1. Project yourself to age 80 (or 10 years from now)
210
+ 2. Ask: "Will I regret NOT trying this?" — regret of inaction vs. regret of action
211
+ 3. Regret of inaction (missed opportunity) typically outweighs regret of action (failed attempt)
212
+ 4. Use when: the decision is personally significant, emotionally charged, or involves a window of opportunity that won't return
213
+ 5. Not suitable for: purely analytical/technical decisions use Expected Value instead
214
+
215
+ ### Step 3c Decomposition Methods (when mode = "decompose")
216
+
217
+ When the problem needs structuring before analysis:
218
+
219
+ | Method | When to Use | Pattern |
220
+ |--------|------------|---------|
221
+ | **Issue Tree** | Don't have a hypothesis yet, exploring | Root Question → Sub-questions (why/what) → deeper |
222
+ | **Hypothesis Tree** | Have domain expertise, need speed | Hypothesis → Conditions that must be true → Evidence needed |
223
+ | **Profitability Tree** | Business performance problem | Profit Revenue (Price × Volume) → Costs (Fixed + Variable) |
224
+ | **Process Flow** | Operational/efficiency problem | Step 1 → Step 2 → ... → find bottleneck |
225
+ | **Systems Map** | Complex with feedback loops | Variables → causal links (+/-) → reinforcing/balancing loops |
226
+ | **Customer Journey** | User/customer problem | Awareness → Consideration → Purchase → Experience → Retention |
227
+
228
+ All decompositions MUST pass the MECE test:
229
+ - **ME** (Mutually Exclusive): branches don't overlap
230
+ - **CE** (Collectively Exhaustive): branches cover all possibilities
231
+
232
+ ### Step 4 Apply Framework
233
+
234
+ Execute the selected framework with discipline. For each framework, follow the steps defined in Step 3a/3b/3c.
235
+
236
+ At each step, apply the bias debiasing strategies identified in Step 2.
237
+
238
+ ### Step 5 Apply Mental Models
239
+
240
+ Cross-check the framework output against relevant mental models:
241
+
242
+ | Model | Core Question | When It Helps |
243
+ |-------|--------------|---------------|
244
+ | **Second-Order Thinking** | "And then what?" consequences of consequences | Decisions with delayed effects |
245
+ | **Bayesian Updating** | How should we update our beliefs given this new evidence? | When new data arrives during analysis |
246
+ | **Margin of Safety** | What buffer do we need for things going wrong? | Planning timelines, budgets, capacity |
247
+ | **Opportunity Cost** | What's the best alternative we're giving up? | Resource allocation, project prioritization |
248
+ | **Occam's Razor** | Among competing explanations, prefer the simplest | Multiple possible root causes |
249
+ | **Leverage Points** | Where does small effort produce large effect? | System redesign, process improvement |
250
+ | **Hanlon's Razor** | Never attribute to malice what can be explained by incompetence or misaligned incentives | Organizational problems, team conflicts |
251
+ | **Regression to the Mean** | Is this extreme result likely to revert to average? | After exceptional performance (good or bad) |
252
+ | **Dialectical Thinking** | Thesis + Antithesis → can we synthesize a higher-order solution? | Two opposing valid positions, binary choice feels forced |
253
+ | **Fermi Estimation** | Can we get a rough order-of-magnitude estimate to sanity-check? | Claims, estimates, or projections that feel off |
254
+
255
+ Apply 1-2 most relevant models. State which and why.
256
+
257
+ ### Step 5.5 — Ethical Dimension Check (when applicable)
258
+
259
+ Run this check when the problem involves: user data, automation replacing human judgment, resource allocation affecting people, public-facing decisions, or stakeholder trade-offs.
260
+
261
+ | Lens | Core Question |
262
+ |------|--------------|
263
+ | **Harm** | Who could be harmed by each option? How severe? How reversible? |
264
+ | **Fairness** | Does this option disadvantage any group disproportionately? |
265
+ | **Transparency** | Would we be comfortable if our reasoning was public? |
266
+ | **Autonomy** | Does this preserve user choice, or does it decide for them? |
267
+ | **Long-term trust** | Will this erode trust with users/team/community over time? |
268
+
269
+ This is NOT a gate it produces warnings, not blocks. If an ethical concern is identified, note it alongside the solution in Step 6 so the decision-maker can weigh it.
270
+
271
+ Skip this step for purely technical problems with no stakeholder impact (e.g., "which sorting algorithm").
272
+
273
+ ### Step 6 Generate Solutions
274
+
275
+ From the framework output, derive 2-3 actionable solutions. For each:
276
+ - Describe what to do concretely
277
+ - Estimate impact: high / medium / low
278
+ - Estimate effort: high / medium / low
279
+ - State any preconditions or risks
280
+ - Note which biases might affect evaluation of this solution
281
+
282
+ Rank solutions by impact/effort ratio.
283
+
284
+ ### Step 7 Select Communication Structure
285
+
286
+ Choose how to present the analysis based on audience:
287
+
288
+ | Audience | Pattern | Format |
289
+ |----------|---------|--------|
290
+ | Executive / senior | **Pyramid Principle** | Lead with recommendation → support with 3 arguments → evidence |
291
+ | Mixed / unfamiliar | **SCR** | Situation (context) → Complication (tension) → Resolution (recommendation) |
292
+ | Technical / peers | **Day-1 Answer** | State best hypothesis → list evidence for/against → confidence level |
293
+ | Quick update | **BLUF** | Bottom Line Up Front → background → details → action required |
294
+
295
+ Structure the output report using the selected pattern.
296
+
297
+ ## Constraints
298
+
299
+ - MUST run domain classification (Step 1.5) — match analysis depth to problem complexity
300
+ - MUST run bias check (Step 2) for EVERY problem — the bias layer IS the differentiator
301
+ - MUST steel-man the least-favored option when comparing alternatives
302
+ - Never skip the framework — the structure is the value
303
+ - Use Sonnet, not Haiku — reasoning depth matters
304
+ - If problem is underspecified, state assumptions explicitly before proceeding
305
+ - Do not produce more than 3 recommended solutions — prioritize quality over quantity
306
+ - Max 5 evaluation criteria in Weighted Matrix — more causes choice overload
307
+ - Decompositions MUST pass MECE test — no overlapping or missing branches
308
+
309
+ ## Output Format
310
+
311
+ ```
312
+ ## Analysis: [Problem Statement]
313
+ - **Type**: [root cause / decision / decomposition / creative / architecture]
314
+ - **Domain**: [Clear / Complicated / Complex / Chaotic / Confused] — [one-line justification]
315
+ - **Framework**: [chosen framework and reason]
316
+ - **Confidence**: high | medium | low
317
+
318
+ ### Bias Warnings
319
+ - ⚠️ [Bias 1]: [how it might affect this analysis] → [debiasing action taken]
320
+ - ⚠️ [Bias 2]: [how it might affect this analysis] → [debiasing action taken]
321
+
322
+ ### Reasoning Chain
323
+ 1. [step with evidence or reasoning]
324
+ 2. [step with evidence or reasoning]
325
+ 3. [step with evidence or reasoning]
326
+ ...
327
+
328
+ ### Mental Model Cross-Check
329
+ - [Model applied]: [insight gained]
330
+
331
+ ### Root Cause / Core Finding
332
+ [what the framework reveals as the fundamental issue or conclusion]
333
+
334
+ ### Recommended Solutions (ranked)
335
+ 1. **[Solution Name]** — Impact: high/medium/low | Effort: high/medium/low
336
+ [concrete description of what to do]
337
+ ⚠️ Bias risk: [which bias might make us over/under-value this]
338
+ 2. **[Solution Name]** — Impact: high/medium/low | Effort: high/medium/low
339
+ [concrete description of what to do]
340
+ 3. **[Solution Name]** — Impact: high/medium/low | Effort: high/medium/low
341
+ [concrete description of what to do]
342
+
343
+ ### Next Action
344
+ [single most important immediate step]
345
+ ```
346
+
347
+ ## Sharp Edges
348
+
349
+ | Failure Mode | Severity | Mitigation |
350
+ |---|---|---|
351
+ | Skipping bias check and jumping to framework | CRITICAL | HARD-GATE: Step 2 is mandatory — biases ARE the value-add |
352
+ | Skipping the framework and jumping to solutions | CRITICAL | Solutions without structured analysis are guesses |
353
+ | Proceeding with underspecified problem | HIGH | Step 1: restate in one sentence — if ambiguous, state interpretation |
354
+ | Producing more than 3 solutions | MEDIUM | Max 3 ranked — prioritize quality over quantity |
355
+ | Framework mismatch (5 Whys for a creative problem) | MEDIUM | Use selection table — match framework to "what is unknown" |
356
+ | Weighted Matrix with > 5 criteria | MEDIUM | Choice overload — max 5 criteria, focus on what matters |
357
+ | Pre-Mortem without debiasing strategies | MEDIUM | Pre-Mortem reveals risks — MUST include mitigation plans |
358
+ | Decomposition failing MECE test | HIGH | Every branch must be ME (no overlap) and CE (no gaps) |
359
+ | Ignoring second-order effects in recommendations | MEDIUM | Apply Second-Order Thinking: "and then what?" |
360
+ | Presenting analysis without communication structure | LOW | Step 7: match output pattern to audience |
361
+ | Using Complicated-domain tools on a Complex problem | HIGH | Step 1.5 Cynefin: Complex → probe-sense-respond, not analyze-plan-execute |
362
+ | Strawmanning the least-favored option | MEDIUM | Steel Manning: build strongest case for option you dislike before dismissing |
363
+ | Running full PESTLE on a purely technical problem | LOW | PESTLE is for macro-environment — skip for algorithm/implementation choices |
364
+ | Skipping ethics check on user-facing decisions | MEDIUM | Step 5.5: lightweight check — warnings not gates, but don't skip for stakeholder-affecting decisions |
365
+
366
+ ## Done When
367
+
368
+ - Problem restated in one sentence (understanding confirmed)
369
+ - Domain classified (Cynefin: Clear / Complicated / Complex / Chaotic / Confused)
370
+ - Bias check completed — 2-3 biases identified with debiasing strategies
371
+ - Framework selected with explicit reason stated
372
+ - Framework applied step-by-step with evidence at each step
373
+ - Mental models cross-checked (1-2 relevant models applied)
374
+ - 2-3 solutions ranked by impact/effort ratio with bias risk noted
375
+ - Next Action identified (single most important immediate step)
376
+ - Analysis Report emitted with communication structure
377
+
378
+ ## Cost Profile
379
+
380
+ ~500-1500 tokens input, ~800-1500 tokens output. Sonnet for reasoning quality. Opus recommended for high-stakes irreversible decisions.