@soleri/forge 5.14.0 → 5.14.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.
Files changed (105) hide show
  1. package/dist/index.js +0 -0
  2. package/dist/lib.d.ts +2 -0
  3. package/dist/lib.js +2 -0
  4. package/dist/lib.js.map +1 -1
  5. package/dist/skills/brain-debrief.md +47 -19
  6. package/dist/skills/brainstorming.md +19 -9
  7. package/dist/skills/code-patrol.md +21 -19
  8. package/dist/skills/context-resume.md +14 -11
  9. package/dist/skills/executing-plans.md +30 -15
  10. package/dist/skills/fix-and-learn.md +17 -14
  11. package/dist/skills/health-check.md +29 -23
  12. package/dist/skills/knowledge-harvest.md +27 -20
  13. package/dist/skills/onboard-me.md +16 -15
  14. package/dist/skills/retrospective.md +34 -18
  15. package/dist/skills/second-opinion.md +16 -9
  16. package/dist/skills/systematic-debugging.md +40 -29
  17. package/dist/skills/test-driven-development.md +45 -30
  18. package/dist/skills/vault-capture.md +31 -15
  19. package/dist/skills/vault-navigator.md +24 -13
  20. package/dist/skills/verification-before-completion.md +38 -26
  21. package/dist/skills/writing-plans.md +21 -13
  22. package/dist/templates/claude-md-template.d.ts +9 -8
  23. package/dist/templates/claude-md-template.js +29 -11
  24. package/dist/templates/claude-md-template.js.map +1 -1
  25. package/dist/templates/inject-claude-md.js +65 -25
  26. package/dist/templates/inject-claude-md.js.map +1 -1
  27. package/dist/templates/shared-rules.d.ts +10 -6
  28. package/dist/templates/shared-rules.js +242 -199
  29. package/dist/templates/shared-rules.js.map +1 -1
  30. package/dist/templates/test-facades.js +6 -4
  31. package/dist/templates/test-facades.js.map +1 -1
  32. package/package.json +1 -1
  33. package/src/lib.ts +2 -0
  34. package/src/templates/claude-md-template.ts +30 -12
  35. package/src/templates/inject-claude-md.ts +65 -25
  36. package/src/templates/shared-rules.ts +259 -210
  37. package/src/templates/test-facades.ts +6 -4
  38. package/dist/skills/skills/brain-debrief.md +0 -214
  39. package/dist/skills/skills/brainstorming.md +0 -180
  40. package/dist/skills/skills/code-patrol.md +0 -178
  41. package/dist/skills/skills/context-resume.md +0 -146
  42. package/dist/skills/skills/executing-plans.md +0 -216
  43. package/dist/skills/skills/fix-and-learn.md +0 -167
  44. package/dist/skills/skills/health-check.md +0 -231
  45. package/dist/skills/skills/knowledge-harvest.md +0 -185
  46. package/dist/skills/skills/onboard-me.md +0 -198
  47. package/dist/skills/skills/retrospective.md +0 -205
  48. package/dist/skills/skills/second-opinion.md +0 -149
  49. package/dist/skills/skills/systematic-debugging.md +0 -241
  50. package/dist/skills/skills/test-driven-development.md +0 -281
  51. package/dist/skills/skills/vault-capture.md +0 -170
  52. package/dist/skills/skills/vault-navigator.md +0 -140
  53. package/dist/skills/skills/verification-before-completion.md +0 -182
  54. package/dist/skills/skills/writing-plans.md +0 -215
  55. package/dist/templates/brain.d.ts +0 -6
  56. package/dist/templates/brain.js +0 -478
  57. package/dist/templates/brain.js.map +0 -1
  58. package/dist/templates/core-facade.d.ts +0 -6
  59. package/dist/templates/core-facade.js +0 -564
  60. package/dist/templates/core-facade.js.map +0 -1
  61. package/dist/templates/facade-factory.d.ts +0 -1
  62. package/dist/templates/facade-factory.js +0 -63
  63. package/dist/templates/facade-factory.js.map +0 -1
  64. package/dist/templates/facade-types.d.ts +0 -1
  65. package/dist/templates/facade-types.js +0 -46
  66. package/dist/templates/facade-types.js.map +0 -1
  67. package/dist/templates/intelligence-loader.d.ts +0 -1
  68. package/dist/templates/intelligence-loader.js +0 -43
  69. package/dist/templates/intelligence-loader.js.map +0 -1
  70. package/dist/templates/intelligence-types.d.ts +0 -1
  71. package/dist/templates/intelligence-types.js +0 -24
  72. package/dist/templates/intelligence-types.js.map +0 -1
  73. package/dist/templates/llm-client.d.ts +0 -7
  74. package/dist/templates/llm-client.js +0 -300
  75. package/dist/templates/llm-client.js.map +0 -1
  76. package/dist/templates/llm-key-pool.d.ts +0 -7
  77. package/dist/templates/llm-key-pool.js +0 -211
  78. package/dist/templates/llm-key-pool.js.map +0 -1
  79. package/dist/templates/llm-types.d.ts +0 -5
  80. package/dist/templates/llm-types.js +0 -161
  81. package/dist/templates/llm-types.js.map +0 -1
  82. package/dist/templates/llm-utils.d.ts +0 -5
  83. package/dist/templates/llm-utils.js +0 -260
  84. package/dist/templates/llm-utils.js.map +0 -1
  85. package/dist/templates/planner.d.ts +0 -5
  86. package/dist/templates/planner.js +0 -150
  87. package/dist/templates/planner.js.map +0 -1
  88. package/dist/templates/test-brain.d.ts +0 -6
  89. package/dist/templates/test-brain.js +0 -474
  90. package/dist/templates/test-brain.js.map +0 -1
  91. package/dist/templates/test-llm.d.ts +0 -7
  92. package/dist/templates/test-llm.js +0 -574
  93. package/dist/templates/test-llm.js.map +0 -1
  94. package/dist/templates/test-loader.d.ts +0 -5
  95. package/dist/templates/test-loader.js +0 -146
  96. package/dist/templates/test-loader.js.map +0 -1
  97. package/dist/templates/test-planner.d.ts +0 -5
  98. package/dist/templates/test-planner.js +0 -271
  99. package/dist/templates/test-planner.js.map +0 -1
  100. package/dist/templates/test-vault.d.ts +0 -5
  101. package/dist/templates/test-vault.js +0 -380
  102. package/dist/templates/test-vault.js.map +0 -1
  103. package/dist/templates/vault.d.ts +0 -5
  104. package/dist/templates/vault.js +0 -263
  105. package/dist/templates/vault.js.map +0 -1
