frontend-project-context 1.7.0 → 1.9.1

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 (55) hide show
  1. package/CHANGELOG.md +26 -0
  2. package/README.md +17 -10
  3. package/UPGRADING.md +18 -0
  4. package/docs/08-INSTALLATION-AND-DISTRIBUTION.md +29 -6
  5. package/docs/14-FORMAL-RELEASE-READINESS.md +14 -0
  6. package/docs/24-A130-REAL-HOST-TARGET-PROJECT-COMPARISON.md +1 -1
  7. package/docs/26-A130-QUALITY-CLOSURE-AND-ADAPTIVE-DELIVERY-REPAIR-DESIGN.md +1 -1
  8. package/docs/27-TEAM-SHARED-CONTEXT-DIRECTION-DISCUSSION.md +30 -0
  9. package/docs/28-REAL-PROJECT-ONBOARDING-CLOSURE-DESIGN.md +544 -0
  10. package/docs/29-REAL-PROJECT-1.8.0-INITIALIZATION-OBSERVATIONS.md +228 -0
  11. package/docs/30-TASK-CONTEXT-CONSUMPTION-CLOSURE-DESIGN.md +563 -0
  12. package/docs/31-TASK-CONTEXT-INTEGRITY-REPAIR-DESIGN.md +281 -0
  13. package/docs/AI-PROJECT-INITIALIZATION.md +90 -0
  14. package/docs/PRODUCT-SHARING-AND-ADOPTION-GUIDE.md +111 -0
  15. package/docs/README.md +24 -0
  16. package/docs/USER-AND-AI-OPERATION-MANUAL.md +17 -13
  17. package/docs/assets/product-sharing-01-overview.svg +32 -0
  18. package/docs/assets/product-sharing-02-how-it-works.svg +17 -0
  19. package/docs/assets/product-sharing-03-example.svg +19 -0
  20. package/examples/README.md +2 -2
  21. package/examples/package.json +1 -1
  22. package/migration-manifest.json +40 -10
  23. package/package.json +2 -2
  24. package/schemas/capabilities.schema.json +29 -10
  25. package/schemas/context-bundle.schema.json +32 -0
  26. package/schemas/coverage-audit.schema.json +6 -4
  27. package/schemas/evidence-bundle.schema.json +1 -1
  28. package/schemas/initialization-instruction.schema.json +72 -0
  29. package/schemas/migration-manifest.schema.json +3 -3
  30. package/schemas/migration-plan.schema.json +2 -2
  31. package/schemas/project-status.schema.json +5 -4
  32. package/schemas/projection-lock.schema.json +1 -1
  33. package/schemas/upgrade-assessment.schema.json +2 -2
  34. package/schemas/upgrade-result-bundle.schema.json +1 -1
  35. package/src/project-context/adaptive-context-schema.mjs +1 -1
  36. package/src/project-context/adaptive-context.mjs +12 -23
  37. package/src/project-context/ai-entry.mjs +24 -9
  38. package/src/project-context/approver.mjs +6 -2
  39. package/src/project-context/authoring.mjs +28 -8
  40. package/src/project-context/capabilities.mjs +18 -1
  41. package/src/project-context/checker.mjs +1 -1
  42. package/src/project-context/cli.mjs +44 -16
  43. package/src/project-context/context-bundle.mjs +378 -0
  44. package/src/project-context/contract-schema.mjs +62 -9
  45. package/src/project-context/coverage-profile.mjs +127 -0
  46. package/src/project-context/exchange-schema.mjs +24 -7
  47. package/src/project-context/exchange.mjs +3 -0
  48. package/src/project-context/initialization-instruction.mjs +60 -0
  49. package/src/project-context/maintenance.mjs +5 -4
  50. package/src/project-context/migration-manifest.mjs +5 -5
  51. package/src/project-context/project-status.mjs +14 -3
  52. package/src/project-context/project-store.mjs +27 -2
  53. package/src/project-context/renderer.mjs +11 -4
  54. package/src/project-context/source-reader.mjs +27 -2
  55. package/src/project-context/upgrade-schema.mjs +2 -2
