ai-design-context 0.4.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 (288) hide show
  1. package/AGENTS.md +156 -0
  2. package/CHANGELOG.md +71 -0
  3. package/CODE_OF_CONDUCT.md +29 -0
  4. package/CONTRIBUTING.md +128 -0
  5. package/LICENSE +21 -0
  6. package/README.md +283 -0
  7. package/RELEASE_NOTES_v0.1.0.md +45 -0
  8. package/RELEASE_NOTES_v0.3.0.md +47 -0
  9. package/RELEASE_NOTES_v0.4.0.md +29 -0
  10. package/RELEASE_READINESS.md +107 -0
  11. package/ROADMAP.md +60 -0
  12. package/SECURITY.md +40 -0
  13. package/assets/logo.svg +9 -0
  14. package/benchmarks/README.md +19 -0
  15. package/benchmarks/chat.md +37 -0
  16. package/benchmarks/mobile-home-screen.md +38 -0
  17. package/benchmarks/notes-app.md +37 -0
  18. package/benchmarks/settings.md +37 -0
  19. package/benchmarks/shopping-list.md +37 -0
  20. package/benchmarks/todo-app.md +144 -0
  21. package/checklists/DESIGN_QA.md +102 -0
  22. package/checklists/GENERATED_INDEX.md +7 -0
  23. package/docs/AGENT_CONTEXT.md +111 -0
  24. package/docs/BENCHMARK.md +170 -0
  25. package/docs/DESIGNLINT_READINESS.md +110 -0
  26. package/docs/DESIGN_SYSTEM.md +23 -0
  27. package/docs/EVALUATION_RUBRIC.md +154 -0
  28. package/docs/GITHUB_SETUP.md +28 -0
  29. package/docs/GLOSSARY.md +45 -0
  30. package/docs/INDEX.md +109 -0
  31. package/docs/KNOWLEDGE_ENGINE.md +594 -0
  32. package/docs/MOBILE_FIRST.md +18 -0
  33. package/docs/NPM_RELEASE.md +43 -0
  34. package/docs/PATTERN_SPEC.md +113 -0
  35. package/docs/PHILOSOPHY.md +25 -0
  36. package/docs/PRODUCT_THINKING.md +26 -0
  37. package/docs/STYLE_GUIDE.md +49 -0
  38. package/docs/TRACEABILITY.md +45 -0
  39. package/evidence/README.md +64 -0
  40. package/evidence/TEMPLATE.md +46 -0
  41. package/evidence/chat/.gitkeep +1 -0
  42. package/evidence/mobile-home/.gitkeep +1 -0
  43. package/evidence/notes/.gitkeep +1 -0
  44. package/evidence/settings/.gitkeep +1 -0
  45. package/evidence/shopping/.gitkeep +1 -0
  46. package/evidence/todo/.gitkeep +1 -0
  47. package/evidence/todo/2026-06-25-codex-gpt-5/EVALUATION.md +66 -0
  48. package/evidence/todo/2026-06-25-codex-gpt-5/README.md +40 -0
  49. package/evidence/todo/2026-06-25-codex-gpt-5/ai-design-rules/generated-output.md +163 -0
  50. package/evidence/todo/2026-06-25-codex-gpt-5/ai-design-rules/metadata.json +38 -0
  51. package/evidence/todo/2026-06-25-codex-gpt-5/ai-design-rules/notes.md +20 -0
  52. package/evidence/todo/2026-06-25-codex-gpt-5/ai-design-rules/prompt.md +16 -0
  53. package/evidence/todo/2026-06-25-codex-gpt-5/ai-design-rules/scores.md +18 -0
  54. package/evidence/todo/2026-06-25-codex-gpt-5/baseline/generated-output.md +98 -0
  55. package/evidence/todo/2026-06-25-codex-gpt-5/baseline/metadata.json +19 -0
  56. package/evidence/todo/2026-06-25-codex-gpt-5/baseline/notes.md +19 -0
  57. package/evidence/todo/2026-06-25-codex-gpt-5/baseline/prompt.md +9 -0
  58. package/evidence/todo/2026-06-25-codex-gpt-5/baseline/scores.md +18 -0
  59. package/evidence/todo/2026-09-28-codex-paired-todo/EVALUATION.md +70 -0
  60. package/evidence/todo/2026-09-28-codex-paired-todo/README.md +52 -0
  61. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/GENERATION_NOTES.md +133 -0
  62. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/app.js +289 -0
  63. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/context/context-preserving-preview.json +443 -0
  64. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/context/daily-home-surface.json +373 -0
  65. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/context/quick-capture.json +301 -0
  66. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/context/sources-read.txt +36 -0
  67. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/generated-output.md +11 -0
  68. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/index.html +64 -0
  69. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/launch-prompt.md +1 -0
  70. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/metadata.json +55 -0
  71. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/notes.md +15 -0
  72. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/parent-status-message.md +1 -0
  73. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/prompt.md +49 -0
  74. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/runtime-checks.json +776 -0
  75. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/scores.md +20 -0
  76. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-completed.png +0 -0
  77. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-default.png +0 -0
  78. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-detail-reduced-motion.png +0 -0
  79. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-detail.png +0 -0
  80. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-empty.png +0 -0
  81. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-keyboard-focus.png +0 -0
  82. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-save-error.png +0 -0
  83. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-saved.png +0 -0
  84. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-saving.png +0 -0
  85. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-validation.png +0 -0
  86. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-completed.png +0 -0
  87. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-default.png +0 -0
  88. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-detail-reduced-motion.png +0 -0
  89. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-detail.png +0 -0
  90. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-empty.png +0 -0
  91. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-keyboard-focus.png +0 -0
  92. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-save-error.png +0 -0
  93. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-saved.png +0 -0
  94. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-saving.png +0 -0
  95. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-validation.png +0 -0
  96. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/source-hashes.json +5 -0
  97. package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/styles.css +122 -0
  98. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/GENERATION_NOTES.md +86 -0
  99. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/app.js +303 -0
  100. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/generated-output.md +11 -0
  101. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/index.html +71 -0
  102. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/launch-prompt.md +1 -0
  103. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/metadata.json +55 -0
  104. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/notes.md +15 -0
  105. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/parent-status-message.md +1 -0
  106. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/prompt.md +49 -0
  107. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/runtime-checks.json +772 -0
  108. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/scores.md +20 -0
  109. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-completed.png +0 -0
  110. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-default.png +0 -0
  111. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-detail-reduced-motion.png +0 -0
  112. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-detail.png +0 -0
  113. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-empty.png +0 -0
  114. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-keyboard-focus.png +0 -0
  115. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-save-error.png +0 -0
  116. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-saved.png +0 -0
  117. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-saving.png +0 -0
  118. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-validation.png +0 -0
  119. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-completed.png +0 -0
  120. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-default.png +0 -0
  121. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-detail-reduced-motion.png +0 -0
  122. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-detail.png +0 -0
  123. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-empty.png +0 -0
  124. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-keyboard-focus.png +0 -0
  125. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-save-error.png +0 -0
  126. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-saved.png +0 -0
  127. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-saving.png +0 -0
  128. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-validation.png +0 -0
  129. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/source-hashes.json +5 -0
  130. package/evidence/todo/2026-09-28-codex-paired-todo/baseline/styles.css +9 -0
  131. package/evidence/todo/2026-09-28-codex-paired-todo/capture-ai-design-rules.js +60 -0
  132. package/evidence/todo/2026-09-28-codex-paired-todo/capture-baseline.js +60 -0
  133. package/evidence/todo/2026-09-28-codex-paired-todo/common/brief.md +35 -0
  134. package/evidence/todo/2026-09-28-codex-paired-todo/common/knowledge-files.json +127 -0
  135. package/evidence/todo/2026-09-28-codex-paired-todo/common/knowledge.patch +890 -0
  136. package/evidence/todo/2026-09-28-codex-paired-todo/common/review-context.json +550 -0
  137. package/evidence/todo/2026-09-28-codex-paired-todo/common/seed.json +86 -0
  138. package/evidence/todo/2026-09-28-codex-paired-todo/common/setup.json +47 -0
  139. package/evidence/todo/2026-09-28-codex-paired-todo/common/technical-envelope.md +11 -0
  140. package/evidence/todo/2026-09-28-codex-paired-todo/layout-metrics.json +133 -0
  141. package/evidence/todo/2026-09-28-codex-paired-todo/layout-probe.js +15 -0
  142. package/examples/GENERATED_INDEX.md +8 -0
  143. package/examples/INDEX.md +16 -0
  144. package/examples/README.md +15 -0
  145. package/examples/consequential-action-confirmation-reference.md +83 -0
  146. package/examples/todo-app-benchmark.md +117 -0
  147. package/examples/todo-reference/README.md +29 -0
  148. package/examples/todo-reference/app.js +154 -0
  149. package/examples/todo-reference/favicon.svg +4 -0
  150. package/examples/todo-reference/index.html +67 -0
  151. package/examples/todo-reference/review-evidence/2026-07-15/desktop-default.png +0 -0
  152. package/examples/todo-reference/review-evidence/2026-07-15/desktop-detail.png +0 -0
  153. package/examples/todo-reference/review-evidence/2026-07-15/mobile-detail.png +0 -0
  154. package/examples/todo-reference/review-evidence/2026-07-15/mobile-error.png +0 -0
  155. package/examples/todo-reference/styles.css +241 -0
  156. package/graph/GENERATED_GRAPH.md +71 -0
  157. package/observations/README.md +23 -0
  158. package/observations/accessibility/reduced-interaction-motion.md +49 -0
  159. package/observations/accessibility/textual-error-recovery.md +50 -0
  160. package/observations/accessibility/visible-keyboard-focus.md +49 -0
  161. package/observations/ai/agent-consequential-action-controls.md +56 -0
  162. package/observations/ai/agent-work-visibility-and-intervention.md +51 -0
  163. package/observations/ai/figma-agent-context-and-skills.md +52 -0
  164. package/observations/finance/high-risk-wallet-recovery-flows.md +55 -0
  165. package/observations/finance/market-interface-adaptive-trading-surfaces.md +55 -0
  166. package/observations/interaction/chrome-scoped-view-transitions.md +52 -0
  167. package/observations/interaction/figma-motion-as-system-capability.md +53 -0
  168. package/observations/mobile/mobile-bottom-sheet-choice-contracts.md +55 -0
  169. package/observations/performance/reserved-loading-space.md +51 -0
  170. package/observations/product-repos/pinned-ai-design-rules-integration.md +49 -0
  171. package/observations/visual/apple-liquid-glass-functional-layer.md +52 -0
  172. package/observations/visual/chrome-content-first-adaptive-ui.md +51 -0
  173. package/observations/visual/material-3-expressive-system.md +52 -0
  174. package/package.json +65 -0
  175. package/patterns/GENERATED_INDEX.md +13 -0
  176. package/patterns/INDEX.md +41 -0
  177. package/patterns/README.md +5 -0
  178. package/patterns/consequential-action-confirmation.md +127 -0
  179. package/patterns/context-preserving-preview.md +145 -0
  180. package/patterns/daily-home-surface.md +134 -0
  181. package/patterns/mobile-primary-action.md +110 -0
  182. package/patterns/object-status-list.md +114 -0
  183. package/patterns/progressive-detail.md +113 -0
  184. package/patterns/quick-capture.md +132 -0
  185. package/prompts/CONSEQUENTIAL_ACTION_REVIEW.md +100 -0
  186. package/prompts/DESIGN_EVIDENCE_REVIEW.md +49 -0
  187. package/prompts/GENERATED_INDEX.md +11 -0
  188. package/prompts/INDEX.md +24 -0
  189. package/prompts/PROTOTYPE_REVIEW.md +189 -0
  190. package/prompts/QUICK_CAPTURE_STATE_REVIEW.md +74 -0
  191. package/prompts/TODO_APP_BENCHMARK.md +88 -0
  192. package/registry/objects.json +568 -0
  193. package/registry/relationships.json +972 -0
  194. package/research/GENERATED_INDEX.md +18 -0
  195. package/research/INDEX.md +40 -0
  196. package/research/accessibility/keyboard-focus-and-interaction-motion.md +62 -0
  197. package/research/accessibility/textual-error-recovery.md +57 -0
  198. package/research/performance/reserved-loading-space.md +56 -0
  199. package/research/products/apple-reminders.md +59 -0
  200. package/research/products/arc.md +61 -0
  201. package/research/products/linear.md +62 -0
  202. package/research/products/telegram.md +61 -0
  203. package/research/products/things-3.md +60 -0
  204. package/research/ux/contextual-agentic-interface.md +68 -0
  205. package/research/ux/high-risk-operational-flows.md +89 -0
  206. package/research/ux/motion-as-state-continuity.md +71 -0
  207. package/research/visual/expressive-system-ui-2026.md +75 -0
  208. package/reviews/GENERATED_INDEX.md +9 -0
  209. package/reviews/README.md +25 -0
  210. package/reviews/consequential-action-confirmation-review.md +92 -0
  211. package/reviews/todo-app-benchmark-reference-review.md +86 -0
  212. package/reviews/todo-reference-fixture-review.md +77 -0
  213. package/rules/GENERATED_INDEX.md +23 -0
  214. package/rules/INDEX.md +37 -0
  215. package/rules/accessibility/A11Y-001.md +58 -0
  216. package/rules/accessibility/A11Y-002.md +55 -0
  217. package/rules/accessibility/A11Y-003.md +54 -0
  218. package/rules/accessibility/A11Y-004.md +54 -0
  219. package/rules/ia/IA-001.md +60 -0
  220. package/rules/ia/IA-002.md +61 -0
  221. package/rules/performance/PERF-001.md +55 -0
  222. package/rules/product/PRD-001.md +61 -0
  223. package/rules/product/PRD-002.md +61 -0
  224. package/rules/ux/UX-001.md +58 -0
  225. package/rules/ux/UX-002.md +61 -0
  226. package/rules/ux/UX-003.md +60 -0
  227. package/rules/ux/UX-004.md +61 -0
  228. package/rules/ux/UX-005.md +62 -0
  229. package/rules/ux/UX-006.md +69 -0
  230. package/rules/visual/VIS-001.md +59 -0
  231. package/rules/visual/VIS-002.md +59 -0
  232. package/schema/checklist.schema.json +21 -0
  233. package/schema/common.schema.json +178 -0
  234. package/schema/observation.schema.json +21 -0
  235. package/schema/pattern.schema.json +21 -0
  236. package/schema/prompt.schema.json +21 -0
  237. package/schema/reference-project.schema.json +21 -0
  238. package/schema/research.schema.json +21 -0
  239. package/schema/review.schema.json +21 -0
  240. package/schema/rule.schema.json +21 -0
  241. package/skills/README.md +48 -0
  242. package/skills/accessibility-reviewer/SKILL.md +101 -0
  243. package/skills/agent-context/SKILL.md +34 -0
  244. package/skills/agent-context/agents/openai.yaml +4 -0
  245. package/skills/design-evidence-researcher/SKILL.md +47 -0
  246. package/skills/design-evidence-researcher/agents/openai.yaml +4 -0
  247. package/skills/design-reviewer/SKILL.md +113 -0
  248. package/skills/design-system-architect/SKILL.md +101 -0
  249. package/skills/information-architect/SKILL.md +97 -0
  250. package/skills/interaction-designer/SKILL.md +104 -0
  251. package/skills/knowledge-graph-architect/SKILL.md +96 -0
  252. package/skills/mobile-ux-expert/SKILL.md +105 -0
  253. package/skills/motion-designer/SKILL.md +100 -0
  254. package/skills/performance-reviewer/SKILL.md +97 -0
  255. package/skills/product-designer/SKILL.md +104 -0
  256. package/skills/prompt-architect/SKILL.md +105 -0
  257. package/skills/reference-driven-design/SKILL.md +119 -0
  258. package/skills/ux-reviewer/SKILL.md +99 -0
  259. package/skills/visual-designer/SKILL.md +107 -0
  260. package/starter-kit/AGENTS.md +37 -0
  261. package/starter-kit/BOOTSTRAP.md +13 -0
  262. package/starter-kit/INSTALL_WITH_AGENT.md +133 -0
  263. package/starter-kit/PROJECT_INTEGRATION.md +60 -0
  264. package/starter-kit/README.md +41 -0
  265. package/starter-kit/benchmarks/BENCHMARK_CHECKLIST.md +10 -0
  266. package/starter-kit/docs/DESIGN_DECISIONS.md +22 -0
  267. package/starter-kit/docs/INFORMATION_ARCHITECTURE.md +25 -0
  268. package/starter-kit/docs/PERSONAS.md +14 -0
  269. package/starter-kit/docs/PRD.md +32 -0
  270. package/starter-kit/docs/USER_FLOWS.md +19 -0
  271. package/starter-kit/reviews/DESIGN_REVIEW.md +49 -0
  272. package/starter-kit/templates/FEATURE_TEMPLATE.md +36 -0
  273. package/starter-kit/templates/TASK_TEMPLATE.md +22 -0
  274. package/templates/CHECKLIST_TEMPLATE.md +43 -0
  275. package/templates/OBSERVATION_TEMPLATE.md +41 -0
  276. package/templates/PATTERN_TEMPLATE.md +100 -0
  277. package/templates/PROMPT_TEMPLATE.md +46 -0
  278. package/templates/PROTOTYPE_REVIEW.md +50 -0
  279. package/templates/REFERENCE_PROJECT_TEMPLATE.md +49 -0
  280. package/templates/REVIEW_TEMPLATE.md +55 -0
  281. package/templates/RULE_TEMPLATE.md +57 -0
  282. package/tools/cli.mjs +46 -0
  283. package/tools/context.mjs +342 -0
  284. package/tools/designlint.mjs +77 -0
  285. package/tools/generate-indexes.mjs +621 -0
  286. package/tools/init.mjs +99 -0
  287. package/tools/validate-benchmark-evidence.mjs +248 -0
  288. package/tools/validate-knowledge.mjs +481 -0