@@ -18,12 +18,14 @@ Write the test first. Watch it fail. Write minimal code to pass.
18
18
  ## When to Use
19
19
 
20
20
  **Always:**
21
+
21
22
  - New features
22
23
  - Bug fixes
23
24
  - Refactoring
24
25
  - Behavior changes
25
26
 
26
27
  **Exceptions (ask your human partner):**
28
+
27
29
  - Throwaway prototypes
28
30
  - Generated code
29
31
  - Configuration files
@@ -35,6 +37,7 @@ Thinking "skip TDD just this once"? Stop. That's rationalization.
35
37
  **Never start writing tests blind.** Follow this lookup order:
36
38
 
37
39
  ### 1. Vault First
40
+
38
41
  Check for existing testing patterns in the knowledge base:
39
42
 
40
43
  ```
@@ -43,6 +46,7 @@ YOUR_AGENT_core op:search_intelligent
43
46
  ```
44
47
 
45
48
  Look for:
49
+
46
50
  - **Testing patterns** for similar features (how were they tested before?)
47
51
  - **Anti-patterns** — common testing mistakes in this domain
48
52
  - **Proven approaches** from brain strengths:
@@ -54,12 +58,15 @@ YOUR_AGENT_core op:brain_strengths
54
58
  If the vault has testing guidance for this domain, follow it. Don't reinvent test strategies that have already been validated.
55
59
 
56
60
  ### 2. Web Search
61
+
57
62
  If the vault has no relevant patterns, search the web for established testing approaches:
63
+
58
64
  - Library-specific testing patterns (e.g., how to test React hooks, Express middleware)
59
65
  - Best practices for the specific type of test (integration, e2e, unit)
60
66
  - Known gotchas in the testing framework being used
61
67
 
62
68
  ### 3. Then Write the Test
69
+
63
70
  Only after consulting vault and web, proceed to write the failing test. You'll write better tests when informed by existing knowledge.
64
71
 
65
72
  ## Start a TDD Loop
@@ -80,6 +87,7 @@ NO PRODUCTION CODE WITHOUT A FAILING TEST FIRST
80
87
  Write code before the test? Delete it. Start over.
81
88
 
82
89
  **No exceptions:**
90
+
83
91
  - Don't keep it as "reference"
84
92
  - Don't "adapt" it while writing tests
85
93
  - Don't look at it
@@ -97,6 +105,7 @@ Good: clear name, tests real behavior, one thing
97
105
  Bad: vague name, tests mock not code
98
106
 
99
107
  **Requirements:**
108
+
100
109
  - One behavior
101
110
  - Clear name
102
111
  - Real code (no mocks unless unavoidable)
@@ -108,6 +117,7 @@ Bad: vague name, tests mock not code
108
117
  Run: `npm test path/to/test.test.ts`
109
118
 
110
119
  Confirm:
120
+
111
121
  - Test fails (not errors)
112
122
  - Failure message is expected
