k0ntext 3.0.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 (239) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +623 -0
  3. package/bin/k0ntext.js +12 -0
  4. package/dist/agents/cleanup-agent.d.ts +39 -0
  5. package/dist/agents/cleanup-agent.d.ts.map +1 -0
  6. package/dist/agents/cleanup-agent.js +56 -0
  7. package/dist/agents/cleanup-agent.js.map +1 -0
  8. package/dist/agents/performance-agent.d.ts +37 -0
  9. package/dist/agents/performance-agent.d.ts.map +1 -0
  10. package/dist/agents/performance-agent.js +91 -0
  11. package/dist/agents/performance-agent.js.map +1 -0
  12. package/dist/analyzer/index.d.ts +5 -0
  13. package/dist/analyzer/index.d.ts.map +1 -0
  14. package/dist/analyzer/index.js +5 -0
  15. package/dist/analyzer/index.js.map +1 -0
  16. package/dist/analyzer/intelligent-analyzer.d.ts +111 -0
  17. package/dist/analyzer/intelligent-analyzer.d.ts.map +1 -0
  18. package/dist/analyzer/intelligent-analyzer.js +537 -0
  19. package/dist/analyzer/intelligent-analyzer.js.map +1 -0
  20. package/dist/cli/commands/cleanup.d.ts +3 -0
  21. package/dist/cli/commands/cleanup.d.ts.map +1 -0
  22. package/dist/cli/commands/cleanup.js +24 -0
  23. package/dist/cli/commands/cleanup.js.map +1 -0
  24. package/dist/cli/commands/export.d.ts +9 -0
  25. package/dist/cli/commands/export.d.ts.map +1 -0
  26. package/dist/cli/commands/export.js +72 -0
  27. package/dist/cli/commands/export.js.map +1 -0
  28. package/dist/cli/commands/import.d.ts +9 -0
  29. package/dist/cli/commands/import.d.ts.map +1 -0
  30. package/dist/cli/commands/import.js +62 -0
  31. package/dist/cli/commands/import.js.map +1 -0
  32. package/dist/cli/commands/performance.d.ts +9 -0
  33. package/dist/cli/commands/performance.d.ts.map +1 -0
  34. package/dist/cli/commands/performance.js +36 -0
  35. package/dist/cli/commands/performance.js.map +1 -0
  36. package/dist/cli/commands/validate.d.ts +9 -0
  37. package/dist/cli/commands/validate.d.ts.map +1 -0
  38. package/dist/cli/commands/validate.js +82 -0
  39. package/dist/cli/commands/validate.js.map +1 -0
  40. package/dist/cli/commands/watch.d.ts +9 -0
  41. package/dist/cli/commands/watch.d.ts.map +1 -0
  42. package/dist/cli/commands/watch.js +72 -0
  43. package/dist/cli/commands/watch.js.map +1 -0
  44. package/dist/cli/generate.d.ts +3 -0
  45. package/dist/cli/generate.d.ts.map +1 -0
  46. package/dist/cli/generate.js +194 -0
  47. package/dist/cli/generate.js.map +1 -0
  48. package/dist/cli/index.d.ts +9 -0
  49. package/dist/cli/index.d.ts.map +1 -0
  50. package/dist/cli/index.js +448 -0
  51. package/dist/cli/index.js.map +1 -0
  52. package/dist/cli/sync.d.ts +26 -0
  53. package/dist/cli/sync.d.ts.map +1 -0
  54. package/dist/cli/sync.js +163 -0
  55. package/dist/cli/sync.js.map +1 -0
  56. package/dist/config/cleanup-config.d.ts +26 -0
  57. package/dist/config/cleanup-config.d.ts.map +1 -0
  58. package/dist/config/cleanup-config.js +21 -0
  59. package/dist/config/cleanup-config.js.map +1 -0
  60. package/dist/db/client.d.ts +284 -0
  61. package/dist/db/client.d.ts.map +1 -0
  62. package/dist/db/client.js +688 -0
  63. package/dist/db/client.js.map +1 -0
  64. package/dist/db/index.d.ts +6 -0
  65. package/dist/db/index.d.ts.map +1 -0
  66. package/dist/db/index.js +6 -0
  67. package/dist/db/index.js.map +1 -0
  68. package/dist/db/schema.d.ts +41 -0
  69. package/dist/db/schema.d.ts.map +1 -0
  70. package/dist/db/schema.js +226 -0
  71. package/dist/db/schema.js.map +1 -0
  72. package/dist/embeddings/index.d.ts +5 -0
  73. package/dist/embeddings/index.d.ts.map +1 -0
  74. package/dist/embeddings/index.js +5 -0
  75. package/dist/embeddings/index.js.map +1 -0
  76. package/dist/embeddings/openrouter.d.ts +133 -0
  77. package/dist/embeddings/openrouter.d.ts.map +1 -0
  78. package/dist/embeddings/openrouter.js +455 -0
  79. package/dist/embeddings/openrouter.js.map +1 -0
  80. package/dist/index.d.ts +14 -0
  81. package/dist/index.d.ts.map +1 -0
  82. package/dist/index.js +18 -0
  83. package/dist/index.js.map +1 -0
  84. package/dist/mcp.d.ts +29 -0
  85. package/dist/mcp.d.ts.map +1 -0
  86. package/dist/mcp.js +257 -0
  87. package/dist/mcp.js.map +1 -0
  88. package/docs/ARCHIVE/MIGRATE_TO_NEW_REPO.md +222 -0
  89. package/docs/ARCHIVE/MIGRATE_TO_UNIFIED.md +220 -0
  90. package/docs/CLEANUP.md +76 -0
  91. package/docs/MCP_QUICKSTART.md +219 -0
  92. package/docs/QUICKSTART.md +119 -0
  93. package/docs/TROUBLESHOOTING.md +611 -0
  94. package/package.json +100 -0
  95. package/skills/context-optimize/SKILL.md +86 -0
  96. package/skills/implement/SKILL.md +150 -0
  97. package/skills/plan/SKILL.md +143 -0
  98. package/skills/research/SKILL.md +103 -0
  99. package/skills/validate/SKILL.md +62 -0
  100. package/skills/verify-docs/SKILL.md +77 -0
  101. package/src/agents/cleanup-agent.ts +96 -0
  102. package/src/agents/performance-agent.ts +117 -0
  103. package/src/analyzer/index.ts +10 -0
  104. package/src/analyzer/intelligent-analyzer.ts +640 -0
  105. package/src/cli/commands/cleanup.ts +26 -0
  106. package/src/cli/commands/export.ts +82 -0
  107. package/src/cli/commands/import.ts +73 -0
  108. package/src/cli/commands/performance.ts +40 -0
  109. package/src/cli/commands/validate.ts +98 -0
  110. package/src/cli/commands/watch.ts +83 -0
  111. package/src/cli/generate.ts +219 -0
  112. package/src/cli/index.ts +510 -0
  113. package/src/cli/sync.ts +194 -0
  114. package/src/config/cleanup-config.ts +42 -0
  115. package/src/db/client.ts +949 -0
  116. package/src/db/index.ts +19 -0
  117. package/src/db/schema.ts +241 -0
  118. package/src/embeddings/index.ts +11 -0
  119. package/src/embeddings/openrouter.ts +592 -0
  120. package/src/index.ts +57 -0
  121. package/src/mcp.ts +354 -0
  122. package/templates/AI_CONTEXT.md.template +245 -0
  123. package/templates/base/README.md +260 -0
  124. package/templates/base/RPI_WORKFLOW_PLAN.md +325 -0
  125. package/templates/base/agents/api-developer.md +76 -0
  126. package/templates/base/agents/context-engineer.md +525 -0
  127. package/templates/base/agents/core-architect.md +76 -0
  128. package/templates/base/agents/database-ops.md +76 -0
  129. package/templates/base/agents/deployment-ops.md +76 -0
  130. package/templates/base/agents/integration-hub.md +76 -0
  131. package/templates/base/analytics/README.md +114 -0
  132. package/templates/base/automation/config.json +58 -0
  133. package/templates/base/automation/generators/code-mapper.js +308 -0
  134. package/templates/base/automation/generators/index-builder.js +321 -0
  135. package/templates/base/automation/hooks/post-commit.sh +83 -0
  136. package/templates/base/automation/hooks/pre-commit.sh +103 -0
  137. package/templates/base/ci-templates/README.md +108 -0
  138. package/templates/base/ci-templates/github-actions/context-check.yml +144 -0
  139. package/templates/base/ci-templates/github-actions/validate-docs.yml +105 -0
  140. package/templates/base/commands/analytics.md +238 -0
  141. package/templates/base/commands/auto-sync.md +172 -0
  142. package/templates/base/commands/collab.md +194 -0
  143. package/templates/base/commands/context-optimize.md +226 -0
  144. package/templates/base/commands/help.md +485 -0
  145. package/templates/base/commands/rpi-implement.md +164 -0
  146. package/templates/base/commands/rpi-plan.md +147 -0
  147. package/templates/base/commands/rpi-research.md +145 -0
  148. package/templates/base/commands/session-resume.md +144 -0
  149. package/templates/base/commands/session-save.md +112 -0
  150. package/templates/base/commands/validate-all.md +77 -0
  151. package/templates/base/commands/verify-docs-current.md +86 -0
  152. package/templates/base/config/base.json +57 -0
  153. package/templates/base/config/environments/development.json +13 -0
  154. package/templates/base/config/environments/production.json +17 -0
  155. package/templates/base/config/environments/staging.json +13 -0
  156. package/templates/base/config/local.json.example +21 -0
  157. package/templates/base/context/.meta/generated-at.json +18 -0
  158. package/templates/base/context/ARCHITECTURE_SNAPSHOT.md +156 -0
  159. package/templates/base/context/CODE_TO_WORKFLOW_MAP.md +94 -0
  160. package/templates/base/context/FILE_OWNERSHIP.md +57 -0
  161. package/templates/base/context/INTEGRATION_POINTS.md +92 -0
  162. package/templates/base/context/KNOWN_GOTCHAS.md +195 -0
  163. package/templates/base/context/TESTING_MAP.md +95 -0
  164. package/templates/base/context/WORKFLOW_INDEX.md +129 -0
  165. package/templates/base/context/workflows/WORKFLOW_TEMPLATE.md +294 -0
  166. package/templates/base/indexes/agents/CAPABILITY_MATRIX.md +255 -0
  167. package/templates/base/indexes/agents/CATEGORY_INDEX.md +44 -0
  168. package/templates/base/indexes/code/CATEGORY_INDEX.md +38 -0
  169. package/templates/base/indexes/routing/CATEGORY_INDEX.md +39 -0
  170. package/templates/base/indexes/search/CATEGORY_INDEX.md +39 -0
  171. package/templates/base/indexes/workflows/CATEGORY_INDEX.md +38 -0
  172. package/templates/base/knowledge/README.md +98 -0
  173. package/templates/base/knowledge/sessions/README.md +88 -0
  174. package/templates/base/knowledge/sessions/TEMPLATE.md +150 -0
  175. package/templates/base/knowledge/shared/decisions/0001-adopt-context-engineering.md +144 -0
  176. package/templates/base/knowledge/shared/decisions/README.md +49 -0
  177. package/templates/base/knowledge/shared/decisions/TEMPLATE.md +123 -0
  178. package/templates/base/knowledge/shared/patterns/README.md +62 -0
  179. package/templates/base/knowledge/shared/patterns/TEMPLATE.md +120 -0
  180. package/templates/base/plans/PLAN_TEMPLATE.md +316 -0
  181. package/templates/base/plans/active/.gitkeep +0 -0
  182. package/templates/base/plans/completed/.gitkeep +0 -0
  183. package/templates/base/research/RESEARCH_TEMPLATE.md +245 -0
  184. package/templates/base/research/active/.gitkeep +0 -0
  185. package/templates/base/research/completed/.gitkeep +0 -0
  186. package/templates/base/schemas/agent.schema.json +141 -0
  187. package/templates/base/schemas/anchors.schema.json +54 -0
  188. package/templates/base/schemas/automation.schema.json +93 -0
  189. package/templates/base/schemas/command.schema.json +134 -0
  190. package/templates/base/schemas/hashes.schema.json +40 -0
  191. package/templates/base/schemas/manifest.schema.json +117 -0
  192. package/templates/base/schemas/plan.schema.json +136 -0
  193. package/templates/base/schemas/research.schema.json +115 -0
  194. package/templates/base/schemas/roles.schema.json +34 -0
  195. package/templates/base/schemas/session.schema.json +77 -0
  196. package/templates/base/schemas/settings.schema.json +244 -0
  197. package/templates/base/schemas/staleness.schema.json +53 -0
  198. package/templates/base/schemas/team-config.schema.json +42 -0
  199. package/templates/base/schemas/workflow.schema.json +126 -0
  200. package/templates/base/session/checkpoints/.gitkeep +2 -0
  201. package/templates/base/session/current/state.json +20 -0
  202. package/templates/base/session/history/.gitkeep +2 -0
  203. package/templates/base/settings.json +3 -0
  204. package/templates/base/standards/COMPATIBILITY.md +219 -0
  205. package/templates/base/standards/EXTENSION_GUIDELINES.md +280 -0
  206. package/templates/base/standards/QUALITY_CHECKLIST.md +211 -0
  207. package/templates/base/standards/README.md +66 -0
  208. package/templates/base/sync/anchors.json +6 -0
  209. package/templates/base/sync/hashes.json +6 -0
  210. package/templates/base/sync/staleness.json +10 -0
  211. package/templates/base/team/README.md +168 -0
  212. package/templates/base/team/config.json +79 -0
  213. package/templates/base/team/roles.json +145 -0
  214. package/templates/base/tools/bin/claude-context.js +151 -0
  215. package/templates/base/tools/lib/anchor-resolver.js +276 -0
  216. package/templates/base/tools/lib/config-loader.js +363 -0
  217. package/templates/base/tools/lib/detector.js +350 -0
  218. package/templates/base/tools/lib/diagnose.js +206 -0
  219. package/templates/base/tools/lib/drift-detector.js +373 -0
  220. package/templates/base/tools/lib/errors.js +199 -0
  221. package/templates/base/tools/lib/index.js +36 -0
  222. package/templates/base/tools/lib/init.js +192 -0
  223. package/templates/base/tools/lib/logger.js +230 -0
  224. package/templates/base/tools/lib/placeholder.js +201 -0
  225. package/templates/base/tools/lib/session-manager.js +354 -0
  226. package/templates/base/tools/lib/validate.js +521 -0
  227. package/templates/base/tools/package.json +49 -0
  228. package/templates/handlebars/aider-config.hbs +146 -0
  229. package/templates/handlebars/antigravity.hbs +377 -0
  230. package/templates/handlebars/claude.hbs +183 -0
  231. package/templates/handlebars/cline.hbs +62 -0
  232. package/templates/handlebars/continue-config.hbs +116 -0
  233. package/templates/handlebars/copilot.hbs +130 -0
  234. package/templates/handlebars/partials/gotcha-list.hbs +11 -0
  235. package/templates/handlebars/partials/header.hbs +3 -0
  236. package/templates/handlebars/partials/workflow-summary.hbs +16 -0
  237. package/templates/handlebars/windsurf-rules.hbs +69 -0
  238. package/templates/hooks/post-commit.hbs +28 -0
  239. package/templates/hooks/pre-commit.hbs +46 -0