@@ -0,0 +1,32 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="1200" height="520" viewBox="0 0 1200 520" role="img" aria-labelledby="title desc">
2
+ <title id="title">从分散知识到统一项目上下文</title>
3
+ <desc id="desc">分散的文档、配置和人工决定经过 Frontend Project Context,变成同一份可信上下文,供不同 AI 工具使用。</desc>
4
+ <defs>
5
+ <filter id="shadow" x="-20%" y="-20%" width="140%" height="140%"><feDropShadow dx="0" dy="8" stdDeviation="12" flood-color="#0f172a" flood-opacity=".12"/></filter>
6
+ <marker id="arrow" markerWidth="12" markerHeight="12" refX="10" refY="6" orient="auto"><path d="M0,0 L12,6 L0,12 Z" fill="#64748b"/></marker>
7
+ </defs>
8
+ <rect width="1200" height="520" rx="28" fill="#f8fafc"/>
9
+ <text x="600" y="54" text-anchor="middle" font-family="-apple-system,BlinkMacSystemFont,'Segoe UI','PingFang SC',sans-serif" font-size="28" font-weight="700" fill="#0f172a">把“到处找规则”变成“从同一份上下文开工”</text>
10
+ <g font-family="-apple-system,BlinkMacSystemFont,'Segoe UI','PingFang SC',sans-serif" filter="url(#shadow)">
11
+ <rect x="60" y="105" width="260" height="74" rx="16" fill="#fff"/><circle cx="98" cy="142" r="20" fill="#dbeafe"/><path d="M89 132h18v21H89zM93 127h10l4 5H89z" fill="#2563eb"/><text x="132" y="150" font-size="21" fill="#1e293b">设计与业务文档</text>
12
+ <rect x="60" y="205" width="260" height="74" rx="16" fill="#fff"/><circle cx="98" cy="242" r="20" fill="#fef3c7"/><path d="M86 237h24v13H86zM90 232h16v5H90z" fill="#d97706"/><text x="132" y="250" font-size="21" fill="#1e293b">配置与代码事实</text>
13
+ <rect x="60" y="305" width="260" height="74" rx="16" fill="#fff"/><circle cx="98" cy="342" r="20" fill="#ede9fe"/><path d="M88 342l7 7 14-17" fill="none" stroke="#7c3aed" stroke-width="5" stroke-linecap="round"/><text x="132" y="350" font-size="21" fill="#1e293b">团队的人工决定</text>
14
+ </g>
15
+ <path d="M350 242H438" stroke="#64748b" stroke-width="4" marker-end="url(#arrow)"/>
16
+ <g filter="url(#shadow)" font-family="-apple-system,BlinkMacSystemFont,'Segoe UI','PingFang SC',sans-serif">
17
+ <rect x="465" y="130" width="300" height="225" rx="28" fill="#1d4ed8"/>
18
+ <circle cx="615" cy="198" r="38" fill="#60a5fa"/><path d="M597 198h36M615 180v36" stroke="#fff" stroke-width="6" stroke-linecap="round"/>
19
+ <text x="615" y="270" text-anchor="middle" font-size="22" font-weight="700" fill="#fff">Frontend Project Context</text>
20
+ <text x="615" y="308" text-anchor="middle" font-size="20" fill="#dbeafe">统一、筛选、追溯、检查</text>
21
+ </g>
22
+ <path d="M792 242H866" stroke="#64748b" stroke-width="4" marker-end="url(#arrow)"/>
23
+ <g filter="url(#shadow)" font-family="-apple-system,BlinkMacSystemFont,'Segoe UI','PingFang SC',sans-serif">
24
+ <rect x="895" y="112" width="245" height="260" rx="26" fill="#fff"/>
25
+ <rect x="930" y="143" width="175" height="72" rx="14" fill="#ecfdf5"/><circle cx="966" cy="179" r="18" fill="#10b981"/><text x="966" y="186" text-anchor="middle" font-size="18" font-weight="700" fill="#fff">AI</text><text x="995" y="186" font-size="19" fill="#14532d">工具 A</text>
26
+ <rect x="930" y="228" width="175" height="72" rx="14" fill="#eff6ff"/><circle cx="966" cy="264" r="18" fill="#3b82f6"/><text x="966" y="271" text-anchor="middle" font-size="18" font-weight="700" fill="#fff">AI</text><text x="995" y="271" font-size="19" fill="#1e3a8a">工具 B</text>
27
+ <text x="1018" y="337" text-anchor="middle" font-size="18" fill="#475569">同一份项目上下文</text>
28
+ </g>
29
+ <text x="190" y="425" text-anchor="middle" font-family="-apple-system,BlinkMacSystemFont,'Segoe UI','PingFang SC',sans-serif" font-size="18" fill="#64748b">分散、难找、可能过期</text>
30
+ <text x="615" y="425" text-anchor="middle" font-family="-apple-system,BlinkMacSystemFont,'Segoe UI','PingFang SC',sans-serif" font-size="18" fill="#64748b">人工确认后才生效</text>
31
+ <text x="1018" y="425" text-anchor="middle" font-family="-apple-system,BlinkMacSystemFont,'Segoe UI','PingFang SC',sans-serif" font-size="18" fill="#64748b">换工具不再重新解释</text>
32
+ </svg>
@@ -0,0 +1,17 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="1200" height="430" viewBox="0 0 1200 430" role="img" aria-labelledby="title desc">
2
+ <title id="title">Frontend Project Context 的四步工作方式</title>
3
+ <desc id="desc">从找到可靠来源,经过人工确认,按任务选择内容,到变化时提醒复核。</desc>
4
+ <defs><marker id="arrow" markerWidth="12" markerHeight="12" refX="10" refY="6" orient="auto"><path d="M0,0 L12,6 L0,12 Z" fill="#94a3b8"/></marker></defs>
5
+ <rect width="1200" height="430" rx="28" fill="#0f172a"/>
6
+ <text x="600" y="58" text-anchor="middle" font-family="-apple-system,BlinkMacSystemFont,'Segoe UI','PingFang SC',sans-serif" font-size="28" font-weight="700" fill="#fff">只需要理解四个动作</text>
7
+ <g font-family="-apple-system,BlinkMacSystemFont,'Segoe UI','PingFang SC',sans-serif">
8
+ <g><rect x="55" y="112" width="235" height="220" rx="24" fill="#fff"/><circle cx="172" cy="168" r="34" fill="#dbeafe"/><text x="172" y="179" text-anchor="middle" font-size="30" font-weight="700" fill="#2563eb">1</text><text x="172" y="231" text-anchor="middle" font-size="24" font-weight="700" fill="#0f172a">找来源</text><text x="172" y="270" text-anchor="middle" font-size="18" fill="#64748b">知道信息从哪来</text><text x="172" y="299" text-anchor="middle" font-size="18" fill="#64748b">不把传言当规则</text></g>
9
+ <path d="M300 222H332" stroke="#94a3b8" stroke-width="4" marker-end="url(#arrow)"/>
10
+ <g><rect x="345" y="112" width="235" height="220" rx="24" fill="#fff"/><circle cx="462" cy="168" r="34" fill="#dcfce7"/><text x="462" y="179" text-anchor="middle" font-size="30" font-weight="700" fill="#16a34a">2</text><text x="462" y="231" text-anchor="middle" font-size="24" font-weight="700" fill="#0f172a">人确认</text><text x="462" y="270" text-anchor="middle" font-size="18" fill="#64748b">AI 可以提议</text><text x="462" y="299" text-anchor="middle" font-size="18" fill="#64748b">人决定是否生效</text></g>
11
+ <path d="M590 222H622" stroke="#94a3b8" stroke-width="4" marker-end="url(#arrow)"/>
12
+ <g><rect x="635" y="112" width="235" height="220" rx="24" fill="#fff"/><circle cx="752" cy="168" r="34" fill="#fef3c7"/><text x="752" y="179" text-anchor="middle" font-size="30" font-weight="700" fill="#d97706">3</text><text x="752" y="231" text-anchor="middle" font-size="24" font-weight="700" fill="#0f172a">按任务给</text><text x="752" y="270" text-anchor="middle" font-size="18" fill="#64748b">只给当前需要的</text><text x="752" y="299" text-anchor="middle" font-size="18" fill="#64748b">不用每次读全部</text></g>
13
+ <path d="M880 222H912" stroke="#94a3b8" stroke-width="4" marker-end="url(#arrow)"/>
14
+ <g><rect x="925" y="112" width="220" height="220" rx="24" fill="#fff"/><circle cx="1035" cy="168" r="34" fill="#fee2e2"/><text x="1035" y="179" text-anchor="middle" font-size="30" font-weight="700" fill="#dc2626">4</text><text x="1035" y="231" text-anchor="middle" font-size="24" font-weight="700" fill="#0f172a">变了提醒</text><text x="1035" y="270" text-anchor="middle" font-size="18" fill="#64748b">规则过期时报告</text><text x="1035" y="299" text-anchor="middle" font-size="18" fill="#64748b">不自动猜测修复</text></g>
15
+ </g>
16
+ <text x="600" y="385" text-anchor="middle" font-family="-apple-system,BlinkMacSystemFont,'Segoe UI','PingFang SC',sans-serif" font-size="20" fill="#cbd5e1">核心原则:上下文属于项目和团队,人保留最终决定权</text>
17
+ </svg>
@@ -0,0 +1,19 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="1200" height="500" viewBox="0 0 1200 500" role="img" aria-labelledby="title desc">
2
+ <title id="title">不同模块获得不同的精准上下文</title>
3
+ <desc id="desc">全局规则适用于整个项目,航班规则只传递给航班任务,酒店规则只传递给酒店任务。</desc>
4
+ <defs><marker id="blueArrow" markerWidth="12" markerHeight="12" refX="10" refY="6" orient="auto"><path d="M0,0 L12,6 L0,12 Z" fill="#3b82f6"/></marker><marker id="greenArrow" markerWidth="12" markerHeight="12" refX="10" refY="6" orient="auto"><path d="M0,0 L12,6 L0,12 Z" fill="#10b981"/></marker></defs>
5
+ <rect width="1200" height="500" rx="28" fill="#f8fafc"/>
6
+ <text x="600" y="52" text-anchor="middle" font-family="-apple-system,BlinkMacSystemFont,'Segoe UI','PingFang SC',sans-serif" font-size="28" font-weight="700" fill="#0f172a">不是给得越多越好,而是给得越准越好</text>
7
+ <g font-family="-apple-system,BlinkMacSystemFont,'Segoe UI','PingFang SC',sans-serif">
8
+ <rect x="55" y="98" width="290" height="92" rx="20" fill="#0f172a"/><text x="200" y="137" text-anchor="middle" font-size="22" font-weight="700" fill="#fff">全项目共同规则</text><text x="200" y="169" text-anchor="middle" font-size="17" fill="#cbd5e1">例:接口错误处理原则</text>
9
+ <rect x="55" y="226" width="290" height="92" rx="20" fill="#dbeafe"/><text x="200" y="265" text-anchor="middle" font-size="22" font-weight="700" fill="#1d4ed8">航班模块规则</text><text x="200" y="297" text-anchor="middle" font-size="17" fill="#1e40af">例:统一价格明细</text>
10
+ <rect x="55" y="354" width="290" height="92" rx="20" fill="#d1fae5"/><text x="200" y="393" text-anchor="middle" font-size="22" font-weight="700" fill="#047857">酒店模块规则</text><text x="200" y="425" text-anchor="middle" font-size="17" fill="#065f46">例:房型和入住人校验</text>
11
+ <rect x="515" y="130" width="280" height="250" rx="28" fill="#fff" stroke="#cbd5e1" stroke-width="2"/><circle cx="655" cy="202" r="42" fill="#2563eb"/><text x="655" y="212" text-anchor="middle" font-size="24" font-weight="700" fill="#fff">AI</text><text x="655" y="276" text-anchor="middle" font-size="24" font-weight="700" fill="#0f172a">当前任务</text><text x="655" y="315" text-anchor="middle" font-size="20" fill="#475569">修改航班价格页面</text><rect x="570" y="338" width="170" height="28" rx="14" fill="#eff6ff"/><text x="655" y="358" text-anchor="middle" font-size="15" fill="#1d4ed8">目标:src/flight</text>
12
+ <path d="M355 144C430 144 430 190 500 190" fill="none" stroke="#64748b" stroke-width="4" marker-end="url(#blueArrow)"/>
13
+ <path d="M355 272C430 272 430 250 500 250" fill="none" stroke="#3b82f6" stroke-width="6" marker-end="url(#blueArrow)"/>
14
+ <path d="M355 400C440 400 438 334 500 322" fill="none" stroke="#cbd5e1" stroke-width="4" stroke-dasharray="9 9"/>
15
+ <circle cx="468" cy="340" r="15" fill="#fff" stroke="#ef4444" stroke-width="3"/><path d="M461 333l14 14M475 333l-14 14" stroke="#ef4444" stroke-width="3"/>
16
+ <rect x="875" y="150" width="270" height="210" rx="26" fill="#eff6ff" stroke="#93c5fd" stroke-width="2"/><text x="1010" y="198" text-anchor="middle" font-size="23" font-weight="700" fill="#1e3a8a">AI 本次拿到</text><text x="915" y="247" font-size="19" fill="#1e3a8a">✓ 全项目共同规则</text><text x="915" y="286" font-size="19" fill="#1e3a8a">✓ 航班模块规则</text><text x="915" y="325" font-size="19" fill="#64748b">— 不带入酒店规则</text>
17
+ <path d="M810 255H855" stroke="#10b981" stroke-width="5" marker-end="url(#greenArrow)"/>
18
+ </g>
19
+ </svg>
@@ -2,10 +2,10 @@
2
2
 