113
123
  - Fails because feature missing (not typos)
@@ -116,6 +126,7 @@ Confirm:
116
126
  **Test errors?** Fix error, re-run until it fails correctly.
117
127
 
118
128
  Track the iteration:
129
+
119
130
  ```
120
131
  YOUR_AGENT_core op:loop_iterate
121
132
  ```
@@ -131,6 +142,7 @@ Write simplest code to pass the test. Don't add features, refactor other code, o
131
142
  Run: `npm test path/to/test.test.ts`
132
143
 
133
144
  Confirm:
145
+
134
146
  - Test passes
135
147
  - Other tests still pass
136
148
  - Output pristine (no errors, warnings)
@@ -139,6 +151,7 @@ Confirm:
139
151
  **Other tests fail?** Fix now.
140
152
 
141
153
  Track the iteration:
154
+
142
155
  ```
143
156
  YOUR_AGENT_core op:loop_iterate
144
157
  ```
@@ -146,6 +159,7 @@ YOUR_AGENT_core op:loop_iterate
146
159
  ### REFACTOR - Clean Up
147
160
 
148
161
  After green only:
162
+
149
163
  - Remove duplication
150
164
  - Improve names
151
165
  - Extract helpers
@@ -158,11 +172,11 @@ Next failing test for next feature.
158
172
 
159
173
  ## Good Tests
160
174
 
161
- | Quality | Good | Bad |
162
- |---------|------|-----|
163
- | **Minimal** | One thing. "and" in name? Split it. | `test('validates email and domain and whitespace')` |
164
- | **Clear** | Name describes behavior | `test('test1')` |
165
- | **Shows intent** | Demonstrates desired API | Obscures what code should do |
175
+ | Quality | Good | Bad |
176
+ | ---------------- | ----------------------------------- | --------------------------------------------------- |
177
+ | **Minimal** | One thing. "and" in name? Split it. | `test('validates email and domain and whitespace')` |
178
+ | **Clear** | Name describes behavior | `test('test1')` |
179
+ | **Shows intent** | Demonstrates desired API | Obscures what code should do |
166
180
 
167
181
  ## Why Order Matters
168
182
 
@@ -170,19 +184,19 @@ Tests written after code pass immediately — proving nothing. Test-first forces
170
184
 
171
185
  ## Common Rationalizations
172
186
 
173
- | Excuse | Reality |
174
- |--------|---------|
175
- | "Too simple to test" | Simple code breaks. Test takes 30 seconds. |
176
- | "I'll test after" | Tests passing immediately prove nothing. |
177
- | "Tests after achieve same goals" | Tests-after = "what does this do?" Tests-first = "what should this do?" |
178
- | "Already manually tested" | Ad-hoc ≠ systematic. No record, can't re-run. |
179
- | "Deleting X hours is wasteful" | Sunk cost fallacy. Keeping unverified code is technical debt. |
180
- | "Keep as reference, write tests first" | You'll adapt it. That's testing after. Delete means delete. |
181
- | "Need to explore first" | Fine. Throw away exploration, start with TDD. |
182
- | "Test hard = design unclear" | Listen to test. Hard to test = hard to use. |
183
- | "TDD will slow me down" | TDD faster than debugging. Pragmatic = test-first. |
184
- | "Manual test faster" | Manual doesn't prove edge cases. You'll re-test every change. |
185
- | "Existing code has no tests" | You're improving it. Add tests for existing code. |
187
+ | Excuse | Reality |
188
+ | -------------------------------------- | ----------------------------------------------------------------------- |
189
+ | "Too simple to test" | Simple code breaks. Test takes 30 seconds. |
190
+ | "I'll test after" | Tests passing immediately prove nothing. |
191
+ | "Tests after achieve same goals" | Tests-after = "what does this do?" Tests-first = "what should this do?" |
192
+ | "Already manually tested" | Ad-hoc ≠ systematic. No record, can't re-run. |
193
+ | "Deleting X hours is wasteful" | Sunk cost fallacy. Keeping unverified code is technical debt. |
194
+ | "Keep as reference, write tests first" | You'll adapt it. That's testing after. Delete means delete. |
195
+ | "Need to explore first" | Fine. Throw away exploration, start with TDD. |
196
+ | "Test hard = design unclear" | Listen to test. Hard to test = hard to use. |
197
+ | "TDD will slow me down" | TDD faster than debugging. Pragmatic = test-first. |
198
+ | "Manual test faster" | Manual doesn't prove edge cases. You'll re-test every change. |
199
+ | "Existing code has no tests" | You're improving it. Add tests for existing code. |
186
200
 
187
201
  ## Red Flags - STOP and Start Over
188
202
 
@@ -220,6 +234,7 @@ Can't check all boxes? You skipped TDD. Start over.
220
234
  ## After TDD — Capture and Complete
