contextos-agents 1.7.0 → 2.0.0-beta.3

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 (313) hide show
  1. package/.agents/AGENTS.md +16 -50
  2. package/.agents/adapters/aider/export.js +117 -99
  3. package/.agents/adapters/claude/export.js +68 -26
  4. package/.agents/adapters/copilot/export.js +90 -53
  5. package/.agents/adapters/cursor/export.js +100 -104
  6. package/.agents/adapters/drift-detector.js +196 -0
  7. package/.agents/adapters/gemini/export.js +76 -45
  8. package/.agents/adapters/pure-compiler.js +443 -0
  9. package/.agents/adapters/zed/export.js +104 -96
  10. package/.agents/compiled/registry.v2.json +504 -0
  11. package/.agents/compiled/registry.v2.sha256 +1 -0
  12. package/.agents/compiler/manifest-compiler.js +963 -0
  13. package/.agents/compiler/vendor/yaml.LICENSE.txt +13 -0
  14. package/.agents/compiler/vendor/yaml.SBOM.json +6 -0
  15. package/.agents/compiler/vendor/yaml.js +139 -0
  16. package/.agents/core/profiles/init.yaml +25 -0
  17. package/.agents/core/skills/context-manager/skill.yaml +3 -5
  18. package/.agents/core/skills/context-os/SKILL.md +3 -6
  19. package/.agents/core/skills/context-os/skill.yaml +3 -8
  20. package/.agents/core/skills/engineering-workflow/skill.yaml +1 -7
  21. package/.agents/core/skills/gemini-precision/skill.yaml +1 -6
  22. package/.agents/core/skills/gstack-roles/skill.yaml +3 -6
  23. package/.agents/core/skills/ponytail-mindset/skill.yaml +1 -7
  24. package/.agents/core/skills/security/skill.yaml +15 -3
  25. package/.agents/ctx.js +537 -112
  26. package/.agents/customization-dx.js +282 -0
  27. package/.agents/doctor.js +855 -66
  28. package/.agents/filesystem/index.js +71 -0
  29. package/.agents/filesystem/journaled-transaction.js +451 -0
  30. package/.agents/filesystem/lockfile-v2.js +275 -0
  31. package/.agents/filesystem/platform-hardening.js +222 -0
  32. package/.agents/filesystem/project-lock.js +218 -0
  33. package/.agents/filesystem/safe-path.js +256 -0
  34. package/.agents/generated/claude/skills/context-os/SKILL.md +1 -1
  35. package/.agents/generated/gemini/skills/context-os/SKILL.md +2 -2
  36. package/.agents/plugins/contextos/plugin.json +1 -1
  37. package/.agents/plugins.js +278 -64
  38. package/.agents/profiles.js +486 -51
  39. package/.agents/resolver/canonical-resolver.js +1348 -0
  40. package/.agents/resolver.js +50 -534
  41. package/.agents/rules/rule-catalog.js +525 -0
  42. package/.agents/schemas/attestation.review.v1.json +111 -0
  43. package/.agents/schemas/attestation.verification.v1.json +85 -0
  44. package/.agents/schemas/lockfile.v2.schema.json +134 -0
  45. package/.agents/schemas/profile.v2.schema.json +114 -0
  46. package/.agents/schemas/runtime.thread.v1.json +192 -0
  47. package/.agents/schemas/skill.manifest.v2.json +177 -0
  48. package/.agents/schemas/verification.spec.v1.json +39 -0
  49. package/.agents/schemas/workspace.graph.schema.json +106 -0
  50. package/.agents/skills-index.json +6 -166
  51. package/.agents/stats.js +9 -9
  52. package/.agents/transaction-core/event-store.js +288 -0
  53. package/.agents/transaction-core/idempotency.js +129 -0
  54. package/.agents/transaction-core/ipc-lock.js +311 -0
  55. package/.agents/transaction-core/plugin-supply-chain-bundle.js +436 -0
  56. package/.agents/validate.js +44 -1
  57. package/.agents/watch.js +354 -102
  58. package/.agents/workspace/workspace-graph.js +778 -0
  59. package/README.md +59 -387
  60. package/benchmarks/v2/analysis/statistics.js +140 -0
  61. package/benchmarks/v2/analysis/stats.js +69 -0
  62. package/benchmarks/v2/arms/arm-definitions.js +79 -0
  63. package/benchmarks/v2/dataset.schema.json +34 -0
  64. package/benchmarks/v2/evaluators/index.js +25 -0
  65. package/benchmarks/v2/evaluators/verified-success.js +116 -0
  66. package/benchmarks/v2/harness/runner.js +88 -0
  67. package/benchmarks/v2/pilot-tasks.json +392 -0
  68. package/bin/commands/recover.js +88 -0
  69. package/bin/commands/update.js +80 -17
  70. package/bin/commands.js +62 -25
  71. package/bin/index.js +138 -81
  72. package/bin/lib/lockfile.js +5 -3
  73. package/bin/lib/safe-writer.js +34 -3
  74. package/package.json +87 -72
  75. package/registry.json +2 -2
  76. package/registry.v2.schema.json +86 -0
  77. package/.agents/core/profiles/backend.yaml +0 -47
  78. package/.agents/core/profiles/enterprise.yaml +0 -46
  79. package/.agents/core/profiles/frontend.yaml +0 -46
  80. package/.agents/core/profiles/hackathon.yaml +0 -45
  81. package/.agents/core/profiles/mvp.yaml +0 -44
  82. package/.agents/core/profiles/startup.yaml +0 -48
  83. package/.agents/core/skills/adapters/EXAMPLES.md +0 -19
  84. package/.agents/core/skills/adapters/SKILL.md +0 -105
  85. package/.agents/core/skills/adapters/TROUBLESHOOTING.md +0 -7
  86. package/.agents/core/skills/adapters/VALIDATION.json +0 -12
  87. package/.agents/core/skills/adapters/skill.yaml +0 -16
  88. package/.agents/core/skills/architecture-diagrams/SKILL.md +0 -108
  89. package/.agents/core/skills/architecture-diagrams/VALIDATION.json +0 -12
  90. package/.agents/core/skills/architecture-diagrams/skill.yaml +0 -12
  91. package/.agents/core/skills/brutalist-design/SKILL.md +0 -150
  92. package/.agents/core/skills/brutalist-design/VALIDATION.json +0 -12
  93. package/.agents/core/skills/brutalist-design/skill.yaml +0 -12
  94. package/.agents/core/skills/database/EXAMPLES.md +0 -74
  95. package/.agents/core/skills/database/SKILL.md +0 -101
  96. package/.agents/core/skills/database/TROUBLESHOOTING.md +0 -18
  97. package/.agents/core/skills/database/VALIDATION.json +0 -11
  98. package/.agents/core/skills/database/skill.yaml +0 -31
  99. package/.agents/core/skills/ddd/EXAMPLES.md +0 -42
  100. package/.agents/core/skills/ddd/SKILL.md +0 -247
  101. package/.agents/core/skills/ddd/TROUBLESHOOTING.md +0 -19
  102. package/.agents/core/skills/ddd/VALIDATION.json +0 -12
  103. package/.agents/core/skills/ddd/ddd.md +0 -178
  104. package/.agents/core/skills/ddd/skill.yaml +0 -17
  105. package/.agents/core/skills/decisions/EXAMPLES.md +0 -35
  106. package/.agents/core/skills/decisions/SKILL.md +0 -90
  107. package/.agents/core/skills/decisions/TROUBLESHOOTING.md +0 -13
  108. package/.agents/core/skills/decisions/VALIDATION.json +0 -12
  109. package/.agents/core/skills/decisions/skill.yaml +0 -16
  110. package/.agents/core/skills/docker/EXAMPLES.md +0 -56
  111. package/.agents/core/skills/docker/SKILL.md +0 -63
  112. package/.agents/core/skills/docker/TROUBLESHOOTING.md +0 -18
  113. package/.agents/core/skills/docker/VALIDATION.json +0 -11
  114. package/.agents/core/skills/docker/skill.yaml +0 -29
  115. package/.agents/core/skills/fastapi/EXAMPLES.md +0 -36
  116. package/.agents/core/skills/fastapi/SKILL.md +0 -148
  117. package/.agents/core/skills/fastapi/TROUBLESHOOTING.md +0 -19
  118. package/.agents/core/skills/fastapi/VALIDATION.json +0 -12
  119. package/.agents/core/skills/fastapi/fastapi.md +0 -112
  120. package/.agents/core/skills/fastapi/skill.yaml +0 -17
  121. package/.agents/core/skills/generators/EXAMPLES.md +0 -19
  122. package/.agents/core/skills/generators/SKILL.md +0 -112
  123. package/.agents/core/skills/generators/TROUBLESHOOTING.md +0 -7
  124. package/.agents/core/skills/generators/VALIDATION.json +0 -12
  125. package/.agents/core/skills/generators/skill.yaml +0 -25
  126. package/.agents/core/skills/generators/templates/API.md +0 -77
  127. package/.agents/core/skills/generators/templates/ARCHITECTURE.md +0 -70
  128. package/.agents/core/skills/generators/templates/DATABASE.md +0 -42
  129. package/.agents/core/skills/generators/templates/DECISION.md +0 -46
  130. package/.agents/core/skills/generators/templates/PRD.md +0 -67
  131. package/.agents/core/skills/generators/templates/PROJECT_GRAPH.md +0 -56
  132. package/.agents/core/skills/generators/templates/ROADMAP.md +0 -51
  133. package/.agents/core/skills/generators/templates/TASKS.md +0 -43
  134. package/.agents/core/skills/generators/templates/UI.md +0 -73
  135. package/.agents/core/skills/graphify/EXAMPLES.md +0 -73
  136. package/.agents/core/skills/graphify/SKILL.md +0 -130
  137. package/.agents/core/skills/graphify/VALIDATION.json +0 -12
  138. package/.agents/core/skills/graphify/skill.yaml +0 -18
  139. package/.agents/core/skills/impeccable-design/EXAMPLES.md +0 -26
  140. package/.agents/core/skills/impeccable-design/SKILL.md +0 -201
  141. package/.agents/core/skills/impeccable-design/TROUBLESHOOTING.md +0 -19
  142. package/.agents/core/skills/impeccable-design/VALIDATION.json +0 -12
  143. package/.agents/core/skills/impeccable-design/skill.yaml +0 -20
  144. package/.agents/core/skills/interview-me/SKILL.md +0 -97
  145. package/.agents/core/skills/interview-me/VALIDATION.json +0 -12
  146. package/.agents/core/skills/interview-me/skill.yaml +0 -12
  147. package/.agents/core/skills/microservices/EXAMPLES.md +0 -38
  148. package/.agents/core/skills/microservices/SKILL.md +0 -164
  149. package/.agents/core/skills/microservices/TROUBLESHOOTING.md +0 -19
  150. package/.agents/core/skills/microservices/VALIDATION.json +0 -12
  151. package/.agents/core/skills/microservices/microservices.md +0 -119
  152. package/.agents/core/skills/microservices/skill.yaml +0 -17
  153. package/.agents/core/skills/minimalist-design/SKILL.md +0 -113
  154. package/.agents/core/skills/minimalist-design/VALIDATION.json +0 -12
  155. package/.agents/core/skills/minimalist-design/skill.yaml +0 -12
  156. package/.agents/core/skills/nestjs/EXAMPLES.md +0 -40
  157. package/.agents/core/skills/nestjs/SKILL.md +0 -139
  158. package/.agents/core/skills/nestjs/TROUBLESHOOTING.md +0 -19
  159. package/.agents/core/skills/nestjs/VALIDATION.json +0 -12
  160. package/.agents/core/skills/nestjs/nestjs.md +0 -103
  161. package/.agents/core/skills/nestjs/skill.yaml +0 -17
  162. package/.agents/core/skills/nextjs/EXAMPLES.md +0 -40
  163. package/.agents/core/skills/nextjs/SKILL.md +0 -163
  164. package/.agents/core/skills/nextjs/TROUBLESHOOTING.md +0 -19
  165. package/.agents/core/skills/nextjs/VALIDATION.json +0 -12
  166. package/.agents/core/skills/nextjs/nextjs.md +0 -67
  167. package/.agents/core/skills/nextjs/skill.yaml +0 -17
  168. package/.agents/core/skills/node/EXAMPLES.md +0 -80
  169. package/.agents/core/skills/node/SKILL.md +0 -128
  170. package/.agents/core/skills/node/TROUBLESHOOTING.md +0 -19
  171. package/.agents/core/skills/node/VALIDATION.json +0 -12
  172. package/.agents/core/skills/node/node.md +0 -87
  173. package/.agents/core/skills/node/skill.yaml +0 -17
  174. package/.agents/core/skills/performance/EXAMPLES.md +0 -30
  175. package/.agents/core/skills/performance/SKILL.md +0 -75
  176. package/.agents/core/skills/performance/TROUBLESHOOTING.md +0 -19
  177. package/.agents/core/skills/performance/VALIDATION.json +0 -12
  178. package/.agents/core/skills/performance/performance.md +0 -52
  179. package/.agents/core/skills/performance/skill.yaml +0 -17
  180. package/.agents/core/skills/react/EXAMPLES.md +0 -79
  181. package/.agents/core/skills/react/SKILL.md +0 -132
  182. package/.agents/core/skills/react/TROUBLESHOOTING.md +0 -19
  183. package/.agents/core/skills/react/VALIDATION.json +0 -12
  184. package/.agents/core/skills/react/react.md +0 -93
  185. package/.agents/core/skills/react/skill.yaml +0 -17
  186. package/.agents/core/skills/react-best-practices/SKILL.md +0 -155
  187. package/.agents/core/skills/react-best-practices/VALIDATION.json +0 -12
  188. package/.agents/core/skills/react-best-practices/skill.yaml +0 -14
  189. package/.agents/core/skills/redesign-audit/SKILL.md +0 -117
  190. package/.agents/core/skills/redesign-audit/VALIDATION.json +0 -12
  191. package/.agents/core/skills/redesign-audit/skill.yaml +0 -12
  192. package/.agents/core/skills/soft-design/SKILL.md +0 -108
  193. package/.agents/core/skills/soft-design/VALIDATION.json +0 -12
  194. package/.agents/core/skills/soft-design/skill.yaml +0 -12
  195. package/.agents/core/skills/state-management/EXAMPLES.md +0 -56
  196. package/.agents/core/skills/state-management/SKILL.md +0 -48
  197. package/.agents/core/skills/state-management/TROUBLESHOOTING.md +0 -18
  198. package/.agents/core/skills/state-management/VALIDATION.json +0 -11
  199. package/.agents/core/skills/state-management/skill.yaml +0 -28
  200. package/.agents/core/skills/subagent-orchestrator/SKILL.md +0 -117
  201. package/.agents/core/skills/subagent-orchestrator/VALIDATION.json +0 -12
  202. package/.agents/core/skills/subagent-orchestrator/skill.yaml +0 -12
  203. package/.agents/core/skills/system-design/EXAMPLES.md +0 -75
  204. package/.agents/core/skills/system-design/SKILL.md +0 -419
  205. package/.agents/core/skills/system-design/TROUBLESHOOTING.md +0 -19
  206. package/.agents/core/skills/system-design/VALIDATION.json +0 -12
  207. package/.agents/core/skills/system-design/skill.yaml +0 -20
  208. package/.agents/core/skills/system-design/system-design.md +0 -112
  209. package/.agents/core/skills/testing/EXAMPLES.md +0 -71
  210. package/.agents/core/skills/testing/SKILL.md +0 -70
  211. package/.agents/core/skills/testing/TROUBLESHOOTING.md +0 -18
  212. package/.agents/core/skills/testing/VALIDATION.json +0 -11
  213. package/.agents/core/skills/testing/skill.yaml +0 -32
  214. package/.agents/core/skills/typescript/EXAMPLES.md +0 -64
  215. package/.agents/core/skills/typescript/SKILL.md +0 -112
  216. package/.agents/core/skills/typescript/TROUBLESHOOTING.md +0 -19
  217. package/.agents/core/skills/typescript/VALIDATION.json +0 -12
  218. package/.agents/core/skills/typescript/skill.yaml +0 -17
  219. package/.agents/core/skills/typescript/typescript.md +0 -71
  220. package/.agents/core/skills/ui-design/EXAMPLES.md +0 -21
  221. package/.agents/core/skills/ui-design/SKILL.md +0 -124
  222. package/.agents/core/skills/ui-design/TROUBLESHOOTING.md +0 -19
  223. package/.agents/core/skills/ui-design/VALIDATION.json +0 -12
  224. package/.agents/core/skills/ui-design/skill.yaml +0 -17
  225. package/.agents/core/skills/ui-design/ui.md +0 -88
  226. package/.agents/core/skills/ui-ux-pro/EXAMPLES.md +0 -62
  227. package/.agents/core/skills/ui-ux-pro/SKILL.md +0 -375
  228. package/.agents/core/skills/ui-ux-pro/TROUBLESHOOTING.md +0 -19
  229. package/.agents/core/skills/ui-ux-pro/VALIDATION.json +0 -12
  230. package/.agents/core/skills/ui-ux-pro/skill.yaml +0 -19
  231. package/.agents/core/skills/ux-design/EXAMPLES.md +0 -36
  232. package/.agents/core/skills/ux-design/SKILL.md +0 -116
  233. package/.agents/core/skills/ux-design/TROUBLESHOOTING.md +0 -19
  234. package/.agents/core/skills/ux-design/VALIDATION.json +0 -12
  235. package/.agents/core/skills/ux-design/skill.yaml +0 -17
  236. package/.agents/core/skills/ux-design/ux.md +0 -80
  237. package/.agents/core/skills/vercel-optimize/SKILL.md +0 -83
  238. package/.agents/core/skills/vercel-optimize/VALIDATION.json +0 -12
  239. package/.agents/core/skills/vercel-optimize/scripts/collect-signals.mjs +0 -131
  240. package/.agents/core/skills/vercel-optimize/scripts/gate-investigations.mjs +0 -142
  241. package/.agents/core/skills/vercel-optimize/scripts/merge-signals.mjs +0 -143
  242. package/.agents/core/skills/vercel-optimize/scripts/scan-codebase.mjs +0 -174
  243. package/.agents/core/skills/vercel-optimize/skill.yaml +0 -18
  244. package/.agents/core/skills/web-accessibility/EXAMPLES.md +0 -39
  245. package/.agents/core/skills/web-accessibility/SKILL.md +0 -170
  246. package/.agents/core/skills/web-accessibility/TROUBLESHOOTING.md +0 -19
  247. package/.agents/core/skills/web-accessibility/VALIDATION.json +0 -12
  248. package/.agents/core/skills/web-accessibility/accessibility.md +0 -63
  249. package/.agents/core/skills/web-accessibility/skill.yaml +0 -17
  250. package/.agents/generated/claude/skills/adapters/SKILL.md +0 -126
  251. package/.agents/generated/claude/skills/architecture-diagrams/SKILL.md +0 -101
  252. package/.agents/generated/claude/skills/brutalist-design/SKILL.md +0 -145
  253. package/.agents/generated/claude/skills/database/SKILL.md +0 -191
  254. package/.agents/generated/claude/skills/ddd/SKILL.md +0 -305
  255. package/.agents/generated/claude/skills/decisions/SKILL.md +0 -134
  256. package/.agents/generated/claude/skills/docker/SKILL.md +0 -135
  257. package/.agents/generated/claude/skills/fastapi/SKILL.md +0 -200
  258. package/.agents/generated/claude/skills/generators/SKILL.md +0 -133
  259. package/.agents/generated/claude/skills/graphify/SKILL.md +0 -198
  260. package/.agents/generated/claude/skills/impeccable-design/SKILL.md +0 -241
  261. package/.agents/generated/claude/skills/interview-me/SKILL.md +0 -90
  262. package/.agents/generated/claude/skills/microservices/SKILL.md +0 -218
  263. package/.agents/generated/claude/skills/minimalist-design/SKILL.md +0 -108
  264. package/.agents/generated/claude/skills/nestjs/SKILL.md +0 -195
  265. package/.agents/generated/claude/skills/nextjs/SKILL.md +0 -219
  266. package/.agents/generated/claude/skills/node/SKILL.md +0 -224
  267. package/.agents/generated/claude/skills/performance/SKILL.md +0 -121
  268. package/.agents/generated/claude/skills/react/SKILL.md +0 -227
  269. package/.agents/generated/claude/skills/react-best-practices/SKILL.md +0 -146
  270. package/.agents/generated/claude/skills/redesign-audit/SKILL.md +0 -112
  271. package/.agents/generated/claude/skills/soft-design/SKILL.md +0 -103
  272. package/.agents/generated/claude/skills/state-management/SKILL.md +0 -120
  273. package/.agents/generated/claude/skills/subagent-orchestrator/SKILL.md +0 -110
  274. package/.agents/generated/claude/skills/system-design/SKILL.md +0 -507
  275. package/.agents/generated/claude/skills/testing/SKILL.md +0 -157
  276. package/.agents/generated/claude/skills/typescript/SKILL.md +0 -192
  277. package/.agents/generated/claude/skills/ui-design/SKILL.md +0 -161
  278. package/.agents/generated/claude/skills/ui-ux-pro/SKILL.md +0 -451
  279. package/.agents/generated/claude/skills/ux-design/SKILL.md +0 -168
  280. package/.agents/generated/claude/skills/vercel-optimize/SKILL.md +0 -76
  281. package/.agents/generated/claude/skills/web-accessibility/SKILL.md +0 -225
  282. package/.agents/generated/gemini/skills/adapters/SKILL.md +0 -135
  283. package/.agents/generated/gemini/skills/architecture-diagrams/SKILL.md +0 -107
  284. package/.agents/generated/gemini/skills/brutalist-design/SKILL.md +0 -151
  285. package/.agents/generated/gemini/skills/database/SKILL.md +0 -200
  286. package/.agents/generated/gemini/skills/ddd/SKILL.md +0 -314
  287. package/.agents/generated/gemini/skills/decisions/SKILL.md +0 -143
  288. package/.agents/generated/gemini/skills/docker/SKILL.md +0 -144
  289. package/.agents/generated/gemini/skills/fastapi/SKILL.md +0 -209
  290. package/.agents/generated/gemini/skills/generators/SKILL.md +0 -142
  291. package/.agents/generated/gemini/skills/graphify/SKILL.md +0 -205
  292. package/.agents/generated/gemini/skills/impeccable-design/SKILL.md +0 -250
  293. package/.agents/generated/gemini/skills/interview-me/SKILL.md +0 -96
  294. package/.agents/generated/gemini/skills/microservices/SKILL.md +0 -227
  295. package/.agents/generated/gemini/skills/minimalist-design/SKILL.md +0 -114
  296. package/.agents/generated/gemini/skills/nestjs/SKILL.md +0 -204
  297. package/.agents/generated/gemini/skills/nextjs/SKILL.md +0 -298
  298. package/.agents/generated/gemini/skills/node/SKILL.md +0 -323
  299. package/.agents/generated/gemini/skills/performance/SKILL.md +0 -185
  300. package/.agents/generated/gemini/skills/react/SKILL.md +0 -332
  301. package/.agents/generated/gemini/skills/react-best-practices/SKILL.md +0 -152
  302. package/.agents/generated/gemini/skills/redesign-audit/SKILL.md +0 -118
  303. package/.agents/generated/gemini/skills/soft-design/SKILL.md +0 -109
  304. package/.agents/generated/gemini/skills/state-management/SKILL.md +0 -129
  305. package/.agents/generated/gemini/skills/subagent-orchestrator/SKILL.md +0 -116
  306. package/.agents/generated/gemini/skills/system-design/SKILL.md +0 -631
  307. package/.agents/generated/gemini/skills/testing/SKILL.md +0 -166
  308. package/.agents/generated/gemini/skills/typescript/SKILL.md +0 -275
  309. package/.agents/generated/gemini/skills/ui-design/SKILL.md +0 -170
  310. package/.agents/generated/gemini/skills/ui-ux-pro/SKILL.md +0 -460
  311. package/.agents/generated/gemini/skills/ux-design/SKILL.md +0 -177
  312. package/.agents/generated/gemini/skills/vercel-optimize/SKILL.md +0 -82
  313. package/.agents/generated/gemini/skills/web-accessibility/SKILL.md +0 -300
