minimal-vibe-coding-kit 0.4.1 → 0.4.2
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.
- package/.agents/skills/agentshield-security-review/scripts/agentshield_repo_probe.py +28 -3
- package/.agents/skills/prompt-sharpener/SKILL.md +54 -0
- package/.agents/skills/vibekit-init/SKILL.md +2 -2
- package/.claude/settings.json +10 -3
- package/.claude/skills/agentshield-security-review/scripts/agentshield_repo_probe.py +28 -3
- package/.claude/skills/prompt-sharpener/SKILL.md +54 -0
- package/.claude/skills/vibekit-init/SKILL.md +2 -2
- package/.codex/rules/vibekit.rules +77 -0
- package/.codex-plugin/plugin.json +1 -1
- package/.cursor/cli.json +18 -0
- package/.cursor/settings.json +15 -8
- package/.cursor/skills/prompt-sharpener/SKILL.md +54 -0
- package/.grok/README.md +13 -0
- package/.grok/config.example.toml +13 -0
- package/.grok/config.toml +29 -0
- package/.grok/rules/safe-delete.md +11 -0
- package/.grok/rules/security.md +5 -0
- package/.grok/rules/vibe-core.md +8 -0
- package/.grok/skills/agentshield-security-review/SKILL.md +75 -0
- package/.grok/skills/agentshield-security-review/agents/openai.yaml +5 -0
- package/.grok/skills/agentshield-security-review/references/native-install.md +97 -0
- package/.grok/skills/agentshield-security-review/references/report-template.md +54 -0
- package/.grok/skills/agentshield-security-review/references/review-checklist.md +45 -0
- package/.grok/skills/agentshield-security-review/scripts/agentshield_repo_probe.py +135 -0
- package/.grok/skills/autoresearch-coding/README.md +15 -0
- package/.grok/skills/autoresearch-coding/SKILL.md +101 -0
- package/.grok/skills/autoresearch-coding/references/experiment-contract.md +13 -0
- package/.grok/skills/autoresearch-coding/references/metric-extraction.md +8 -0
- package/.grok/skills/autoresearch-coding/references/result-ledger.md +15 -0
- package/.grok/skills/autoresearch-coding/scripts/log_result.py +24 -0
- package/.grok/skills/autoresearch-coding/scripts/run_logged.py +30 -0
- package/.grok/skills/clearthought/SKILL.md +100 -0
- package/.grok/skills/clearthought/examples/decision-framework.md +441 -0
- package/.grok/skills/clearthought/examples/metagame-examples.md +536 -0
- package/.grok/skills/clearthought/examples/sequential-thinking.md +380 -0
- package/.grok/skills/clearthought/references/output-schemas.md +494 -0
- package/.grok/skills/clearthought/references/parameter-reference.md +482 -0
- package/.grok/skills/coding-level/SKILL.md +34 -0
- package/.grok/skills/coding-level/references/level-0.md +131 -0
- package/.grok/skills/coding-level/references/level-1.md +118 -0
- package/.grok/skills/coding-level/references/level-2.md +140 -0
- package/.grok/skills/coding-level/references/level-3.md +142 -0
- package/.grok/skills/coding-level/references/level-4.md +152 -0
- package/.grok/skills/coding-level/references/level-5.md +84 -0
- package/.grok/skills/daily-workflow-curator/SKILL.md +52 -0
- package/.grok/skills/memento/SKILL.md +36 -0
- package/.grok/skills/parallel-analysis/SKILL.md +160 -0
- package/.grok/skills/path-sensitive-shell-safety/SKILL.md +69 -0
- package/.grok/skills/path-sensitive-shell-safety/references/workflow.md +127 -0
- package/.grok/skills/prompt-sharpener/SKILL.md +54 -0
- package/.grok/skills/reviewing-4p-priorities/SKILL.md +72 -0
- package/.grok/skills/reviewing-4p-priorities/examples.md +298 -0
- package/.grok/skills/sequential-thinking/SKILL.md +106 -0
- package/.grok/skills/sequential-thinking/examples/adaptive-depth.md +542 -0
- package/.grok/skills/sequential-thinking/examples/branching-exploration.md +474 -0
- package/.grok/skills/sequential-thinking/examples/linear-reasoning.md +210 -0
- package/.grok/skills/sequential-thinking/examples/revision-pattern.md +304 -0
- package/.grok/skills/sequential-thinking/references/output-schema.md +483 -0
- package/.grok/skills/sequential-thinking/references/parameters.md +463 -0
- package/.grok/skills/sequential-thinking/references/patterns.md +666 -0
- package/.grok/skills/vibekit-init/SKILL.md +52 -0
- package/.grok/skills/visual-design-loop/SKILL.md +103 -0
- package/.grok/skills/visual-design-loop/agents/openai.yaml +4 -0
- package/.vibekit/docs/BACKBONE_REFERENCE.md +1 -1
- package/.vibekit/docs/INSTALL.md +9 -7
- package/.vibekit/docs/SECURITY_MODEL.md +1 -1
- package/.vibekit/docs/TOOLING_GUIDE.md +5 -0
- package/.vibekit/docs/templates/CONTEXT_TEMPLATE.md +1 -1
- package/.vibekit/init/CLAUDE-template.md +1 -0
- package/.vibekit/init/FIRST_PROMPT.md +1 -1
- package/.vibekit/init/FIRST_TIME_INIT.md +2 -2
- package/.vibekit/scripts/doctor.mjs +11 -4
- package/.vibekit/scripts/mvck.mjs +24 -9
- package/.vibekit/scripts/test-install.mjs +8 -0
- package/.vibekit/scripts/validate-kit.mjs +104 -39
- package/.vibekit/skills/agentshield-security-review/scripts/agentshield_repo_probe.py +28 -3
- package/.vibekit/skills/prompt-sharpener/SKILL.md +54 -0
- package/.vibekit/skills/vibekit-init/SKILL.md +2 -2
- package/AGENTS.md +2 -2
- package/CHANGELOG.md +10 -0
- package/README.md +17 -12
- package/backbone.yml +2 -1
- package/docs/README.vi.md +56 -51
- package/package.json +7 -2
|
@@ -0,0 +1,536 @@
|
|
|
1
|
+
# Metagame Operations - Examples
|
|
2
|
+
|
|
3
|
+
Advanced frameworks for high-stakes problem-solving and rapid iteration.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## OODA Loop Examples
|
|
8
|
+
|
|
9
|
+
### Example 1: Product Feature Development
|
|
10
|
+
|
|
11
|
+
**Turn 1: Start**
|
|
12
|
+
```
|
|
13
|
+
/clearthought ooda_loop action=start We need to improve checkout conversion rate
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
**Output:**
|
|
17
|
+
```json
|
|
18
|
+
{
|
|
19
|
+
"toolOperation": "ooda_loop",
|
|
20
|
+
"action": "start",
|
|
21
|
+
"currentPhase": "observe",
|
|
22
|
+
"loopNumber": 1,
|
|
23
|
+
"nodes": [],
|
|
24
|
+
"hypotheses": {},
|
|
25
|
+
"metrics": {
|
|
26
|
+
"completedLoops": 0,
|
|
27
|
+
"avgLoopTimeMs": 0,
|
|
28
|
+
"evidenceQuality": 0,
|
|
29
|
+
"learningRate": 0
|
|
30
|
+
},
|
|
31
|
+
"phaseChecklist": {
|
|
32
|
+
"observe": ["data_collected", "anomalies_noted", "baseline_established"],
|
|
33
|
+
"orient": ["patterns_identified", "context_analyzed", "assumptions_listed"],
|
|
34
|
+
"decide": ["options_generated", "criteria_defined", "decision_made"],
|
|
35
|
+
"act": ["action_planned", "execution_started", "feedback_mechanism"]
|
|
36
|
+
},
|
|
37
|
+
"config": {
|
|
38
|
+
"maxLoopTimeMs": 300000,
|
|
39
|
+
"autoAdvance": true,
|
|
40
|
+
"minEvidence": 3,
|
|
41
|
+
"carryForwardHypotheses": true
|
|
42
|
+
},
|
|
43
|
+
"sessionContext": {
|
|
44
|
+
"sessionId": "conversation"
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
**Turn 2: Observe**
|
|
50
|
+
```
|
|
51
|
+
/clearthought ooda_loop action=continue evidence=["data_collected: 67% cart abandonment", "anomalies_noted: spike at payment step", "baseline_established: 15% conversion"]
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
**Output:**
|
|
55
|
+
```json
|
|
56
|
+
{
|
|
57
|
+
"toolOperation": "ooda_loop",
|
|
58
|
+
"action": "continue",
|
|
59
|
+
"currentPhase": "observe",
|
|
60
|
+
"loopNumber": 1,
|
|
61
|
+
"nodes": [
|
|
62
|
+
{
|
|
63
|
+
"phase": "observe",
|
|
64
|
+
"content": "Collected: 67% cart abandonment at payment step, current 15% conversion",
|
|
65
|
+
"timestamp": "2026-04-05T10:30:00Z",
|
|
66
|
+
"evidence": ["data_collected", "anomalies_noted", "baseline_established"]
|
|
67
|
+
}
|
|
68
|
+
],
|
|
69
|
+
"metrics": {
|
|
70
|
+
"completedLoops": 0,
|
|
71
|
+
"avgLoopTimeMs": 0,
|
|
72
|
+
"evidenceQuality": 0.8,
|
|
73
|
+
"learningRate": 0
|
|
74
|
+
},
|
|
75
|
+
"autoAdvancing": true,
|
|
76
|
+
"nextPhase": "orient",
|
|
77
|
+
"sessionContext": {
|
|
78
|
+
"sessionId": "conversation"
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
**Turn 3: Orient (Auto-Advanced)**
|
|
84
|
+
```
|
|
85
|
+
/clearthought ooda_loop action=continue evidence=["patterns_identified: users confused by payment form", "context_analyzed: mobile checkout broken", "assumptions_listed: form too long"]
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
**Turn 4: Decide**
|
|
89
|
+
```
|
|
90
|
+
/clearthought ooda_loop action=continue decision={"options": ["Simplify form", "Fix mobile", "Add express checkout"], "selected": "Fix mobile", "rationale": "Highest impact, affects 70% of users"}
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
**Turn 5: Act**
|
|
94
|
+
```
|
|
95
|
+
/clearthought ooda_loop action=continue action={"action": "Fix mobile checkout", "outcome": "Deployed fix, monitoring conversion", "metrics": {"conversion": "21%", "improvement": "+6%"}}
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
**Turn 6: Complete Loop & Advance**
|
|
99
|
+
```
|
|
100
|
+
/clearthought ooda_loop action=advance
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
**Output (Loop Completed):**
|
|
104
|
+
```json
|
|
105
|
+
{
|
|
106
|
+
"toolOperation": "ooda_loop",
|
|
107
|
+
"action": "advance",
|
|
108
|
+
"currentPhase": "observe",
|
|
109
|
+
"loopNumber": 2,
|
|
110
|
+
"nodes": [
|
|
111
|
+
{"phase": "observe", "content": "...", "timestamp": "..."},
|
|
112
|
+
{"phase": "orient", "content": "...", "timestamp": "..."},
|
|
113
|
+
{"phase": "decide", "content": "...", "timestamp": "..."},
|
|
114
|
+
{"phase": "act", "content": "...", "timestamp": "..."}
|
|
115
|
+
],
|
|
116
|
+
"hypotheses": {
|
|
117
|
+
"mobile_checkout_broken": {
|
|
118
|
+
"text": "Mobile checkout bug causing 67% abandonment",
|
|
119
|
+
"status": "validated",
|
|
120
|
+
"validatedAt": "2026-04-05T10:45:00Z"
|
|
121
|
+
}
|
|
122
|
+
},
|
|
123
|
+
"metrics": {
|
|
124
|
+
"completedLoops": 1,
|
|
125
|
+
"avgLoopTimeMs": 900000,
|
|
126
|
+
"evidenceQuality": 0.85,
|
|
127
|
+
"learningRate": 1.0
|
|
128
|
+
},
|
|
129
|
+
"loopSummary": {
|
|
130
|
+
"observed": "67% abandonment at payment",
|
|
131
|
+
"oriented": "Mobile checkout broken",
|
|
132
|
+
"decided": "Fix mobile",
|
|
133
|
+
"acted": "Deployed fix, +6% conversion"
|
|
134
|
+
},
|
|
135
|
+
"sessionContext": {
|
|
136
|
+
"sessionId": "conversation"
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
---
|
|
142
|
+
|
|
143
|
+
## Ulysses Protocol Examples
|
|
144
|
+
|
|
145
|
+
### Example 1: Critical Bug Fix
|
|
146
|
+
|
|
147
|
+
**Turn 1: Start High-Stakes Session**
|
|
148
|
+
```
|
|
149
|
+
/clearthought ulysses_protocol action=start Critical: Payment gateway returning 500 errors, affecting 40% of transactions
|
|
150
|
+
```
|
|
151
|
+
|
|
152
|
+
**Output:**
|
|
153
|
+
```json
|
|
154
|
+
{
|
|
155
|
+
"toolOperation": "ulysses_protocol",
|
|
156
|
+
"action": "start",
|
|
157
|
+
"currentPhase": "reconnaissance",
|
|
158
|
+
"gates": [
|
|
159
|
+
{
|
|
160
|
+
"phase": "reconnaissance",
|
|
161
|
+
"status": "open",
|
|
162
|
+
"entryCriteria": ["scope_defined", "stakeholders_identified", "impact_assessed"],
|
|
163
|
+
"exitCriteria": ["risks_catalogued", "resources_allocated", "timeline_established"],
|
|
164
|
+
"entryMet": [],
|
|
165
|
+
"exitMet": []
|
|
166
|
+
},
|
|
167
|
+
{
|
|
168
|
+
"phase": "planning",
|
|
169
|
+
"status": "locked",
|
|
170
|
+
"entryCriteria": ["approach_selected", "tasks_defined", "dependencies_mapped"],
|
|
171
|
+
"exitCriteria": ["plan_validated", "risks_mitigated", "team_aligned"],
|
|
172
|
+
"entryMet": [],
|
|
173
|
+
"exitMet": []
|
|
174
|
+
},
|
|
175
|
+
{
|
|
176
|
+
"phase": "implementation",
|
|
177
|
+
"status": "locked",
|
|
178
|
+
"entryCriteria": ["environment_ready", "tests_prepared", "rollback_planned"],
|
|
179
|
+
"exitCriteria": ["solution_implemented", "tests_passed", "code_reviewed"],
|
|
180
|
+
"entryMet": [],
|
|
181
|
+
"exitMet": []
|
|
182
|
+
},
|
|
183
|
+
{
|
|
184
|
+
"phase": "validation",
|
|
185
|
+
"status": "locked",
|
|
186
|
+
"entryCriteria": ["solution_deployed", "monitoring_active", "success_criteria_defined"],
|
|
187
|
+
"exitCriteria": ["success_validated", "side_effects_checked", "documentation_complete"],
|
|
188
|
+
"entryMet": [],
|
|
189
|
+
"exitMet": []
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
"phase": "ship_or_abort",
|
|
193
|
+
"status": "locked",
|
|
194
|
+
"entryCriteria": ["decision_ready"],
|
|
195
|
+
"exitCriteria": ["decision_executed"],
|
|
196
|
+
"entryMet": [],
|
|
197
|
+
"exitMet": []
|
|
198
|
+
}
|
|
199
|
+
],
|
|
200
|
+
"nodes": [],
|
|
201
|
+
"metrics": {
|
|
202
|
+
"gatesPassed": 0,
|
|
203
|
+
"iteration": 0,
|
|
204
|
+
"confidence": 0,
|
|
205
|
+
"scopeDrift": 0,
|
|
206
|
+
"timeSpentMs": 0
|
|
207
|
+
},
|
|
208
|
+
"constraints": {
|
|
209
|
+
"timeboxMs": 14400000,
|
|
210
|
+
"maxIterations": 3,
|
|
211
|
+
"minConfidence": 0.9,
|
|
212
|
+
"maxScopeDrift": 0.3
|
|
213
|
+
},
|
|
214
|
+
"policy": {
|
|
215
|
+
"autoEscalate": true,
|
|
216
|
+
"notifyWhen": ["gate_failed", "constraint_exceeded", "iteration_limit"],
|
|
217
|
+
"allowOverride": false
|
|
218
|
+
},
|
|
219
|
+
"sessionContext": {
|
|
220
|
+
"sessionId": "conversation"
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
```
|
|
224
|
+
|
|
225
|
+
**Turn 2: Reconnaissance**
|
|
226
|
+
```
|
|
227
|
+
/clearthought ulysses_protocol action=continue evidence=["scope_defined: payment 500 errors", "stakeholders_identified: eng team, customers, finance", "impact_assessed: $50k/hour revenue loss"]
|
|
228
|
+
```
|
|
229
|
+
|
|
230
|
+
**Turn 3: Pass Reconnaissance Gate**
|
|
231
|
+
```
|
|
232
|
+
/clearthought ulysses_protocol action=advance evidence=["risks_catalogued: data corruption, downtime", "resources_allocated: 2 senior engineers", "timeline_established: 4 hour deadline"]
|
|
233
|
+
```
|
|
234
|
+
|
|
235
|
+
**Output (Gate Passed):**
|
|
236
|
+
```json
|
|
237
|
+
{
|
|
238
|
+
"toolOperation": "ulysses_protocol",
|
|
239
|
+
"action": "advance",
|
|
240
|
+
"currentPhase": "planning",
|
|
241
|
+
"gates": [
|
|
242
|
+
{
|
|
243
|
+
"phase": "reconnaissance",
|
|
244
|
+
"status": "passed",
|
|
245
|
+
"entryCriteria": ["scope_defined", "stakeholders_identified", "impact_assessed"],
|
|
246
|
+
"exitCriteria": ["risks_catalogued", "resources_allocated", "timeline_established"],
|
|
247
|
+
"entryMet": ["scope_defined", "stakeholders_identified", "impact_assessed"],
|
|
248
|
+
"exitMet": ["risks_catalogued", "resources_allocated", "timeline_established"]
|
|
249
|
+
},
|
|
250
|
+
{
|
|
251
|
+
"phase": "planning",
|
|
252
|
+
"status": "open",
|
|
253
|
+
"entryCriteria": ["approach_selected", "tasks_defined", "dependencies_mapped"],
|
|
254
|
+
"exitCriteria": ["plan_validated", "risks_mitigated", "team_aligned"],
|
|
255
|
+
"entryMet": [],
|
|
256
|
+
"exitMet": []
|
|
257
|
+
},
|
|
258
|
+
"... other gates ..."
|
|
259
|
+
],
|
|
260
|
+
"nodes": [
|
|
261
|
+
{
|
|
262
|
+
"phase": "reconnaissance",
|
|
263
|
+
"content": "Identified: Payment 500 errors affecting 40% transactions, $50k/hour loss",
|
|
264
|
+
"timestamp": "2026-04-05T10:30:00Z"
|
|
265
|
+
},
|
|
266
|
+
{
|
|
267
|
+
"phase": "reconnaissance",
|
|
268
|
+
"content": "Resources: 2 senior engineers, 4 hour deadline",
|
|
269
|
+
"timestamp": "2026-04-05T10:32:00Z"
|
|
270
|
+
}
|
|
271
|
+
],
|
|
272
|
+
"metrics": {
|
|
273
|
+
"gatesPassed": 1,
|
|
274
|
+
"iteration": 2,
|
|
275
|
+
"confidence": 0.7,
|
|
276
|
+
"scopeDrift": 0,
|
|
277
|
+
"timeSpentMs": 120000
|
|
278
|
+
},
|
|
279
|
+
"gateTransition": {
|
|
280
|
+
"from": "reconnaissance",
|
|
281
|
+
"to": "planning",
|
|
282
|
+
"success": true
|
|
283
|
+
},
|
|
284
|
+
"sessionContext": {
|
|
285
|
+
"sessionId": "conversation"
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
```
|
|
289
|
+
|
|
290
|
+
**Turn 4-N: Continue through Planning → Implementation → Validation**
|
|
291
|
+
|
|
292
|
+
**Final Turn: Ship Decision**
|
|
293
|
+
```
|
|
294
|
+
/clearthought ulysses_protocol action=decide rationale="All tests passed, error rate reduced to 0.1%, monitoring shows stable performance"
|
|
295
|
+
```
|
|
296
|
+
|
|
297
|
+
**Output:**
|
|
298
|
+
```json
|
|
299
|
+
{
|
|
300
|
+
"toolOperation": "ulysses_protocol",
|
|
301
|
+
"action": "decide",
|
|
302
|
+
"currentPhase": "ship_or_abort",
|
|
303
|
+
"finalDecision": {
|
|
304
|
+
"decision": "ship",
|
|
305
|
+
"rationale": "All tests passed, error rate reduced to 0.1%, monitoring shows stable performance",
|
|
306
|
+
"timestamp": "2026-04-05T14:30:00Z",
|
|
307
|
+
"confidence": 0.95
|
|
308
|
+
},
|
|
309
|
+
"gates": [
|
|
310
|
+
{"phase": "reconnaissance", "status": "passed"},
|
|
311
|
+
{"phase": "planning", "status": "passed"},
|
|
312
|
+
{"phase": "implementation", "status": "passed"},
|
|
313
|
+
{"phase": "validation", "status": "passed"},
|
|
314
|
+
{"phase": "ship_or_abort", "status": "passed"}
|
|
315
|
+
],
|
|
316
|
+
"metrics": {
|
|
317
|
+
"gatesPassed": 5,
|
|
318
|
+
"iteration": 12,
|
|
319
|
+
"confidence": 0.95,
|
|
320
|
+
"scopeDrift": 0.05,
|
|
321
|
+
"timeSpentMs": 12600000
|
|
322
|
+
},
|
|
323
|
+
"summary": "Successfully resolved payment gateway errors in 3.5 hours, under budget and constraints",
|
|
324
|
+
"sessionContext": {
|
|
325
|
+
"sessionId": "conversation"
|
|
326
|
+
}
|
|
327
|
+
}
|
|
328
|
+
```
|
|
329
|
+
|
|
330
|
+
---
|
|
331
|
+
|
|
332
|
+
### Example 2: Ulysses Export (Markdown Report)
|
|
333
|
+
|
|
334
|
+
**Input:**
|
|
335
|
+
```
|
|
336
|
+
/clearthought ulysses_protocol action=export
|
|
337
|
+
```
|
|
338
|
+
|
|
339
|
+
**Output:**
|
|
340
|
+
```json
|
|
341
|
+
{
|
|
342
|
+
"toolOperation": "ulysses_protocol",
|
|
343
|
+
"action": "export",
|
|
344
|
+
"format": "markdown",
|
|
345
|
+
"export": "# Ulysses Protocol Session Report\n\n**Session:** conversation\n**Stakes:** Critical\n**Status:** Complete\n\n## Gates Status\n\n### ✅ Reconnaissance (PASSED)\n- Status: passed\n- Entry criteria: [x] scope_defined [x] stakeholders_identified [x] impact_assessed\n- Exit criteria: [x] risks_catalogued [x] resources_allocated [x] timeline_established\n\n### ✅ Planning (PASSED)\n...\n\n## Metrics\n- Gates Passed: 5/5\n- Total Iterations: 12\n- Confidence: 0.95\n- Time Spent: 3.5 hours\n\n## Final Decision\n✅ **SHIP**\n\n**Rationale:** All tests passed, error rate reduced to 0.1%\n**Confidence:** 0.95\n\n## Phase History\n\n### Reconnaissance\n- Identified payment errors affecting 40% transactions\n- Assessed $50k/hour revenue impact\n\n### Planning\n- Debugged gateway timeout issue\n- Planned database connection pool fix\n\n### Implementation\n- Increased connection pool size\n- Added retry logic with exponential backoff\n- Deployed canary release\n\n### Validation\n- Monitored error rates: 500 errors → 0.1%\n- Performance: p95 latency 120ms → 45ms\n- All regression tests passed\n\n## Constraints\n- Timebox: 4 hours (used 3.5h) ✅\n- Max Iterations: 3 (used 2) ✅\n- Min Confidence: 0.9 (achieved 0.95) ✅\n- Max Scope Drift: 0.3 (actual 0.05) ✅\n\n## Lessons Learned\n1. Connection pool was undersized for peak load\n2. Retry logic critical for transient errors\n3. Canary deployment allowed safe validation\n",
|
|
346
|
+
"sessionContext": {
|
|
347
|
+
"sessionId": "conversation"
|
|
348
|
+
}
|
|
349
|
+
}
|
|
350
|
+
```
|
|
351
|
+
|
|
352
|
+
---
|
|
353
|
+
|
|
354
|
+
## PDR Reasoning Examples
|
|
355
|
+
|
|
356
|
+
### Example: Multi-Pass Analysis
|
|
357
|
+
|
|
358
|
+
**Turn 1: Start Session**
|
|
359
|
+
```
|
|
360
|
+
/clearthought pdr_reasoning action=start Analyze performance bottlenecks in API
|
|
361
|
+
```
|
|
362
|
+
|
|
363
|
+
**Output:**
|
|
364
|
+
```json
|
|
365
|
+
{
|
|
366
|
+
"toolOperation": "pdr_reasoning",
|
|
367
|
+
"action": "start",
|
|
368
|
+
"sessionId": "pdr-session-123",
|
|
369
|
+
"passes": [
|
|
370
|
+
{"name": "scan", "defaultApproach": "sequential", "budget": {"subjectsLimit": 10}},
|
|
371
|
+
{"name": "cluster", "defaultApproach": "tree", "budget": {"subjectsLimit": 5}},
|
|
372
|
+
{"name": "select", "defaultApproach": "beam", "budget": {"subjectsLimit": 3}},
|
|
373
|
+
{"name": "deepen", "defaultApproach": "graph", "budget": {"subjectsLimit": 3}},
|
|
374
|
+
{"name": "synthesize", "defaultApproach": "mcts", "budget": {"subjectsLimit": 1}}
|
|
375
|
+
],
|
|
376
|
+
"maxPasses": 5,
|
|
377
|
+
"stopConditions": {
|
|
378
|
+
"maxTimeMs": 1800000,
|
|
379
|
+
"minImprovement": 0.05,
|
|
380
|
+
"confidenceThreshold": 0.9
|
|
381
|
+
},
|
|
382
|
+
"suggestions": ["Add subjects with 'add_subject' action"],
|
|
383
|
+
"sessionContext": {
|
|
384
|
+
"sessionId": "conversation"
|
|
385
|
+
}
|
|
386
|
+
}
|
|
387
|
+
```
|
|
388
|
+
|
|
389
|
+
**Turn 2: Add Subjects**
|
|
390
|
+
```
|
|
391
|
+
/clearthought pdr_reasoning action=add_subject title="Database query optimization" description="Slow N+1 queries" tags=["performance", "database"]
|
|
392
|
+
```
|
|
393
|
+
|
|
394
|
+
**Turn 3: Run Scan Pass**
|
|
395
|
+
```
|
|
396
|
+
/clearthought pdr_reasoning action=run_pass passName=scan
|
|
397
|
+
```
|
|
398
|
+
|
|
399
|
+
**Output:**
|
|
400
|
+
```json
|
|
401
|
+
{
|
|
402
|
+
"toolOperation": "pdr_reasoning",
|
|
403
|
+
"action": "run_pass",
|
|
404
|
+
"sessionId": "pdr-session-123",
|
|
405
|
+
"passName": "scan",
|
|
406
|
+
"approach": "sequential",
|
|
407
|
+
"subjects": [
|
|
408
|
+
{
|
|
409
|
+
"id": "subject-1",
|
|
410
|
+
"title": "Database query optimization",
|
|
411
|
+
"description": "Slow N+1 queries",
|
|
412
|
+
"tags": ["performance", "database"],
|
|
413
|
+
"score": 0.85,
|
|
414
|
+
"confidence": 0.75
|
|
415
|
+
}
|
|
416
|
+
],
|
|
417
|
+
"traces": [
|
|
418
|
+
"Analyzed subject-1 using sequential approach",
|
|
419
|
+
"Generated artifact: analysis-subject-1.md",
|
|
420
|
+
"Confidence: 0.75, Score: 0.85"
|
|
421
|
+
],
|
|
422
|
+
"metrics": {
|
|
423
|
+
"subjectsAnalyzed": 1,
|
|
424
|
+
"passCompleted": true,
|
|
425
|
+
"avgScore": 0.85
|
|
426
|
+
},
|
|
427
|
+
"suggestions": ["Run cluster pass to group related subjects"],
|
|
428
|
+
"nextStepNeeded": true,
|
|
429
|
+
"sessionContext": {
|
|
430
|
+
"sessionId": "conversation"
|
|
431
|
+
}
|
|
432
|
+
}
|
|
433
|
+
```
|
|
434
|
+
|
|
435
|
+
**Turn 4: Select Best**
|
|
436
|
+
```
|
|
437
|
+
/clearthought pdr_reasoning action=select criteria={"minScore": 0.8, "topK": 1}
|
|
438
|
+
```
|
|
439
|
+
|
|
440
|
+
**Output:**
|
|
441
|
+
```json
|
|
442
|
+
{
|
|
443
|
+
"toolOperation": "pdr_reasoning",
|
|
444
|
+
"action": "select",
|
|
445
|
+
"sessionId": "pdr-session-123",
|
|
446
|
+
"selected": ["subject-1"],
|
|
447
|
+
"criteria": {
|
|
448
|
+
"minScore": 0.8,
|
|
449
|
+
"topK": 1
|
|
450
|
+
},
|
|
451
|
+
"summary": {
|
|
452
|
+
"totalSubjects": 1,
|
|
453
|
+
"selectedCount": 1,
|
|
454
|
+
"avgScore": 0.85,
|
|
455
|
+
"topSubjects": [
|
|
456
|
+
{"id": "subject-1", "title": "Database query optimization", "score": 0.85}
|
|
457
|
+
]
|
|
458
|
+
},
|
|
459
|
+
"suggestions": ["Export results with 'export' action"],
|
|
460
|
+
"sessionContext": {
|
|
461
|
+
"sessionId": "conversation"
|
|
462
|
+
}
|
|
463
|
+
}
|
|
464
|
+
```
|
|
465
|
+
|
|
466
|
+
---
|
|
467
|
+
|
|
468
|
+
## Comparison: OODA vs Ulysses
|
|
469
|
+
|
|
470
|
+
### When to Use OODA
|
|
471
|
+
|
|
472
|
+
**Characteristics:**
|
|
473
|
+
- Rapid iteration
|
|
474
|
+
- Hypothesis-driven
|
|
475
|
+
- Auto-advancing phases
|
|
476
|
+
- Learning through cycles
|
|
477
|
+
- Good for: product development, experiments, iterative debugging
|
|
478
|
+
|
|
479
|
+
**Example Scenario:** "Test different UI variations to improve conversion"
|
|
480
|
+
|
|
481
|
+
---
|
|
482
|
+
|
|
483
|
+
### When to Use Ulysses
|
|
484
|
+
|
|
485
|
+
**Characteristics:**
|
|
486
|
+
- Phased governance
|
|
487
|
+
- Strict gate validation
|
|
488
|
+
- High-stakes decisions
|
|
489
|
+
- Constraint enforcement
|
|
490
|
+
- Good for: production incidents, critical releases, major migrations
|
|
491
|
+
|
|
492
|
+
**Example Scenario:** "Fix payment system bug affecting revenue"
|
|
493
|
+
|
|
494
|
+
---
|
|
495
|
+
|
|
496
|
+
## Advanced: Constraint Escalation
|
|
497
|
+
|
|
498
|
+
**Ulysses with Constraint Violation:**
|
|
499
|
+
|
|
500
|
+
```json
|
|
501
|
+
{
|
|
502
|
+
"toolOperation": "ulysses_protocol",
|
|
503
|
+
"action": "continue",
|
|
504
|
+
"currentPhase": "implementation",
|
|
505
|
+
"constraintViolations": [
|
|
506
|
+
"⚠️ Time constraint: 3.8h / 4h used (95%)",
|
|
507
|
+
"⚠️ Iteration limit: 3/3 iterations in implementation"
|
|
508
|
+
],
|
|
509
|
+
"escalation": {
|
|
510
|
+
"triggered": true,
|
|
511
|
+
"reason": "Iteration limit reached",
|
|
512
|
+
"action": "abort",
|
|
513
|
+
"escalationNode": {
|
|
514
|
+
"phase": "implementation",
|
|
515
|
+
"content": "🚨 ESCALATION: Iteration limit reached, forcing decision",
|
|
516
|
+
"escalated": true
|
|
517
|
+
}
|
|
518
|
+
},
|
|
519
|
+
"finalDecision": {
|
|
520
|
+
"decision": "abort",
|
|
521
|
+
"rationale": "Cannot achieve confidence within constraints",
|
|
522
|
+
"timestamp": "2026-04-05T14:28:00Z",
|
|
523
|
+
"confidence": 0.65
|
|
524
|
+
},
|
|
525
|
+
"sessionContext": {
|
|
526
|
+
"sessionId": "conversation"
|
|
527
|
+
}
|
|
528
|
+
}
|
|
529
|
+
```
|
|
530
|
+
|
|
531
|
+
---
|
|
532
|
+
|
|
533
|
+
**For more examples:**
|
|
534
|
+
- [sequential-thinking.md](sequential-thinking.md)
|
|
535
|
+
- [decision-framework.md](decision-framework.md)
|
|
536
|
+
- `../references/output-schemas.md`
|