221
235
 
222
236
  Complete the loop:
237
+
223
238
  ```
224
239
  YOUR_AGENT_core op:loop_complete
225
240
  ```
@@ -238,12 +253,12 @@ This compounds across sessions — next time someone works on similar code, the
238
253
 
239
254
  ## When Stuck
240
255
 
241
- | Problem | Solution |
242
- |---------|----------|
256
+ | Problem | Solution |
257
+ | ---------------------- | -------------------------------------------------------------------- |
243
258
  | Don't know how to test | Write wished-for API. Write assertion first. Ask your human partner. |
244
- | Test too complicated | Design too complicated. Simplify interface. |
245
- | Must mock everything | Code too coupled. Use dependency injection. |
246
- | Test setup huge | Extract helpers. Still complex? Simplify design. |
259
+ | Test too complicated | Design too complicated. Simplify interface. |
260
+ | Must mock everything | Code too coupled. Use dependency injection. |
261
+ | Test setup huge | Extract helpers. Still complex? Simplify design. |
247
262
 
248
263
  ## Final Rule
249
264
 
@@ -256,11 +271,11 @@ No exceptions without your human partner's permission.
256
271
 
257
272
  ## Agent Tools Reference
258
273
 
259
- | Op | When to Use |
260
- |----|-------------|
274
+ | Op | When to Use |
275
+ | -------------------- | ------------------------------------- |
261
276
  | `search_intelligent` | Find testing patterns before starting |
262
- | `brain_strengths` | Check proven testing approaches |
263
- | `loop_start` | Begin TDD validation loop |
264
- | `loop_iterate` | Track each red-green cycle |
265
- | `loop_complete` | Finish TDD loop |
266
- | `capture_quick` | Capture new testing patterns |
277
+ | `brain_strengths` | Check proven testing approaches |
278
+ | `loop_start` | Begin TDD validation loop |
279
+ | `loop_iterate` | Track each red-green cycle |
280
+ | `loop_complete` | Finish TDD loop |
281
+ | `capture_quick` | Capture new testing patterns |
@@ -14,6 +14,7 @@ After discovering something worth remembering: a solution that worked, a mistake
14
14
  ## Orchestration Sequence
15
15
 
16
16
  ### Step 1: Check for Duplicates
17
+
17
18
  Call `YOUR_AGENT_core op:search_intelligent` with the knowledge title or description. If a similar entry exists, consider updating it instead of creating a duplicate.
18
19
 
19
20
  ```
@@ -30,7 +31,9 @@ YOUR_AGENT_core op:curator_detect_duplicates
30
31
  If duplicates are found, decide: update the existing entry or merge them.
31
32
 
32
33
  ### Step 2: Classify the Knowledge
34
+
33
35
  Determine the entry type:
36
+
34
37
  - **pattern** — Something that works and should be repeated
35
38
  - **anti-pattern** — Something that fails and should be avoided
36
39
  - **workflow** — A sequence of steps for a specific task
@@ -45,8 +48,10 @@ YOUR_AGENT_core op:route_intent
45
48
  ```
46
49
 
47
50
  ### Step 3: Capture
51
+
48
52
  For quick, single-entry captures:
49
53
  Call `YOUR_AGENT_core op:capture_knowledge` with:
54
+
50
55
  - **title**: Clear, searchable name
51
56
  - **description**: What it is and when it applies
52
57
  - **type**: From Step 2 classification
@@ -69,6 +74,7 @@ YOUR_AGENT_core op:capture_knowledge
69
74
  ```
70
75
 
71
76
  For quick captures:
77
+
72
78
  ```
73
79
  YOUR_AGENT_core op:capture_quick
74
80
  params: { title: "<name>", description: "<details>" }
@@ -79,29 +85,34 @@ YOUR_AGENT_core op:capture_quick
79
85
  After capturing, run the curator to ensure quality:
80
86
 
81
87
  **Groom the entry** — normalize tags, fix metadata:
88
+
82
89
  ```
83
90
  YOUR_AGENT_core op:curator_groom
84
91
  params: { entryId: "<captured entry id>" }
85
92
  ```
86
93
 
87
94
  **Enrich the entry** — use LLM to add context, improve description:
95
+
88
96
  ```
89
97
  YOUR_AGENT_core op:curator_enrich
90
98
  params: { entryId: "<captured entry id>" }
91
99
  ```
92
100
 
93
101
  **Check for contradictions** — does this conflict with existing knowledge?
102
+
94
103
  ```
95
104
  YOUR_AGENT_core op:curator_contradictions
96
105
  ```
97
106
 
98
107
  If contradictions found, resolve them:
108
+
99
109
  ```
100
110
  YOUR_AGENT_core op:curator_resolve_contradiction
101
111
  params: { contradictionId: "<id>" }
102
112
  ```