@@ -0,0 +1,377 @@
1
+ {{!--
2
+ Google Antigravity Template
3
+ Generates multiple files for .agent/ directory:
4
+ - rules/*.md - Workspace rules by category
5
+ - workflows/*.md - On-demand /commands
6
+ - skills/*.md - Modular capabilities
7
+ --}}
8
+
9
+ {{!-- ============================================================ --}}
10
+ {{!-- RULES: Main Project Identity --}}
11
+ {{!-- ============================================================ --}}
12
+ {{{fileStart "rules/identity.md"}}}
13
+ <!-- Auto-generated by AI Context Engineering v{{metadata.generator_version}} -->
14
+ <!-- Generated: {{metadata.timestamp}} -->
15
+
16
+ # {{project.name}} - Project Identity
17
+
18
+ ## Overview
19
+
20
+ - **Name:** {{project.name}}
21
+ - **Description:** {{project.description}}
22
+ - **Tech Stack:** {{join project.tech_stack ", "}}
23
+ - **Primary Language:** {{project.primary_language}}
24
+
25
+ ## Quick Commands
26
+
27
+ {{#each commands}}
28
+ - **{{@key}}:** `{{this}}`
29
+ {{/each}}
30
+
31
+ ## Architecture
32
+
33
+ **Pattern:** {{architecture.pattern}}
34
+
35
+ {{#if architecture.layers}}
36
+ **Layers:**
37
+ {{#each architecture.layers}}
38
+ - `{{path}}` - {{purpose}}
39
+ {{/each}}
40
+ {{/if}}
41
+
42
+ ## Key Entry Points
43
+
44
+ {{#each key_files.entry_points}}
45
+ - `{{this}}`
46
+ {{/each}}
47
+
48
+ {{#if environment.required}}
49
+ ## Environment Variables
50
+
51
+ **Required:**
52
+ {{#each environment.required}}
53
+ - `{{this}}`
54
+ {{/each}}
55
+
56
+ {{#if environment.optional}}
57
+ **Optional:**
58
+ {{#each environment.optional}}
59
+ - `{{this}}`
60
+ {{/each}}
61
+ {{/if}}
62
+ {{/if}}
63
+
64
+ ---
65
+
66
+ {{{coordination.footer}}}
67
+ {{{fileEnd}}}
68
+
69
+ {{!-- ============================================================ --}}
70
+ {{!-- RULES: Architecture Details --}}
71
+ {{!-- ============================================================ --}}
72
+ {{{fileStart "rules/architecture.md"}}}
73
+ <!-- Auto-generated by AI Context Engineering -->
74
+
75
+ # Architecture Rules for {{project.name}}
76
+
77
+ ## Pattern: {{architecture.pattern}}
78
+
79
+ {{#each architecture.layers}}
80
+ ### Layer: {{name}}
81
+
82
+ **Path:** `{{path}}`
83
+ **Purpose:** {{purpose}}
84
+
85
+ {{/each}}
86
+
87
+ ## Key Files by Category
88
+
89
+ {{#if key_files.entry_points}}
90
+ ### Entry Points
91
+ {{#each key_files.entry_points}}
92
+ - `{{this}}`
93
+ {{/each}}
94
+ {{/if}}
95
+
96
+ {{#if key_files.api_routes}}
97
+ ### API Routes
98
+ {{#each key_files.api_routes}}
99
+ - `{{this}}`
100
+ {{/each}}
101
+ {{/if}}
102
+
103
+ {{#if key_files.config}}
104
+ ### Configuration
105
+ {{#each key_files.config}}
106
+ - `{{this}}`
107
+ {{/each}}
108
+ {{/if}}
109
+
110
+ ---
111
+
112
+ {{{coordination.footer}}}
113
+ {{{fileEnd}}}
114
+
115
+ {{!-- ============================================================ --}}
116
+ {{!-- RULES: Gotchas (Critical Issues) --}}
117
+ {{!-- ============================================================ --}}
118
+ {{{fileStart "rules/gotchas.md"}}}
119
+ <!-- Auto-generated by AI Context Engineering -->
120
+
121
+ # Critical Gotchas for {{project.name}}
122
+
123
+ These are known issues and pitfalls. Review before making changes.
124
+
125
+ {{#if gotchas}}
126
+ {{#each gotchas}}
127
+ ## {{id}}: {{title}}
128
+
129
+ **Severity:** {{severity}}
130
+
131
+ **Symptom:** {{symptom}}
132
+
133
+ **Fix:**
134
+ ```
135
+ {{fix}}
136
+ ```
137
+
138
+ ---
139
+
140
+ {{/each}}
141
+ {{else}}
142
+ *No gotchas documented yet. Add as discovered.*
143
+ {{/if}}
144
+
145
+ ---
146
+
147
+ {{{coordination.footer}}}
148
+ {{{fileEnd}}}
149
+
150
+ {{!-- ============================================================ --}}
151
+ {{!-- RULES: Constraints --}}
152
+ {{!-- ============================================================ --}}
153
+ {{{fileStart "rules/constraints.md"}}}
154
+ <!-- Auto-generated by AI Context Engineering -->
155
+
156
+ # Critical Constraints for {{project.name}}
157
+
158
+ These rules MUST be followed. Violations may cause production issues.
159
+
160
+ {{#if critical_constraints}}
161
+ {{#each critical_constraints}}
162
+ {{@index}}. {{this}}
163
+ {{/each}}
164
+ {{else}}
165
+ *No constraints documented yet. Add critical rules as identified.*
166
+ {{/if}}
167
+
168
+ ## Summary
169
+
170
+ - Total Constraints: {{length critical_constraints}}
171
+ - Gotchas: {{length gotchas}}
172
+ - Workflows: {{length workflows}}
173
+
174
+ ---
175
+
176
+ {{{coordination.footer}}}
177
+ {{{fileEnd}}}
178
+
179
+ {{!-- ============================================================ --}}
180
+ {{!-- RULES: Workflows Summary --}}
181
+ {{!-- ============================================================ --}}
182
+ {{{fileStart "rules/workflows.md"}}}
183
+ <!-- Auto-generated by AI Context Engineering -->
184
+
185
+ # Available Workflows for {{project.name}}
186
+
187
+ {{#if workflows}}
188
+ {{#each workflows}}
189
+ ## {{name}}
190
+
191
+ **Category:** {{category}} | **Complexity:** {{complexity}}
192
+
193
+ {{description}}
194
+
195
+ {{#if entry_points}}
196
+ **Entry Points:**
197
+ {{#each (first entry_points 5)}}
198
+ - `{{endpoint}}` - {{file}}:{{line}}
199
+ {{/each}}
200
+ {{/if}}
201
+
202
+ ---
203
+
204
+ {{/each}}
205
+ {{else}}
206
+ *No workflows discovered. Run AI analysis to populate.*
207
+ {{/if}}
208
+
209
+ ---
210
+
211
+ {{{coordination.footer}}}
212
+ {{{fileEnd}}}
213
+
214
+ {{!-- ============================================================ --}}
215
+ {{!-- WORKFLOWS: Command Files --}}
216
+ {{!-- ============================================================ --}}
217
+
218
+ {{{fileStart "workflows/run.md"}}}
219
+ <!-- Auto-generated by AI Context Engineering -->
220
+
221
+ # /run - Start Development Server
222
+
223
+ ## Command
224
+ ```bash
225
+ {{commands.dev}}
226
+ ```
227
+
228
+ ## Description
229
+ Starts the {{project.name}} development server.
230
+
231
+ ## Prerequisites
232
+ - All dependencies installed
233
+ - Environment variables configured
234
+
235
+ ## Related
236
+ - See `rules/identity.md` for full command list
237
+
238
+ ---
239
+
240
+ {{{coordination.footer}}}
241
+ {{{fileEnd}}}
242
+
243
+ {{{fileStart "workflows/test.md"}}}
244
+ <!-- Auto-generated by AI Context Engineering -->
245
+
246
+ # /test - Run Test Suite
247
+
248
+ ## Command
249
+ ```bash
250
+ {{commands.test}}
251
+ ```
252
+
253
+ ## Description
254
+ Runs the test suite for {{project.name}}.
255
+
256
+ ## Tips
257
+ - Run before committing changes
258
+ - Check test coverage reports
259
+
260
+ ---
261
+
262
+ {{{coordination.footer}}}
263
+ {{{fileEnd}}}
264
+
265
+ {{{fileStart "workflows/build.md"}}}
266
+ <!-- Auto-generated by AI Context Engineering -->
267
+
268
+ # /build - Build Project
269
+
270
+ ## Command
271
+ ```bash
272
+ {{commands.build}}
273
+ ```
274
+
275
+ ## Description
276
+ Builds {{project.name}} for production.
277
+
278
+ ---
279
+
280
+ {{{coordination.footer}}}
281
+ {{{fileEnd}}}
282
+
283
+ {{!-- ============================================================ --}}
284
+ {{!-- SKILLS: Modular Capabilities --}}
285
+ {{!-- ============================================================ --}}
286
+
287
+ {{{fileStart "skills/debugging.md"}}}
288
+ <!-- Auto-generated by AI Context Engineering -->
289
+
290
+ # Debugging Skill for {{project.name}}
291
+
292
+ ## When to Use
293
+ Activate this skill when debugging issues in {{project.name}}.
294
+
295
+ {{#if gotchas}}
296
+ ## Known Issues
297
+
298
+ {{#each gotchas}}
299
+ ### {{id}}: {{title}}
300
+
301
+ **Severity:** {{severity}}
302
+
303
+ **Symptom:** {{symptom}}
304
+
305
+ **Quick Fix:**
306
+ ```
307
+ {{truncate fix 200}}
308
+ ```
309
+
310
+ {{/each}}
311
+ {{/if}}
312
+
313
+ ## Debug Commands
314
+
315
+ ```bash
316
+ # Start dev server
317
+ {{commands.dev}}
318
+
319
+ # Run tests
320
+ {{commands.test}}
321
+ ```
322
+
323
+ ## Tips
324
+
325
+ - Check application logs for errors
326
+ - Review stack traces carefully
327
+ - Verify environment configuration
328
+
329
+ ---
330
+
331
+ {{{coordination.footer}}}
332
+ {{{fileEnd}}}
333
+
334
+ {{{fileStart "skills/implementation.md"}}}
335
+ <!-- Auto-generated by AI Context Engineering -->
336
+
337
+ # Implementation Skill for {{project.name}}
338
+
339
+ ## When to Use
340
+ Activate this skill when implementing new features in {{project.name}}.
341
+
342
+ ## Architecture Overview
343
+
344
+ **Pattern:** {{architecture.pattern}}
345
+
346
+ {{#if architecture.layers}}
347
+ **Layers:**
348
+ {{#each architecture.layers}}
349
+ - `{{path}}` - {{purpose}}
350
+ {{/each}}
351
+ {{/if}}
352
+
353
+ ## Code Standards
354
+
355
+ 1. Follow existing patterns in the codebase
356
+ 2. Add tests for new functionality
357
+ 3. Update documentation as needed
358
+ 4. Review gotchas before modifying critical areas
359
+
360
+ ## Key Files to Reference
361
+
362
+ {{#each key_files.entry_points}}
363
+ - `{{this}}`
364
+ {{/each}}
365
+
366
+ {{#if critical_constraints}}
367
+ ## Constraints to Follow
368
+
369
+ {{#each critical_constraints}}
370
+ - {{this}}
371
+ {{/each}}
372
+ {{/if}}
373
+
374
+ ---
375
+
376
+ {{{coordination.footer}}}
377
+ {{{fileEnd}}}
@@ -0,0 +1,183 @@
1
+ {{!-- Claude/Universal AI Context Template --}}
2
+ {{> header}}
3
+
4
+ # AI_CONTEXT.md - {{project.name}}
5
+
6
+ This file provides guidance to AI coding assistants when working with this repository.
7
+
8
+ ---
9
+
10
+ ## Project Identity
11
+
12
+ **Platform:** {{project.description}}
13
+ **Tech Stack:** {{join project.tech_stack ", "}}
14
+ **Primary Language:** {{project.primary_language}}
15
+ **Status:** Development
16
+
17
+ ---
18
+
19
+ ## Essential Commands
20
+
21
+ ### Development
22
+ ```bash
23
+ {{commands.install}}
24
+ {{commands.dev}}
25
+ ```
26
+
27
+ ### Testing
28
+ ```bash
29
+ {{commands.test}}
30
+ ```
31
+
32
+ ### Build
33
+ ```bash
34
+ {{commands.build}}
35
+ ```
36
+
37
+ ---
38
+
39
+ ## Architecture
40
+
41
+ **Pattern:** {{architecture.pattern}}
42
+
43
+ {{#if architecture.layers}}
44
+ ### Layers
45
+
46
+ | Layer | Path | Purpose |
47
+ |-------|------|---------|
48
+ {{#each architecture.layers}}
49
+ | {{name}} | `{{path}}` | {{purpose}} |
50
+ {{/each}}
51
+ {{/if}}
52
+
53
+ ---
54
+
55
+ ## Key Files
56
+
57
+ {{#if key_files.entry_points}}
58
+ ### Entry Points
59
+ {{#each key_files.entry_points}}
60
+ - `{{this}}`
61
+ {{/each}}
62
+ {{/if}}
63
+
64
+ {{#if key_files.api_routes}}
65
+ ### API Routes
66
+ {{#each key_files.api_routes}}
67
+ - `{{this}}`
68
+ {{/each}}
69
+ {{/if}}
70
+
71
+ {{#if key_files.config}}
72
+ ### Configuration
73
+ {{#each key_files.config}}
74
+ - `{{this}}`
75
+ {{/each}}
76
+ {{/if}}
77
+
78
+ ---
79
+
80
+ ## Workflows
81
+
82
+ {{#if workflows}}
83
+ {{#each workflows}}
84
+ ### {{name}}
85
+
86
+ **Category:** {{category}} | **Complexity:** {{complexity}}
87
+
88
+ {{description}}
89
+
90
+ {{#if entry_points}}
91
+ **Entry Points:**
92
+ {{#each entry_points}}
93
+ - `{{endpoint}}` - {{file}}:{{line}} ({{method}})
94
+ {{/each}}
95
+ {{/if}}
96
+
97
+ {{#if files}}
98
+ **Files:**
99
+ {{#each (first files 5)}}
100
+ - `{{this}}`
101
+ {{/each}}
102
+ {{/if}}
103
+
104
+ ---
105
+
106
+ {{/each}}
107
+ {{else}}
108
+ *No workflows discovered. Run AI analysis to populate.*
109
+ {{/if}}
110
+
111
+ ---
112
+
113
+ ## Navigation Rules
114
+
115
+ ### High-Level Task
116
+ 1. Start: [.ai-context/context/WORKFLOW_INDEX.md](./.ai-context/context/WORKFLOW_INDEX.md)
117
+ 2. Load relevant workflow
118
+ 3. Implement with context
119
+
120
+ ### Feature Development
121
+ 1. /rpi-research - Explore codebase
122
+ 2. /rpi-plan - Create blueprint
123
+ 3. /rpi-implement - Execute with tests
124
+
125
+ ---
126
+
127
+ ## Documentation System
128
+
129
+ **Navigation:** 3-level chain (AI_CONTEXT.md → Category → Domain → Detail)
130
+ **Validation:** Run /verify-docs-current after modifications
131
+ **RPI Workflow:** /rpi-research → /rpi-plan → /rpi-implement
132
+
133
+ See: [.ai-context/RPI_WORKFLOW_PLAN.md](./.ai-context/RPI_WORKFLOW_PLAN.md)
134
+
135
+ ---
136
+
137
+ {{#if gotchas}}
138
+ ## Critical Gotchas
139
+
140
+ {{> gotcha-list}}
141
+ {{/if}}
142
+
143
+ ---
144
+
145
+ {{#if critical_constraints}}
146
+ ## Critical Constraints
147
+
148
+ {{#each critical_constraints}}
149
+ - {{this}}
150
+ {{/each}}
151
+ {{/if}}
152
+
153
+ ---
154
+
155
+ {{#if environment.required}}
156
+ ## Environment Variables
157
+
158
+ **Required:**
159
+ {{#each environment.required}}
160
+ - `{{this}}`
161
+ {{/each}}
162
+
163
+ {{#if environment.optional}}
164
+ **Optional:**
165
+ {{#each environment.optional}}
166
+ - `{{this}}`
167
+ {{/each}}
168
+ {{/if}}
169
+ {{/if}}
170
+
171
+ ---
172
+
173
+ ## AI Tools Configuration
174
+
175
+ This context is optimized for:
176
+ - **Claude Code** - Full context reading (this file)
177
+ - **GitHub Copilot** - See `.github/copilot-instructions.md`
178
+ - **Cline** - See `.clinerules`
179
+ - **Antigravity** - See `.agent/` directory
180
+
181
+ ---
182
+
183
+ {{{coordination.footer}}}
@@ -0,0 +1,62 @@
1
+ {{!-- Cline Rules Template - Compact format for Cline VS Code extension --}}
2
+ # {{project.name}} - Cline Rules
3
+ # Generated: {{metadata.timestamp}}
4
+
5
+ [identity]
6
+ name={{project.name}}
7
+ description={{project.description}}
8
+ stack={{join project.tech_stack ", "}}
9
+ lang={{project.primary_language}}
10
+
11
+ [architecture]
12
+ pattern={{architecture.pattern}}
13
+ {{#each architecture.layers}}
14
+ layer.{{@index}}={{name}}={{path}}
15
+ {{/each}}
16
+
17
+ [entry_points]
18
+ {{#each key_files.entry_points}}
19
+ {{@index}}={{this}}
20
+ {{/each}}
21
+
22
+ [commands]
23
+ {{#each commands}}
24
+ {{@key}}={{this}}
25
+ {{/each}}
26
+
27
+ {{#if workflows}}
28
+ [workflows]
29
+ {{#each workflows}}
30
+ {{slugify name}}={{category}}/{{complexity}}
31
+ {{/each}}
32
+ {{/if}}
33
+
34
+ {{#if gotchas}}
35
+ [gotchas]
36
+ {{#each gotchas}}
37
+ {{id}}={{severity}} | {{title}}
38
+ {{/each}}
39
+ {{/if}}
40
+
41
+ {{#if critical_constraints}}
42
+ [constraints]
43
+ {{#each critical_constraints}}
44
+ {{@index}}={{this}}
45
+ {{/each}}
46
+ {{/if}}
47
+
48
+ {{#if environment.required}}
49
+ [env.required]
50
+ {{#each environment.required}}
51
+ {{@index}}={{this}}
52
+ {{/each}}
53
+ {{/if}}
54
+
55
+ {{#if environment.optional}}
56
+ [env.optional]
57
+ {{#each environment.optional}}
58
+ {{@index}}={{this}}
59
+ {{/each}}
60
+ {{/if}}
61
+
62
+ {{{coordination.footer}}}