3
3
  包实际发布后,把 [package.json](./package.json) 中的脚本和 devDependency 合并到项目,并把 [project-context-check.yml](./project-context-check.yml) 复制到 `.github/workflows/project-context-check.yml`。
4
4
 
5
- 维护者首次初始化:
5
+ 维护者首次初始化前先读取包内唯一指令;后续命令由该指令和一次集中语义确认驱动:
6
6
 
7
7
  ```bash
8
- npm run context:setup -- --id my-project --name "My Project" --write --json
8
+ npm exec --offline -- project-context instructions --project . --prompt
9
9
  ```
10
10
 
11
11
  为完全新窗口写入稳定入口并查询治理健康:
@@ -14,6 +14,6 @@
14
14
  "context:upgrade-check": "project-context upgrade-check --project ."
15
15
  },
16
16
  "devDependencies": {
17
- "frontend-project-context": "1.7.0"
17
+ "frontend-project-context": "1.9.1"
18
18
  }
19
19
  }
@@ -23,14 +23,17 @@
23
23
  "consumerChanges": {
24
24
  "actionPlan": {"reason": "Action Plan schema 1 and 2 readers remain compatible; writers remain schema 2.", "state": "preserve"},
25
25
  "adaptiveContextBundle": {"reason": "Schema 1 Adaptive Context Bundles lack task lineage and strict withheld-delivery semantics; regenerate as schema 2.", "state": "regenerate"},
26
- "capabilities": {"reason": "Consumers must branch on capabilities schema 7 and exchange protocol 7.", "state": "regenerate"},
26
+ "capabilities": {"reason": "Consumers must branch on capabilities schema 9 and exchange protocol 9.", "state": "regenerate"},
27
+ "contextBundle": {"reason": "Context Bundle schema 1 is short-lived and must be regenerated from the current Contract and exact task paths.", "state": "regenerate"},
27
28
  "contextQuery": {"reason": "Context Query schema 1 is short-lived and must use current snapshots.", "state": "regenerate"},
28
- "coverageAudit": {"reason": "Coverage Audit schema 1 is derived from the current Contract and filesystem evidence.", "state": "regenerate"},
29
+ "coverageAudit": {"reason": "Coverage Audit schema 2 is derived from the current Contract and declared coverage profile.", "state": "regenerate"},
29
30
  "evidenceBundle": {"reason": "Evidence Bundle schema 1 remains readable and separate from upgrade results.", "state": "preserve"},
30
31
  "evidenceInput": {"reason": "Evidence Input schema 1 remains readable and is never rewritten by upgrade.", "state": "preserve"},
31
- "exchange": {"reason": "Exchange protocol capability metadata changes to version 7.", "state": "regenerate"},
32
+ "exchange": {"reason": "Exchange protocol capability metadata changes to version 9.", "state": "regenerate"},
32
33
  "hostPromotionEvidence": {"reason": "Host Promotion Evidence is short-lived and remains bound to exact code, artifact, and Project Context snapshots.", "state": "regenerate"},
34
+ "initializationInstruction": {"reason": "Schema 2 adds concentrated human entry rule dispositions and remains package-derived.", "state": "regenerate"},
33
35
  "integrationReviewBundle": {"reason": "Short-lived integration review bundles must be regenerated against current baselines.", "state": "regenerate"},
36
+ "projectStatus": {"reason": "Schema 2 separates governance health from Contract readiness and task-context routing.", "state": "regenerate"},
34
37
  "reviewBundle": {"reason": "Review Bundle schema 2 remains readable but short-lived reviews must be regenerated when their baselines change.", "state": "regenerate"},
35
38
  "routingIndex": {"reason": "Routing Index schema 1 is disposable derived data and must be rebuilt from the current Contract.", "state": "invalidate"},
36
39
  "stageContextBundle": {"reason": "Short-lived stage context bundles must be regenerated against current receipts.", "state": "regenerate"},
@@ -40,8 +43,8 @@
40
43
  ,"truthReconciliationReviewBundle": {"reason": "Schema 1 reviews lack finding digests and machine-verifiable resolution outcomes; recompute as schema 2.", "state": "regenerate"}
41
44
  },