103
113
 
104
114
  ### Step 5: Handle Governance (if enabled)
115
+
105
116
  If governance policy requires review, the capture returns a `proposalId`. The entry is queued for approval.
106
117
 
107
118
  ```
@@ -112,7 +123,9 @@ YOUR_AGENT_core op:governance_proposals
112
123
  Present pending proposals to the user for approval.
113
124
 
114
125
  ### Step 6: Promote to Global (Optional)
126
+
115
127
  If the knowledge applies across projects (not project-specific):
128
+
116
129
  ```
117
130
  YOUR_AGENT_core op:memory_promote_to_global
118
131
  params: { entryId: "<entry id>" }
@@ -121,12 +134,15 @@ YOUR_AGENT_core op:memory_promote_to_global
121
134
  This makes it available in cross-project searches and brain recommendations.
122
135
 
123
136
  ### Step 7: Verify Health
137
+
124
138
  Confirm the capture was stored and vault health is maintained:
139
+
125
140
  ```
126
141
  YOUR_AGENT_core op:admin_health
127
142
  ```
128
143
 
129
144
  Check vault analytics for overall knowledge quality:
145
+
130
146
  ```
131
147
  YOUR_AGENT_core op:admin_vault_analytics
132
148
  ```
@@ -137,18 +153,18 @@ Capture is complete when: the entry is stored (or queued for review), categorize
137
153
 
138
154
  ## Agent Tools Reference
139
155
 
140
- | Op | When to Use |
141
- |----|-------------|
142
- | `search_intelligent` | Check for duplicates before capture |
143
- | `curator_detect_duplicates` | Explicit duplicate detection |
144
- | `route_intent` | Help classify knowledge type |
145
- | `capture_knowledge` | Full-metadata capture |
146
- | `capture_quick` | Fast capture for simple entries |
147
- | `curator_groom` | Normalize tags and metadata |
148
- | `curator_enrich` | LLM-powered metadata enrichment |
149
- | `curator_contradictions` | Find conflicting entries |
150
- | `curator_resolve_contradiction` | Resolve conflicts |
151
- | `governance_proposals` | Check/manage approval queue |
152
- | `memory_promote_to_global` | Share across projects |
153
- | `admin_health` | Verify system health |
154
- | `admin_vault_analytics` | Overall knowledge quality metrics |
156
+ | Op | When to Use |
157
+ | ------------------------------- | ----------------------------------- |
158
+ | `search_intelligent` | Check for duplicates before capture |
159
+ | `curator_detect_duplicates` | Explicit duplicate detection |
160
+ | `route_intent` | Help classify knowledge type |
161
+ | `capture_knowledge` | Full-metadata capture |
162
+ | `capture_quick` | Fast capture for simple entries |
163
+ | `curator_groom` | Normalize tags and metadata |
164
+ | `curator_enrich` | LLM-powered metadata enrichment |
165
+ | `curator_contradictions` | Find conflicting entries |
166
+ | `curator_resolve_contradiction` | Resolve conflicts |
167
+ | `governance_proposals` | Check/manage approval queue |
168
+ | `memory_promote_to_global` | Share across projects |
169
+ | `admin_health` | Verify system health |
170
+ | `admin_vault_analytics` | Overall knowledge quality metrics |
@@ -14,6 +14,7 @@ Any time the user wants to find existing knowledge before building something new
14
14
  ## Search Strategy Decision Tree
15
15
 
16
16
  ### For "Have we seen this before?" / "Best practice for X"
17
+
17
18
  Start with `YOUR_AGENT_core op:search_intelligent` — this is semantic search, the broadest and smartest query. Pass the user's question as the query.
18
19
 
19
20
  ```
@@ -24,24 +25,29 @@ YOUR_AGENT_core op:search_intelligent
24
25
  If results are weak (low scores or few matches), fall back to `YOUR_AGENT_core op:search` with explicit filters (type, category, tags, severity). This is structured search — narrower but more precise.
25
26
 
26
27
  ### For "Show me everything about X" (Exploration)
28
+
27
29
  Use tag-based and domain-based browsing for broader exploration:
28
30
 
29
31
  ```
30
32
  YOUR_AGENT_core op:vault_tags
31
33
  ```
34
+
32
35
  Lists all tags in the vault — helps discover what topics are covered.
33
36
 
34
37
  ```
35
38
  YOUR_AGENT_core op:vault_domains
36
39
  ```
40
+
37
41
  Lists all domains — shows the knowledge landscape at a glance.
38
42
 
39
43
  ```
40
44
  YOUR_AGENT_core op:vault_recent
41
45
  ```
46
+
42
47
  Shows recently added or modified entries — what's fresh in the vault.
43
48
 
44
49
  ### For "What's stale?" / "What needs updating?"
50
+
45
51
  Run an age report to find outdated knowledge:
46
52
 
47
53
  ```
