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.
- package/AGENTS.md +156 -0
- package/CHANGELOG.md +71 -0
- package/CODE_OF_CONDUCT.md +29 -0
- package/CONTRIBUTING.md +128 -0
- package/LICENSE +21 -0
- package/README.md +283 -0
- package/RELEASE_NOTES_v0.1.0.md +45 -0
- package/RELEASE_NOTES_v0.3.0.md +47 -0
- package/RELEASE_NOTES_v0.4.0.md +29 -0
- package/RELEASE_READINESS.md +107 -0
- package/ROADMAP.md +60 -0
- package/SECURITY.md +40 -0
- package/assets/logo.svg +9 -0
- package/benchmarks/README.md +19 -0
- package/benchmarks/chat.md +37 -0
- package/benchmarks/mobile-home-screen.md +38 -0
- package/benchmarks/notes-app.md +37 -0
- package/benchmarks/settings.md +37 -0
- package/benchmarks/shopping-list.md +37 -0
- package/benchmarks/todo-app.md +144 -0
- package/checklists/DESIGN_QA.md +102 -0
- package/checklists/GENERATED_INDEX.md +7 -0
- package/docs/AGENT_CONTEXT.md +111 -0
- package/docs/BENCHMARK.md +170 -0
- package/docs/DESIGNLINT_READINESS.md +110 -0
- package/docs/DESIGN_SYSTEM.md +23 -0
- package/docs/EVALUATION_RUBRIC.md +154 -0
- package/docs/GITHUB_SETUP.md +28 -0
- package/docs/GLOSSARY.md +45 -0
- package/docs/INDEX.md +109 -0
- package/docs/KNOWLEDGE_ENGINE.md +594 -0
- package/docs/MOBILE_FIRST.md +18 -0
- package/docs/NPM_RELEASE.md +43 -0
- package/docs/PATTERN_SPEC.md +113 -0
- package/docs/PHILOSOPHY.md +25 -0
- package/docs/PRODUCT_THINKING.md +26 -0
- package/docs/STYLE_GUIDE.md +49 -0
- package/docs/TRACEABILITY.md +45 -0
- package/evidence/README.md +64 -0
- package/evidence/TEMPLATE.md +46 -0
- package/evidence/chat/.gitkeep +1 -0
- package/evidence/mobile-home/.gitkeep +1 -0
- package/evidence/notes/.gitkeep +1 -0
- package/evidence/settings/.gitkeep +1 -0
- package/evidence/shopping/.gitkeep +1 -0
- package/evidence/todo/.gitkeep +1 -0
- package/evidence/todo/2026-06-25-codex-gpt-5/EVALUATION.md +66 -0
- package/evidence/todo/2026-06-25-codex-gpt-5/README.md +40 -0
- package/evidence/todo/2026-06-25-codex-gpt-5/ai-design-rules/generated-output.md +163 -0
- package/evidence/todo/2026-06-25-codex-gpt-5/ai-design-rules/metadata.json +38 -0
- package/evidence/todo/2026-06-25-codex-gpt-5/ai-design-rules/notes.md +20 -0
- package/evidence/todo/2026-06-25-codex-gpt-5/ai-design-rules/prompt.md +16 -0
- package/evidence/todo/2026-06-25-codex-gpt-5/ai-design-rules/scores.md +18 -0
- package/evidence/todo/2026-06-25-codex-gpt-5/baseline/generated-output.md +98 -0
- package/evidence/todo/2026-06-25-codex-gpt-5/baseline/metadata.json +19 -0
- package/evidence/todo/2026-06-25-codex-gpt-5/baseline/notes.md +19 -0
- package/evidence/todo/2026-06-25-codex-gpt-5/baseline/prompt.md +9 -0
- package/evidence/todo/2026-06-25-codex-gpt-5/baseline/scores.md +18 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/EVALUATION.md +70 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/README.md +52 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/GENERATION_NOTES.md +133 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/app.js +289 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/context/context-preserving-preview.json +443 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/context/daily-home-surface.json +373 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/context/quick-capture.json +301 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/context/sources-read.txt +36 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/generated-output.md +11 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/index.html +64 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/launch-prompt.md +1 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/metadata.json +55 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/notes.md +15 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/parent-status-message.md +1 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/prompt.md +49 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/runtime-checks.json +776 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/scores.md +20 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-completed.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-default.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-detail-reduced-motion.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-detail.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-empty.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-keyboard-focus.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-save-error.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-saved.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-saving.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/desktop-validation.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-completed.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-default.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-detail-reduced-motion.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-detail.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-empty.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-keyboard-focus.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-save-error.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-saved.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-saving.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/screenshots/mobile-validation.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/source-hashes.json +5 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/ai-design-rules/styles.css +122 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/GENERATION_NOTES.md +86 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/app.js +303 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/generated-output.md +11 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/index.html +71 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/launch-prompt.md +1 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/metadata.json +55 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/notes.md +15 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/parent-status-message.md +1 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/prompt.md +49 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/runtime-checks.json +772 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/scores.md +20 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-completed.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-default.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-detail-reduced-motion.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-detail.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-empty.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-keyboard-focus.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-save-error.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-saved.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-saving.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/desktop-validation.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-completed.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-default.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-detail-reduced-motion.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-detail.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-empty.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-keyboard-focus.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-save-error.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-saved.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-saving.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/screenshots/mobile-validation.png +0 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/source-hashes.json +5 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/baseline/styles.css +9 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/capture-ai-design-rules.js +60 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/capture-baseline.js +60 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/common/brief.md +35 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/common/knowledge-files.json +127 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/common/knowledge.patch +890 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/common/review-context.json +550 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/common/seed.json +86 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/common/setup.json +47 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/common/technical-envelope.md +11 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/layout-metrics.json +133 -0
- package/evidence/todo/2026-09-28-codex-paired-todo/layout-probe.js +15 -0
- package/examples/GENERATED_INDEX.md +8 -0
- package/examples/INDEX.md +16 -0
- package/examples/README.md +15 -0
- package/examples/consequential-action-confirmation-reference.md +83 -0
- package/examples/todo-app-benchmark.md +117 -0
- package/examples/todo-reference/README.md +29 -0
- package/examples/todo-reference/app.js +154 -0
- package/examples/todo-reference/favicon.svg +4 -0
- package/examples/todo-reference/index.html +67 -0
- package/examples/todo-reference/review-evidence/2026-07-15/desktop-default.png +0 -0
- package/examples/todo-reference/review-evidence/2026-07-15/desktop-detail.png +0 -0
- package/examples/todo-reference/review-evidence/2026-07-15/mobile-detail.png +0 -0
- package/examples/todo-reference/review-evidence/2026-07-15/mobile-error.png +0 -0
- package/examples/todo-reference/styles.css +241 -0
- package/graph/GENERATED_GRAPH.md +71 -0
- package/observations/README.md +23 -0
- package/observations/accessibility/reduced-interaction-motion.md +49 -0
- package/observations/accessibility/textual-error-recovery.md +50 -0
- package/observations/accessibility/visible-keyboard-focus.md +49 -0
- package/observations/ai/agent-consequential-action-controls.md +56 -0
- package/observations/ai/agent-work-visibility-and-intervention.md +51 -0
- package/observations/ai/figma-agent-context-and-skills.md +52 -0
- package/observations/finance/high-risk-wallet-recovery-flows.md +55 -0
- package/observations/finance/market-interface-adaptive-trading-surfaces.md +55 -0
- package/observations/interaction/chrome-scoped-view-transitions.md +52 -0
- package/observations/interaction/figma-motion-as-system-capability.md +53 -0
- package/observations/mobile/mobile-bottom-sheet-choice-contracts.md +55 -0
- package/observations/performance/reserved-loading-space.md +51 -0
- package/observations/product-repos/pinned-ai-design-rules-integration.md +49 -0
- package/observations/visual/apple-liquid-glass-functional-layer.md +52 -0
- package/observations/visual/chrome-content-first-adaptive-ui.md +51 -0
- package/observations/visual/material-3-expressive-system.md +52 -0
- package/package.json +65 -0
- package/patterns/GENERATED_INDEX.md +13 -0
- package/patterns/INDEX.md +41 -0
- package/patterns/README.md +5 -0
- package/patterns/consequential-action-confirmation.md +127 -0
- package/patterns/context-preserving-preview.md +145 -0
- package/patterns/daily-home-surface.md +134 -0
- package/patterns/mobile-primary-action.md +110 -0
- package/patterns/object-status-list.md +114 -0
- package/patterns/progressive-detail.md +113 -0
- package/patterns/quick-capture.md +132 -0
- package/prompts/CONSEQUENTIAL_ACTION_REVIEW.md +100 -0
- package/prompts/DESIGN_EVIDENCE_REVIEW.md +49 -0
- package/prompts/GENERATED_INDEX.md +11 -0
- package/prompts/INDEX.md +24 -0
- package/prompts/PROTOTYPE_REVIEW.md +189 -0
- package/prompts/QUICK_CAPTURE_STATE_REVIEW.md +74 -0
- package/prompts/TODO_APP_BENCHMARK.md +88 -0
- package/registry/objects.json +568 -0
- package/registry/relationships.json +972 -0
- package/research/GENERATED_INDEX.md +18 -0
- package/research/INDEX.md +40 -0
- package/research/accessibility/keyboard-focus-and-interaction-motion.md +62 -0
- package/research/accessibility/textual-error-recovery.md +57 -0
- package/research/performance/reserved-loading-space.md +56 -0
- package/research/products/apple-reminders.md +59 -0
- package/research/products/arc.md +61 -0
- package/research/products/linear.md +62 -0
- package/research/products/telegram.md +61 -0
- package/research/products/things-3.md +60 -0
- package/research/ux/contextual-agentic-interface.md +68 -0
- package/research/ux/high-risk-operational-flows.md +89 -0
- package/research/ux/motion-as-state-continuity.md +71 -0
- package/research/visual/expressive-system-ui-2026.md +75 -0
- package/reviews/GENERATED_INDEX.md +9 -0
- package/reviews/README.md +25 -0
- package/reviews/consequential-action-confirmation-review.md +92 -0
- package/reviews/todo-app-benchmark-reference-review.md +86 -0
- package/reviews/todo-reference-fixture-review.md +77 -0
- package/rules/GENERATED_INDEX.md +23 -0
- package/rules/INDEX.md +37 -0
- package/rules/accessibility/A11Y-001.md +58 -0
- package/rules/accessibility/A11Y-002.md +55 -0
- package/rules/accessibility/A11Y-003.md +54 -0
- package/rules/accessibility/A11Y-004.md +54 -0
- package/rules/ia/IA-001.md +60 -0
- package/rules/ia/IA-002.md +61 -0
- package/rules/performance/PERF-001.md +55 -0
- package/rules/product/PRD-001.md +61 -0
- package/rules/product/PRD-002.md +61 -0
- package/rules/ux/UX-001.md +58 -0
- package/rules/ux/UX-002.md +61 -0
- package/rules/ux/UX-003.md +60 -0
- package/rules/ux/UX-004.md +61 -0
- package/rules/ux/UX-005.md +62 -0
- package/rules/ux/UX-006.md +69 -0
- package/rules/visual/VIS-001.md +59 -0
- package/rules/visual/VIS-002.md +59 -0
- package/schema/checklist.schema.json +21 -0
- package/schema/common.schema.json +178 -0
- package/schema/observation.schema.json +21 -0
- package/schema/pattern.schema.json +21 -0
- package/schema/prompt.schema.json +21 -0
- package/schema/reference-project.schema.json +21 -0
- package/schema/research.schema.json +21 -0
- package/schema/review.schema.json +21 -0
- package/schema/rule.schema.json +21 -0
- package/skills/README.md +48 -0
- package/skills/accessibility-reviewer/SKILL.md +101 -0
- package/skills/agent-context/SKILL.md +34 -0
- package/skills/agent-context/agents/openai.yaml +4 -0
- package/skills/design-evidence-researcher/SKILL.md +47 -0
- package/skills/design-evidence-researcher/agents/openai.yaml +4 -0
- package/skills/design-reviewer/SKILL.md +113 -0
- package/skills/design-system-architect/SKILL.md +101 -0
- package/skills/information-architect/SKILL.md +97 -0
- package/skills/interaction-designer/SKILL.md +104 -0
- package/skills/knowledge-graph-architect/SKILL.md +96 -0
- package/skills/mobile-ux-expert/SKILL.md +105 -0
- package/skills/motion-designer/SKILL.md +100 -0
- package/skills/performance-reviewer/SKILL.md +97 -0
- package/skills/product-designer/SKILL.md +104 -0
- package/skills/prompt-architect/SKILL.md +105 -0
- package/skills/reference-driven-design/SKILL.md +119 -0
- package/skills/ux-reviewer/SKILL.md +99 -0
- package/skills/visual-designer/SKILL.md +107 -0
- package/starter-kit/AGENTS.md +37 -0
- package/starter-kit/BOOTSTRAP.md +13 -0
- package/starter-kit/INSTALL_WITH_AGENT.md +133 -0
- package/starter-kit/PROJECT_INTEGRATION.md +60 -0
- package/starter-kit/README.md +41 -0
- package/starter-kit/benchmarks/BENCHMARK_CHECKLIST.md +10 -0
- package/starter-kit/docs/DESIGN_DECISIONS.md +22 -0
- package/starter-kit/docs/INFORMATION_ARCHITECTURE.md +25 -0
- package/starter-kit/docs/PERSONAS.md +14 -0
- package/starter-kit/docs/PRD.md +32 -0
- package/starter-kit/docs/USER_FLOWS.md +19 -0
- package/starter-kit/reviews/DESIGN_REVIEW.md +49 -0
- package/starter-kit/templates/FEATURE_TEMPLATE.md +36 -0
- package/starter-kit/templates/TASK_TEMPLATE.md +22 -0
- package/templates/CHECKLIST_TEMPLATE.md +43 -0
- package/templates/OBSERVATION_TEMPLATE.md +41 -0
- package/templates/PATTERN_TEMPLATE.md +100 -0
- package/templates/PROMPT_TEMPLATE.md +46 -0
- package/templates/PROTOTYPE_REVIEW.md +50 -0
- package/templates/REFERENCE_PROJECT_TEMPLATE.md +49 -0
- package/templates/REVIEW_TEMPLATE.md +55 -0
- package/templates/RULE_TEMPLATE.md +57 -0
- package/tools/cli.mjs +46 -0
- package/tools/context.mjs +342 -0
- package/tools/designlint.mjs +77 -0
- package/tools/generate-indexes.mjs +621 -0
- package/tools/init.mjs +99 -0
- package/tools/validate-benchmark-evidence.mjs +248 -0
- package/tools/validate-knowledge.mjs +481 -0
|
@@ -0,0 +1,594 @@
|
|
|
1
|
+
# Knowledge Engine
|
|
2
|
+
|
|
3
|
+
AI Design Context is a schema-first, AI-first engineering knowledge graph for product design decisions.
|
|
4
|
+
|
|
5
|
+
It is not a documentation archive. Every object should connect to upstream evidence and downstream usage through machine-readable metadata.
|
|
6
|
+
|
|
7
|
+
```text
|
|
8
|
+
observation -> research -> knowledge -> rules -> patterns -> prompts -> reference projects -> reviews
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Knowledge Flow
|
|
12
|
+
|
|
13
|
+
## How Knowledge Enters
|
|
14
|
+
|
|
15
|
+
Knowledge enters as an observation: a specific product behavior, design decision, failure mode, review finding, or implementation result.
|
|
16
|
+
|
|
17
|
+
Observations should be concrete:
|
|
18
|
+
|
|
19
|
+
- product and source;
|
|
20
|
+
- screen or workflow;
|
|
21
|
+
- behavior observed;
|
|
22
|
+
- why it may matter;
|
|
23
|
+
- date captured.
|
|
24
|
+
|
|
25
|
+
Why this matters: raw observations prevent the repository from becoming a set of unsupported opinions.
|
|
26
|
+
|
|
27
|
+
## Observations Become Research
|
|
28
|
+
|
|
29
|
+
Research groups observations into product studies or theme studies.
|
|
30
|
+
|
|
31
|
+
A research file should separate:
|
|
32
|
+
|
|
33
|
+
- source signals;
|
|
34
|
+
- observed behavior;
|
|
35
|
+
- design takeaways;
|
|
36
|
+
- candidate rule directions;
|
|
37
|
+
- what not to copy blindly.
|
|
38
|
+
|
|
39
|
+
Why this matters: research turns raw evidence into reusable context without becoming a rule too early.
|
|
40
|
+
|
|
41
|
+
## Research Becomes Rules
|
|
42
|
+
|
|
43
|
+
Rules are extracted when the same design decision appears stable, reusable, and reviewable.
|
|
44
|
+
|
|
45
|
+
A rule must:
|
|
46
|
+
|
|
47
|
+
- point to source research;
|
|
48
|
+
- state the design instruction;
|
|
49
|
+
- explain why it exists;
|
|
50
|
+
- define good and bad output;
|
|
51
|
+
- provide an agent checklist.
|
|
52
|
+
|
|
53
|
+
Why this matters: rules are the smallest reviewable unit of product design guidance.
|
|
54
|
+
|
|
55
|
+
## Rules Compose Patterns
|
|
56
|
+
|
|
57
|
+
Patterns are compositions of rules. A pattern solves one product or UX problem by combining required rules, mobile behavior, desktop behavior, states, related research, and related patterns.
|
|
58
|
+
|
|
59
|
+
Patterns must follow `docs/PATTERN_SPEC.md`.
|
|
60
|
+
|
|
61
|
+
Why this matters: patterns prevent prompts from reassembling product structure from scratch every time.
|
|
62
|
+
|
|
63
|
+
## Patterns Drive Prompts
|
|
64
|
+
|
|
65
|
+
Prompts should reference patterns and rules explicitly.
|
|
66
|
+
|
|
67
|
+
A prompt should define:
|
|
68
|
+
|
|
69
|
+
- target product or workflow;
|
|
70
|
+
- required patterns;
|
|
71
|
+
- required rules;
|
|
72
|
+
- reference project, when applicable;
|
|
73
|
+
- review expectations.
|
|
74
|
+
|
|
75
|
+
Why this matters: prompts become application instructions, not a parallel source of design advice.
|
|
76
|
+
|
|
77
|
+
## Prompts Are Validated By Reference Projects
|
|
78
|
+
|
|
79
|
+
Reference projects show whether patterns and prompts work in realistic product contexts.
|
|
80
|
+
|
|
81
|
+
A reference project should list:
|
|
82
|
+
|
|
83
|
+
- patterns used;
|
|
84
|
+
- rules applied;
|
|
85
|
+
- research influence;
|
|
86
|
+
- validation questions;
|
|
87
|
+
- known gaps.
|
|
88
|
+
|
|
89
|
+
Why this matters: examples keep the knowledge graph grounded in product outcomes.
|
|
90
|
+
|
|
91
|
+
## Reviews Improve Knowledge
|
|
92
|
+
|
|
93
|
+
Reviews identify missing evidence, weak rules, overlapping patterns, and prompt failure modes.
|
|
94
|
+
|
|
95
|
+
A review can:
|
|
96
|
+
|
|
97
|
+
- add observations;
|
|
98
|
+
- recommend research updates;
|
|
99
|
+
- change rule status;
|
|
100
|
+
- clarify pattern ownership;
|
|
101
|
+
- mark prompts as unsafe, weak, or validated.
|
|
102
|
+
|
|
103
|
+
Why this matters: reviews are feedback loops, not final reports.
|
|
104
|
+
|
|
105
|
+
## Knowledge Object Metadata
|
|
106
|
+
|
|
107
|
+
Every knowledge object should use common metadata. Existing files are in migration; new objects should use schema-compatible YAML front matter.
|
|
108
|
+
|
|
109
|
+
The metadata schema lives in `schema/common.schema.json`.
|
|
110
|
+
|
|
111
|
+
Object-specific schemas live in `schema/`.
|
|
112
|
+
|
|
113
|
+
The registry proof-of-format lives in `registry/`.
|
|
114
|
+
|
|
115
|
+
Recommended machine-readable front matter:
|
|
116
|
+
|
|
117
|
+
```yaml
|
|
118
|
+
---
|
|
119
|
+
id: OBJ-000
|
|
120
|
+
alias: UX-001
|
|
121
|
+
slug: object-slug
|
|
122
|
+
title: Object title
|
|
123
|
+
object_type: rule
|
|
124
|
+
status: draft
|
|
125
|
+
version: 0.1.0
|
|
126
|
+
category: ux
|
|
127
|
+
relationships:
|
|
128
|
+
- type: derived_from
|
|
129
|
+
target: RESEARCH-00001
|
|
130
|
+
last_reviewed_at: 2026-06-25
|
|
131
|
+
---
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
Common status values:
|
|
135
|
+
|
|
136
|
+
- `draft`
|
|
137
|
+
- `active`
|
|
138
|
+
- `deprecated`
|
|
139
|
+
- `superseded`
|
|
140
|
+
|
|
141
|
+
Common maturity values:
|
|
142
|
+
|
|
143
|
+
- `seed`
|
|
144
|
+
- `reviewed`
|
|
145
|
+
- `validated`
|
|
146
|
+
- `canonical`
|
|
147
|
+
|
|
148
|
+
Common risk values:
|
|
149
|
+
|
|
150
|
+
- `low`
|
|
151
|
+
- `medium`
|
|
152
|
+
- `high`
|
|
153
|
+
- `critical`
|
|
154
|
+
|
|
155
|
+
## Maturity Lifecycle
|
|
156
|
+
|
|
157
|
+
Maturity expresses the strength of evidence behind an object, not whether its prose sounds complete.
|
|
158
|
+
|
|
159
|
+
```text
|
|
160
|
+
seed -> reviewed -> validated -> canonical
|
|
161
|
+
```
|
|
162
|
+
|
|
163
|
+
- `seed`: a draft object with traceable upstream evidence but no completed review.
|
|
164
|
+
- `reviewed`: an object reviewed on the recorded `last_reviewed_at` date; it can remain `draft` while follow-up work is open.
|
|
165
|
+
- `validated`: an `active` object with a resolvable `validates` relationship to evidence, a reference project, or a review.
|
|
166
|
+
- `canonical`: an `active`, validated object with a stable major version (`1.x.x` or higher). Use sparingly for guidance that should be the default choice.
|
|
167
|
+
|
|
168
|
+
`tools/validate-knowledge.mjs` enforces these observable lifecycle invariants. It cannot infer historical process, so do not promote maturity without recording the underlying review or validation relationship.
|
|
169
|
+
|
|
170
|
+
## Global IDs, Aliases, And Slugs
|
|
171
|
+
|
|
172
|
+
Use three identifiers:
|
|
173
|
+
|
|
174
|
+
- `id`: stable machine identifier. It must not change after publication.
|
|
175
|
+
- `alias`: human-friendly identifier such as `UX-001`, `VIS-001`, or `A11Y-001`.
|
|
176
|
+
- `slug`: URL-safe and file-friendly name.
|
|
177
|
+
|
|
178
|
+
Global ID prefixes:
|
|
179
|
+
|
|
180
|
+
- `OBS-00001`
|
|
181
|
+
- `RESEARCH-00001`
|
|
182
|
+
- `RULE-00001`
|
|
183
|
+
- `PAT-00001`
|
|
184
|
+
- `PROMPT-00001`
|
|
185
|
+
- `SKILL-00001`
|
|
186
|
+
- `REVIEW-00001`
|
|
187
|
+
- `CHECK-00001`
|
|
188
|
+
- `REF-00001`
|
|
189
|
+
|
|
190
|
+
Do not rename all existing files yet. Current files may keep human-readable names while metadata and registry entries introduce global IDs.
|
|
191
|
+
|
|
192
|
+
## Registry
|
|
193
|
+
|
|
194
|
+
The registry is the transitional source for machine-readable object discovery.
|
|
195
|
+
|
|
196
|
+
- `registry/objects.json` lists known object IDs, aliases, slugs, titles, types, statuses, versions, categories, and paths.
|
|
197
|
+
- `registry/relationships.json` lists typed edges between objects.
|
|
198
|
+
|
|
199
|
+
Generated indexes are the preferred navigation layer for migrated objects:
|
|
200
|
+
|
|
201
|
+
- `research/GENERATED_INDEX.md`
|
|
202
|
+
- `rules/GENERATED_INDEX.md`
|
|
203
|
+
- `patterns/GENERATED_INDEX.md`
|
|
204
|
+
- `prompts/GENERATED_INDEX.md`
|
|
205
|
+
- `checklists/GENERATED_INDEX.md`
|
|
206
|
+
- `examples/GENERATED_INDEX.md`
|
|
207
|
+
- `reviews/GENERATED_INDEX.md`
|
|
208
|
+
- `graph/GENERATED_GRAPH.md`
|
|
209
|
+
|
|
210
|
+
Manual indexes are temporary context pages. They should not become the source of truth for migrated objects.
|
|
211
|
+
|
|
212
|
+
Run `npm run generate:indexes` after changing registry metadata.
|
|
213
|
+
|
|
214
|
+
## Migration Status
|
|
215
|
+
|
|
216
|
+
The migrated knowledge flow is now registry-backed:
|
|
217
|
+
|
|
218
|
+
```text
|
|
219
|
+
research -> rules -> patterns -> prompts -> reference projects -> reviews
|
|
220
|
+
\-> checklists -/
|
|
221
|
+
```
|
|
222
|
+
|
|
223
|
+
Every current product research file, rule, pattern, prompt, checklist, reference project, and review in the migrated flow has schema-compatible YAML front matter with:
|
|
224
|
+
|
|
225
|
+
- global machine ID;
|
|
226
|
+
- human alias;
|
|
227
|
+
- slug;
|
|
228
|
+
- object type;
|
|
229
|
+
- status and version;
|
|
230
|
+
- category and tags;
|
|
231
|
+
- maturity and risk level;
|
|
232
|
+
- typed relationships.
|
|
233
|
+
|
|
234
|
+
`tools/validate-knowledge.mjs` validates schema-compatible observation front matter, every migrated directory (including `checklists/`, `examples/`, and `reviews/`), local Codex skill metadata, and registry relationship targets in both directions.
|
|
235
|
+
|
|
236
|
+
It also checks that generated indexes are in sync with registry metadata.
|
|
237
|
+
|
|
238
|
+
Observations are validated but are not registry-backed yet. Skills use standalone Codex metadata and are intentionally not registry objects until skill metadata migration is explicitly requested.
|
|
239
|
+
|
|
240
|
+
## Object Types
|
|
241
|
+
|
|
242
|
+
## Observation
|
|
243
|
+
|
|
244
|
+
Raw evidence captured before synthesis.
|
|
245
|
+
|
|
246
|
+
Required metadata:
|
|
247
|
+
|
|
248
|
+
- ID: stable `OBS-00001`.
|
|
249
|
+
- Title: concise observation name.
|
|
250
|
+
- Status: `draft`, `active`, `deprecated`, or `superseded`.
|
|
251
|
+
- Version: usually `0.1.0`.
|
|
252
|
+
- Category: product area or theme.
|
|
253
|
+
- Source: product, URL, screenshot, review, or implementation.
|
|
254
|
+
- Related Objects: linked research or review.
|
|
255
|
+
- Depends On: usually none.
|
|
256
|
+
- Used By: research files that absorb it.
|
|
257
|
+
- Last Reviewed: date.
|
|
258
|
+
|
|
259
|
+
## Research
|
|
260
|
+
|
|
261
|
+
Synthesis of observations from one product or theme.
|
|
262
|
+
|
|
263
|
+
Required metadata:
|
|
264
|
+
|
|
265
|
+
- ID: stable `RESEARCH-00001`.
|
|
266
|
+
- Title: product or theme name.
|
|
267
|
+
- Status: `draft`, `active`, `deprecated`, or `superseded`.
|
|
268
|
+
- Version: semantic version.
|
|
269
|
+
- Category: product, ux, ia, visual, accessibility, performance.
|
|
270
|
+
- Source: observations and external sources.
|
|
271
|
+
- Related Objects: adjacent research.
|
|
272
|
+
- Depends On: observations.
|
|
273
|
+
- Used By: rules and patterns.
|
|
274
|
+
- Last Reviewed: date.
|
|
275
|
+
|
|
276
|
+
## Rule
|
|
277
|
+
|
|
278
|
+
Reviewable design instruction extracted from research.
|
|
279
|
+
|
|
280
|
+
Required metadata:
|
|
281
|
+
|
|
282
|
+
- ID: stable `RULE-00001`.
|
|
283
|
+
- Title: rule name.
|
|
284
|
+
- Status: `draft`, `active`, `deprecated`, or `superseded`.
|
|
285
|
+
- Version: semantic version.
|
|
286
|
+
- Category: product, ia, ux, visual, accessibility, performance.
|
|
287
|
+
- Source: research files.
|
|
288
|
+
- Related Objects: adjacent or conflicting rules.
|
|
289
|
+
- Depends On: research.
|
|
290
|
+
- Used By: patterns, prompts, checklists, reference projects.
|
|
291
|
+
- Last Reviewed: date.
|
|
292
|
+
|
|
293
|
+
## Pattern
|
|
294
|
+
|
|
295
|
+
Reusable product structure composed from rules.
|
|
296
|
+
|
|
297
|
+
Required metadata:
|
|
298
|
+
|
|
299
|
+
- ID: stable `PAT-00001`.
|
|
300
|
+
- Title: pattern name.
|
|
301
|
+
- Status: `draft`, `active`, `deprecated`, or `superseded`.
|
|
302
|
+
- Version: semantic version.
|
|
303
|
+
- Category: product, ia, ux, mobile, workflow, accessibility.
|
|
304
|
+
- Source: required rules and related research.
|
|
305
|
+
- Related Objects: parent, child, alternative, adjacent patterns.
|
|
306
|
+
- Depends On: rules.
|
|
307
|
+
- Used By: prompts, reference projects, reviews.
|
|
308
|
+
- Last Reviewed: date.
|
|
309
|
+
|
|
310
|
+
## Prompt
|
|
311
|
+
|
|
312
|
+
Agent instruction that applies patterns and rules to a target task.
|
|
313
|
+
|
|
314
|
+
Required metadata:
|
|
315
|
+
|
|
316
|
+
- ID: stable `PROMPT-00001`.
|
|
317
|
+
- Title: prompt name.
|
|
318
|
+
- Status: `draft`, `active`, `deprecated`, or `superseded`.
|
|
319
|
+
- Version: semantic version.
|
|
320
|
+
- Category: generation, review, refactor, reference-project.
|
|
321
|
+
- Source: patterns and rules.
|
|
322
|
+
- Related Objects: examples, checklists, skills.
|
|
323
|
+
- Depends On: patterns and rules.
|
|
324
|
+
- Used By: skills and reference projects.
|
|
325
|
+
- Last Reviewed: date.
|
|
326
|
+
|
|
327
|
+
## Skill
|
|
328
|
+
|
|
329
|
+
Packaged agent workflow using prompts, patterns, rules, and checks.
|
|
330
|
+
|
|
331
|
+
Required metadata:
|
|
332
|
+
|
|
333
|
+
- ID: stable `SKILL-00001`.
|
|
334
|
+
- Title: skill name.
|
|
335
|
+
- Status: `draft`, `active`, `deprecated`, or `superseded`.
|
|
336
|
+
- Version: semantic version.
|
|
337
|
+
- Category: product, review, implementation, QA.
|
|
338
|
+
- Source: prompts, patterns, rules.
|
|
339
|
+
- Related Objects: checklists, reference projects.
|
|
340
|
+
- Depends On: prompts and checklists.
|
|
341
|
+
- Used By: agents.
|
|
342
|
+
- Last Reviewed: date.
|
|
343
|
+
|
|
344
|
+
## Checklist
|
|
345
|
+
|
|
346
|
+
Review artifact used to validate output.
|
|
347
|
+
|
|
348
|
+
Required metadata:
|
|
349
|
+
|
|
350
|
+
- ID: stable `CHECK-00001`.
|
|
351
|
+
- Title: checklist name.
|
|
352
|
+
- Status: `draft`, `active`, `deprecated`, or `superseded`.
|
|
353
|
+
- Version: semantic version.
|
|
354
|
+
- Category: review, accessibility, mobile, design-qa.
|
|
355
|
+
- Source: rules and patterns.
|
|
356
|
+
- Related Objects: reviews, prompts.
|
|
357
|
+
- Depends On: rules and patterns.
|
|
358
|
+
- Used By: reviews, prompts, skills.
|
|
359
|
+
- Last Reviewed: date.
|
|
360
|
+
|
|
361
|
+
## Review
|
|
362
|
+
|
|
363
|
+
Evaluation of a product, prompt output, rule set, or reference project.
|
|
364
|
+
|
|
365
|
+
Required metadata:
|
|
366
|
+
|
|
367
|
+
- ID: stable `REVIEW-00001`.
|
|
368
|
+
- Title: review name.
|
|
369
|
+
- Status: `draft`, `active`, `deprecated`, or `superseded`.
|
|
370
|
+
- Version: semantic version.
|
|
371
|
+
- Category: quality-gate, design-qa, prompt-eval, reference-eval.
|
|
372
|
+
- Source: reviewed object.
|
|
373
|
+
- Related Objects: issues found and patches proposed.
|
|
374
|
+
- Depends On: checklists, rules, patterns.
|
|
375
|
+
- Used By: research updates, rule updates, roadmap.
|
|
376
|
+
- Last Reviewed: date.
|
|
377
|
+
|
|
378
|
+
## Reference Project
|
|
379
|
+
|
|
380
|
+
Product context used to validate the graph.
|
|
381
|
+
|
|
382
|
+
Required metadata:
|
|
383
|
+
|
|
384
|
+
- ID: stable `REF-00001`.
|
|
385
|
+
- Title: reference project name.
|
|
386
|
+
- Status: `draft`, `active`, `deprecated`, or `superseded`.
|
|
387
|
+
- Version: semantic version.
|
|
388
|
+
- Category: consumer, productivity, collaboration, mobile-first.
|
|
389
|
+
- Source: product brief and prompts.
|
|
390
|
+
- Related Objects: patterns, rules, research.
|
|
391
|
+
- Depends On: prompts, patterns, rules.
|
|
392
|
+
- Used By: reviews and future DesignLint tests.
|
|
393
|
+
- Last Reviewed: date.
|
|
394
|
+
|
|
395
|
+
## Relationship Types
|
|
396
|
+
|
|
397
|
+
Use these relationship names consistently. Do not use broad untyped `related_objects`.
|
|
398
|
+
|
|
399
|
+
## `derived_from`
|
|
400
|
+
|
|
401
|
+
Use when an object is extracted from evidence.
|
|
402
|
+
|
|
403
|
+
Examples:
|
|
404
|
+
|
|
405
|
+
- Rule `derived_from` research.
|
|
406
|
+
- Research `derived_from` observations.
|
|
407
|
+
|
|
408
|
+
## `requires`
|
|
409
|
+
|
|
410
|
+
Use when an object cannot be valid without another object.
|
|
411
|
+
|
|
412
|
+
Examples:
|
|
413
|
+
|
|
414
|
+
- Pattern `requires` rules.
|
|
415
|
+
- Prompt `requires` patterns.
|
|
416
|
+
|
|
417
|
+
## `validates`
|
|
418
|
+
|
|
419
|
+
Use when an object proves another object works in context.
|
|
420
|
+
|
|
421
|
+
Examples:
|
|
422
|
+
|
|
423
|
+
- Reference project `validates` patterns.
|
|
424
|
+
- Review `validates` or rejects prompt output.
|
|
425
|
+
|
|
426
|
+
## `implements`
|
|
427
|
+
|
|
428
|
+
Use when a concrete artifact applies an abstract object.
|
|
429
|
+
|
|
430
|
+
Examples:
|
|
431
|
+
|
|
432
|
+
- Reference project `implements` patterns.
|
|
433
|
+
- Skill `implements` prompts.
|
|
434
|
+
|
|
435
|
+
## `related_to`
|
|
436
|
+
|
|
437
|
+
Use for non-required conceptual proximity.
|
|
438
|
+
|
|
439
|
+
Examples:
|
|
440
|
+
|
|
441
|
+
- Pattern `related_to` alternative pattern.
|
|
442
|
+
- Rule `related_to` adjacent rule.
|
|
443
|
+
|
|
444
|
+
## `supersedes`
|
|
445
|
+
|
|
446
|
+
Use when a newer object replaces an older one.
|
|
447
|
+
|
|
448
|
+
Examples:
|
|
449
|
+
|
|
450
|
+
- Rule version `supersedes` older rule.
|
|
451
|
+
- Prompt `supersedes` weak prompt.
|
|
452
|
+
|
|
453
|
+
## `deprecated_by`
|
|
454
|
+
|
|
455
|
+
Use when an object should no longer be used and points to a replacement.
|
|
456
|
+
|
|
457
|
+
Examples:
|
|
458
|
+
|
|
459
|
+
- Pattern `deprecated_by` stronger pattern.
|
|
460
|
+
- Research `deprecated_by` newer research.
|
|
461
|
+
|
|
462
|
+
## `cites`
|
|
463
|
+
|
|
464
|
+
Use when an object references a source without being derived from it.
|
|
465
|
+
|
|
466
|
+
Examples:
|
|
467
|
+
|
|
468
|
+
- Research `cites` a product documentation page.
|
|
469
|
+
- Review `cites` a checklist.
|
|
470
|
+
|
|
471
|
+
## `inspired_by`
|
|
472
|
+
|
|
473
|
+
Use when an object is influenced by a source but not directly extracted from it.
|
|
474
|
+
|
|
475
|
+
Examples:
|
|
476
|
+
|
|
477
|
+
- Observation `inspired_by` product behavior.
|
|
478
|
+
- Pattern `inspired_by` a product study.
|
|
479
|
+
|
|
480
|
+
## `replaced_by`
|
|
481
|
+
|
|
482
|
+
Use as the forward pointer from a deprecated object to its replacement.
|
|
483
|
+
|
|
484
|
+
Examples:
|
|
485
|
+
|
|
486
|
+
- Deprecated prompt `replaced_by` newer prompt.
|
|
487
|
+
- Deprecated pattern `replaced_by` canonical pattern.
|
|
488
|
+
|
|
489
|
+
## Repository Navigation
|
|
490
|
+
|
|
491
|
+
New contributors should be able to answer four questions quickly:
|
|
492
|
+
|
|
493
|
+
- Where is the rule?
|
|
494
|
+
- What research supports it?
|
|
495
|
+
- Which patterns use it?
|
|
496
|
+
- Which examples validate it?
|
|
497
|
+
|
|
498
|
+
Current navigation strategy:
|
|
499
|
+
|
|
500
|
+
- `docs/INDEX.md` explains the graph.
|
|
501
|
+
- `research/GENERATED_INDEX.md` lists current migrated research from registry metadata.
|
|
502
|
+
- `rules/GENERATED_INDEX.md` lists current migrated rules from registry metadata.
|
|
503
|
+
- `patterns/GENERATED_INDEX.md` lists current migrated patterns from registry metadata.
|
|
504
|
+
- `prompts/GENERATED_INDEX.md` lists current migrated prompts from registry metadata.
|
|
505
|
+
- `checklists/GENERATED_INDEX.md` lists current migrated checklists from registry metadata.
|
|
506
|
+
- `examples/GENERATED_INDEX.md` lists current migrated reference projects from registry metadata.
|
|
507
|
+
- `reviews/GENERATED_INDEX.md` lists current migrated reviews from registry metadata.
|
|
508
|
+
- `graph/GENERATED_GRAPH.md` reports graph coverage, orphans, missing targets, and chain usage.
|
|
509
|
+
- Manual `INDEX.md` files remain transitional human context pages.
|
|
510
|
+
|
|
511
|
+
At scale, every index should be sortable by ID, status, category, and last reviewed date.
|
|
512
|
+
|
|
513
|
+
Manual indexes are transitional. Generated indexes read `registry/objects.json` and `registry/relationships.json`.
|
|
514
|
+
|
|
515
|
+
For migrated research, rules, patterns, prompts, checklists, reference projects, and reviews, update metadata and registry records first, then regenerate indexes. Do not edit generated files manually.
|
|
516
|
+
|
|
517
|
+
## DesignLint Readiness
|
|
518
|
+
|
|
519
|
+
DesignLint should not inspect prose heuristically. It should read stable IDs, metadata, schemas, registry records, and typed relationships.
|
|
520
|
+
|
|
521
|
+
DesignLint will require:
|
|
522
|
+
|
|
523
|
+
- stable IDs for all objects;
|
|
524
|
+
- machine-readable object type;
|
|
525
|
+
- status and version;
|
|
526
|
+
- category;
|
|
527
|
+
- source links;
|
|
528
|
+
- required relationships;
|
|
529
|
+
- deprecation relationships;
|
|
530
|
+
- last reviewed dates;
|
|
531
|
+
- checklist coverage.
|
|
532
|
+
|
|
533
|
+
See `docs/DESIGNLINT_READINESS.md`.
|
|
534
|
+
|
|
535
|
+
Repository conventions to enforce:
|
|
536
|
+
|
|
537
|
+
- one object per file;
|
|
538
|
+
- stable IDs never reused;
|
|
539
|
+
- lowercase kebab-case filenames;
|
|
540
|
+
- object metadata at the top of each file;
|
|
541
|
+
- relationship values use known relationship types;
|
|
542
|
+
- required links point to existing files or IDs;
|
|
543
|
+
- deprecated objects name their replacement;
|
|
544
|
+
- active prompts reference active patterns and rules;
|
|
545
|
+
- reference projects list implemented patterns and rules.
|
|
546
|
+
|
|
547
|
+
Machine-readable relationships should support:
|
|
548
|
+
|
|
549
|
+
- rule coverage checks;
|
|
550
|
+
- pattern dependency checks;
|
|
551
|
+
- prompt dependency checks;
|
|
552
|
+
- reference project validation checks;
|
|
553
|
+
- stale object detection;
|
|
554
|
+
- orphan object detection;
|
|
555
|
+
- deprecated object usage warnings.
|
|
556
|
+
|
|
557
|
+
## Repository Audit
|
|
558
|
+
|
|
559
|
+
## Strengths
|
|
560
|
+
|
|
561
|
+
- Clear top-level graph: research, docs, rules, patterns, prompts, examples, benchmarks, and evidence.
|
|
562
|
+
- Research, rules, patterns, prompts, checklists, reference projects, and reviews now have generated indexes.
|
|
563
|
+
- Patterns have a strict specification and template.
|
|
564
|
+
- Benchmarks provide the current public validation mechanism.
|
|
565
|
+
- Rules already reference source research.
|
|
566
|
+
|
|
567
|
+
## Weaknesses
|
|
568
|
+
|
|
569
|
+
- Observations are validated but not registry-backed.
|
|
570
|
+
- The Todo App benchmark reference project is directional evidence only: it has no rendered output, screenshots, or independent evaluation.
|
|
571
|
+
- Rules need severity, category normalization, and checklist naming.
|
|
572
|
+
- The first review validates benchmark evidence, not a rendered product surface.
|
|
573
|
+
|
|
574
|
+
## Technical Debt
|
|
575
|
+
|
|
576
|
+
- Decide when to migrate observations into the registry.
|
|
577
|
+
- Decide which manual `INDEX.md` files should remain as human guides after generated navigation stabilizes.
|
|
578
|
+
- Add future reference archetypes only after benchmark-backed public validation exists.
|
|
579
|
+
- Expand generated indexes when more object metadata becomes enforceable.
|
|
580
|
+
- Add schema validation in CI after the lightweight validator stabilizes.
|
|
581
|
+
|
|
582
|
+
## Missing Architectural Pieces
|
|
583
|
+
|
|
584
|
+
- Observation intake format.
|
|
585
|
+
- Prompt specification.
|
|
586
|
+
- Skill specification.
|
|
587
|
+
- DesignLint schema.
|
|
588
|
+
|
|
589
|
+
## Recommended Roadmap After Phase 5
|
|
590
|
+
|
|
591
|
+
1. Phase 5.1: Migrate observations into the registry when intake volume justifies it.
|
|
592
|
+
2. Phase 5.2: Add rendered, independently evaluated reference projects.
|
|
593
|
+
3. Phase 5.3: Add schema validation in CI after the lightweight validator stabilizes.
|
|
594
|
+
4. Phase 5.4: Prototype DesignLint without prose heuristics.
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# Mobile First
|
|
2
|
+
|
|
3
|
+
Mobile-first means the product must work in the smallest common consumer context before desktop space is used for support.
|
|
4
|
+
|
|
5
|
+
Use `390px` width as the first-pass constraint for consumer workflows.
|
|
6
|
+
|
|
7
|
+
## Agent Checklist
|
|
8
|
+
|
|
9
|
+
- Is the primary action visible without horizontal scanning?
|
|
10
|
+
- Can the main action be reached in the thumb zone?
|
|
11
|
+
- Are tap targets at least `44x44` CSS pixels?
|
|
12
|
+
- Does navigation stay understandable without desktop sidebars?
|
|
13
|
+
- Do long labels wrap or compress without breaking layout?
|
|
14
|
+
- Are empty, loading, and error states usable on mobile?
|
|
15
|
+
|
|
16
|
+
## Desktop Rule
|
|
17
|
+
|
|
18
|
+
Desktop should add context, comparison, or speed. It should not change the core product model that mobile users rely on.
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
# npm Releases
|
|
2
|
+
|
|
3
|
+
Package: `ai-design-context`. GitHub: `dev-ik/ai-design-rules`.
|
|
4
|
+
|
|
5
|
+
## First publication
|
|
6
|
+
|
|
7
|
+
The first npm version is `0.4.0`. The existing GitHub `v0.4.0` release predates npm packaging; preserve its tag and release instead of moving them. Future npm releases use new matching version tags.
|
|
8
|
+
|
|
9
|
+
Log in with `npm login`, run `npm pack`, and publish the verified tarball with `npm publish ./ai-design-context-0.4.0.tgz --access public`. Complete npm's browser/2FA challenge if requested. Verify `npm view ai-design-context@0.4.0 version` and a clean consumer installation afterward.
|
|
10
|
+
|
|
11
|
+
## One-time trusted publisher setup
|
|
12
|
+
|
|
13
|
+
After the package exists on npm and `.github/workflows/publish.yml` is pushed, configure npm's Trusted Publisher for:
|
|
14
|
+
|
|
15
|
+
| Field | Value |
|
|
16
|
+
| --- | --- |
|
|
17
|
+
| Provider | GitHub Actions |
|
|
18
|
+
| Organization or user | `dev-ik` |
|
|
19
|
+
| Repository | `ai-design-rules` |
|
|
20
|
+
| Workflow filename | `publish.yml` |
|
|
21
|
+
| Environment | Leave empty |
|
|
22
|
+
| Allowed action | Direct `npm publish` |
|
|
23
|
+
|
|
24
|
+
Use the npm package settings page or, with npm >=11.15.0, an authenticated account with 2FA, and package write access:
|
|
25
|
+
|
|
26
|
+
```bash
|
|
27
|
+
npm trust github ai-design-context --repo dev-ik/ai-design-rules --file publish.yml --allow-publish --yes
|
|
28
|
+
npm trust list ai-design-context
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
The workflow uses a GitHub-hosted runner, Node.js 24, npm >=11.5.1, and `id-token: write`. No `NPM_TOKEN` secret is needed. Provenance links each release to its GitHub source. See [npm Trusted Publishing](https://docs.npmjs.com/trusted-publishers/) and [npm trust](https://docs.npmjs.com/cli/v11/commands/npm-trust/).
|
|
32
|
+
|
|
33
|
+
## Subsequent releases
|
|
34
|
+
|
|
35
|
+
1. Update `package.json` and `package-lock.json` to a new version, write its changelog, and run `npm run check` and `npm test`.
|
|
36
|
+
2. Commit and push the reviewed source, including the workflow and lockfile.
|
|
37
|
+
3. Create and push a tag matching `v<package.json version>`, such as `v0.4.1`.
|
|
38
|
+
4. Publish a GitHub Release for that tag. This triggers **Publish npm Package**.
|
|
39
|
+
5. Confirm the workflow succeeds, then verify the version in npm.
|
|
40
|
+
|
|
41
|
+
The workflow validates the release tag and prerelease status before installing, checking, testing, and packing. Stable releases publish under `latest`; versions such as `0.5.0-beta.1` require a GitHub prerelease and publish under `next`. Publishing a GitHub Release authorizes an immutable npm version; rerunning a successful publish cannot replace it.
|
|
42
|
+
|
|
43
|
+
A manual workflow run performs all checks and packs the package without publishing. Use this to verify Actions setup before creating a release. A failed or accidental release should be corrected with a new version; do not rewrite published npm versions or historical Git tags.
|