42
45
  "externalEffects": {"automaticUpgrade": false, "businessCode": false, "git": false, "network": false, "packageManager": false, "projectTests": false},
43
- "manifestDigest": "sha256:34b1b611ebf31471f2e136eb3f84ad627df612998d0358654e7cdde4713de777",
44
- "package": {"name": "frontend-project-context", "version": "1.7.0"},
46
+ "manifestDigest": "sha256:8b1a6bce6ac179591b122593c062cf6d0f80680da1eca5aba663e3273bbd1e56",
47
+ "package": {"name": "frontend-project-context", "version": "1.9.1"},
45
48
  "paths": [
46
49
  {
47
50
  "acceptance": ["project-context-clean", "target-renderers-current"],
@@ -74,18 +77,45 @@
74
77
  "migrationIds": ["upgrade.republish-ai-entry.v1"],
75
78
  "requiresHumanReview": false,
76
79
  "rollbackClass": "package-only"
80
+ },
81
+ {
82
+ "acceptance": ["project-context-clean", "target-renderers-current"],
83
+ "classification": "package-only",
84
+ "fromVersion": "1.7.0",
85
+ "migrationIds": ["upgrade.republish-ai-entry.v1"],
86
+ "requiresHumanReview": false,
87
+ "rollbackClass": "package-only"
88
+ },
89
+ {
90
+ "acceptance": ["project-context-clean", "target-renderers-current"],
91
+ "classification": "package-only",
92
+ "fromVersion": "1.8.0",
93
+ "migrationIds": ["upgrade.republish-ai-entry.v1"],
94
+ "requiresHumanReview": false,
95
+ "rollbackClass": "package-only"
96
+ },
97
+ {
98
+ "acceptance": ["project-context-clean", "target-renderers-current"],
99
+ "classification": "package-only",
100
+ "fromVersion": "1.9.0",
101
+ "migrationIds": [],
102
+ "requiresHumanReview": false,
103
+ "rollbackClass": "package-only"
77
104
  }
78
105
  ],
79
106
  "protocols": {
80
107
  "actionPlan": {"readable": [1, 2], "written": 2},
81
108
  "adaptiveContextBundle": {"readable": [2], "written": 2},
109
+ "contextBundle": {"readable": [1], "written": 1},
82
110
  "contextQuery": {"readable": [2], "written": 2},
83
- "coverageAudit": {"readable": [1], "written": 1},
111
+ "coverageAudit": {"readable": [1, 2], "written": 2},
84
112
  "evidenceBundle": {"readable": [1], "written": 1},
85
113
  "evidenceInput": {"readable": [1], "written": 1},
86
- "exchange": {"readable": [4, 5, 6, 7], "written": 7},
114
+ "exchange": {"readable": [4, 5, 6, 7, 8, 9], "written": 9},
87
115
  "hostPromotionEvidence": {"readable": [1], "written": 1},
116
+ "initializationInstruction": {"readable": [1, 2], "written": 2},
88
117
  "integrationReviewBundle": {"readable": [1], "written": 1},
118
+ "projectStatus": {"readable": [1, 2], "written": 2},
89
119
  "reviewBundle": {"readable": [1, 2], "written": 2},
90
120
  "routingIndex": {"readable": [1, 2], "written": 2},
91
121
  "stageContextBundle": {"readable": [1], "written": 1},
@@ -95,16 +125,16 @@
95
125
  "truthReconciliationReviewBundle": {"readable": [2], "written": 2}
96
126
  },
97
127
  "renderers": {
98
- "aiEntry": {"readable": [1, 2, 3], "written": 3},
128
+ "aiEntry": {"readable": [1, 2, 3, 4, 5], "written": 5},
99
129
  "projection": {"readable": [1, 2, 3], "written": 3}
100
130
  },
101
131
  "rollback": {"automatic": false, "defaultClass": "package-only", "externalRestoreRequired": true},
102
132
  "schemaVersion": 2,
103
133
  "stores": {
104
- "contract": {"readable": [1, 2], "written": [1, 2]},
134
+ "contract": {"readable": [1, 2, 3], "written": [1, 2, 3]},
105
135
  "projectionLock": {"readable": [1, 2], "written": [1, 2]},
106
136
  "proposal": {"readable": [1], "written": [1]},
107
137
  "sourceLock": {"readable": [1], "written": [1]}
108
138
  },
109
- "upgradeFrom": ["1.3.1", "1.4.0", "1.5.0", "1.6.0"]
139
+ "upgradeFrom": ["1.3.1", "1.4.0", "1.5.0", "1.6.0", "1.7.0", "1.8.0", "1.9.0"]
110
140
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "frontend-project-context",
3
- "version": "1.7.0",
3
+ "version": "1.9.1",
4
4
  "description": "Govern, compile, and verify project-local context for AI coding tools.",
5
5
  "private": false,
6
6
  "publishConfig": {
@@ -27,7 +27,7 @@
27
27
  },