@@ -51,6 +57,7 @@ YOUR_AGENT_core op:vault_age_report
51
57
  Present entries that haven't been updated recently — these are candidates for review, refresh, or removal.
52
58
 
53
59
  ### For "What do other projects do?"
60
+
54
61
  Call `YOUR_AGENT_core op:memory_cross_project_search` with `crossProject: true`. This searches across all linked projects, not just the current one.
55
62
 
56
63
  ```
@@ -65,6 +72,7 @@ YOUR_AGENT_core op:project_linked_projects
65
72
  ```
66
73
 
67
74
  ### For "Has brain learned anything about X?"
75
+
68
76
  Call `YOUR_AGENT_core op:brain_strengths` to see which patterns have proven strength. Then call `YOUR_AGENT_core op:brain_global_patterns` with a domain or tag filter to find cross-project patterns.
69
77
 
70
78
  ```
@@ -74,6 +82,7 @@ YOUR_AGENT_core op:brain_global_patterns
74
82
  ```
75
83
 
76
84
  ### For "What do I know about X?" (broad exploration)
85
+
77
86
  Chain multiple strategies for comprehensive results:
78
87
 
79
88
  1. `search_intelligent` → semantic vault search
@@ -86,6 +95,7 @@ Present all findings with source labels so the user knows where each insight cam
86
95
  ## Presenting Results
87
96
 
88
97
  Always include:
98
+
89
99
  - **Source**: Which search found it (vault, memory, brain, tags, domains)
90
100
  - **Confidence**: Score or strength rating
91
101
  - **Relevance**: Why this result matches the query
@@ -94,6 +104,7 @@ Always include:
94
104
  ## Fallback: Web Search
95
105
 
96
106
  If all vault strategies return no results, search the web for the user's question before saying "nothing found." The web may have:
107
+
97
108
  - Documentation, articles, or guides on the topic
98
109
  - Community patterns and best practices
99
110
  - Library-specific solutions
@@ -114,16 +125,16 @@ Search is complete when at least one search strategy has been tried and results
114
125
 
115
126
  ## Agent Tools Reference
116
127
 
117
- | Op | When to Use |
118
- |----|-------------|
119
- | `search_intelligent` | Default semantic search — broadest and smartest |
120
- | `search` | Structured search with filters (type, tags, category) |
121
- | `vault_tags` | Browse all tags — discover knowledge landscape |
122
- | `vault_domains` | Browse all domains — see what areas are covered |
123
- | `vault_recent` | Recently modified entries — what's fresh |
124
- | `vault_age_report` | Find stale entries needing refresh |
125
- | `memory_cross_project_search` | Search across linked projects |
126
- | `project_linked_projects` | See what projects are connected |
127
- | `brain_strengths` | Proven patterns ranked by success |
128
- | `brain_global_patterns` | Cross-project patterns from global pool |
129
- | `capture_quick` | Capture web findings to vault for next time |
128
+ | Op | When to Use |
129
+ | ----------------------------- | ----------------------------------------------------- |
130
+ | `search_intelligent` | Default semantic search — broadest and smartest |
131
+ | `search` | Structured search with filters (type, tags, category) |
132
+ | `vault_tags` | Browse all tags — discover knowledge landscape |
133
+ | `vault_domains` | Browse all domains — see what areas are covered |
134
+ | `vault_recent` | Recently modified entries — what's fresh |
135
+ | `vault_age_report` | Find stale entries needing refresh |
136
+ | `memory_cross_project_search` | Search across linked projects |
137
+ | `project_linked_projects` | See what projects are connected |
138
+ | `brain_strengths` | Proven patterns ranked by success |
139
+ | `brain_global_patterns` | Cross-project patterns from global pool |
140
+ | `capture_quick` | Capture web findings to vault for next time |
@@ -45,37 +45,43 @@ Skip any step = lying, not verifying
45
45
  After passing all verification commands, run system diagnostics:
46
46
 
47
47
  ### Health Check
48
+
48
49
  ```
49
50
  YOUR_AGENT_core op:admin_health
50
51
  ```
52
+
51
53
  Catches issues tests might miss — vault corruption, stale caches, configuration drift.
52
54
 
53
55
  ### Full Diagnostic
56
+
54
57
  ```
55
58
  YOUR_AGENT_core op:admin_diagnostic
56
59
  ```
60
+
57
61
  Comprehensive system check — module status, database integrity, cache health, configuration validity.
58
62
 
59
63
  ### Vault Analytics
64
+
60
65
  ```
61
66
  YOUR_AGENT_core op:admin_vault_analytics
62
67
  ```
68
+
63
69
  Verify knowledge quality metrics — are capture rates healthy? Any degradation?
64
70
 
65
71
  If any check reports problems, address them before claiming completion.