@@ -1,77 +0,0 @@
1
- # {{Project Name}} — API Specification
2
-
3
- ## Base URL
4
-
5
- `{{base_url}}` (e.g., `https://api.example.com/v1`)
6
-
7
- ## Authentication
8
-
9
- {{auth_method}} (e.g., Bearer token via JWT)
10
-
11
- ## Endpoints
12
-
13
- ### {{Module Name}}
14
-
15
- #### `{{METHOD}} {{path}}`
16
-
17
- {{description}}
18
-
19
- **Request:**
20
-
21
- ```json
22
- {{request_body}}
23
- ```
24
-
25
- **Response (200):**
26
-
27
- ```json
28
- {{response_body}}
29
- ```
30
-
31
- **Errors:**
32
-
33
- | Code | Description |
34
- | --- | --- |
35
- | 400 | {{bad_request_reason}} |
36
- | 401 | Unauthorized |
37
- | 404 | {{not_found_reason}} |
38
-
39
- ---
40
-
41
- ## Error Format
42
-
43
- All errors follow this format:
44
-
45
- ```json
46
- {
47
- "error": {
48
- "code": "ERROR_CODE",
49
- "message": "Human-readable message",
50
- "details": {}
51
- }
52
- }
53
- ```
54
-
55
- ## Pagination
56
-
57
- ```json
58
- {
59
- "data": [...],
60
- "pagination": {
61
- "page": 1,
62
- "per_page": 20,
63
- "total": 100,
64
- "total_pages": 5
65
- }
66
- }
67
- ```
68
-
69
- ## Rate Limiting
70
-
71
- - {{rate_limit}} requests per {{window}}
72
- - Headers: `X-RateLimit-Limit`, `X-RateLimit-Remaining`, `X-RateLimit-Reset`
73
-
74
- ## Versioning
75
-
76
- - URL-based: `/v1/`, `/v2/`
77
- - Breaking changes require new version
@@ -1,70 +0,0 @@
1
- # {{Project Name}} — System Architecture
2
-
3
- ## Architecture Overview
4
- <!-- High-level architecture description and diagram -->
5
-
6
- ```
7
- {{architecture_diagram}}
8
- ```
9
-
10
- ## Tech Stack
11
-
12
- | Layer | Technology | Reason |
13
- | --- | --- | --- |
14
- | Frontend | {{e.g., Next.js + React}} | {{reason}} |
15
- | Backend | {{e.g., Node.js + Express}} | {{reason}} |
16
- | Database | {{e.g., PostgreSQL}} | {{reason}} |
17
- | Cache | {{e.g., Redis}} | {{reason}} |
18
- | Auth | {{e.g., JWT + OAuth2}} | {{reason}} |
19
- | Hosting | {{e.g., Vercel + Railway}} | {{reason}} |
20
-
21
- ## System Components
22
-
23
- ### {{Component 1 Name}}
24
-
25
- - **Responsibility:** {{what it does}}
26
- - **Interfaces:** {{what it exposes}}
27
- - **Dependencies:** {{what it depends on}}
28
-
29
- ### {{Component 2 Name}}
30
-
31
- - **Responsibility:** {{what it does}}
32
- - **Interfaces:** {{what it exposes}}
33
- - **Dependencies:** {{what it depends on}}
34
-
35
- ## Data Flow
36
-
37
- ```
38
- User → Frontend → API Gateway → Service Layer → Database
39
- ↓
40
- Cache Layer
41
- ```
42
-
43
- ## Directory Structure
44
-
45
- ```
46
- {{project_root}}/
47
- ├── src/
48
- │ ├── modules/ # Feature modules
49
- │ │ ├── {{module_1}}/
50
- │ │ └── {{module_2}}/
51
- │ ├── shared/ # Shared utilities
52
- │ ├── config/ # Configuration
53
- │ └── types/ # Type definitions
54
- ├── tests/
55
- ├── docs/
56
- └── infrastructure/
57
- ```
58
-
59
- ## Security Architecture
60
- <!-- Authentication, authorization, data protection -->
61
-
62
- ## Scalability Considerations
63
- <!-- How will this scale? What are the bottlenecks? -->
64
-
65
- ## Error Handling Strategy
66
- <!-- How are errors propagated, logged, and reported? -->
67
-
68
- ## Key Architectural Decisions
69
- <!-- Reference to ADRs in docs/decisions/ -->
70
- - See `docs/decisions/` for all architectural decisions with rationale
@@ -1,42 +0,0 @@
1
- # {{Project Name}} — Database Schema
2
-
3
- ## Database Engine
4
-
5
- {{e.g., PostgreSQL 16}}
6
-
7
- ## Entity Relationship Diagram
8
-
9
- ```
10
- {{ER_diagram}}
11
- ```
12
-
13
- ## Tables
14
-
15
- ### {{table_name}}
16
-
17
- | Column | Type | Constraints | Description |
18
- | --- | --- | --- | --- |
19
- | id | UUID | PK, DEFAULT gen_random_uuid() | Primary key |
20
- | {{column}} | {{type}} | {{constraints}} | {{description}} |
21
- | created_at | TIMESTAMPTZ | NOT NULL, DEFAULT NOW() | Creation timestamp |
22
- | updated_at | TIMESTAMPTZ | NOT NULL, DEFAULT NOW() | Last update timestamp |
23
-
24
- **Indexes:**
25
-
26
- - `idx_{{table}}_{{column}}` ON ({{column}})
27
-
28
- **Relations:**
29
-
30
- - {{table_name}}.{{fk_column}} → {{related_table}}.id
31
-
32
- ## Migrations Strategy
33
- <!-- How are schema changes applied? -->
34
- - Tool: {{e.g., Prisma Migrate, Alembic, Knex}}
35
- - Naming: `YYYYMMDD_HHMMSS_description`
36
- - Rule: Never modify existing migrations, always create new ones
37
-
38
- ## Seed Data
39
- <!-- What data needs to exist for the app to work? -->
40
-
41
- ## Performance Considerations
42
- <!-- Indexes, query optimization, connection pooling -->
@@ -1,46 +0,0 @@
1
- # ADR-{{number}}: {{Decision Title}}
2
-
3
- **Date:** {{YYYY-MM-DD}}
4
- **Status:** {{proposed | accepted | deprecated | superseded}}
5
- **Affected modules:** {{module_1}}, {{module_2}}
6
-
7
- ## Decision
8
-
9
- {{What was decided, in one sentence.}}
10
-
11
- ## Why
12
-
13
- {{The reasoning behind this decision. What problem does it solve?}}
14
-
15
- ## Alternatives Considered
16
-
17
- ### {{Alternative 1}}
18
-
19
- - **Pros:** {{advantages}}
20
- - **Cons:** {{disadvantages}}
21
- - **Why rejected:** {{reason}}
22
-
23
- ### {{Alternative 2}}
24
-
25
- - **Pros:** {{advantages}}
26
- - **Cons:** {{disadvantages}}
27
- - **Why rejected:** {{reason}}
28
-
29
- ## Tradeoffs
30
-
31
- | Aspect | Gain | Cost |
32
- | --- | --- | --- |
33
- | {{aspect_1}} | {{what_we_gain}} | {{what_we_lose}} |
34
- | {{aspect_2}} | {{what_we_gain}} | {{what_we_lose}} |
35
-
36
- ## Impact
37
-
38
- - **Code changes:** {{what files/modules are affected}}
39
- - **Performance:** {{performance impact}}
40
- - **Team:** {{learning curve, tooling changes}}
41
- - **Reversibility:** {{easy | moderate | hard | irreversible}}
42
-
43
- ## References
44
-
45
- - {{link_1}}
46
- - {{link_2}}
@@ -1,67 +0,0 @@
1
- # {{Project Name}} — Product Requirements Document
2
-
3
- ## Overview
4
- <!-- One paragraph describing what this product does and who it's for -->
5
- {{project_description}}
6
-
7
- ## Problem Statement
8
- <!-- What problem does this solve? Why does it need to exist? -->
9
-
10
- ## Target Users
11
- <!-- Who will use this? Define user personas -->
12
-
13
- | Persona | Description | Key Needs |
14
- | --- | --- | --- |
15
- | {{persona_1}} | {{description}} | {{needs}} |
16
- | {{persona_2}} | {{description}} | {{needs}} |
17
-
18
- ## Core Features
19
-
20
- ### Must Have (P0)
21
- <!-- Features required for MVP -->
22
- - [ ] {{feature_1}}
23
- - [ ] {{feature_2}}
24
-
25
- ### Should Have (P1)
26
- <!-- Features for v1.0 -->
27
- - [ ] {{feature_3}}
28
- - [ ] {{feature_4}}
29
-
30
- ### Nice to Have (P2)
31
- <!-- Future features -->
32
- - [ ] {{feature_5}}
33
-
34
- ## User Flows
35
-
36
- ### {{Primary Flow Name}}
37
-
38
- ```
39
- Step 1: {{action}}
40
- Step 2: {{action}}
41
- Step 3: {{action}}
42
- ```
43
-
44
- ## Non-Functional Requirements
45
-
46
- | Requirement | Target |
47
- | --- | --- |
48
- | Performance | {{e.g., page load < 2s}} |
49
- | Availability | {{e.g., 99.9%}} |
50
- | Security | {{e.g., OWASP Top 10 compliance}} |
51
- | Accessibility | {{e.g., WCAG 2.1 AA}} |
52
- | Scalability | {{e.g., 10K concurrent users}} |
53
-
54
- ## Constraints
55
- <!-- Technical, business, or timeline constraints -->
56
- - {{constraint_1}}
57
- - {{constraint_2}}
58
-
59
- ## Success Metrics
60
- <!-- How will we measure success? -->
61
- - {{metric_1}}
62
- - {{metric_2}}
63
-
64
- ## Out of Scope
65
- <!-- What this project explicitly does NOT do -->
66
- - {{exclusion_1}}
67
- - {{exclusion_2}}
@@ -1,56 +0,0 @@
1
- # {{Project Name}} — Project Graph
2
-
3
- ## Project
4
-
5
- ```yaml
6
- name: "{{project_name}}"
7
- type: {{webapp | api | mobile | cli | saas | crm | ecommerce}}
8
- profile: {{startup | enterprise | mvp | hackathon}}
9
- pack: {{skill_pack_name}}
10
- ```
11
-
12
- ## Modules
13
-
14
- ### {{module_name}}
15
-
16
- ```yaml
17
- module: {{module_name}}
18
- description: "{{what this module does}}"
19
- features:
20
- - {{feature_1}}
21
- - {{feature_2}}
22
- files:
23
- - src/modules/{{module_name}}/**
24
- skills: [{{skill_1}}, {{skill_2}}]
25
- depends_on: [{{other_module}}]
26
- ```
27
-
28
- ---
29
-
30
- <!-- Repeat for each module -->
31
-
32
- ## Module Dependency Graph
33
-
34
- ```
35
- {{module_1}} ──depends──▶ {{module_2}}
36
- │
37
- └──depends──▶ {{module_3}}
38
- ```
39
-
40
- ## File → Module Mapping
41
-
42
- | File Pattern | Module | Skills |
43
- | --- | --- | --- |
44
- | `src/modules/{{module}}/**` | {{module}} | {{skills}} |
45
- | `src/shared/**` | shared | {{skills}} |
46
- | `src/config/**` | config | — |
47
- | `tests/**` | testing | testing |
48
- | `docs/**` | docs | — |
49
-
50
- ## Feature → Task Mapping
51
-
52
- ### {{Feature Name}} `[{{module}}]`
53
-
54
- - [ ] {{task_1}} → `{{file_path}}`
55
- - [ ] {{task_2}} → `{{file_path}}`
56
- - [ ] {{task_3}} → `{{file_path}}`
@@ -1,51 +0,0 @@
1
- # {{Project Name}} — Roadmap
2
-
3
- ## Vision
4
-
5
- {{one_sentence_vision}}
6
-
7
- ## Milestones
8
-
9
- ### v0.1 — MVP ({{target_date}})
10
-
11
- **Goal:** {{what_mvp_achieves}}
12
-
13
- - [ ] {{feature_1}}
14
- - [ ] {{feature_2}}
15
- - [ ] {{feature_3}}
16
-
17
- **Success criteria:** {{how_to_know_mvp_is_done}}
18
-
19
- ---
20
-
21
- ### v0.2 — {{milestone_name}} ({{target_date}})
22
-
23
- **Goal:** {{what_this_milestone_achieves}}
24
-
25
- - [ ] {{feature_4}}
26
- - [ ] {{feature_5}}
27
-
28
- ---
29
-
30
- ### v1.0 — Production ({{target_date}})
31
-
32
- **Goal:** {{what_production_means}}
33
-
34
- - [ ] {{feature_6}}
35
- - [ ] {{feature_7}}
36
- - [ ] Performance optimization
37
- - [ ] Security audit
38
- - [ ] Documentation
39
-
40
- ---
41
-
42
- ## Backlog
43
- <!-- Future ideas not yet scheduled -->
44
- - {{idea_1}}
45
- - {{idea_2}}
46
-
47
- ## Risks
48
-
49
- | Risk | Impact | Mitigation |
50
- |---|---|---|
51
- | {{risk_1}} | {{high/medium/low}} | {{mitigation}} |
@@ -1,43 +0,0 @@
1
- # {{Project Name}} — Tasks
2
-
3
- ## Current Sprint: {{sprint_name}}
4
-
5
- ### In Progress
6
-
7
- - [ ] {{task}} `[{{module}}]` `[{{size: S/M/L/XL}}]`
8
-
9
- ### To Do
10
-
11
- - [ ] {{task}} `[{{module}}]` `[{{size}}]`
12
- - [ ] {{task}} `[{{module}}]` `[{{size}}]`
13
-
14
- ### Done
15
-
16
- - [x] {{completed_task}} `[{{module}}]`
17
-
18
- ---
19
-
20
- ## Task Format
21
-
22
- Each task should include:
23
-
24
- - **Description**: What needs to be done
25
- - **Module**: Which Project Graph module this belongs to
26
- - **Size**: S (< 1hr), M (1-4hr), L (4-8hr), XL (> 8hr)
27
- - **Dependencies**: What must be done first
28
- - **Acceptance criteria**: How to know it's done
29
- - **Skills needed**: Which skills the AI should load
30
-
31
- ### Example Task
32
-
33
- ```
34
- - [ ] Implement appointment calendar API [appointments] [L]
35
- Dependencies: auth module, database schema
36
- Acceptance: CRUD endpoints for appointments, tests passing
37
- Skills: node, typescript, postgres, testing
38
- ```
39
-
40
- ## Backlog
41
- <!-- Tasks not yet assigned to a sprint -->
42
- - [ ] {{backlog_task_1}}
43
- - [ ] {{backlog_task_2}}
@@ -1,73 +0,0 @@
1
- # {{Project Name}} — UI/UX Specification
2
-
3
- ## Design System
4
-
5
- ### Colors
6
-
7
- | Token | Value | Usage |
8
- | --- | --- | --- |
9
- | `--color-primary` | {{hex}} | Primary actions, links |
10
- | `--color-secondary` | {{hex}} | Secondary elements |
11
- | `--color-background` | {{hex}} | Page background |
12
- | `--color-surface` | {{hex}} | Card/panel backgrounds |
13
- | `--color-text` | {{hex}} | Body text |
14
- | `--color-text-muted` | {{hex}} | Secondary text |
15
- | `--color-error` | {{hex}} | Error states |
16
- | `--color-success` | {{hex}} | Success states |
17
-
18
- ### Typography
19
-
20
- | Level | Font | Size | Weight | Line Height |
21
- | --- | --- | --- | --- | --- |
22
- | H1 | {{font}} | {{size}} | {{weight}} | {{lh}} |
23
- | H2 | {{font}} | {{size}} | {{weight}} | {{lh}} |
24
- | Body | {{font}} | {{size}} | {{weight}} | {{lh}} |
25
- | Caption | {{font}} | {{size}} | {{weight}} | {{lh}} |
26
-
27
- ### Spacing Scale
28
-
29
- `4px, 8px, 12px, 16px, 24px, 32px, 48px, 64px`
30
-
31
- ### Border Radius
32
-
33
- | Token | Value | Usage |
34
- | --- | --- | --- |
35
- | `--radius-sm` | 4px | Inputs, small elements |
36
- | `--radius-md` | 8px | Cards, panels |
37
- | `--radius-lg` | 16px | Modals, hero sections |
38
- | `--radius-full` | 9999px | Pills, avatars |
39
-
40
- ## Pages
41
-
42
- ### {{Page Name}}
43
-
44
- - **Route:** `{{route}}`
45
- - **Purpose:** {{what this page does}}
46
- - **Components:** {{list of components}}
47
- - **States:** default, loading, empty, error
48
-
49
- ## Component Library
50
- <!-- List of reusable components -->
51
-
52
- | Component | Props | Variants |
53
- | --- | --- | --- |
54
- | Button | `variant, size, disabled` | primary, secondary, ghost |
55
- | Input | `type, label, error` | text, email, password |
56
- | Card | `title, actions` | default, elevated |
57
-
58
- ## Responsive Breakpoints
59
-
60
- | Name | Width | Layout |
61
- | --- | --- | --- |
62
- | Mobile | < 640px | Single column |
63
- | Tablet | 640-1024px | Two columns |
64
- | Desktop | > 1024px | Full layout |
65
-
66
- ## Anti-Patterns (avoid these)
67
-
68
- - No gray text on colored backgrounds
69
- - No pure black — always tint with brand color
70
- - No bounce/elastic easing — use ease-out
71
- - No cards nested inside cards
72
- - No generic color palettes (plain red, blue, green)
73
- - No default browser fonts — use curated typography
@@ -1,73 +0,0 @@
1
- # Graphify Examples — Anti-patterns vs ContextOS Standard
2
-
3
- ## Example 1: Codebase Exploration & Architecture Mapping
4
-
5
- ### Anti-pattern: Context Window Flooding (Dumping source directories into prompt)
6
-
7
- ```bash
8
- # BAD: Reading 150 TypeScript files into context to understand system architecture.
9
- # Burns 200k+ tokens, causes model hallucinations, and loses attention span.
10
- cat src/**/*.ts | llm "explain the architecture and component connections"
11
- ```
12
-
13
- ### Best practice: ContextOS Standard (Deterministic Tree-sitter AST Graph)
14
-
15
- ```bash
16
- # GOOD: Generate queryable AST knowledge graph and compact architecture summary
17
- graphify run ./src --output .graphify/
18
-
19
- # Inspect high-level architecture and god nodes with minimal tokens (<2k tokens)
20
- cat .graphify/GRAPH_REPORT.md
21
- ```
22
-
23
- ---
24
-
25
- ## Example 2: Refactoring Blast-Radius Analysis
26
-
27
- ### Anti-pattern: String Grep Guesswork
28
-
29
- ```bash
30
- # BAD: Grepping for common symbol names returns hundreds of false positives (comments, logs, unrelated types)
31
- grep -rn "PaymentService" src/
32
- ```
33
-
34
- ### Best practice: ContextOS Standard (Inbound Dependency Traversal via graph.json)
35
-
36
- ```javascript
37
- // GOOD: Precise AST-level callers extracted directly from knowledge graph edges
38
- const fs = require('fs');
39
- const graph = JSON.parse(fs.readFileSync('.graphify/graph.json', 'utf8'));
40
-
41
- const targetNode = 'PaymentService';
42
- const dependents = graph.edges
43
- .filter(edge => edge.target === targetNode && edge.type === 'imports')
44
- .map(edge => edge.source);
45
-
46
- console.log(`Modules directly broken by modifying ${targetNode}:`, dependents);
47
- ```
48
-
49
- ---
50
-
51
- ## Example 3: Keeping Graph Fresh in CI / Pre-commit
52
-
53
- ### Anti-pattern: Relying on Outdated Graphs
54
-
55
- ```bash
56
- # BAD: Developing against a graph generated two months ago.
57
- # Dependencies drift, leading to false safety assumptions.
58
- ```
59
-
60
- ### Best practice: ContextOS Standard (Git Hook & Automated Watch)
61
-
62
- ```bash
63
- # Option A: Active development in watch mode
64
- graphify watch ./src --output .graphify/
65
-
66
- # Option B: Pre-commit hook to verify fresh GRAPH_REPORT.md
67
- #!/bin/sh
68
- # .git/hooks/pre-commit
69
- if command -v graphify >/dev/null 2>&1; then
70
- graphify run ./src --report-only
71
- git add GRAPH_REPORT.md
72
- fi
73
- ```