28
28
  "scripts": {
29
29
  "check": "node --check bin/project-context.mjs && npm test",
30
- "test": "node --test test/project-context/acceptance.test.mjs test/project-context/adaptive-context.test.mjs test/project-context/adaptive-delivery-v2.test.mjs test/project-context/assist.test.mjs test/project-context/cli.test.mjs test/project-context/dashboard.test.mjs test/project-context/evidence.test.mjs test/project-context/exchange.test.mjs test/project-context/maintenance.test.mjs test/project-context/source-lifecycle.test.mjs test/project-context/task-context.test.mjs test/project-context/takeover.test.mjs test/project-context/truth-reconciliation.test.mjs test/project-context/upgrade.test.mjs test/release/acceptance.test.mjs",
30
+ "test": "node --test test/project-context/acceptance.test.mjs test/project-context/adaptive-context.test.mjs test/project-context/adaptive-delivery-v2.test.mjs test/project-context/assist.test.mjs test/project-context/cli.test.mjs test/project-context/dashboard.test.mjs test/project-context/evidence.test.mjs test/project-context/exchange.test.mjs test/project-context/maintenance.test.mjs test/project-context/onboarding-closure.test.mjs test/project-context/source-lifecycle.test.mjs test/project-context/task-context.test.mjs test/project-context/task-context-consumption.test.mjs test/project-context/takeover.test.mjs test/project-context/truth-reconciliation.test.mjs test/project-context/upgrade.test.mjs test/release/acceptance.test.mjs",
31
31
  "prepack": "npm run check"
32
32
  },
33
33
  "engines": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "$id": "urn:frontend-project-context:schema:capabilities:7",
3
+ "$id": "urn:frontend-project-context:schema:capabilities:9",
4
4
  "title": "Frontend Project Context Capabilities",
5
5
  "type": "object",
6
6
  "additionalProperties": false,
@@ -12,23 +12,24 @@
12
12
  "commands",
13
13
  "actionKinds",
14
14
  "contextBudget",
15
+ "initializationInstruction",
15
16
  "initialization",
16
17
  "initialized",
17
18
  "project",
18
19
  "boundaries"
19
20
  ],
20
21
  "properties": {
21
- "schemaVersion": { "const": 7 },
22
+ "schemaVersion": { "const": 9 },
22
23
  "package": {
23
24
  "type": "object",
24
25
  "additionalProperties": false,
25
26
  "required": ["name", "version"],
26
27
  "properties": {
27
28
  "name": { "const": "frontend-project-context" },
28
- "version": { "const": "1.7.0" }
29
+ "version": { "const": "1.9.1" }
29
30
  }
30
31
  },
31
- "exchangeProtocolVersion": { "const": 7 },
32
+ "exchangeProtocolVersion": { "const": 9 },
32
33
  "schemas": {
33
34
  "type": "object",
34
35
  "additionalProperties": false,
@@ -38,6 +39,8 @@
38
39
  "assistBundle",
39
40
  "capabilities",
40
41
  "contract",
42
+ "contractReadable",
43
+ "contextBundle",
41
44
  "contextQuery",
42
45
  "coverageAudit",
43
46
  "dashboardViewModel",
@@ -45,6 +48,7 @@
45
48
  "evidenceInput",
46
49
  "hostPromotionEvidence",
47
50
  "integrationReviewBundle",
51
+ "initializationInstruction",
48
52
  "projectionLock",
49
53
  "projectionLockReadable",
50
54
  "projectionLockWritten",
@@ -69,22 +73,25 @@
69
73
  "actionPlan": { "const": 2 },
70
74
  "adaptiveContextBundle": { "const": 2 },
71
75
  "assistBundle": { "const": 1 },
72
- "capabilities": { "const": 7 },
73
- "contract": { "const": 2 },
76
+ "capabilities": { "const": 9 },
77
+ "contract": { "const": 3 },
78
+ "contractReadable": { "const": [1, 2, 3] },
79
+ "contextBundle": { "const": 1 },
74
80
  "contextQuery": { "const": 2 },
75
- "coverageAudit": { "const": 1 },
81
+ "coverageAudit": { "const": 2 },
76
82
  "dashboardViewModel": { "type": "integer" },
77
83
  "evidenceBundle": { "const": 1 },
78
84
  "evidenceInput": { "const": 1 },
79
85
  "hostPromotionEvidence": { "const": 1 },
80
86
  "integrationReviewBundle": { "const": 1 },
87
+ "initializationInstruction": { "const": 2 },
81
88
  "projectionLock": { "const": 2 },
82
89
  "projectionLockReadable": { "const": [1, 2] },
83
90
  "projectionLockWritten": { "enum": [1, 2] },
84
91
  "projectionRenderer": { "type": "integer" },
85
92
  "proposal": { "const": 1 },
86
- "projectStatus": { "const": 1 },
87
- "aiEntryRenderer": { "const": 3 },
93
+ "projectStatus": { "const": 2 },
94
+ "aiEntryRenderer": { "const": 5 },
88
95
  "migrationManifest": { "const": 2 },
89
96
  "migrationPlan": { "const": 1 },
90
97
  "reviewBundle": { "const": 2 },
@@ -99,7 +106,7 @@
99
106
  "upgradeResultBundle": { "const": 1 }
100
107
  }
101
108
  },
102
- "commands": { "type": "array", "minItems": 1, "uniqueItems": true, "allOf": [{"contains": {"const": "upgrade-check"}}, {"contains": {"const": "upgrade-plan"}}, {"contains": {"const": "upgrade-apply"}}], "items": { "type": "string" } },
109
+ "commands": { "type": "array", "minItems": 1, "uniqueItems": true, "allOf": [{"contains": {"const": "instructions"}}, {"contains": {"const": "upgrade-check"}}, {"contains": {"const": "upgrade-plan"}}, {"contains": {"const": "upgrade-apply"}}], "items": { "type": "string" } },
103
110
  "actionKinds": {
104
111
  "type": "array",
105
112
  "minItems": 10,
@@ -130,6 +137,18 @@
130
137
  "callerMustProvideLimit": { "const": true }
131
138
  }
132
139
  },
140
+ "initializationInstruction": {
141
+ "type": "object",
142
+ "additionalProperties": false,
143
+ "required": ["id", "version", "packagePath", "digest", "command"],
144
+ "properties": {
145
+ "id": {"const": "ai-project-initialization"},
146
+ "version": {"const": 2},
147
+ "packagePath": {"const": "docs/AI-PROJECT-INITIALIZATION.md"},
148
+ "digest": {"type": "string", "pattern": "^sha256:[a-f0-9]{64}$"},
149
+ "command": {"const": "project-context instructions --project PATH [--json | --prompt]"}
150
+ }
151
+ },
133
152
  "initialization": { "enum": ["uninitialized", "partial", "initialized"] },
134
153
  "initialized": { "type": "boolean" },