66
72
 
67
73
  ## Common Failures
68
74
 
69
- | Claim | Requires | Not Sufficient |
70
- |-------|----------|----------------|
71
- | Tests pass | Test command output: 0 failures | Previous run, "should pass" |
72
- | Linter clean | Linter output: 0 errors | Partial check, extrapolation |
73
- | Build succeeds | Build command: exit 0 | Linter passing, logs look good |
74
- | Bug fixed | Test original symptom: passes | Code changed, assumed fixed |
75
- | Regression test works | Red-green cycle verified | Test passes once |
76
- | Agent completed | VCS diff shows changes | Agent reports "success" |
77
- | Requirements met | Line-by-line checklist | Tests passing |
78
- | Agent healthy | `admin_diagnostic` clean | "No errors in logs" |
75
+ | Claim | Requires | Not Sufficient |
76
+ | --------------------- | ------------------------------- | ------------------------------ |
77
+ | Tests pass | Test command output: 0 failures | Previous run, "should pass" |
78
+ | Linter clean | Linter output: 0 errors | Partial check, extrapolation |
79
+ | Build succeeds | Build command: exit 0 | Linter passing, logs look good |
80
+ | Bug fixed | Test original symptom: passes | Code changed, assumed fixed |
81
+ | Regression test works | Red-green cycle verified | Test passes once |
82
+ | Agent completed | VCS diff shows changes | Agent reports "success" |
83
+ | Requirements met | Line-by-line checklist | Tests passing |
84
+ | Agent healthy | `admin_diagnostic` clean | "No errors in logs" |
79
85
 
80
86
  ## Red Flags - STOP
81
87
 
@@ -90,44 +96,49 @@ If any check reports problems, address them before claiming completion.
90
96
 
91
97
  ## Rationalization Prevention
92
98
 
93
- | Excuse | Reality |
94
- |--------|---------|
95
- | "Should work now" | RUN the verification |
96
- | "I'm confident" | Confidence ≠ evidence |
97
- | "Just this once" | No exceptions |
98
- | "Linter passed" | Linter ≠ compiler |
99
- | "Agent said success" | Verify independently |
100
- | "I'm tired" | Exhaustion ≠ excuse |
101
- | "Partial check is enough" | Partial proves nothing |
102
- | "Different words so rule doesn't apply" | Spirit over letter |
99
+ | Excuse | Reality |
100
+ | --------------------------------------- | ---------------------- |
101
+ | "Should work now" | RUN the verification |
102
+ | "I'm confident" | Confidence ≠ evidence |
103
+ | "Just this once" | No exceptions |
104
+ | "Linter passed" | Linter ≠ compiler |
105
+ | "Agent said success" | Verify independently |
106
+ | "I'm tired" | Exhaustion ≠ excuse |
107
+ | "Partial check is enough" | Partial proves nothing |
108
+ | "Different words so rule doesn't apply" | Spirit over letter |
103
109
 
104
110
  ## Key Patterns
105
111
 
106
112
  **Tests:**
113
+
107
114
  ```
108
115
  [Run test command] [See: 34/34 pass] "All tests pass"
109
116
  NOT: "Should pass now" / "Looks correct"
110
117
  ```
111
118
 
112
119
  **Regression tests (TDD Red-Green):**
120
+
113
121
  ```
114
122
  Write -> Run (pass) -> Revert fix -> Run (MUST FAIL) -> Restore -> Run (pass)
115
123
  NOT: "I've written a regression test" (without red-green verification)
116
124
  ```
117
125
 
118
126
  **Build:**
127
+
119
128
  ```
120
129
  [Run build] [See: exit 0] "Build passes"
121
130
  NOT: "Linter passed" (linter doesn't check compilation)
122
131
  ```
123
132
 
124
133
  **Requirements:**
134
+
125
135
  ```
126
136
  Re-read plan -> Create checklist -> Verify each -> Report gaps or completion
127
137
  NOT: "Tests pass, phase complete"
128
138
  ```
129
139
 
130
140
  **Agent delegation:**