package/AGENTS.md ADDED
@@ -0,0 +1,156 @@
1
+ # AI Design Context Agent Guide
2
+
3
+ AI Design Context is an AI-first knowledge base for teaching coding agents how to design modern consumer products.
4
+
5
+ Do not treat this repository as a documentation dump. Treat it as a knowledge graph.
6
+
7
+ ## Core Flow
8
+
9
+ Follow this order:
10
+
11
+ ```text
12
+ observation -> research -> knowledge -> rules -> patterns -> prompts -> reference projects -> reviews
13
+ ```
14
+
15
+ Never skip upstream evidence. Never generate UI from taste alone.
16
+
17
+ ## Architecture Source
18
+
19
+ Read `docs/KNOWLEDGE_ENGINE.md` before changing repository structure, adding object types, or changing relationships.
20
+
21
+ Use it as the source of truth for:
22
+
23
+ - schema-first object metadata;
24
+ - global IDs, aliases, and slugs;
25
+ - object metadata;
26
+ - relationship types;
27
+ - registry records;
28
+ - navigation;
29
+ - DesignLint readiness;
30
+ - long-term scalability.
31
+
32
+ ## Working Rules
33
+
34
+ - Improve architecture before adding volume.
35
+ - Prefer improving existing knowledge over creating parallel files.
36
+ - Keep every object connected to upstream sources and downstream usage.
37
+ - Use schema-compatible YAML front matter for new knowledge objects.
38
+ - Preserve schema-compatible YAML front matter on every migrated research, rule, pattern, prompt, and reference project.
39
+ - Use typed relationships only.
40
+ - Treat manual indexes as transitional context pages.
41
+ - Use generated indexes as the preferred navigation layer for the migrated minimal chain.
42
+ - Do not add rules without research.
43
+ - Do not add patterns without required rules and related research.
44
+ - Do not add prompts that invent design advice outside rules and patterns.
45
+ - Do not treat reference projects as demos; use them to validate the graph.
46
+
47
+ ## Agent Context Retrieval
48
+
49
+ Before planning or changing a user-facing product, UX, UI, accessibility, motion, or prompt task, resolve focused graph context:
50
+
51
+ ```bash
52
+ npm run context -- --task <task-slug-or-phrase> --intent implement
53
+ ```
54
+
55
+ Add `--platform mobile` when narrow-screen behavior matters. Before reviewing an implementation, reference fixture, benchmark artifact, or prompt output, use:
56
+
57
+ ```bash
58
+ npm run context -- --review <path-or-object-id> --intent qa
59
+ ```
60
+
61
+ Read the returned research and rules before making product decisions. Treat `draft` and `seed` objects as bounded guidance. If no context resolves, record an observation or research need rather than inventing a rule. Skip the command for backend-only, infrastructure-only, or unrelated maintenance tasks.
62
+
63
+ ## Knowledge Objects
64
+
65
+ - Observation
66
+ - Research
67
+ - Rule
68
+ - Pattern
69
+ - Prompt
70
+ - Skill
71
+ - Checklist
72
+ - Review
73
+ - Reference Project
74
+
75
+ ## Local Skill Specs
76
+
77
+ The current reusable agent skills live in `skills/*/SKILL.md`.
78
+
79
+ Use them when the task matches their role:
80
+
81
+ - `skills/product-designer/SKILL.md` for product direction, primary action, object model, and pattern selection.
82
+ - `skills/ux-reviewer/SKILL.md` for journey clarity, usability, state coverage, and user friction.
83
+ - `skills/information-architect/SKILL.md` for object model, navigation, hierarchy, labels, and status language.
84
+ - `skills/mobile-ux-expert/SKILL.md` for touch-first mobile behavior, capture flows, primary actions, and context preservation.
85
+ - `skills/interaction-designer/SKILL.md` for flow mechanics, feedback, recovery, previews, and state transitions.
86
+ - `skills/design-system-architect/SKILL.md` for semantic tokens, reusable state behavior, and pattern/component boundaries.
87
+ - `skills/visual-designer/SKILL.md` for visual hierarchy, spacing, typography, color meaning, and polish.
88
+ - `skills/motion-designer/SKILL.md` for purposeful motion and reduced-motion behavior.
89
+ - `skills/accessibility-reviewer/SKILL.md` for labels, focus, target size, contrast, errors, and reduced motion.
90
+ - `skills/performance-reviewer/SKILL.md` for perceived performance, loading behavior, responsiveness, and layout stability.
91
+ - `skills/design-reviewer/SKILL.md` for design QA, traceability checks, and rule/pattern coverage review.
92
+ - `skills/prompt-architect/SKILL.md` for graph-backed prompt structure and output contracts.
93
+ - `skills/knowledge-graph-architect/SKILL.md` for schema, registry, generated indexes, relationships, and validation scope.
94
+ - `skills/agent-context/SKILL.md` for focused graph retrieval before implementation or review.
95
+
96
+ These skill files are not registered knowledge objects yet. Do not add them to `registry/objects.json` until skill metadata migration is explicitly requested.
97
+
98
+ ## Relationship Discipline
99
+
100
+ Use the relationship types defined in `docs/KNOWLEDGE_ENGINE.md`:
101
+
102
+ - `derived_from`
103
+ - `cites`
104
+ - `inspired_by`
105
+ - `requires`
106
+ - `validates`
107
+ - `implements`
108
+ - `related_to`
109
+ - `supersedes`
110
+ - `deprecated_by`
111
+ - `replaced_by`
112
+
113
+ Every new object should be traceable.
114
+
115
+ ## Validation Discipline
116
+
117
+ Research, rules, patterns, prompts, and reference projects are the first migrated chain.
118
+
119
+ When changing `research/`, `rules/`, `patterns/`, `prompts/`, `examples/`, `registry/objects.json`, or `registry/relationships.json`:
120
+
121
+ 1. Keep front matter and registry records aligned.
122
+ 2. Keep relationship targets typed and resolvable.
123
+ 3. Run `npm run generate:indexes`.
124
+ 4. Run `npm run validate`.
125
+
126
+ Do not edit generated indexes manually.
127
+
128
+ The validator is intentionally limited. It does not replace future DesignLint and does not enforce unmigrated object types yet.
129
+
130
+ ## Quality Bar
131
+
132
+ Progress means:
133
+
134
+ - stronger relationships;
135
+ - fewer duplicates;
136
+ - better discoverability;
137
+ - clearer specifications;
138
+ - more reliable agent behavior.
139
+
140
+ Progress does not mean:
141
+
142
+ - more pages;
143
+ - more prompts;
144
+ - more rules without evidence;
145
+ - more disconnected examples.
146
+
147
+ ## Future Compatibility
148
+
149
+ Every architectural decision should support:
150
+
151
+ - 1000+ rules;
152
+ - 300+ patterns;
153
+ - 200+ prompts;
154
+ - multiple reference projects;
155
+ - future DesignLint integration;
156
+ - IDE and MCP integration.
package/CHANGELOG.md ADDED
@@ -0,0 +1,71 @@
1
+ # Changelog
2
+
3
+ ## Unreleased
4
+
5
+ - Rename the project to AI Design Context and use `ai-design-context` as the package name; keep the GitHub URL at `dev-ik/ai-design-rules`.
6
+ - Preserve historical releases, frozen benchmark evidence, stable graph identifiers, and schema URIs under their original names.
7
+ - Package the complete graph and upstream evidence with a dependency-free Node.js 20+ CLI and an explicit publish allowlist.
8
+ - Add `init` for preserving existing agent instructions and creating only missing templates, with repeated-run and symlink protections.
9
+ - Add installed-package `context` retrieval with absolute reading paths while preserving the existing checkout CLI contract.
10
+ - Verify offline installation and use of the actual npm tarball; run repository checks and tests before packing.
11
+
12
+ ## v0.4.0 — Focused Context And Applied Patterns
13
+
14
+ - Add an agent-led installation guide for pinned knowledge integration into existing product repositories.
15
+ - Add the consequential-action guidance chain: observations, research, `UX-006`, a confirmation pattern, a review prompt, and a reference specification with specification-level validation.
16
+ - Rank task context by exact identifiers and focused titles before incidental mentions, with whole-word matching and support for simple English task phrasing.
17
+ - Resolve all transitive required and upstream knowledge dependencies while limiting optional graph expansion; include an explanation for every selected object.
18
+ - Select platform context from eligible rules and patterns before ranking, and preserve JSON object fields with additive selection reasons.
19
+ - Apply `VIS-001` and `VIS-002` in Daily Home Surface and `UX-004` in Context-Preserving Preview, with concrete hierarchy, focus, interruption, and fallback contracts.
20
+ - Add regression coverage for realistic queries, dependency completeness, cycles, platform selection, and missing targets.
21
+ - Define the next paired rendered Todo run, with identical generation conditions, mobile/desktop state captures, interaction checks, and evaluation limits.
22
+ - Record the first paired rendered Todo run with frozen source, forty screenshots, exact context bundles, runtime measurements, and an internal unblinded evaluation.
23
+ - Extend Quick Capture State Review with populated-list keyboard paths and geometry checks for saving, wrapped errors, and retry, based on the observed benchmark gaps.
24
+
25
+ ### Evidence Boundary
26
+
27
+ The updated patterns and review prompt remain `draft` / `seed`. The [rendered Todo pair](evidence/todo/2026-09-28-codex-paired-todo/EVALUATION.md) scored 7.42 versus 7.67 in an internal unblinded evaluation, with equal visual-hierarchy scores and a worse sequential keyboard capture path in the rules-assisted output. One pair does not establish a general quality gain, independent validation, or an improvement over the previous release. The resulting review-prompt revision still needs a new paired run.
28
+
29
+ ## v0.3.0 — Expressive Systems And Agent Context
30
+
31
+ - Added primary-source observations for expressive platform materials, adaptive web UI, systematic motion, and observable agentic workflows.
32
+ - Added research on expressive system UI, motion as state continuity, and contextual agentic interfaces.
33
+ - Added `VIS-002`, `UX-004`, and `UX-005` for content-first expression, purposeful motion, and visible agent work.
34
+ - Added the `reference-driven-design` skill for evidence-backed reference selection without brand copying.
35
+ - Expanded Prototype Review and Design QA with visual layers, responsive behavior, complete state coverage, motion fallbacks, and agent lifecycle review.
36
+ - Improved research-led context retrieval so matching research can resolve downstream rules, prompts, and review gates.
37
+
38
+ ### Evidence Boundary
39
+
40
+ The new visual, motion, and agentic knowledge remains `draft` and `seed`. It is traceable to primary-source observations, but it does not yet have paired rendered benchmark evidence or independent evaluation. This release improves the knowledge and review workflow; it does not claim measured visual-quality gains.
41
+
42
+ ## v0.2.1 — Validation Hardening
43
+
44
+ - Fixed Unicode task lookup and exact object resolution in the agent context CLI.
45
+ - Removed unsafe HTML rendering from the runnable Todo fixture.
46
+ - Made the main validation command read-only so stale generated indexes fail CI.
47
+ - Hardened rendered benchmark screenshot path, file, and metadata validation.
48
+ - Improved malformed knowledge-object diagnostics and expanded regression coverage.
49
+
50
+ ## v0.2.0 — Evidence-Aware QA and Context Retrieval
51
+
52
+ - Added focused agent context retrieval for implementation and QA tasks.
53
+ - Added DesignLint v0 for evidence-chain relationship checks.
54
+ - Added benchmark-evidence validation with explicit directional-versus-rendered boundaries.
55
+ - Extended the graph with accessibility and performance observations, research, rules, prompts, reviews, and templates.
56
+ - Added a runnable Todo reference fixture with responsive and accessibility QA coverage.
57
+ - Expanded registry validation, generated indexes, and automated test coverage.
58
+
59
+ ### Evidence Boundary
60
+
61
+ The current Todo benchmark remains directional only. It does not claim paired rendered benchmark evidence, independent evaluation, or measured performance validation.
62
+
63
+ ## v0.1.0 — Foundation + Benchmark Ready
64
+
65
+ - Established the schema-first knowledge graph foundation.
66
+ - Migrated research, rules, patterns, and prompts to metadata-backed objects.
67
+ - Added generated indexes for research, rules, patterns, prompts, examples, and graph reporting.
68
+ - Added validation tooling for metadata, registry coverage, relationships, and generated index sync.
69
+ - Added benchmark methodology and evaluation rubric.
70
+ - Added first todo benchmark evidence.
71
+ - Completed OSS cleanup with no personal project references.
@@ -0,0 +1,29 @@
1
+ # Code of Conduct
2
+
3
+ AI Design Context is a public OSS project for practical, evidence-driven product design knowledge.
4
+
5
+ ## Expected Behavior
6
+
7
+ - Be direct, respectful, and specific.
8
+ - Critique ideas, files, and claims instead of people.
9
+ - Explain reasoning when proposing changes.
10
+ - Keep discussions focused on repository quality and public usefulness.
11
+ - Welcome good-faith contributions from people with different levels of design, engineering, and AI tooling experience.
12
+
13
+ ## Unacceptable Behavior
14
+
15
+ - Harassment, insults, threats, or personal attacks.
16
+ - Discriminatory language or behavior.
17
+ - Publishing private information without permission.
18
+ - Repeated low-effort comments that derail maintainers or contributors.
19
+ - Presenting unsupported claims as evidence.
20
+
21
+ ## Evidence Standard
22
+
23
+ This project values benchmark-backed and source-backed claims. If a discussion concerns product quality, design rules, or AI output improvement, prefer reproducible evidence over preference.
24
+
25
+ ## Enforcement
26
+
27
+ Maintainers may edit, close, hide, or remove issues, pull requests, comments, or accounts that violate this code of conduct.
28
+
29
+ For security-sensitive reports, use `SECURITY.md` instead of public issues.
@@ -0,0 +1,128 @@
1
+ # Contributing
2
+
3
+ AI Design Context accepts concise, practical contributions that help AI coding agents design better consumer products.
4
+
5
+ ## Contribution Pipeline
6
+
7
+ Use the same order as the repository:
8
+
9
+ ```text
10
+ observation -> research -> knowledge -> rules -> patterns -> prompts -> reference projects -> reviews
11
+ ```
12
+
13
+ Start with evidence. Do not add a rule, pattern, or prompt if the underlying product behavior is not clear.
14
+
15
+ ## What To Contribute
16
+
17
+ - Product research in `research/`.
18
+ - Design rules in `rules/`.
19
+ - Reusable patterns in `patterns/`.
20
+ - Product prompts in `prompts/`.
21
+ - Review checklists or templates in `checklists/` and `templates/`.
22
+ - Agent skills in `skills/` when a workflow is stable enough to reuse.
23
+
24
+ ## Rule Contributions
25
+
26
+ Use `templates/RULE_TEMPLATE.md`.
27
+
28
+ Every rule must include:
29
+
30
+ - why the rule exists;
31
+ - what good output looks like;
32
+ - what bad output looks like;
33
+ - how to review it.
34
+
35
+ Do not submit rules that are only taste, preference, or vague advice.
36
+
37
+ Rules are migrated objects. New or changed rule files must include schema-compatible YAML front matter and be listed in `registry/objects.json`.
38
+
39
+ If a rule changes upstream sources, update its typed `relationships` front matter.
40
+
41
+ ## Pattern Contributions
42
+
43
+ Use `templates/PATTERN_TEMPLATE.md`.
44
+
45
+ Every pattern must follow `docs/PATTERN_SPEC.md` and include schema-compatible YAML front matter.
46
+
47
+ Patterns are migrated objects. New or changed pattern files must:
48
+
49
+ - use a stable `PAT-00000` machine ID;
50
+ - keep a human-friendly alias;
51
+ - list required rule relationships;
52
+ - be listed in `registry/objects.json`;
53
+ - have required and related edges in `registry/relationships.json`.
54
+
55
+ ## Documentation Style
56
+
57
+ Follow `docs/STYLE_GUIDE.md`.
58
+
59
+ Write for agents that need to act inside a codebase. Prefer direct rules, clear examples, and reviewable criteria.
60
+
61
+ ## Knowledge Object Metadata
62
+
63
+ New object types and future metadata migrations should follow `docs/KNOWLEDGE_ENGINE.md`.
64
+
65
+ Do not create disconnected files. Every research, rule, pattern, prompt, checklist, skill, review, or reference project should link upstream sources and downstream usage.
66
+
67
+ ## Schema-First Contributions
68
+
69
+ New knowledge objects should include YAML front matter compatible with the relevant schema in `schema/`.
70
+
71
+ Research, rules, patterns, prompts, and reference projects are the first enforced migrated chain. Run:
72
+
73
+ ```sh
74
+ npm run generate:indexes
75
+ npm run validate
76
+ ```
77
+
78
+ before submitting changes to `research/`, `rules/`, `patterns/`, `prompts/`, `examples/`, `registry/objects.json`, or `registry/relationships.json`.
79
+
80
+ Use global machine IDs for new objects:
81
+
82
+ - `OBS-00001`
83
+ - `RESEARCH-00001`
84
+ - `RULE-00001`
85
+ - `PAT-00001`
86
+ - `PROMPT-00001`
87
+ - `REVIEW-00001`
88
+ - `CHECK-00001`
89
+ - `REF-00001`
90
+
91
+ Use `alias` for human-friendly IDs such as `UX-001`.
92
+
93
+ Use `slug` for file-safe names.
94
+
95
+ Relationships must be typed. Use only the relationship types defined in `schema/common.schema.json`.
96
+
97
+ Generated indexes are the preferred navigation layer for the migrated minimal chain:
98
+
99
+ - `research/GENERATED_INDEX.md`
100
+ - `rules/GENERATED_INDEX.md`
101
+ - `patterns/GENERATED_INDEX.md`
102
+ - `prompts/GENERATED_INDEX.md`
103
+ - `examples/GENERATED_INDEX.md`
104
+ - `graph/GENERATED_GRAPH.md`
105
+
106
+ Do not edit generated files manually. Update front matter and registry metadata, then run `npm run generate:indexes`.
107
+
108
+ Manual indexes are transitional. Keep them useful for human context, but do not treat them as the source of truth.
109
+
110
+ ## Reference Projects
111
+
112
+ Reference projects are intentionally omitted from the first OSS release.
113
+
114
+ Use `benchmarks/` and `evidence/` when validating new rules, prompts, or review checklists.
115
+
116
+ Future reference projects are not demos for decoration. They should use generic product archetypes and benchmark-backed evidence.
117
+
118
+ ## Review Checklist
119
+
120
+ Before opening a contribution:
121
+
122
+ - The content fits the repository pipeline.
123
+ - The file is in the correct folder.
124
+ - The naming follows existing conventions.
125
+ - The contribution explains why, not only what.
126
+ - There is no filler content.
127
+ - The change does not create a duplicate concept under a different name.
128
+ - Generated indexes are updated when registry metadata changes.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Dev Ik
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,283 @@
1
+ <p align="center">
2
+ <img src="assets/logo.svg" alt="AI Design Context logo" width="96" height="96">
3
+ </p>
4
+
5
+ <h1 align="center">AI Design Context</h1>
6
+
7
+ <p align="center">
8
+ <a href="LICENSE"><img alt="License: MIT" src="https://img.shields.io/badge/license-MIT-blue.svg"></a>
9
+ <a href="CHANGELOG.md"><img alt="Status: active" src="https://img.shields.io/badge/status-active-success.svg"></a>
10
+ <a href="evidence/README.md"><img alt="Evidence: benchmark driven" src="https://img.shields.io/badge/evidence-benchmark--driven-orange.svg"></a>
11
+ </p>
12
+
13
+ > **Build products. Not dashboards.**
14
+ >
15
+ > **Teach AI to think like a product designer.**
16
+
17
+ **AI Design Context** is a **vendor-neutral, evidence-driven knowledge base** for AI coding agents.
18
+
19
+ Instead of teaching AI how to generate interfaces, it teaches AI how to design modern software products through **research**, **design rules**, **reusable patterns**, and **reproducible benchmarks**.
20
+
21
+ Previously named **AI Design Rules**. Historical releases, benchmark artifacts, and stable schema identifiers retain the original name.
22
+
23
+ ---
24
+
25
+ ## Why AI Design Context?
26
+
27
+ Modern AI coding agents are excellent at generating code.
28
+
29
+ They are far less consistent at making product decisions.
30
+
31
+ AI Design Context helps agents move beyond generating screens by providing:
32
+
33
+ - Research-driven product knowledge
34
+ - Reusable design rules
35
+ - Composable UI patterns
36
+ - Structured design workflows
37
+ - Reproducible benchmarks
38
+
39
+ Instead of relying on prompts alone, agents learn from an evolving knowledge graph.
40
+
41
+ ---
42
+
43
+ ## Core Principles
44
+
45
+ - Research before implementation
46
+ - Rules before prompts
47
+ - Evidence over opinion
48
+ - Reusable patterns instead of one-off solutions
49
+ - Benchmarks instead of subjective claims
50
+
51
+ ---
52
+
53
+ ## Knowledge Pipeline
54
+
55
+ ```text
56
+ Observations
57
+ ↓
58
+ Research
59
+ ↓
60
+ Rules
61
+ ↓
62
+ Patterns
63
+ ↓
64
+ Prompts
65
+ ↓
66
+ Benchmarks
67
+ ↓
68
+ Evidence
69
+ ↓
70
+ Reviews
71
+ ```
72
+
73
+ The repository is built as a **schema-first knowledge graph** for both humans and AI coding agents.
74
+
75
+ ---
76
+
77
+ ## Features
78
+
79
+ - Vendor-neutral architecture
80
+ - Schema-first knowledge graph
81
+ - Stable IDs and typed relationships
82
+ - Research-driven design rules
83
+ - Reusable product and UI patterns
84
+ - AI agent skills
85
+ - Validation tooling
86
+ - Benchmark framework
87
+ - DesignLint v0 for evidence-chain relationship checks
88
+
89
+ ---
90
+
91
+ ## Supported AI Coding Agents
92
+
93
+ AI Design Context is model-agnostic and works with any AI coding agent capable of reading repository documentation, including:
94
+
95
+ - OpenAI Codex
96
+ - Claude Code
97
+ - Cursor
98
+ - GitHub Copilot
99
+ - Gemini CLI
100
+ - Cline
101
+ - Continue
102
+ - Aider
103
+
104
+ ---
105
+
106
+ ## Evidence-Driven Development
107
+
108
+ AI Design Context does **not** assume it improves AI output.
109
+
110
+ Every significant change should be validated using reproducible benchmarks.
111
+
112
+ ```text
113
+ Baseline AI
114
+ ↓
115
+ AI + AI Design Context
116
+ ```
117
+
118
+ The first benchmark is **directional**, not conclusive, and serves as the starting point for future public validation.
119
+
120
+ ---
121
+
122
+ ## Add It to a Product Repository
123
+
124
+ AI Design Context ships as the dependency-free npm package `ai-design-context` with a CLI and a versioned knowledge graph. Requires **Node.js 20 or later**. The GitHub repository stays at [`dev-ik/ai-design-rules`](https://github.com/dev-ik/ai-design-rules).
125
+
126
+ After the first npm publication:
127
+
128
+ ```bash
129
+ npm install --save-dev --save-exact ai-design-context
130
+ npx ai-design-context init
131
+ npx ai-design-context context --task quick-capture --platform mobile --intent implement
132
+ ```
133
+
134
+ Commit the project's dependency manifest and lockfile to pin the knowledge version. Installation alone does not edit project files: `init` explicitly appends a marked section to `AGENTS.md` and creates only missing product-context docs, feature/task templates, and review/benchmark checklists. It preserves existing instructions, populated files, and edited integration blocks; repeated runs do not duplicate them. Fill new placeholders with actual product context.
135
+
136
+ `context` reads the graph from the installed package, independently of the project's working directory. Markdown provides absolute reading paths; JSON adds `knowledgeRoot` and each object's `absolutePath` while preserving graph-relative `path`. Read the selected research and rules before implementing UI changes.
137
+
138
+ ```bash
139
+ npx ai-design-context context --object PAT-00002 --format json
140
+ npx ai-design-context context --review REF-00001 --intent qa
141
+ npx ai-design-context --help
142
+ ```
143
+
144
+ Review queries retrieve matching graph knowledge; they do not analyze arbitrary application files. Matching is lexical, with known IDs and slugs available when phrases do not match. See [Agent Context](docs/AGENT_CONTEXT.md).
145
+
146
+ Before publication, build a local tarball from this repository and install it into a product repository:
147
+
148
+ ```bash
149
+ # In the AI Design Context checkout. Runs graph checks and tests before packing.
150
+ npm pack
151
+
152
+ # In the product repository; replace the path with the generated tarball path.
153
+ npm install --save-dev /path/to/ai-design-context-0.4.0.tgz
154
+ npx ai-design-context init
155
+ ```
156
+
157
+ For deliberate updates after publication, run `npm install --save-dev --save-exact ai-design-context@<version>`, review the new guidance, and commit the lockfile. There are no install hooks, application runtime dependencies, or new UI frameworks.
158
+
159
+ Git submodules and sibling checkouts remain supported alternatives. See [Install with a Coding Agent](starter-kit/INSTALL_WITH_AGENT.md) for both npm and Git workflows.
160
+
161
+ Maintainers: [npm Releases](docs/NPM_RELEASE.md) describes initial publication and automatic publishing from GitHub Releases with npm Trusted Publishing.
162
+
163
+ ---
164
+
165
+ ## Quick Start
166
+
167
+ ```bash
168
+ npm install
169
+ npm run check
170
+ ```
171
+
172
+ This command validates metadata, relationships, generated indexes, and the repository knowledge graph.
173
+ It is read-only and fails when generated indexes are stale. After changing registry metadata, run `npm run generate:indexes` before `npm run check`.
174
+
175
+ For focused checks:
176
+
177
+ ```bash
178
+ npm run lint:design
179
+ npm run benchmark:validate
180
+ ```
181
+
182
+ The benchmark validator checks raw evidence completeness and distinguishes directional runs from rendered runs with local visual artifacts. It never treats scores alone as proof of product quality.
183
+
184
+ Ask the graph for task-specific context instead of reading every index manually:
185
+
186
+ ```bash
187
+ npm run context -- --task quick-capture --platform mobile
188
+ npm run context -- --review examples/todo-reference
189
+ ```
190
+
191
+ Use `--format json` when another agent or script will consume the result. See `docs/AGENT_CONTEXT.md` for the object-resolution and evidence-boundary contract.
192
+
193
+ ---
194
+
195
+ ## Recommended Workflow
196
+
197
+ 1. Read `AGENTS.md`
198
+ 2. Follow `docs/INDEX.md`
199
+ 3. Explore relevant research
200
+ 4. Select applicable rules
201
+ 5. Compose patterns
202
+ 6. Apply prompts
203
+ 7. Validate with benchmarks
204
+ 8. Record evidence
205
+ 9. Improve the knowledge graph
206
+
207
+ ---
208
+
209
+ ## Repository Structure
210
+
211
+ ```text
212
+ docs/
213
+ research/
214
+ rules/
215
+ patterns/
216
+ prompts/
217
+ skills/
218
+ benchmarks/
219
+ evidence/
220
+ starter-kit/
221
+ schema/
222
+ registry/
223
+ templates/
224
+ reviews/
225
+ observations/
226
+ ```
227
+
228
+ Generated indexes are built from repository metadata.
229
+
230
+ `starter-kit/` can be copied into a product repository that wants to adopt AI Design Context.
231
+
232
+ ---
233
+
234
+ ## Contributing
235
+
236
+ Start with:
237
+
238
+ - `CONTRIBUTING.md`
239
+ - `AGENTS.md`
240
+ - `docs/INDEX.md`
241
+
242
+ Every contribution should explain:
243
+
244
+ - where the knowledge came from;
245
+ - why it exists;
246
+ - when it applies;
247
+ - how it relates to existing knowledge.
248
+
249
+ ---
250
+
251
+ ## Project Status
252
+
253
+ AI Design Context is under active development.
254
+
255
+ Current public release includes:
256
+
257
+ - Schema-first architecture
258
+ - Knowledge graph
259
+ - JSON Schemas
260
+ - Stable metadata model
261
+ - Generated indexes
262
+ - Validation tooling
263
+ - Benchmark methodology
264
+ - AI agent skills
265
+
266
+ See `CHANGELOG.md` for release history.
267
+
268
+ ---
269
+
270
+ ## Roadmap
271
+
272
+ - Expanded benchmark evidence
273
+ - Public reference archetypes
274
+ - Expanded DesignLint semantics
275
+ - IDE integrations
276
+ - MCP integrations
277
+ - Community-driven rule evolution
278
+
279
+ ---
280
+
281
+ ## License
282
+
283
+ See `LICENSE`.