135
154
  "project": {
@@ -0,0 +1,32 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "urn:frontend-project-context:schema:context-bundle:1",
4
+ "title": "Frontend Project Context Bundle",
5
+ "type": "object",
6
+ "additionalProperties": false,
7
+ "required": ["schemaVersion", "kind", "project", "mode", "task", "snapshots", "semanticCompleteness", "commonItemIds", "targets", "items", "readTargets", "provenanceSources", "coverage", "authority", "gaps", "nextActions", "content", "bundleDigest"],
8
+ "properties": {
9
+ "schemaVersion": {"const": 1},
10
+ "kind": {"const": "context-bundle"},
11
+ "project": {"type": "object", "additionalProperties": false, "required": ["id", "name"], "properties": {"id": {"type": "string", "minLength": 1}, "name": {"type": "string", "minLength": 1}}},
12
+ "mode": {"enum": ["locate", "targeted"]},
13
+ "task": {"type": "object", "additionalProperties": false, "required": ["text", "paths"], "properties": {"text": {"type": "string"}, "paths": {"$ref": "#/$defs/strings"}}},
14
+ "snapshots": {"type": "object", "additionalProperties": false, "required": ["contract", "sourcesLock", "projectionsLock"], "properties": {"contract": {"$ref": "#/$defs/digest"}, "sourcesLock": {"$ref": "#/$defs/digest"}, "projectionsLock": {"$ref": "#/$defs/digest"}}},
15
+ "semanticCompleteness": {"const": "not-claimed"},
16
+ "commonItemIds": {"$ref": "#/$defs/strings"},
17
+ "targets": {"type": "array", "items": {"type": "object", "additionalProperties": false, "required": ["path", "scopeCoverage", "itemIds", "scopedItemIds", "deltaItemIds"], "properties": {"path": {"type": "string"}, "scopeCoverage": {"enum": ["scoped", "project-only", "none"]}, "itemIds": {"$ref": "#/$defs/strings"}, "scopedItemIds": {"$ref": "#/$defs/strings"}, "deltaItemIds": {"$ref": "#/$defs/strings"}}}},
18
+ "items": {"type": "array", "items": {"type": "object", "additionalProperties": false, "required": ["id", "kind", "subject", "scope", "sourceIds", "statement", "value", "overrides"], "properties": {"id": {"type": "string", "minLength": 1}, "kind": {"enum": ["fact", "policy", "reference", "validation-description"]}, "subject": {"type": "string", "minLength": 1}, "scope": {"type": "object", "additionalProperties": false, "required": ["kind"], "properties": {"kind": {"enum": ["project", "path-prefix", "file"]}, "path": {"type": "string"}}}, "sourceIds": {"$ref": "#/$defs/strings"}, "statement": {"type": "string", "minLength": 1}, "value": true, "overrides": {"$ref": "#/$defs/strings"}, "verification": {"type": "object", "additionalProperties": false, "required": ["kind"], "properties": {"kind": {"enum": ["none", "file-exists", "json-value", "path-digest"]}, "source": {"type": "string"}, "expected": true}}, "consumption": {"type": "object", "additionalProperties": false, "required": ["requiredSources", "conditionalSources"], "properties": {"requiredSources": {"$ref": "#/$defs/strings"}, "conditionalSources": {"$ref": "#/$defs/strings"}}}}}},
19
+ "readTargets": {"type": "array", "items": {"type": "object", "additionalProperties": false, "required": ["path", "role", "itemIds", "sourceIds", "reasons"], "properties": {"path": {"type": "string"}, "role": {"enum": ["required", "conditional"]}, "itemIds": {"$ref": "#/$defs/strings"}, "sourceIds": {"$ref": "#/$defs/strings"}, "reasons": {"$ref": "#/$defs/strings"}, "pointers": {"$ref": "#/$defs/strings"}}}},
20
+ "provenanceSources": {"type": "array", "items": {"type": "object", "additionalProperties": false, "required": ["sourceId", "itemIds", "kind", "locator"], "properties": {"sourceId": {"type": "string"}, "itemIds": {"$ref": "#/$defs/strings"}, "kind": {"type": "string"}, "locator": {"type": "object"}}}},
21
+ "coverage": {"type": "object", "additionalProperties": false, "required": ["profileItemId", "profileVersion", "registrationCoverage", "targets", "guarantee"], "properties": {"profileItemId": {"type": ["string", "null"]}, "profileVersion": {"enum": [null, 1, 2]}, "registrationCoverage": {"enum": ["not-declared", "review-required", "unresolved", "closed-for-declared-scope"]}, "targets": {"type": "array", "items": {"type": "object", "additionalProperties": false, "required": ["path", "disposition", "domainId"], "properties": {"path": {"type": "string"}, "disposition": {"enum": ["contract-covered", "dynamic-investigation", "excluded-approved", "unresolved", "outside-declared-coverage"]}, "domainId": {"type": ["string", "null"]}}}}, "guarantee": {"const": "declared-scope-only-never-all-project-truth"}}},
22
+ "authority": {"type": "object", "additionalProperties": false, "required": ["productTaskExecution", "productBusinessCodeWrites", "hostTaskAuthority", "resolveFrom"], "properties": {"productTaskExecution": {"const": false}, "productBusinessCodeWrites": {"const": false}, "hostTaskAuthority": {"const": "external-to-project-context"}, "resolveFrom": {"const": ["current-user-request", "human-authored-project-instructions", "higher-priority-safety-constraints"]}}},
23
+ "gaps": {"type": "array", "items": {"type": "object", "additionalProperties": false, "required": ["code"], "properties": {"code": {"enum": ["target-path-not-yet-known", "project-scope-only", "no-applicable-contract-item", "registration-coverage-not-declared", "registration-coverage-review-required", "required-read-target-unavailable"]}, "path": {"type": "string"}, "sourceIds": {"$ref": "#/$defs/strings"}, "reason": {"type": "string"}, "disposition": {"enum": ["unresolved"]}}}},
24
+ "nextActions": {"$ref": "#/$defs/strings"},
25
+ "content": {"type": "string", "minLength": 1},
26
+ "bundleDigest": {"$ref": "#/$defs/digest"}
27
+ },
28
+ "$defs": {
29
+ "digest": {"type": "string", "pattern": "^sha256:[a-f0-9]{64}$"},
30
+ "strings": {"type": "array", "uniqueItems": true, "items": {"type": "string"}}
31
+ }
32
+ }
@@ -1,25 +1,27 @@
1
1
  {
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "$id": "urn:frontend-project-context:schema:coverage-audit:1",
3
+ "$id": "urn:frontend-project-context:schema:coverage-audit:2",
4
4
  "title": "Frontend Project Context Coverage Audit",
5
5
  "type": "object",
6
6
  "additionalProperties": false,
7
7
  "required": ["schemaVersion", "kind", "project", "snapshots", "profile", "registrationCoverage", "categories", "guarantee", "auditDigest"],
8
8
  "properties": {
9
- "schemaVersion": { "const": 1 },
9
+ "schemaVersion": { "const": 2 },
10
10
  "kind": { "const": "coverage-audit" },
11
11
  "project": { "type": "object", "additionalProperties": false, "required": ["id", "name"], "properties": { "id": { "type": "string" }, "name": { "type": "string" } } },
12
12
  "snapshots": { "$ref": "context-query.schema.json#/$defs/snapshots" },
13
13
  "profile": { "type": ["object", "null"] },
14
- "registrationCoverage": { "enum": ["not-declared", "review-required", "closed-for-declared-scope"] },
14
+ "registrationCoverage": { "enum": ["not-declared", "review-required", "unresolved", "closed-for-declared-scope"] },
15
15
  "categories": {
16
16
  "type": "object",
17
17
  "additionalProperties": false,
18
- "required": ["registered", "excluded-approved", "review-required", "outside-declared-coverage"],
18
+ "required": ["registered", "dynamic-investigation", "excluded-approved", "review-required", "unresolved", "outside-declared-coverage"],
19
19
  "properties": {
20
20
  "registered": { "$ref": "#/$defs/candidates" },
21
+ "dynamic-investigation": { "$ref": "#/$defs/candidates" },
21
22
  "excluded-approved": { "$ref": "#/$defs/candidates" },
22
23
  "review-required": { "$ref": "#/$defs/candidates" },
24
+ "unresolved": { "$ref": "#/$defs/candidates" },
23
25
  "outside-declared-coverage": { "$ref": "#/$defs/candidates" }
24
26
  }
25
27
  },
@@ -14,7 +14,7 @@
14
14
  "required": ["name", "version", "exchangeProtocolVersion"],
15
15
  "properties": {
16
16
  "name": { "const": "frontend-project-context" },
17
- "version": { "const": "1.7.0" },
17
+ "version": { "const": "1.9.1" },
18
18
  "exchangeProtocolVersion": { "const": 6 }
19
19
  }
20
20
  },
@@ -0,0 +1,72 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "urn:frontend-project-context:schema:initialization-instruction:2",
4
+ "title": "Frontend Project Context Initialization Instruction",
5
+ "type": "object",
6
+ "additionalProperties": false,
7
+ "required": ["schemaVersion", "package", "instruction", "targetRoot", "boundaries", "entryRuleReview"],
8
+ "properties": {
9
+ "schemaVersion": {"const": 2},
10
+ "package": {
11
+ "type": "object",
12
+ "additionalProperties": false,
13
+ "required": ["name", "version"],
14
+ "properties": {
15
+ "name": {"const": "frontend-project-context"},
16
+ "version": {"const": "1.9.1"}
17
+ }
18
+ },
19
+ "instruction": {
20
+ "type": "object",
21
+ "additionalProperties": false,
22
+ "required": ["id", "version", "packagePath", "digest", "content"],
23
+ "properties": {
24
+ "id": {"const": "ai-project-initialization"},
25
+ "version": {"const": 2},
26
+ "packagePath": {"const": "docs/AI-PROJECT-INITIALIZATION.md"},
27
+ "digest": {"$ref": "#/$defs/digest"},
28
+ "content": {"type": "string", "minLength": 1}
29
+ }
30
+ },
31
+ "targetRoot": {"type": "string", "minLength": 1},
32
+ "entryRuleReview": {
33
+ "type": "object",
34
+ "additionalProperties": false,
35
+ "required": ["path", "present", "allowedDispositions", "records", "automaticDeletion"],
36
+ "properties": {
37
+ "path": {"const": "AGENTS.md"},
38
+ "present": {"type": "boolean"},
39
+ "allowedDispositions": {"const": ["migrated-to-contract", "kept-in-entry-intentionally", "excluded-as-stale", "unresolved-blocker"]},
40
+ "records": {"type": "array", "items": {"type": "object", "additionalProperties": false, "required": ["id", "disposition", "rationale"], "properties": {"id": {"type": "string"}, "disposition": {"enum": ["migrated-to-contract", "kept-in-entry-intentionally", "excluded-as-stale", "unresolved-blocker"]}, "rationale": {"type": "string"}}}},
41
+ "automaticDeletion": {"const": false}
42
+ }
43
+ },
44
+ "boundaries": {
45
+ "type": "object",
46
+ "additionalProperties": false,
47
+ "required": ["provider", "agentRuntime", "git", "network", "dependencyInstallation", "automaticApproval", "businessCodeWrites", "taskExecution", "stagePathBodyReads", "applyPlan", "scheduler", "daemon", "telemetry", "selfUpdate", "automaticEvidenceUpload", "packageManager", "automaticUpgrade"],
48
+ "properties": {
49
+ "provider": {"const": false},
50
+ "agentRuntime": {"const": false},
51
+ "git": {"const": false},
52
+ "network": {"const": false},
53
+ "dependencyInstallation": {"const": false},
54
+ "automaticApproval": {"const": false},
55
+ "businessCodeWrites": {"const": false},
56
+ "taskExecution": {"const": false},
57
+ "stagePathBodyReads": {"const": false},
58
+ "applyPlan": {"const": false},
59
+ "scheduler": {"const": false},
60
+ "daemon": {"const": false},
61
+ "telemetry": {"const": false},
62
+ "selfUpdate": {"const": false},
63
+ "automaticEvidenceUpload": {"const": false},
64
+ "packageManager": {"const": false},
65
+ "automaticUpgrade": {"const": false}
66
+ }
67
+ }
68
+ },
69
+ "$defs": {
70
+ "digest": {"type": "string", "pattern": "^sha256:[a-f0-9]{64}$"}
71
+ }
72
+ }
@@ -7,12 +7,12 @@
7
7
  "required": ["schemaVersion", "package", "upgradeFrom", "stores", "renderers", "protocols", "paths", "builtInMigrations", "consumerChanges", "acceptanceCommands", "rollback", "externalEffects", "manifestDigest"],