141
+
131
142
  ```
132
143
  Agent reports success -> Check VCS diff -> Verify changes -> Report actual state
133
144
  NOT: Trust agent report
@@ -149,6 +160,7 @@ This ensures the next session has context about what was verified and completed.
149
160
  ## When To Apply
150
161
 
151
162
  **ALWAYS before:**
163
+
152
164
  - ANY variation of success/completion claims
153
165
  - ANY expression of satisfaction
154
166
  - ANY positive statement about work state
@@ -162,9 +174,9 @@ Run the command. Read the output. THEN claim the result. This is non-negotiable.
162
174
 
163
175
  ## Agent Tools Reference
164
176
 
165
- | Op | When to Use |
166
- |----|-------------|
167
- | `admin_health` | Quick system health check |
168
- | `admin_diagnostic` | Comprehensive system diagnostic |
169
- | `admin_vault_analytics` | Knowledge quality metrics |
170
- | `session_capture` | Persist verified completion context |
177
+ | Op | When to Use |
178
+ | ----------------------- | ----------------------------------- |
179
+ | `admin_health` | Quick system health check |
180
+ | `admin_diagnostic` | Comprehensive system diagnostic |
181
+ | `admin_vault_analytics` | Knowledge quality metrics |
182
+ | `session_capture` | Persist verified completion context |
@@ -22,6 +22,7 @@ Assume they are a skilled developer, but know almost nothing about our toolset o
22
22
  **Never write a plan from scratch.** Always search for existing knowledge first.
23
23
 
24
24
  ### 1. Vault First
25
+
25
26
  Check the vault for relevant implementation patterns:
26
27
 
27
28
  ```
@@ -30,6 +31,7 @@ YOUR_AGENT_core op:search_intelligent
30
31
  ```
31
32
 
32
33
  Look for:
34
+
33
35
  - **Implementation patterns** — proven approaches for similar features
34
36
  - **Anti-patterns** — approaches that failed and should be avoided
35
37
  - **Testing patterns** — how similar features were tested
@@ -48,13 +50,16 @@ YOUR_AGENT_core op:vault_tags
48
50
  ```
49
51
 
50
52
  ### 2. Web Search Second
53
+
51
54
  If the vault doesn't have implementation guidance, search the web:
55
+
52
56
  - **Libraries and tools** — is there a package that does this already?
53
57
  - **Reference implementations** — how did other projects solve this?
54
58
  - **API documentation** — official docs for libraries you'll use
55
59
  - **Known issues** — pitfalls others ran into
56
60
 
57
61
  ### 3. Then Write the Plan
62
+
58
63
  Incorporate vault insights and web findings into the plan. Reference specific vault entries and documentation links when they inform a step. A plan informed by existing knowledge is dramatically better than one written from first principles.
59
64
 
60
65
  ## Create a Tracked Plan
@@ -123,6 +128,7 @@ This generates individual tasks from the plan steps, ready for execution trackin
123
128
  ## Bite-Sized Task Granularity
124
129
 
125
130
  **Each step is one action (2-5 minutes):**
131
+
126
132
  - "Write the failing test" - step
127
133
  - "Run it to make sure it fails" - step
128
134
  - "Implement the minimal code to make the test pass" - step
@@ -150,6 +156,7 @@ This generates individual tasks from the plan steps, ready for execution trackin
150
156
  ## Task Structure
151
157
 
152
158
  Each task uses this format:
159
+
153
160
  - Files: Create / Modify / Test paths
154
161
  - Step 1: Write the failing test (with code)
155
162
  - Step 2: Run test to verify it fails (with expected output)
@@ -158,6 +165,7 @@ Each task uses this format:
158
165
  - Step 5: Commit (with exact git commands)
159
166
 
160
167
  ## Remember
168
+
161
169
  - Exact file paths always
162
170
  - Complete code in plan (not "add validation")
163
171
  - Exact commands with expected output
@@ -192,16 +200,16 @@ Which approach?"
192
200
 
193
201
  ## Agent Tools Reference
194
202
 
195
- | Op | When to Use |
196
- |----|-------------|
197
- | `search_intelligent` | Find relevant patterns before planning |
198
- | `brain_strengths` | Check proven approaches |
199
- | `vault_domains` / `vault_tags` | Browse knowledge landscape |
200
- | `create_plan` | Create tracked, persistent plan |
201
- | `plan_grade` | Grade plan quality |
202
- | `plan_auto_improve` | Auto-fix plan weaknesses |
203
- | `plan_meets_grade` | Verify grade target reached |
204
- | `plan_iterate` | Iterate on draft with feedback |
205
- | `plan_split` | Split plan into trackable tasks |
206
- | `approve_plan` | Lock in approved plan |
207
- | `plan_stats` | Overview of plan metrics |
203
+ | Op | When to Use |
204
+ | ------------------------------ | -------------------------------------- |
205
+ | `search_intelligent` | Find relevant patterns before planning |
206
+ | `brain_strengths` | Check proven approaches |
207
+ | `vault_domains` / `vault_tags` | Browse knowledge landscape |
208
+ | `create_plan` | Create tracked, persistent plan |
209
+ | `plan_grade` | Grade plan quality |
210
+ | `plan_auto_improve` | Auto-fix plan weaknesses |
211
+ | `plan_meets_grade` | Verify grade target reached |
212
+ | `plan_iterate` | Iterate on draft with feedback |
213
+ | `plan_split` | Split plan into trackable tasks |
214
+ | `approve_plan` | Lock in approved plan |
215
+ | `plan_stats` | Overview of plan metrics |