8
8
  "properties": {
9
9
  "schemaVersion": {"const": 2},
10
- "package": {"type": "object", "additionalProperties": false, "required": ["name", "version"], "properties": {"name": {"const": "frontend-project-context"}, "version": {"const": "1.7.0"}}},
11
- "upgradeFrom": {"const": ["1.3.1", "1.4.0", "1.5.0", "1.6.0"]},
10
+ "package": {"type": "object", "additionalProperties": false, "required": ["name", "version"], "properties": {"name": {"const": "frontend-project-context"}, "version": {"const": "1.9.1"}}},
11
+ "upgradeFrom": {"const": ["1.3.1", "1.4.0", "1.5.0", "1.6.0", "1.7.0", "1.8.0"]},
12
12
  "stores": {"type": "object", "additionalProperties": false, "required": ["contract", "projectionLock", "proposal", "sourceLock"], "properties": {"contract": {"$ref": "#/$defs/versionMatrix"}, "projectionLock": {"$ref": "#/$defs/versionMatrix"}, "proposal": {"$ref": "#/$defs/versionMatrix"}, "sourceLock": {"$ref": "#/$defs/versionMatrix"}}},
13
13
  "renderers": {"type": "object", "additionalProperties": false, "required": ["aiEntry", "projection"], "properties": {"aiEntry": {"$ref": "#/$defs/versionTarget"}, "projection": {"$ref": "#/$defs/versionTarget"}}},
14
14
  "protocols": {"type": "object", "additionalProperties": {"$ref": "#/$defs/versionTarget"}},
15
- "paths": {"type": "array", "minItems": 4, "maxItems": 4, "items": {"type": "object", "additionalProperties": false, "required": ["fromVersion", "classification", "migrationIds", "requiresHumanReview", "rollbackClass", "acceptance"], "properties": {"fromVersion": {"enum": ["1.3.1", "1.4.0", "1.5.0", "1.6.0"]}, "classification": {"enum": ["package-only", "republish-ai-entry", "republish-projection", "built-in-store-migration", "invalidate-ephemeral-protocol"]}, "migrationIds": {"$ref": "#/$defs/strings"}, "requiresHumanReview": {"type": "boolean"}, "rollbackClass": {"$ref": "#/$defs/rollbackClass"}, "acceptance": {"$ref": "#/$defs/strings"}}}},
15
+ "paths": {"type": "array", "minItems": 6, "maxItems": 6, "items": {"type": "object", "additionalProperties": false, "required": ["fromVersion", "classification", "migrationIds", "requiresHumanReview", "rollbackClass", "acceptance"], "properties": {"fromVersion": {"enum": ["1.3.1", "1.4.0", "1.5.0", "1.6.0", "1.7.0", "1.8.0"]}, "classification": {"enum": ["package-only", "republish-ai-entry", "republish-projection", "built-in-store-migration", "invalidate-ephemeral-protocol"]}, "migrationIds": {"$ref": "#/$defs/strings"}, "requiresHumanReview": {"type": "boolean"}, "rollbackClass": {"$ref": "#/$defs/rollbackClass"}, "acceptance": {"$ref": "#/$defs/strings"}}}},
16
16
  "builtInMigrations": {"type": "array", "items": {"type": "object", "additionalProperties": false, "required": ["id", "kind", "input", "targetType", "writes", "rollbackClass", "reverseMigrationId"], "properties": {"id": {"type": "string"}, "kind": {"enum": ["package-only", "republish-ai-entry", "republish-projection", "built-in-store-migration", "invalidate-ephemeral-protocol"]}, "input": {"type": "object", "additionalProperties": false, "required": ["schemaVersions", "beforeDigestRequired"], "properties": {"schemaVersions": {"type": "array", "items": {"type": "integer", "minimum": 1}}, "beforeDigestRequired": {"type": "boolean"}}}, "targetType": {"enum": ["none", "ai-entry", "projection", "store", "ephemeral-protocol"]}, "writes": {"type": "boolean"}, "rollbackClass": {"$ref": "#/$defs/rollbackClass"}, "reverseMigrationId": {"type": ["string", "null"]}}}},
17
17
  "consumerChanges": {"type": "object", "additionalProperties": {"type": "object", "additionalProperties": false, "required": ["state", "reason"], "properties": {"state": {"enum": ["preserve", "regenerate", "invalidate"]}, "reason": {"type": "string"}}}},
18
18
  "acceptanceCommands": {"$ref": "#/$defs/strings"},
@@ -8,8 +8,8 @@
8
8
  "properties": {
9
9
  "schemaVersion": {"const": 1},
10
10
  "kind": {"const": "target-upgrade-plan"},
11
- "fromVersion": {"enum": ["1.3.1", "1.4.0", "1.5.0", "1.6.0"]},
12
- "targetVersion": {"const": "1.7.0"},
11
+ "fromVersion": {"enum": ["1.3.1", "1.4.0", "1.5.0", "1.6.0", "1.7.0"]},
12
+ "targetVersion": {"const": "1.9.1"},
13
13
  "manifestDigest": {"$ref": "#/$defs/digest"},
14
14
  "assessmentDigest": {"$ref": "#/$defs/digest"},
15
15
  "snapshots": {"anyOf": [{"type": "null"}, {"$ref": "#/$defs/snapshots"}]},
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "$id": "urn:frontend-project-context:schema:project-status:1",
3
+ "$id": "urn:frontend-project-context:schema:project-status:2",
4
4
  "title": "Frontend Project Context Project Status",
5
5
  "type": "object",
6
6
  "additionalProperties": false,
7
- "required": ["schemaVersion", "package", "initialization", "project", "snapshots", "health", "entry", "summary", "findingCodes", "sourceIds", "itemIds", "projectionPaths", "readTargets", "workUnits", "nextActions", "boundaries"],
7
+ "required": ["schemaVersion", "package", "initialization", "project", "snapshots", "health", "entry", "contractReadiness", "summary", "findingCodes", "sourceIds", "itemIds", "projectionPaths", "readTargets", "workUnits", "nextActions", "boundaries"],
8
8
  "properties": {
9
- "schemaVersion": { "const": 1 },
9
+ "schemaVersion": { "const": 2 },
10
10
  "package": {
11
11
  "type": "object",
12
12
  "additionalProperties": false,
@@ -36,6 +36,7 @@
36
36
  "rendererVersion": { "type": ["integer", "null"] }
37
37
  }
38
38
  },
39
+ "contractReadiness": {"enum": ["not-initialized", "contract-incomplete", "contract-ready"]},
39
40
  "summary": {
40
41
  "type": "object",
41
42
  "additionalProperties": false,
@@ -56,7 +57,7 @@
56
57
  "nextActions": {
57
58
  "type": "array",
58
59
  "uniqueItems": true,
59
- "items": { "enum": ["run-setup-preview", "run-sync", "review-pending", "review-source-change", "review-projection", "publish-ai-entry", "resolve-conflict", "ready-for-task"] }
60
+ "items": { "enum": ["read-initialization-instructions", "complete-onboarding", "compile-task-context", "run-sync", "review-pending", "review-source-change", "review-projection", "publish-ai-entry", "resolve-conflict"] }
60
61
  },
61
62
  "boundaries": { "type": "object", "additionalProperties": { "const": false } }
62
63
  },
@@ -33,7 +33,7 @@
33
33
  "properties": {
34
34
  "path": { "type": "string" }, "target": { "const": "ai-entry" }, "ownership": { "const": "region" },
35
35
  "regionId": { "const": "project-context-ai-entry" }, "regionDigest": { "$ref": "#/$defs/digest" },
36
- "rendererVersion": { "enum": [1, 2, 3] }, "createdFile": { "type": "boolean" }
36
+ "rendererVersion": { "enum": [1, 2, 3, 4, 5] }, "createdFile": { "type": "boolean" }
37
37
  }
38
38
  },
39
39
  "schema1": {