skill-family-engineering-kit 0.2.0 → 0.2.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.
- package/CHANGELOG.md +21 -0
- package/CHANGELOG.zh-CN.md +21 -0
- package/NOTICE +10 -0
- package/README.md +157 -55
- package/README.zh-CN.md +207 -0
- package/candidate/index.mjs +4 -0
- package/candidate/profile-bundle.mjs +268 -0
- package/candidate/projection-bundle-cli.mjs +22 -0
- package/docs/404.html +1434 -408
- package/docs/agents/architecture-routing/index.html +1944 -0
- package/docs/agents/capability-catalog.en.json +1561 -0
- package/docs/agents/capability-catalog.json +934 -0
- package/docs/agents/capability-catalog.schema.json +179 -0
- package/docs/agents/capability-catalog.zh-CN.json +1561 -0
- package/docs/agents/index.html +1914 -0
- package/docs/architecture/index.html +1706 -497
- package/docs/assets/javascripts/lunr/tinyseg.js +2 -2
- package/docs/assets/javascripts/lunr/wordcut.js +37 -37
- package/docs/en/agents/architecture-routing/index.html +1944 -0
- package/docs/en/agents/index.html +1925 -0
- package/docs/en/architecture/index.html +2187 -0
- package/docs/en/examples-and-fixtures/index.html +1888 -0
- package/docs/en/help/index.html +2035 -0
- package/docs/en/index.html +1895 -0
- package/docs/en/licensing/index.html +1917 -0
- package/docs/en/migration/index.html +2334 -0
- package/docs/en/quickstart/index.html +1919 -0
- package/docs/en/recipes/adapter-text-closure/index.html +2000 -0
- package/docs/en/recipes/adopt-existing-repository/index.html +1986 -0
- package/docs/en/recipes/deterministic-human-report/index.html +1998 -0
- package/docs/en/recipes/domain-schema-validation/index.html +2007 -0
- package/docs/en/recipes/durable-local-state/index.html +2009 -0
- package/docs/en/recipes/host-profile-integration/index.html +2001 -0
- package/docs/en/recipes/index.html +1876 -0
- package/docs/en/recipes/safe-filesystem-and-atomic-write/index.html +1994 -0
- package/docs/en/reference/api/index.html +1917 -0
- package/docs/en/reference/compatibility/index.html +1990 -0
- package/docs/en/reference/failure-and-side-effect-matrix/index.html +2216 -0
- package/docs/examples-and-fixtures/index.html +1871 -0
- package/docs/git-lifecycle/index.html +1508 -482
- package/docs/help/index.html +1655 -554
- package/docs/index.html +1479 -450
- package/docs/integration/audit/failure-evidence/index.html +1488 -462
- package/docs/integration/audit/independence/index.html +1513 -487
- package/docs/integration/audit/index.html +1514 -488
- package/docs/integration/audit/mutation-taxonomy/index.html +1548 -522
- package/docs/integration/audit/version-compatibility/index.html +1489 -463
- package/docs/licensing/index.html +1917 -0
- package/docs/migration/index.html +1678 -586
- package/docs/public/status/index.html +1542 -516
- package/docs/quickstart/index.html +1589 -539
- package/docs/recipes/adapter-text-closure/index.html +2000 -0
- package/docs/recipes/adopt-existing-repository/index.html +1986 -0
- package/docs/recipes/deterministic-human-report/index.html +1998 -0
- package/docs/recipes/domain-schema-validation/index.html +2007 -0
- package/docs/recipes/durable-local-state/index.html +2009 -0
- package/docs/recipes/host-profile-integration/index.html +2001 -0
- package/docs/recipes/index.html +1876 -0
- package/docs/recipes/safe-filesystem-and-atomic-write/index.html +1994 -0
- package/docs/reference/api/contracts/index.html +2532 -0
- package/docs/reference/api/engineering-kit/index.html +2551 -0
- package/docs/reference/api/harness/index.html +2608 -0
- package/docs/reference/api/index.html +1857 -0
- package/docs/reference/compatibility/index.html +1990 -0
- package/docs/reference/failure-and-side-effect-matrix/index.html +2216 -0
- package/docs/search/search_index.json +1 -1
- package/docs/setup/index.html +1494 -468
- package/docs/sitemap.xml +152 -0
- package/package.json +14 -4
- package/release-notes/0.2.1.yaml +23 -0
|
@@ -0,0 +1,1561 @@
|
|
|
1
|
+
{
|
|
2
|
+
"schemaVersion": 1,
|
|
3
|
+
"kind": "skill-family.documentation-capability-catalog",
|
|
4
|
+
"bundle": "locale-overlay",
|
|
5
|
+
"locale": "zh-CN",
|
|
6
|
+
"generatedFrom": [
|
|
7
|
+
"package.json",
|
|
8
|
+
"packages/skill-family-contracts/package.json",
|
|
9
|
+
"packages/skill-family-harness-node/package.json",
|
|
10
|
+
"packages/skill-family-engineering-kit/package.json",
|
|
11
|
+
"packages/skill-family-contracts/src/index.mjs",
|
|
12
|
+
"packages/skill-family-harness-node/src/index.mjs",
|
|
13
|
+
"packages/skill-family-engineering-kit/src/index.mjs",
|
|
14
|
+
"packages/skill-family-engineering-kit/src/cli.mjs",
|
|
15
|
+
"packages/skill-family-contracts/src/registry.json",
|
|
16
|
+
"profiles/README.md",
|
|
17
|
+
"docs/architecture.md",
|
|
18
|
+
"docs/status/current.md"
|
|
19
|
+
],
|
|
20
|
+
"capabilities": [
|
|
21
|
+
{
|
|
22
|
+
"id": "foundation.contracts.object-validation",
|
|
23
|
+
"intent": "用 Ajv 8.20.0(精确 pin)在 draft-07 与 2020-12 双方言下编译并校验 Foundation 已登记的 18 类顶层契约对象文档",
|
|
24
|
+
"useWhen": [
|
|
25
|
+
"需要校验 project-manifest、profile-descriptor、report-model 等已登记契约对象",
|
|
26
|
+
"需要探测文档方言并选择 strict 或 tolerant 校验策略"
|
|
27
|
+
],
|
|
28
|
+
"doNotUseWhen": [
|
|
29
|
+
"需要校验消费者自有业务 Schema(消费者应自行持有,Foundation 不取代)",
|
|
30
|
+
"需要把领域语义校验混入通用契约"
|
|
31
|
+
],
|
|
32
|
+
"prerequisites": [
|
|
33
|
+
"待校验文档带有已登记契约对象的 $id",
|
|
34
|
+
"Node >= 22.22.2"
|
|
35
|
+
],
|
|
36
|
+
"inputs": [
|
|
37
|
+
"契约文档对象(任意 JSON 值)",
|
|
38
|
+
"目标契约对象 $id 或 schema",
|
|
39
|
+
"校验策略(strict | tolerant,默认 strict)"
|
|
40
|
+
],
|
|
41
|
+
"outputs": [
|
|
42
|
+
"校验通过:返回 {valid:true}(不含 errorCode 字段)",
|
|
43
|
+
"校验失败:返回 {valid:false, errorCode, errors},不抛出",
|
|
44
|
+
"首次编译结果写入 Ajv 编译缓存,后续同 (schemaId,dialect,policy) 复用"
|
|
45
|
+
],
|
|
46
|
+
"sideEffects": [
|
|
47
|
+
"无文件系统、Git、网络或进程副作用(纯函数 + 内存缓存)"
|
|
48
|
+
],
|
|
49
|
+
"failureSemantics": [
|
|
50
|
+
"SFC1002:未知契约对象 $id 未登记(返回 valid:false,不抛出)",
|
|
51
|
+
"SFC1001:文档不符合已登记 Schema(返回 valid:false,errors 含 Ajv keyword 明细)",
|
|
52
|
+
"调用方以返回值的 valid 字段判断成败,不以 try/catch 捕获——validateDocument 永不抛出",
|
|
53
|
+
"compileSchema 对无法编译的 schema 抛 ContractsError(SFC1012 SCHEMA_COMPILE_FAILED);detectDialect 对未知方言抛 ContractsError(SFC1006)"
|
|
54
|
+
],
|
|
55
|
+
"invariants": [
|
|
56
|
+
"同一 (对象, 方言, 策略) 复用编译缓存,重复校验不重新编译",
|
|
57
|
+
"仅接受 Ajv 8.20.0,不接入其他校验器"
|
|
58
|
+
],
|
|
59
|
+
"ownedByCaller": [
|
|
60
|
+
"具体业务字段的语义解释",
|
|
61
|
+
"领域级校验规则"
|
|
62
|
+
],
|
|
63
|
+
"routeElsewhere": [
|
|
64
|
+
"消费者业务 Schema 校验:留在调用方",
|
|
65
|
+
"远端发布写入:转 release-skill"
|
|
66
|
+
]
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
"id": "foundation.contracts.registry-protocol",
|
|
70
|
+
"intent": "登记并查询契约对象 Schema $id 与协议名,作为协议名与 Schema 唯一权威",
|
|
71
|
+
"useWhen": [
|
|
72
|
+
"需要按对象名或 $id 查找已登记 Schema",
|
|
73
|
+
"需要按协议名查找 kernel 协议定义"
|
|
74
|
+
],
|
|
75
|
+
"doNotUseWhen": [
|
|
76
|
+
"需要新增第四类登记对象(未经 ADR 不得扩展 18 类对象集)"
|
|
77
|
+
],
|
|
78
|
+
"prerequisites": [
|
|
79
|
+
"registry.json 已随包发布",
|
|
80
|
+
"Node >= 22.22.2"
|
|
81
|
+
],
|
|
82
|
+
"inputs": [
|
|
83
|
+
"对象名、Schema $id 或协议名"
|
|
84
|
+
],
|
|
85
|
+
"outputs": [
|
|
86
|
+
"已登记的 Schema 元信息或协议定义",
|
|
87
|
+
"查询未命中时返回 undefined 或抛错"
|
|
88
|
+
],
|
|
89
|
+
"sideEffects": [
|
|
90
|
+
"无文件系统、Git、网络或进程副作用(纯函数)"
|
|
91
|
+
],
|
|
92
|
+
"failureSemantics": [
|
|
93
|
+
"SFC1003:重复 $id 登记",
|
|
94
|
+
"SFC1004:重复协议登记"
|
|
95
|
+
],
|
|
96
|
+
"invariants": [
|
|
97
|
+
"registry.json 的 schemaVersion=1、contractsVersion=1.4.0 为唯一权威",
|
|
98
|
+
"18 类顶层对象集合固定,新增需 ADR"
|
|
99
|
+
],
|
|
100
|
+
"ownedByCaller": [
|
|
101
|
+
"对象业务含义的解释"
|
|
102
|
+
],
|
|
103
|
+
"routeElsewhere": [
|
|
104
|
+
"发布状态:转 release-skill"
|
|
105
|
+
]
|
|
106
|
+
},
|
|
107
|
+
{
|
|
108
|
+
"id": "foundation.contracts.kernel-protocol",
|
|
109
|
+
"intent": "加载并校验 skill-family.kernel.operation 协议(stable,Contracts 1.4.0),定义操作请求/结果结构",
|
|
110
|
+
"useWhen": [
|
|
111
|
+
"需要解析或校验 operation-request / operation-result 结构",
|
|
112
|
+
"需要按操作名查找参数契约"
|
|
113
|
+
],
|
|
114
|
+
"doNotUseWhen": [
|
|
115
|
+
"需要定义业务操作语义(语义由消费者拥有)"
|
|
116
|
+
],
|
|
117
|
+
"prerequisites": [
|
|
118
|
+
"kernel-protocol.json 已随包发布"
|
|
119
|
+
],
|
|
120
|
+
"inputs": [
|
|
121
|
+
"协议名、操作名、操作参数"
|
|
122
|
+
],
|
|
123
|
+
"outputs": [
|
|
124
|
+
"协议定义或操作参数校验结果"
|
|
125
|
+
],
|
|
126
|
+
"sideEffects": [
|
|
127
|
+
"无副作用(纯函数)"
|
|
128
|
+
],
|
|
129
|
+
"failureSemantics": [
|
|
130
|
+
"SFC2002:未知操作",
|
|
131
|
+
"SFC2003:参数违反协议"
|
|
132
|
+
],
|
|
133
|
+
"invariants": [
|
|
134
|
+
"kernel 协议版本与 Contracts 版本绑定"
|
|
135
|
+
],
|
|
136
|
+
"ownedByCaller": [
|
|
137
|
+
"操作的具体业务语义"
|
|
138
|
+
],
|
|
139
|
+
"routeElsewhere": [
|
|
140
|
+
"业务状态机/重试/终态:转 loop-agent"
|
|
141
|
+
]
|
|
142
|
+
},
|
|
143
|
+
{
|
|
144
|
+
"id": "foundation.contracts.mandatory-checks",
|
|
145
|
+
"intent": "运行 9 类 mandatory rule 的机械检查(预算上限 20,绝对上限 30),对登记表内全部 Schema 统一编译",
|
|
146
|
+
"useWhen": [
|
|
147
|
+
"需要确认契约集满足强制机械规则",
|
|
148
|
+
"需要收集未解析引用(unresolved refs)"
|
|
149
|
+
],
|
|
150
|
+
"doNotUseWhen": [
|
|
151
|
+
"需要语义级审阅(属外部独立审阅,不在仓内维护第二份门禁)"
|
|
152
|
+
],
|
|
153
|
+
"prerequisites": [
|
|
154
|
+
"registry 与 rules 已加载"
|
|
155
|
+
],
|
|
156
|
+
"inputs": [
|
|
157
|
+
"待检查的契约集或合成 registry/fixtures"
|
|
158
|
+
],
|
|
159
|
+
"outputs": [
|
|
160
|
+
"检查结论与未解析引用清单"
|
|
161
|
+
],
|
|
162
|
+
"sideEffects": [
|
|
163
|
+
"无副作用(纯函数)"
|
|
164
|
+
],
|
|
165
|
+
"failureSemantics": [
|
|
166
|
+
"SFC1002/1003/1004/1005/1006/1008/1009/1010:对应规则 violated"
|
|
167
|
+
],
|
|
168
|
+
"invariants": [
|
|
169
|
+
"CHECK_TYPES 为 9 类闭集",
|
|
170
|
+
"RULE_BUDGET 限制 firstVersionMax 与 absoluteMax"
|
|
171
|
+
],
|
|
172
|
+
"ownedByCaller": [
|
|
173
|
+
"规则业务理由的解释"
|
|
174
|
+
],
|
|
175
|
+
"routeElsewhere": [
|
|
176
|
+
"语义接受/拒绝:外部独立审阅"
|
|
177
|
+
]
|
|
178
|
+
},
|
|
179
|
+
{
|
|
180
|
+
"id": "foundation.contracts.fixture-verification",
|
|
181
|
+
"intent": "枚举并校验公开/虚构 fixture,确认其符合对应契约对象的 expect 声明",
|
|
182
|
+
"useWhen": [
|
|
183
|
+
"需要证明某契约对象被 fixture 覆盖",
|
|
184
|
+
"需要运行 positive/negative/dialect-boundary 类 fixture"
|
|
185
|
+
],
|
|
186
|
+
"doNotUseWhen": [
|
|
187
|
+
"需要把 fixture 当作业务 oracle(fixture 只证明结构,不证明语义)"
|
|
188
|
+
],
|
|
189
|
+
"prerequisites": [
|
|
190
|
+
"fixtures 目录为公开或完全虚构数据"
|
|
191
|
+
],
|
|
192
|
+
"inputs": [
|
|
193
|
+
"fixture 类或单个 fixture 标识"
|
|
194
|
+
],
|
|
195
|
+
"outputs": [
|
|
196
|
+
"逐 fixture 的校验结果"
|
|
197
|
+
],
|
|
198
|
+
"sideEffects": [
|
|
199
|
+
"无副作用(只读 fixture)"
|
|
200
|
+
],
|
|
201
|
+
"failureSemantics": [
|
|
202
|
+
"SFC1010:负例 fixture 未产生预期失败"
|
|
203
|
+
],
|
|
204
|
+
"invariants": [
|
|
205
|
+
"fixture 与审计器预期结果不共享"
|
|
206
|
+
],
|
|
207
|
+
"ownedByCaller": [
|
|
208
|
+
"fixture 背后的业务意图"
|
|
209
|
+
],
|
|
210
|
+
"routeElsewhere": [
|
|
211
|
+
"领域审计语义:转独立审计消费者"
|
|
212
|
+
]
|
|
213
|
+
},
|
|
214
|
+
{
|
|
215
|
+
"id": "foundation.contracts.error-codes",
|
|
216
|
+
"intent": "定义并登记稳定错误码体系,提供校验与断言入口,保证错误码不漂移",
|
|
217
|
+
"useWhen": [
|
|
218
|
+
"需要抛出或分类带稳定错误码的 ContractsError",
|
|
219
|
+
"需要断言某错误码已登记"
|
|
220
|
+
],
|
|
221
|
+
"doNotUseWhen": [
|
|
222
|
+
"需要定义在 Foundation 范围外的业务错误语义"
|
|
223
|
+
],
|
|
224
|
+
"prerequisites": [
|
|
225
|
+
"error-codes.json 已随包发布"
|
|
226
|
+
],
|
|
227
|
+
"inputs": [
|
|
228
|
+
"错误码字符串、错误上下文"
|
|
229
|
+
],
|
|
230
|
+
"outputs": [
|
|
231
|
+
"带稳定错误码与 details 的错误对象"
|
|
232
|
+
],
|
|
233
|
+
"sideEffects": [
|
|
234
|
+
"无副作用(纯函数)"
|
|
235
|
+
],
|
|
236
|
+
"failureSemantics": [
|
|
237
|
+
"对未登记错误码的断言失败",
|
|
238
|
+
"冻结对象不可变违反"
|
|
239
|
+
],
|
|
240
|
+
"invariants": [
|
|
241
|
+
"错误码注册表冻结,不可运行时增删"
|
|
242
|
+
],
|
|
243
|
+
"ownedByCaller": [
|
|
244
|
+
"错误码的业务归因"
|
|
245
|
+
],
|
|
246
|
+
"routeElsewhere": [
|
|
247
|
+
"语义审阅结论:外部独立审阅"
|
|
248
|
+
]
|
|
249
|
+
},
|
|
250
|
+
{
|
|
251
|
+
"id": "foundation.contracts.audit-surface",
|
|
252
|
+
"intent": "以确定性方式序列化契约表面(canonical JSON + sha256 摘要),供审计消费者只读投影",
|
|
253
|
+
"useWhen": [
|
|
254
|
+
"需要为契约表面生成可复算摘要",
|
|
255
|
+
"需要描述审计表面结构"
|
|
256
|
+
],
|
|
257
|
+
"doNotUseWhen": [
|
|
258
|
+
"需要审计领域语义(语义与最终接受/拒绝属外部审阅)"
|
|
259
|
+
],
|
|
260
|
+
"prerequisites": [
|
|
261
|
+
"AUDIT_SURFACE_VERSION=1、AUDIT_DIGEST_ALGORITHMS=[sha256]"
|
|
262
|
+
],
|
|
263
|
+
"inputs": [
|
|
264
|
+
"任意 JSON 文档"
|
|
265
|
+
],
|
|
266
|
+
"outputs": [
|
|
267
|
+
"canonical 字符串与 sha256 摘要"
|
|
268
|
+
],
|
|
269
|
+
"sideEffects": [
|
|
270
|
+
"无副作用(纯函数)"
|
|
271
|
+
],
|
|
272
|
+
"failureSemantics": [
|
|
273
|
+
"非 JSON 值、未知算法、冻结违规均抛错"
|
|
274
|
+
],
|
|
275
|
+
"invariants": [
|
|
276
|
+
"摘要算法仅 sha256,版本号固定"
|
|
277
|
+
],
|
|
278
|
+
"ownedByCaller": [
|
|
279
|
+
"审计语义结论"
|
|
280
|
+
],
|
|
281
|
+
"routeElsewhere": [
|
|
282
|
+
"领域审计语义:转独立审计消费者"
|
|
283
|
+
]
|
|
284
|
+
},
|
|
285
|
+
{
|
|
286
|
+
"id": "foundation.harness.contract-validation",
|
|
287
|
+
"intent": "在 Node 运行时解析契约上下文并复用 Contracts 校验器,校验契约文档并缓存校验器实例",
|
|
288
|
+
"useWhen": [
|
|
289
|
+
"需要在 Node 内校验 Foundation 契约文档",
|
|
290
|
+
"需要复用以 schema 为键的校验器缓存"
|
|
291
|
+
],
|
|
292
|
+
"doNotUseWhen": [
|
|
293
|
+
"需要在非 Node 运行时校验(当前只有 Node 实现)"
|
|
294
|
+
],
|
|
295
|
+
"prerequisites": [
|
|
296
|
+
"已安装 skill-family-contracts"
|
|
297
|
+
],
|
|
298
|
+
"inputs": [
|
|
299
|
+
"schema 上下文、契约文档"
|
|
300
|
+
],
|
|
301
|
+
"outputs": [
|
|
302
|
+
"校验结果,复用缓存的 Ajv 实例"
|
|
303
|
+
],
|
|
304
|
+
"sideEffects": [
|
|
305
|
+
"进程内内存缓存校验器(无文件/Git/网络)"
|
|
306
|
+
],
|
|
307
|
+
"failureSemantics": [
|
|
308
|
+
"date-time 等反例矩阵触发 SFC 校验失败"
|
|
309
|
+
],
|
|
310
|
+
"invariants": [
|
|
311
|
+
"校验器以 (schema) 为键缓存,size 可查询"
|
|
312
|
+
],
|
|
313
|
+
"ownedByCaller": [
|
|
314
|
+
"契约业务字段语义"
|
|
315
|
+
],
|
|
316
|
+
"routeElsewhere": [
|
|
317
|
+
"契约对象定义:转 Contracts"
|
|
318
|
+
]
|
|
319
|
+
},
|
|
320
|
+
{
|
|
321
|
+
"id": "foundation.harness.path-containment",
|
|
322
|
+
"intent": "把外部路径输入分类并解析到受收容根目录内,拒绝路径穿越、symlink 逃逸与 realpath 逃逸",
|
|
323
|
+
"useWhen": [
|
|
324
|
+
"需要把用户/调用方提供的路径限制在某个根目录内",
|
|
325
|
+
"需要安全读取受收容文件"
|
|
326
|
+
],
|
|
327
|
+
"doNotUseWhen": [
|
|
328
|
+
"需要把文件选择的业务规则放入 Foundation(业务规则由调用方拥有)"
|
|
329
|
+
],
|
|
330
|
+
"prerequisites": [
|
|
331
|
+
"调用方提供明确的根目录(收容边界)"
|
|
332
|
+
],
|
|
333
|
+
"inputs": [
|
|
334
|
+
"根目录、待解析的相对/绝对路径"
|
|
335
|
+
],
|
|
336
|
+
"outputs": [
|
|
337
|
+
"受收容的绝对路径或读到的文件内容"
|
|
338
|
+
],
|
|
339
|
+
"sideEffects": [
|
|
340
|
+
"只读文件系统访问(读取/解析)"
|
|
341
|
+
],
|
|
342
|
+
"failureSemantics": [
|
|
343
|
+
"SFC2004:path-traversal / symlink-escape / realpath-escape,携带稳定 kind",
|
|
344
|
+
"Windows 盘符/UNC 逃逸同样拒绝"
|
|
345
|
+
],
|
|
346
|
+
"invariants": [
|
|
347
|
+
"所有解析结果必须落在根目录内"
|
|
348
|
+
],
|
|
349
|
+
"ownedByCaller": [
|
|
350
|
+
"哪些路径是业务允许的选择规则"
|
|
351
|
+
],
|
|
352
|
+
"routeElsewhere": [
|
|
353
|
+
"业务文件选择语义:留在调用方"
|
|
354
|
+
]
|
|
355
|
+
},
|
|
356
|
+
{
|
|
357
|
+
"id": "foundation.harness.atomic-write",
|
|
358
|
+
"intent": "在已收容路径内以临时文件 + fsync + rename 原子写入普通文件,失败时回滚不留残影",
|
|
359
|
+
"useWhen": [
|
|
360
|
+
"需要更新受收容目录内的普通文本/二进制文件",
|
|
361
|
+
"需要保证写入要么完整可见、要么不可见"
|
|
362
|
+
],
|
|
363
|
+
"doNotUseWhen": [
|
|
364
|
+
"需要写入未受收容路径(越界由 path-containment 拒绝)"
|
|
365
|
+
],
|
|
366
|
+
"prerequisites": [
|
|
367
|
+
"目标路径经 path-containment 验证在根目录内"
|
|
368
|
+
],
|
|
369
|
+
"inputs": [
|
|
370
|
+
"已收容目标路径、文件内容(string 或 Buffer)"
|
|
371
|
+
],
|
|
372
|
+
"outputs": [
|
|
373
|
+
"写入完成的文件,字节与输入一致"
|
|
374
|
+
],
|
|
375
|
+
"sideEffects": [
|
|
376
|
+
"在根目录内创建临时文件并最终 rename 覆盖目标"
|
|
377
|
+
],
|
|
378
|
+
"failureSemantics": [
|
|
379
|
+
"越界路径、非法数据类型抛错并回滚临时文件",
|
|
380
|
+
"二进制内容逐字节保留"
|
|
381
|
+
],
|
|
382
|
+
"invariants": [
|
|
383
|
+
"rename 前先 fsync,保证崩溃一致性"
|
|
384
|
+
],
|
|
385
|
+
"ownedByCaller": [
|
|
386
|
+
"写入内容的业务正确性"
|
|
387
|
+
],
|
|
388
|
+
"routeElsewhere": [
|
|
389
|
+
"内容选择业务规则:留在调用方"
|
|
390
|
+
]
|
|
391
|
+
},
|
|
392
|
+
{
|
|
393
|
+
"id": "foundation.harness.temporary-workspace",
|
|
394
|
+
"intent": "创建并管理临时工作目录,提供 with 语法的安全生命周期,退出时清理",
|
|
395
|
+
"useWhen": [
|
|
396
|
+
"需要在隔离目录内做构建/中间产物",
|
|
397
|
+
"需要保证异常时临时目录被回收"
|
|
398
|
+
],
|
|
399
|
+
"doNotUseWhen": [
|
|
400
|
+
"需要持久保存产物(应显式 materialize 到受收容路径)"
|
|
401
|
+
],
|
|
402
|
+
"prerequisites": [
|
|
403
|
+
"宿主提供可写临时目录(如 os.tmpdir)"
|
|
404
|
+
],
|
|
405
|
+
"inputs": [
|
|
406
|
+
"可选前缀/标签"
|
|
407
|
+
],
|
|
408
|
+
"outputs": [
|
|
409
|
+
"临时工作目录句柄"
|
|
410
|
+
],
|
|
411
|
+
"sideEffects": [
|
|
412
|
+
"在系统临时目录创建子目录,退出时删除"
|
|
413
|
+
],
|
|
414
|
+
"failureSemantics": [
|
|
415
|
+
"创建失败 reject;with 回调抛错时仍清理临时目录"
|
|
416
|
+
],
|
|
417
|
+
"invariants": [
|
|
418
|
+
"临时目录路径不逃逸出宿主临时根"
|
|
419
|
+
],
|
|
420
|
+
"ownedByCaller": [
|
|
421
|
+
"临时产物的最终去处"
|
|
422
|
+
],
|
|
423
|
+
"routeElsewhere": [
|
|
424
|
+
"持久状态:转 state-store"
|
|
425
|
+
]
|
|
426
|
+
},
|
|
427
|
+
{
|
|
428
|
+
"id": "foundation.harness.resource-closure",
|
|
429
|
+
"intent": "计算确定性、去重、有序的资源闭包并以 sha256 摘要,供 adapter 文本闭包与构建清单使用",
|
|
430
|
+
"useWhen": [
|
|
431
|
+
"需要把一组资源归一成可复算的闭包",
|
|
432
|
+
"需要为构建清单生成摘要"
|
|
433
|
+
],
|
|
434
|
+
"doNotUseWhen": [
|
|
435
|
+
"需要纳入二进制资源(当前只支持文本闭包)"
|
|
436
|
+
],
|
|
437
|
+
"prerequisites": [
|
|
438
|
+
"资源为可序列化的文本条目"
|
|
439
|
+
],
|
|
440
|
+
"inputs": [
|
|
441
|
+
"资源列表(路径 + 内容)"
|
|
442
|
+
],
|
|
443
|
+
"outputs": [
|
|
444
|
+
"确定性闭包对象与 sha256 摘要"
|
|
445
|
+
],
|
|
446
|
+
"sideEffects": [
|
|
447
|
+
"无副作用(纯函数)"
|
|
448
|
+
],
|
|
449
|
+
"failureSemantics": [
|
|
450
|
+
"非法/重复资源声明抛错或 reject"
|
|
451
|
+
],
|
|
452
|
+
"invariants": [
|
|
453
|
+
"去重与排序固定,相同输入恒得相同摘要"
|
|
454
|
+
],
|
|
455
|
+
"ownedByCaller": [
|
|
456
|
+
"资源业务含义"
|
|
457
|
+
],
|
|
458
|
+
"routeElsewhere": [
|
|
459
|
+
"二进制投影:明确 unsupported"
|
|
460
|
+
]
|
|
461
|
+
},
|
|
462
|
+
{
|
|
463
|
+
"id": "foundation.harness.request-processing",
|
|
464
|
+
"intent": "解析 operation-request 并驱动 operation-result 管线,产出终态 REJECTED / FAILED / SUCCESS",
|
|
465
|
+
"useWhen": [
|
|
466
|
+
"需要把入站请求规整为统一操作请求结构",
|
|
467
|
+
"需要确定性产出操作结果"
|
|
468
|
+
],
|
|
469
|
+
"doNotUseWhen": [
|
|
470
|
+
"需要模型调用或业务编排(均不在 Foundation 范围)"
|
|
471
|
+
],
|
|
472
|
+
"prerequisites": [
|
|
473
|
+
"请求符合 kernel 协议结构"
|
|
474
|
+
],
|
|
475
|
+
"inputs": [
|
|
476
|
+
"原始请求负载"
|
|
477
|
+
],
|
|
478
|
+
"outputs": [
|
|
479
|
+
"规范化 operation-request 与终态 operation-result"
|
|
480
|
+
],
|
|
481
|
+
"sideEffects": [
|
|
482
|
+
"无副作用(纯函数管线)"
|
|
483
|
+
],
|
|
484
|
+
"failureSemantics": [
|
|
485
|
+
"解析失败进入 REJECTED/FAILED 终态并带稳定错误码"
|
|
486
|
+
],
|
|
487
|
+
"invariants": [
|
|
488
|
+
"终态集合固定为 REJECTED/FAILED/SUCCESS"
|
|
489
|
+
],
|
|
490
|
+
"ownedByCaller": [
|
|
491
|
+
"操作的具体业务语义"
|
|
492
|
+
],
|
|
493
|
+
"routeElsewhere": [
|
|
494
|
+
"业务状态机/重试:转 loop-agent"
|
|
495
|
+
]
|
|
496
|
+
},
|
|
497
|
+
{
|
|
498
|
+
"id": "foundation.harness.report",
|
|
499
|
+
"intent": "以确定性方式校验 report-model、渲染 Markdown、绑定摘要并分级检查,人类报告由机器结果派生而非自由撰写",
|
|
500
|
+
"useWhen": [
|
|
501
|
+
"需要把机器结果渲染成人类可读报告",
|
|
502
|
+
"需要把 model/result/report 三摘要绑定防篡改"
|
|
503
|
+
],
|
|
504
|
+
"doNotUseWhen": [
|
|
505
|
+
"需要从开放业务 outputs 自由编报告(禁止)"
|
|
506
|
+
],
|
|
507
|
+
"prerequisites": [
|
|
508
|
+
"REPORT_RENDERER_NAME / VERSION 取自各自 package(当前 0.2.1)",
|
|
509
|
+
"SUPPORTED_REPORT_LOCALES = [zh-CN, en-US]"
|
|
510
|
+
],
|
|
511
|
+
"inputs": [
|
|
512
|
+
"report-model、渲染选项(locale/audience/style)"
|
|
513
|
+
],
|
|
514
|
+
"outputs": [
|
|
515
|
+
"Markdown 文本、绑定对象、分级检查发现"
|
|
516
|
+
],
|
|
517
|
+
"sideEffects": [
|
|
518
|
+
"无文件/Git/网络副作用(纯函数)"
|
|
519
|
+
],
|
|
520
|
+
"failureSemantics": [
|
|
521
|
+
"SFC3001/3002/3003:模型校验/绑定/检查硬失败"
|
|
522
|
+
],
|
|
523
|
+
"invariants": [
|
|
524
|
+
"Markdown 确定性转义,双输出成组写入并拒绝路径别名与输入覆盖"
|
|
525
|
+
],
|
|
526
|
+
"ownedByCaller": [
|
|
527
|
+
"报告业务结论的解读"
|
|
528
|
+
],
|
|
529
|
+
"routeElsewhere": [
|
|
530
|
+
"报告生成编排:Kit report 子动作"
|
|
531
|
+
]
|
|
532
|
+
},
|
|
533
|
+
{
|
|
534
|
+
"id": "foundation.harness.host-adapter",
|
|
535
|
+
"intent": "实现宿主接入的通用机制层:归一化 adapter source、计算构建闭包、校验构建清单、materialize 构建、probe 版本向量(默认禁 spawn)",
|
|
536
|
+
"useWhen": [
|
|
537
|
+
"需要把宿主适配源做成可复算的文本闭包",
|
|
538
|
+
"需要在受收容处 materialize 构建产物",
|
|
539
|
+
"需要探测宿主版本向量(不自动执行宿主二进制)"
|
|
540
|
+
],
|
|
541
|
+
"doNotUseWhen": [
|
|
542
|
+
"需要 host apply/install/update/uninstall(明确 unsupported)",
|
|
543
|
+
"需要二进制 adapter source(仅支持文本闭包)"
|
|
544
|
+
],
|
|
545
|
+
"prerequisites": [
|
|
546
|
+
"adapter source 为已声明文本闭包"
|
|
547
|
+
],
|
|
548
|
+
"inputs": [
|
|
549
|
+
"adapter source、目标路径"
|
|
550
|
+
],
|
|
551
|
+
"outputs": [
|
|
552
|
+
"构建闭包、校验后的清单、materialize 产物"
|
|
553
|
+
],
|
|
554
|
+
"sideEffects": [
|
|
555
|
+
"在受收容目标创建 sibling staging 并单次 rename",
|
|
556
|
+
"probe 默认不 spawn,不走 PATH"
|
|
557
|
+
],
|
|
558
|
+
"failureSemantics": [
|
|
559
|
+
"清单摘要不符、目标已存在、非受信可执行文件均抛错"
|
|
560
|
+
],
|
|
561
|
+
"invariants": [
|
|
562
|
+
"materialize 为原子 sibling + rename"
|
|
563
|
+
],
|
|
564
|
+
"ownedByCaller": [
|
|
565
|
+
"宿主具体业务语义"
|
|
566
|
+
],
|
|
567
|
+
"routeElsewhere": [
|
|
568
|
+
"host apply:明确 unsupported",
|
|
569
|
+
"宿主差异声明:转 Profile + Kit host 子动作"
|
|
570
|
+
]
|
|
571
|
+
},
|
|
572
|
+
{
|
|
573
|
+
"id": "foundation.harness.state-store",
|
|
574
|
+
"intent": "提供持久状态底座:append-only 事件、hash chain、派生快照,以及锁检查与显式恢复;事件含义与 reducer 转移由调用方拥有",
|
|
575
|
+
"useWhen": [
|
|
576
|
+
"需要持久化事件日志并保证顺序与完整性",
|
|
577
|
+
"需要重建或校验派生快照",
|
|
578
|
+
"需要检查或恢复协作式单写者锁"
|
|
579
|
+
],
|
|
580
|
+
"doNotUseWhen": [
|
|
581
|
+
"需要在 Foundation 定义 workflow 状态机(禁止)",
|
|
582
|
+
"需要抵御同权限恶意进程(fencing 不承诺该场景)"
|
|
583
|
+
],
|
|
584
|
+
"prerequisites": [
|
|
585
|
+
"STATE_GENESIS_DIGEST 作为链起点"
|
|
586
|
+
],
|
|
587
|
+
"inputs": [
|
|
588
|
+
"事件负载、快照、锁令牌"
|
|
589
|
+
],
|
|
590
|
+
"outputs": [
|
|
591
|
+
"事件、hash chain 校验结果、快照"
|
|
592
|
+
],
|
|
593
|
+
"sideEffects": [
|
|
594
|
+
"在受收容路径读写事件日志与快照文件",
|
|
595
|
+
"写锁文件用于协作式单写者"
|
|
596
|
+
],
|
|
597
|
+
"failureSemantics": [
|
|
598
|
+
"hash chain 断裂、锁 fencing 冲突、恢复失败抛错"
|
|
599
|
+
],
|
|
600
|
+
"invariants": [
|
|
601
|
+
"事件日志是唯一权威,snapshot 为派生缓存",
|
|
602
|
+
"本地协作式单写者使用 fencing 与显式恢复"
|
|
603
|
+
],
|
|
604
|
+
"ownedByCaller": [
|
|
605
|
+
"事件业务含义、reducer 转移、confirmOwnerTerminated 信任锚"
|
|
606
|
+
],
|
|
607
|
+
"routeElsewhere": [
|
|
608
|
+
"业务状态机/终态:转 loop-agent"
|
|
609
|
+
]
|
|
610
|
+
},
|
|
611
|
+
{
|
|
612
|
+
"id": "foundation.harness.errors",
|
|
613
|
+
"intent": "定义 Harness 机制错误类型与稳定错误类,统一错误分类",
|
|
614
|
+
"useWhen": [
|
|
615
|
+
"需要抛出带稳定 kind 的 HarnessError"
|
|
616
|
+
],
|
|
617
|
+
"doNotUseWhen": [
|
|
618
|
+
"需要定义业务错误语义"
|
|
619
|
+
],
|
|
620
|
+
"prerequisites": [],
|
|
621
|
+
"inputs": [
|
|
622
|
+
"错误 kind、上下文"
|
|
623
|
+
],
|
|
624
|
+
"outputs": [
|
|
625
|
+
"带稳定 kind 的错误对象"
|
|
626
|
+
],
|
|
627
|
+
"sideEffects": [
|
|
628
|
+
"无副作用(纯函数)"
|
|
629
|
+
],
|
|
630
|
+
"failureSemantics": [
|
|
631
|
+
"非法 kind 调用抛错"
|
|
632
|
+
],
|
|
633
|
+
"invariants": [
|
|
634
|
+
"HARNESS_EXCLUSIONS 明确排除 release-state / remote-network-access / business-semantics / workflow-orchestration / model-calls / git-writes"
|
|
635
|
+
],
|
|
636
|
+
"ownedByCaller": [
|
|
637
|
+
"错误业务归因"
|
|
638
|
+
],
|
|
639
|
+
"routeElsewhere": [
|
|
640
|
+
"业务语义:留在调用方"
|
|
641
|
+
]
|
|
642
|
+
},
|
|
643
|
+
{
|
|
644
|
+
"id": "foundation.kit.scaffold",
|
|
645
|
+
"intent": "在新项目骨架中生成精确集合的托管文件(原子 + 路径收容),不覆盖非空存量仓",
|
|
646
|
+
"useWhen": [
|
|
647
|
+
"需要为新技能族项目生成最小可验证骨架",
|
|
648
|
+
"目标目录为空或仅含可收容内容"
|
|
649
|
+
],
|
|
650
|
+
"doNotUseWhen": [
|
|
651
|
+
"需要覆盖已存在的非空存量仓(应改用 adopt-plan)"
|
|
652
|
+
],
|
|
653
|
+
"prerequisites": [
|
|
654
|
+
"目标为可写空目录",
|
|
655
|
+
"Node >= 22.22.2"
|
|
656
|
+
],
|
|
657
|
+
"inputs": [
|
|
658
|
+
"目标根、骨架选项(id 等)"
|
|
659
|
+
],
|
|
660
|
+
"outputs": [
|
|
661
|
+
"精确集合的托管骨架文件"
|
|
662
|
+
],
|
|
663
|
+
"sideEffects": [
|
|
664
|
+
"在受收容目标创建文件(原子 + 收容)"
|
|
665
|
+
],
|
|
666
|
+
"failureSemantics": [
|
|
667
|
+
"非空目标、非法 kebab id 抛错"
|
|
668
|
+
],
|
|
669
|
+
"invariants": [
|
|
670
|
+
"只写空目标、原子 + 收容",
|
|
671
|
+
"骨架集合与 scaffold-conformance fixture 一致"
|
|
672
|
+
],
|
|
673
|
+
"ownedByCaller": [
|
|
674
|
+
"业务项目内容"
|
|
675
|
+
],
|
|
676
|
+
"routeElsewhere": [
|
|
677
|
+
"存量采用:转 adopt-plan"
|
|
678
|
+
]
|
|
679
|
+
},
|
|
680
|
+
{
|
|
681
|
+
"id": "foundation.kit.adopt-plan",
|
|
682
|
+
"intent": "对已存在的存量仓做严格只读盘点(分类、嵌套仓发现、迁移清单、完成判定),不写文件、不自动迁移",
|
|
683
|
+
"useWhen": [
|
|
684
|
+
"需要把存量仓分类为 direct-adoption / compatibility-layer / keep-business / foundation-gap",
|
|
685
|
+
"需要为迁移生成 handoff 草稿或完成判定"
|
|
686
|
+
],
|
|
687
|
+
"doNotUseWhen": [
|
|
688
|
+
"需要自动改写存量仓(禁止写文件、禁止自动迁移)"
|
|
689
|
+
],
|
|
690
|
+
"prerequisites": [
|
|
691
|
+
"目标仓存在且可只读访问"
|
|
692
|
+
],
|
|
693
|
+
"inputs": [
|
|
694
|
+
"目标根、迁移清单路径"
|
|
695
|
+
],
|
|
696
|
+
"outputs": [
|
|
697
|
+
"采用分类、完成判定、handoff 草稿(仅输出,不落盘)"
|
|
698
|
+
],
|
|
699
|
+
"sideEffects": [
|
|
700
|
+
"无文件写入(严格只读)",
|
|
701
|
+
"可能触发只读 git 探测"
|
|
702
|
+
],
|
|
703
|
+
"failureSemantics": [
|
|
704
|
+
"例外缺字段、未退出旧实现则完成判定为 false"
|
|
705
|
+
],
|
|
706
|
+
"invariants": [
|
|
707
|
+
"不写文件、不自动迁移"
|
|
708
|
+
],
|
|
709
|
+
"ownedByCaller": [
|
|
710
|
+
"存量业务代码的迁移决策"
|
|
711
|
+
],
|
|
712
|
+
"routeElsewhere": [
|
|
713
|
+
"真正迁移执行:调用方负责"
|
|
714
|
+
]
|
|
715
|
+
},
|
|
716
|
+
{
|
|
717
|
+
"id": "foundation.kit.projection",
|
|
718
|
+
"intent": "按投影清单把受管事实机械投影到目标(如 public 镜像),全校验通过后才写,任一失败零写/回滚",
|
|
719
|
+
"useWhen": [
|
|
720
|
+
"需要把权威数据投影到 public 快照或发布镜像",
|
|
721
|
+
"需要保证投影与目标一致"
|
|
722
|
+
],
|
|
723
|
+
"doNotUseWhen": [
|
|
724
|
+
"需要覆盖 handwritten 文件(禁止)"
|
|
725
|
+
],
|
|
726
|
+
"prerequisites": [
|
|
727
|
+
"投影清单已登记"
|
|
728
|
+
],
|
|
729
|
+
"inputs": [
|
|
730
|
+
"投影清单、目标根"
|
|
731
|
+
],
|
|
732
|
+
"outputs": [
|
|
733
|
+
"投影文件(仅在校验全部通过时)"
|
|
734
|
+
],
|
|
735
|
+
"sideEffects": [
|
|
736
|
+
"在受收容目标写投影文件",
|
|
737
|
+
"两阶段:全校验后才写,失败回滚"
|
|
738
|
+
],
|
|
739
|
+
"failureSemantics": [
|
|
740
|
+
"未授权、手写冲突、越界、内容冲突均抛错且不残留"
|
|
741
|
+
],
|
|
742
|
+
"invariants": [
|
|
743
|
+
"不覆盖 handwritten 文件",
|
|
744
|
+
"任一校验失败零写"
|
|
745
|
+
],
|
|
746
|
+
"ownedByCaller": [
|
|
747
|
+
"投影内容的业务含义"
|
|
748
|
+
],
|
|
749
|
+
"routeElsewhere": [
|
|
750
|
+
"远端发布:转 release-skill"
|
|
751
|
+
]
|
|
752
|
+
},
|
|
753
|
+
{
|
|
754
|
+
"id": "foundation.kit.check",
|
|
755
|
+
"intent": "只诊断不修复:运行 contracts/drift/closure/version/docs/git/identity 七类检查,输出发现(findings)",
|
|
756
|
+
"useWhen": [
|
|
757
|
+
"需要发现工程不一致但不自动修改",
|
|
758
|
+
"需要按 --only 缩小检查范围"
|
|
759
|
+
],
|
|
760
|
+
"doNotUseWhen": [
|
|
761
|
+
"需要自动修复(禁止,check 不写修复)"
|
|
762
|
+
],
|
|
763
|
+
"prerequisites": [],
|
|
764
|
+
"inputs": [
|
|
765
|
+
"--only 取值:contracts|drift|closure|version|docs|git|identity"
|
|
766
|
+
],
|
|
767
|
+
"outputs": [
|
|
768
|
+
"发现清单;退出码 findings=1、mechanism=2"
|
|
769
|
+
],
|
|
770
|
+
"sideEffects": [
|
|
771
|
+
"无文件写入(只读诊断)"
|
|
772
|
+
],
|
|
773
|
+
"failureSemantics": [
|
|
774
|
+
"findings 退出码 1;mechanism 拒绝退出码 2"
|
|
775
|
+
],
|
|
776
|
+
"invariants": [
|
|
777
|
+
"CHECK_CLASSES 为七类闭集,不扩张"
|
|
778
|
+
],
|
|
779
|
+
"ownedByCaller": [
|
|
780
|
+
"发现项的业务处置"
|
|
781
|
+
],
|
|
782
|
+
"routeElsewhere": [
|
|
783
|
+
"自动修复执行:调用方"
|
|
784
|
+
]
|
|
785
|
+
},
|
|
786
|
+
{
|
|
787
|
+
"id": "foundation.kit.report",
|
|
788
|
+
"intent": "以 CLI 子动作编排人类报告:projection report 渲染、check report 分级,默认只写 stdout",
|
|
789
|
+
"useWhen": [
|
|
790
|
+
"需要从已渲染 model 产出报告文本",
|
|
791
|
+
"需要对报告做分级检查"
|
|
792
|
+
],
|
|
793
|
+
"doNotUseWhen": [
|
|
794
|
+
"需要从开放业务输出自由编报告(禁止)"
|
|
795
|
+
],
|
|
796
|
+
"prerequisites": [
|
|
797
|
+
"已存在 Harness report-model"
|
|
798
|
+
],
|
|
799
|
+
"inputs": [
|
|
800
|
+
"report-model、--out/--binding 选项"
|
|
801
|
+
],
|
|
802
|
+
"outputs": [
|
|
803
|
+
"Markdown 文本;--out/--binding 才落盘"
|
|
804
|
+
],
|
|
805
|
+
"sideEffects": [
|
|
806
|
+
"默认只写 stdout;显式 --out/--binding 才写受收容文件"
|
|
807
|
+
],
|
|
808
|
+
"failureSemantics": [
|
|
809
|
+
"硬失败计为发现;非法参数 reject"
|
|
810
|
+
],
|
|
811
|
+
"invariants": [
|
|
812
|
+
"报告由机器结果确定性渲染"
|
|
813
|
+
],
|
|
814
|
+
"ownedByCaller": [
|
|
815
|
+
"报告结论解读"
|
|
816
|
+
],
|
|
817
|
+
"routeElsewhere": [
|
|
818
|
+
"报告机制:转 Harness report"
|
|
819
|
+
]
|
|
820
|
+
},
|
|
821
|
+
{
|
|
822
|
+
"id": "foundation.kit.git-probe",
|
|
823
|
+
"intent": "以只读白名单探测 Git 状态与事实,供诊断与采用盘点使用,不执行任何 Git 写操作",
|
|
824
|
+
"useWhen": [
|
|
825
|
+
"需要只读发现当前 Git 状态(status/ls-files/check-ignore)",
|
|
826
|
+
"需要为采用盘点提供 Git 事实"
|
|
827
|
+
],
|
|
828
|
+
"doNotUseWhen": [
|
|
829
|
+
"需要 Git 写操作(stage/commit/push/tag,明确禁止)"
|
|
830
|
+
],
|
|
831
|
+
"prerequisites": [],
|
|
832
|
+
"inputs": [
|
|
833
|
+
"目标根"
|
|
834
|
+
],
|
|
835
|
+
"outputs": [
|
|
836
|
+
"Git 状态与事实(只读)"
|
|
837
|
+
],
|
|
838
|
+
"sideEffects": [
|
|
839
|
+
"只读调用 git status/ls-files/check-ignore(参数向量冻结)"
|
|
840
|
+
],
|
|
841
|
+
"failureSemantics": [
|
|
842
|
+
"不在白名单的参数向量被拒绝"
|
|
843
|
+
],
|
|
844
|
+
"invariants": [
|
|
845
|
+
"GIT_READ_ONLY_ALLOWLIST 限定可调用子命令"
|
|
846
|
+
],
|
|
847
|
+
"ownedByCaller": [
|
|
848
|
+
"Git 写操作授权"
|
|
849
|
+
],
|
|
850
|
+
"routeElsewhere": [
|
|
851
|
+
"Git 写操作:见 Git 生命周期指南,Foundation 不拥有"
|
|
852
|
+
]
|
|
853
|
+
},
|
|
854
|
+
{
|
|
855
|
+
"id": "foundation.kit.host",
|
|
856
|
+
"intent": "注入具体宿主 Profile 与受信 driver,提供 describe/build/probe/plan;apply 稳定拒绝,install/update/uninstall 未实现",
|
|
857
|
+
"useWhen": [
|
|
858
|
+
"需要描述已登记宿主(claude/codex)",
|
|
859
|
+
"需要探测、构建或规划宿主接入(只读机制层)"
|
|
860
|
+
],
|
|
861
|
+
"doNotUseWhen": [
|
|
862
|
+
"需要 host apply/install/update/uninstall(明确 unsupported)",
|
|
863
|
+
"需要 Qoder 完整 driver(该宿主 unsupported)"
|
|
864
|
+
],
|
|
865
|
+
"prerequisites": [
|
|
866
|
+
"宿主 Profile 已在 profiles/hosts 登记",
|
|
867
|
+
"受信 driver 仅 claude-version-v1 / codex-version-v1"
|
|
868
|
+
],
|
|
869
|
+
"inputs": [
|
|
870
|
+
"宿主标识、probe/plan 选项"
|
|
871
|
+
],
|
|
872
|
+
"outputs": [
|
|
873
|
+
"宿主描述、probe 结果、构建产物、plan"
|
|
874
|
+
],
|
|
875
|
+
"sideEffects": [
|
|
876
|
+
"build/materialize 在受收容目标写产物",
|
|
877
|
+
"probe 默认不 spawn"
|
|
878
|
+
],
|
|
879
|
+
"failureSemantics": [
|
|
880
|
+
"unsupported host(如 qoder)抛错",
|
|
881
|
+
"apply 稳定拒绝",
|
|
882
|
+
"缺 probe facts 抛错"
|
|
883
|
+
],
|
|
884
|
+
"invariants": [
|
|
885
|
+
"HOST_DRIVER_IDS 仅两个受信 driver",
|
|
886
|
+
"apply 稳定拒绝"
|
|
887
|
+
],
|
|
888
|
+
"ownedByCaller": [
|
|
889
|
+
"宿主业务语义"
|
|
890
|
+
],
|
|
891
|
+
"routeElsewhere": [
|
|
892
|
+
"host apply:明确 unsupported",
|
|
893
|
+
"Qoder 完整 driver:unsupported"
|
|
894
|
+
]
|
|
895
|
+
},
|
|
896
|
+
{
|
|
897
|
+
"id": "foundation.kit.licensing",
|
|
898
|
+
"intent": "加载并校验 Profile 授权数据,生成许可证/声明/身份记录内容",
|
|
899
|
+
"useWhen": [
|
|
900
|
+
"需要按 Profile 生成 LICENSE/NOTICE/身份记录",
|
|
901
|
+
"需要校验授权 Profile 合法性"
|
|
902
|
+
],
|
|
903
|
+
"doNotUseWhen": [
|
|
904
|
+
"需要执行业务授权决策(语义由调用方)"
|
|
905
|
+
],
|
|
906
|
+
"prerequisites": [
|
|
907
|
+
"profiles/licensing/registry.json + schema.json 存在"
|
|
908
|
+
],
|
|
909
|
+
"inputs": [
|
|
910
|
+
"Profile 标识、变体选择"
|
|
911
|
+
],
|
|
912
|
+
"outputs": [
|
|
913
|
+
"许可证/声明/身份记录文本"
|
|
914
|
+
],
|
|
915
|
+
"sideEffects": [
|
|
916
|
+
"无副作用(纯函数生成)"
|
|
917
|
+
],
|
|
918
|
+
"failureSemantics": [
|
|
919
|
+
"多变体未指定、非法 Profile 抛错"
|
|
920
|
+
],
|
|
921
|
+
"invariants": [
|
|
922
|
+
"默认取 registry 第一变体,多变体须显式选择"
|
|
923
|
+
],
|
|
924
|
+
"ownedByCaller": [
|
|
925
|
+
"授权业务语义"
|
|
926
|
+
],
|
|
927
|
+
"routeElsewhere": [
|
|
928
|
+
"授权决策:留在调用方"
|
|
929
|
+
]
|
|
930
|
+
},
|
|
931
|
+
{
|
|
932
|
+
"id": "foundation.kit.identity-check",
|
|
933
|
+
"intent": "加载身份记录与清单,检查身份漂移并对照 Profile 校验一致性",
|
|
934
|
+
"useWhen": [
|
|
935
|
+
"需要检测 package/identity 漂移",
|
|
936
|
+
"需要对照 Profile 校验身份"
|
|
937
|
+
],
|
|
938
|
+
"doNotUseWhen": [
|
|
939
|
+
"需要自动修复漂移(check 不修复)"
|
|
940
|
+
],
|
|
941
|
+
"prerequisites": [],
|
|
942
|
+
"inputs": [
|
|
943
|
+
"目标根、Profile 标识"
|
|
944
|
+
],
|
|
945
|
+
"outputs": [
|
|
946
|
+
"漂移发现、校验结论"
|
|
947
|
+
],
|
|
948
|
+
"sideEffects": [
|
|
949
|
+
"只读读取目标文件"
|
|
950
|
+
],
|
|
951
|
+
"failureSemantics": [
|
|
952
|
+
"漂移或校验失败产出 findings"
|
|
953
|
+
],
|
|
954
|
+
"invariants": [
|
|
955
|
+
"不修改目标文件"
|
|
956
|
+
],
|
|
957
|
+
"ownedByCaller": [
|
|
958
|
+
"漂移业务处置"
|
|
959
|
+
],
|
|
960
|
+
"routeElsewhere": [
|
|
961
|
+
"自动修复:调用方"
|
|
962
|
+
]
|
|
963
|
+
},
|
|
964
|
+
{
|
|
965
|
+
"id": "foundation.kit.cli",
|
|
966
|
+
"intent": "提供 skill-family-kit CLI 入口,分派四个顶层命令与子动作,并在入口处拒绝变更旗标",
|
|
967
|
+
"useWhen": [
|
|
968
|
+
"需要通过命令行运行 scaffold/adopt-plan/projection/check",
|
|
969
|
+
"需要运行 report/host 子动作"
|
|
970
|
+
],
|
|
971
|
+
"doNotUseWhen": [
|
|
972
|
+
"需要第五个顶层命令(命令集合固定为 4,不扩张)"
|
|
973
|
+
],
|
|
974
|
+
"prerequisites": [
|
|
975
|
+
"Node >= 22.22.2"
|
|
976
|
+
],
|
|
977
|
+
"inputs": [
|
|
978
|
+
"argv"
|
|
979
|
+
],
|
|
980
|
+
"outputs": [
|
|
981
|
+
"命令结果;退出码 ok=0/findings=1/rejected=2"
|
|
982
|
+
],
|
|
983
|
+
"sideEffects": [
|
|
984
|
+
"依命令产生受收容文件写入或只读探测"
|
|
985
|
+
],
|
|
986
|
+
"failureSemantics": [
|
|
987
|
+
"未知命令、拒绝旗标(如 --apply)退出码 2"
|
|
988
|
+
],
|
|
989
|
+
"invariants": [
|
|
990
|
+
"TOP_LEVEL_COMMANDS 固定 4 个",
|
|
991
|
+
"REFUSED_MUTATION_FLAGS 在 parseOptions 入口即拒"
|
|
992
|
+
],
|
|
993
|
+
"ownedByCaller": [
|
|
994
|
+
"命令的业务目标"
|
|
995
|
+
],
|
|
996
|
+
"routeElsewhere": [
|
|
997
|
+
"第 5 个命令:禁止新增"
|
|
998
|
+
]
|
|
999
|
+
},
|
|
1000
|
+
{
|
|
1001
|
+
"id": "foundation.profile.extension-spi",
|
|
1002
|
+
"intent": "声明宿主与项目形态差异的扩展机制:differences(adds/overrides/removes)与开放扩展点(host-projection/artifact-render/surface-scan),校验 Profile 合法性",
|
|
1003
|
+
"useWhen": [
|
|
1004
|
+
"需要声明项目形态差异而不改公共核心",
|
|
1005
|
+
"需要把扩展点数据资源注入稳定 SPI"
|
|
1006
|
+
],
|
|
1007
|
+
"doNotUseWhen": [
|
|
1008
|
+
"需要把业务语义塞进公共核心(coreOwned 目标禁入)",
|
|
1009
|
+
"需要把可执行脚本放进 Profile(入口必须为 JSON 数据资源)"
|
|
1010
|
+
],
|
|
1011
|
+
"prerequisites": [
|
|
1012
|
+
"Profile 为声明式差异,不反向依赖公共核心"
|
|
1013
|
+
],
|
|
1014
|
+
"inputs": [
|
|
1015
|
+
"profileRoot、descriptorRelPath"
|
|
1016
|
+
],
|
|
1017
|
+
"outputs": [
|
|
1018
|
+
"SPI 结果码(SPE0000/1001..1005)"
|
|
1019
|
+
],
|
|
1020
|
+
"sideEffects": [
|
|
1021
|
+
"无副作用(只读校验 Profile)"
|
|
1022
|
+
],
|
|
1023
|
+
"failureSemantics": [
|
|
1024
|
+
"SPE1004:带可执行扩展名的 entrypoint 在读取字节前即拒绝",
|
|
1025
|
+
"越界目标或非法差异结构报错"
|
|
1026
|
+
],
|
|
1027
|
+
"invariants": [
|
|
1028
|
+
"coreOwned = packages/commands/namespacePrefixes 为禁入目标",
|
|
1029
|
+
"entrypoint 必须为 JSON 数据资源"
|
|
1030
|
+
],
|
|
1031
|
+
"ownedByCaller": [
|
|
1032
|
+
"差异的业务语义"
|
|
1033
|
+
],
|
|
1034
|
+
"routeElsewhere": [
|
|
1035
|
+
"公共核心变更:须走 Contracts/Harness/Kit"
|
|
1036
|
+
]
|
|
1037
|
+
},
|
|
1038
|
+
{
|
|
1039
|
+
"id": "foundation.profile.public-plugin",
|
|
1040
|
+
"intent": "公开样例 Profile:以 public-plugin 声明三个 adds 差异与三个 SPI 数据资源,作为 Profile 形态的可读实例",
|
|
1041
|
+
"useWhen": [
|
|
1042
|
+
"需要参考一个符合规范的公开 Profile 实例",
|
|
1043
|
+
"需要理解 Profile descriptor 与 SPI 资源如何挂接"
|
|
1044
|
+
],
|
|
1045
|
+
"doNotUseWhen": [
|
|
1046
|
+
"需要把私有 Profile 或真实业务数据写进公开文档(禁止泄漏)"
|
|
1047
|
+
],
|
|
1048
|
+
"prerequisites": [
|
|
1049
|
+
"base.contractsVersion = 1.4.0"
|
|
1050
|
+
],
|
|
1051
|
+
"inputs": [
|
|
1052
|
+
"Profile descriptor 与各 SPI 数据资源"
|
|
1053
|
+
],
|
|
1054
|
+
"outputs": [
|
|
1055
|
+
"可被 verifyProfile 通过的公开 Profile"
|
|
1056
|
+
],
|
|
1057
|
+
"sideEffects": [
|
|
1058
|
+
"无副作用(声明数据)"
|
|
1059
|
+
],
|
|
1060
|
+
"failureSemantics": [
|
|
1061
|
+
"descriptor 不符合 schema 时报错"
|
|
1062
|
+
],
|
|
1063
|
+
"invariants": [
|
|
1064
|
+
"仅使用公开或完全虚构样例"
|
|
1065
|
+
],
|
|
1066
|
+
"ownedByCaller": [
|
|
1067
|
+
"Profile 业务含义"
|
|
1068
|
+
],
|
|
1069
|
+
"routeElsewhere": [
|
|
1070
|
+
"私有 Profile:不进入公开文档"
|
|
1071
|
+
]
|
|
1072
|
+
},
|
|
1073
|
+
{
|
|
1074
|
+
"id": "foundation.profile.licensing",
|
|
1075
|
+
"intent": "声明授权数据权威(registry + schema),由 Kit licensing 入口经契约校验器执行,默认取第一变体",
|
|
1076
|
+
"useWhen": [
|
|
1077
|
+
"需要定义授权数据变体",
|
|
1078
|
+
"需要为 Kit licensing 提供数据权威"
|
|
1079
|
+
],
|
|
1080
|
+
"doNotUseWhen": [
|
|
1081
|
+
"需要执行业务授权决策(语义由调用方)"
|
|
1082
|
+
],
|
|
1083
|
+
"prerequisites": [
|
|
1084
|
+
"registry.json + schema.json 存在"
|
|
1085
|
+
],
|
|
1086
|
+
"inputs": [
|
|
1087
|
+
"授权变体声明"
|
|
1088
|
+
],
|
|
1089
|
+
"outputs": [
|
|
1090
|
+
"供 Kit 加载的授权数据"
|
|
1091
|
+
],
|
|
1092
|
+
"sideEffects": [
|
|
1093
|
+
"无副作用(声明数据)"
|
|
1094
|
+
],
|
|
1095
|
+
"failureSemantics": [
|
|
1096
|
+
"多变体未指定则加载失败"
|
|
1097
|
+
],
|
|
1098
|
+
"invariants": [
|
|
1099
|
+
"所有商业载荷当前关闭"
|
|
1100
|
+
],
|
|
1101
|
+
"ownedByCaller": [
|
|
1102
|
+
"授权业务语义"
|
|
1103
|
+
],
|
|
1104
|
+
"routeElsewhere": [
|
|
1105
|
+
"授权执行:调用方"
|
|
1106
|
+
]
|
|
1107
|
+
},
|
|
1108
|
+
{
|
|
1109
|
+
"id": "foundation.profile.hosts",
|
|
1110
|
+
"intent": "登记宿主差异声明(claude/codex 支持、qoder 不支持),为 Kit host 子动作提供 descriptor 与 registry",
|
|
1111
|
+
"useWhen": [
|
|
1112
|
+
"需要登记受支持宿主(claude/codex)的差异",
|
|
1113
|
+
"需要为宿主接入提供声明数据"
|
|
1114
|
+
],
|
|
1115
|
+
"doNotUseWhen": [
|
|
1116
|
+
"需要登记 Qoder 完整 driver(该宿主 unsupported)"
|
|
1117
|
+
],
|
|
1118
|
+
"prerequisites": [
|
|
1119
|
+
"宿主 descriptor 绑定受信 driverId"
|
|
1120
|
+
],
|
|
1121
|
+
"inputs": [
|
|
1122
|
+
"宿主标识、descriptor 字段"
|
|
1123
|
+
],
|
|
1124
|
+
"outputs": [
|
|
1125
|
+
"宿主 registry 与 descriptor"
|
|
1126
|
+
],
|
|
1127
|
+
"sideEffects": [
|
|
1128
|
+
"无副作用(声明数据)"
|
|
1129
|
+
],
|
|
1130
|
+
"failureSemantics": [
|
|
1131
|
+
"qoder 标记 unsupported,引用即拒绝"
|
|
1132
|
+
],
|
|
1133
|
+
"invariants": [
|
|
1134
|
+
"claude/codex support=supported 且绑定 driverId;qoder support=unsupported"
|
|
1135
|
+
],
|
|
1136
|
+
"ownedByCaller": [
|
|
1137
|
+
"宿主业务语义"
|
|
1138
|
+
],
|
|
1139
|
+
"routeElsewhere": [
|
|
1140
|
+
"Qoder 完整 driver:unsupported"
|
|
1141
|
+
]
|
|
1142
|
+
},
|
|
1143
|
+
{
|
|
1144
|
+
"id": "foundation.unsupported.host-apply",
|
|
1145
|
+
"intent": "宿主 apply(应用接入变更到宿主运行环境)在只读 Phase D 切片中稳定拒绝,不实现",
|
|
1146
|
+
"useWhen": [],
|
|
1147
|
+
"doNotUseWhen": [
|
|
1148
|
+
"任何需要真正改变宿主运行环境的场景(当前不可用)"
|
|
1149
|
+
],
|
|
1150
|
+
"prerequisites": [
|
|
1151
|
+
"无"
|
|
1152
|
+
],
|
|
1153
|
+
"inputs": [
|
|
1154
|
+
"无"
|
|
1155
|
+
],
|
|
1156
|
+
"outputs": [
|
|
1157
|
+
"抛错:host apply is not implemented in the read-only Phase D slice"
|
|
1158
|
+
],
|
|
1159
|
+
"sideEffects": [
|
|
1160
|
+
"无"
|
|
1161
|
+
],
|
|
1162
|
+
"failureSemantics": [
|
|
1163
|
+
"调用即抛错,CLI 层 host-apply 子动作同样拒绝"
|
|
1164
|
+
],
|
|
1165
|
+
"invariants": [
|
|
1166
|
+
"apply 稳定拒绝,不进入 0.2.x 实现范围"
|
|
1167
|
+
],
|
|
1168
|
+
"ownedByCaller": [
|
|
1169
|
+
"宿主接入的最终落地"
|
|
1170
|
+
],
|
|
1171
|
+
"routeElsewhere": [
|
|
1172
|
+
"宿主应用逻辑:调用方或后续版本"
|
|
1173
|
+
]
|
|
1174
|
+
},
|
|
1175
|
+
{
|
|
1176
|
+
"id": "foundation.unsupported.host-install-update-uninstall",
|
|
1177
|
+
"intent": "宿主 install/update/uninstall 均未实现,不在 Foundation 0.2.x 范围",
|
|
1178
|
+
"useWhen": [],
|
|
1179
|
+
"doNotUseWhen": [
|
|
1180
|
+
"任何需要安装/更新/卸载宿主组件的场景"
|
|
1181
|
+
],
|
|
1182
|
+
"prerequisites": [
|
|
1183
|
+
"无"
|
|
1184
|
+
],
|
|
1185
|
+
"inputs": [
|
|
1186
|
+
"无"
|
|
1187
|
+
],
|
|
1188
|
+
"outputs": [
|
|
1189
|
+
"无(未实现)"
|
|
1190
|
+
],
|
|
1191
|
+
"sideEffects": [
|
|
1192
|
+
"无"
|
|
1193
|
+
],
|
|
1194
|
+
"failureSemantics": [
|
|
1195
|
+
"不存在对应入口,调用应转向外部工具"
|
|
1196
|
+
],
|
|
1197
|
+
"invariants": [
|
|
1198
|
+
"安装/卸载/更新均未实现"
|
|
1199
|
+
],
|
|
1200
|
+
"ownedByCaller": [
|
|
1201
|
+
"宿主生命周期管理"
|
|
1202
|
+
],
|
|
1203
|
+
"routeElsewhere": [
|
|
1204
|
+
"宿主生命周期:外部工具或后续版本"
|
|
1205
|
+
]
|
|
1206
|
+
},
|
|
1207
|
+
{
|
|
1208
|
+
"id": "foundation.unsupported.qoder-driver",
|
|
1209
|
+
"intent": "Qoder 宿主的完整 driver 未冻结(No auditable non-interactive host driver is frozen),标记为 unsupported,仅参考其结构",
|
|
1210
|
+
"useWhen": [],
|
|
1211
|
+
"doNotUseWhen": [
|
|
1212
|
+
"任何需要在 Qoder 实际运行的场景"
|
|
1213
|
+
],
|
|
1214
|
+
"prerequisites": [
|
|
1215
|
+
"无"
|
|
1216
|
+
],
|
|
1217
|
+
"inputs": [
|
|
1218
|
+
"无"
|
|
1219
|
+
],
|
|
1220
|
+
"outputs": [
|
|
1221
|
+
"无(unsupported)"
|
|
1222
|
+
],
|
|
1223
|
+
"sideEffects": [
|
|
1224
|
+
"无"
|
|
1225
|
+
],
|
|
1226
|
+
"failureSemantics": [
|
|
1227
|
+
"引用 qoder driver 即报错"
|
|
1228
|
+
],
|
|
1229
|
+
"invariants": [
|
|
1230
|
+
"HOST_DRIVER_IDS 仅 claude-version-v1 / codex-version-v1"
|
|
1231
|
+
],
|
|
1232
|
+
"ownedByCaller": [
|
|
1233
|
+
"Qoder 接入"
|
|
1234
|
+
],
|
|
1235
|
+
"routeElsewhere": [
|
|
1236
|
+
"Qoder 支持:后续版本或外部"
|
|
1237
|
+
]
|
|
1238
|
+
},
|
|
1239
|
+
{
|
|
1240
|
+
"id": "foundation.unsupported.binary-adapter-source",
|
|
1241
|
+
"intent": "adapter source 的 content 仅支持 string(utf8 文本闭包),二进制投影不在范围",
|
|
1242
|
+
"useWhen": [],
|
|
1243
|
+
"doNotUseWhen": [
|
|
1244
|
+
"需要把二进制资源纳入 adapter 投影"
|
|
1245
|
+
],
|
|
1246
|
+
"prerequisites": [
|
|
1247
|
+
"无"
|
|
1248
|
+
],
|
|
1249
|
+
"inputs": [
|
|
1250
|
+
"无"
|
|
1251
|
+
],
|
|
1252
|
+
"outputs": [
|
|
1253
|
+
"无(明确不支持二进制)"
|
|
1254
|
+
],
|
|
1255
|
+
"sideEffects": [
|
|
1256
|
+
"无"
|
|
1257
|
+
],
|
|
1258
|
+
"failureSemantics": [
|
|
1259
|
+
"非 string content 校验失败"
|
|
1260
|
+
],
|
|
1261
|
+
"invariants": [
|
|
1262
|
+
"adapter source content 类型固定为 string,仅 utf8"
|
|
1263
|
+
],
|
|
1264
|
+
"ownedByCaller": [
|
|
1265
|
+
"二进制资源处理"
|
|
1266
|
+
],
|
|
1267
|
+
"routeElsewhere": [
|
|
1268
|
+
"二进制处理:外部工具"
|
|
1269
|
+
]
|
|
1270
|
+
},
|
|
1271
|
+
{
|
|
1272
|
+
"id": "foundation.unsupported.remote-publish",
|
|
1273
|
+
"intent": "远端发布与全部远端写入归 release-skill,Foundation 不拥有",
|
|
1274
|
+
"useWhen": [],
|
|
1275
|
+
"doNotUseWhen": [
|
|
1276
|
+
"任何需要发布到 npm/GitHub/Registry 或远端写入的场景"
|
|
1277
|
+
],
|
|
1278
|
+
"prerequisites": [
|
|
1279
|
+
"无"
|
|
1280
|
+
],
|
|
1281
|
+
"inputs": [
|
|
1282
|
+
"无"
|
|
1283
|
+
],
|
|
1284
|
+
"outputs": [
|
|
1285
|
+
"无(转 release-skill)"
|
|
1286
|
+
],
|
|
1287
|
+
"sideEffects": [
|
|
1288
|
+
"无"
|
|
1289
|
+
],
|
|
1290
|
+
"failureSemantics": [
|
|
1291
|
+
"Foundation 不提供任何远端写入入口"
|
|
1292
|
+
],
|
|
1293
|
+
"invariants": [
|
|
1294
|
+
"contracts doesNotOwn remote writes;harness HARNESS_EXCLUSIONS 含 remote-network-access;kit FORBIDDEN_SIDE_EFFECTS 含 publish/remote-write"
|
|
1295
|
+
],
|
|
1296
|
+
"ownedByCaller": [
|
|
1297
|
+
"发布流程"
|
|
1298
|
+
],
|
|
1299
|
+
"routeElsewhere": [
|
|
1300
|
+
"发布:release-skill"
|
|
1301
|
+
]
|
|
1302
|
+
},
|
|
1303
|
+
{
|
|
1304
|
+
"id": "foundation.unsupported.business-state-machine",
|
|
1305
|
+
"intent": "业务状态机、任务节点、重试、终态、记忆等语义不纳入 Foundation,state-store 只提供底座",
|
|
1306
|
+
"useWhen": [],
|
|
1307
|
+
"doNotUseWhen": [
|
|
1308
|
+
"任何需要在 Foundation 定义 workflow 状态机或业务终态的场景"
|
|
1309
|
+
],
|
|
1310
|
+
"prerequisites": [
|
|
1311
|
+
"无"
|
|
1312
|
+
],
|
|
1313
|
+
"inputs": [
|
|
1314
|
+
"无"
|
|
1315
|
+
],
|
|
1316
|
+
"outputs": [
|
|
1317
|
+
"无(转 loop-agent)"
|
|
1318
|
+
],
|
|
1319
|
+
"sideEffects": [
|
|
1320
|
+
"无"
|
|
1321
|
+
],
|
|
1322
|
+
"failureSemantics": [
|
|
1323
|
+
"不应在 Foundation 内实现业务状态转移"
|
|
1324
|
+
],
|
|
1325
|
+
"invariants": [
|
|
1326
|
+
"Event meaning and reducer transitions remain consumer-owned"
|
|
1327
|
+
],
|
|
1328
|
+
"ownedByCaller": [
|
|
1329
|
+
"业务状态机语义"
|
|
1330
|
+
],
|
|
1331
|
+
"routeElsewhere": [
|
|
1332
|
+
"任务/重试/返工/验收:loop-agent"
|
|
1333
|
+
]
|
|
1334
|
+
},
|
|
1335
|
+
{
|
|
1336
|
+
"id": "foundation.unsupported.model-orchestration",
|
|
1337
|
+
"intent": "模型编排与工作流编排不在 Foundation 范围,仅提供业务中立机制",
|
|
1338
|
+
"useWhen": [],
|
|
1339
|
+
"doNotUseWhen": [
|
|
1340
|
+
"任何需要模型调用或工作流编排的场景"
|
|
1341
|
+
],
|
|
1342
|
+
"prerequisites": [
|
|
1343
|
+
"无"
|
|
1344
|
+
],
|
|
1345
|
+
"inputs": [
|
|
1346
|
+
"无"
|
|
1347
|
+
],
|
|
1348
|
+
"outputs": [
|
|
1349
|
+
"无(转相应编排层)"
|
|
1350
|
+
],
|
|
1351
|
+
"sideEffects": [
|
|
1352
|
+
"无"
|
|
1353
|
+
],
|
|
1354
|
+
"failureSemantics": [
|
|
1355
|
+
"Foundation 不含模型调用或工作流引擎"
|
|
1356
|
+
],
|
|
1357
|
+
"invariants": [
|
|
1358
|
+
"harness HARNESS_EXCLUSIONS 含 workflow-orchestration / model-calls;contracts doesNotOwn generation"
|
|
1359
|
+
],
|
|
1360
|
+
"ownedByCaller": [
|
|
1361
|
+
"编排语义"
|
|
1362
|
+
],
|
|
1363
|
+
"routeElsewhere": [
|
|
1364
|
+
"编排:相应消费者或编排层"
|
|
1365
|
+
]
|
|
1366
|
+
},
|
|
1367
|
+
{
|
|
1368
|
+
"id": "foundation.unsupported.domain-audit-semantics",
|
|
1369
|
+
"intent": "领域审计语义与最终接受/拒绝结论属外部独立审阅,Foundation 只提供审计表面(canonical + digest)",
|
|
1370
|
+
"useWhen": [],
|
|
1371
|
+
"doNotUseWhen": [
|
|
1372
|
+
"任何需要 Foundation 拥有领域审计 oracle 或语义结论的场景"
|
|
1373
|
+
],
|
|
1374
|
+
"prerequisites": [
|
|
1375
|
+
"无"
|
|
1376
|
+
],
|
|
1377
|
+
"inputs": [
|
|
1378
|
+
"无"
|
|
1379
|
+
],
|
|
1380
|
+
"outputs": [
|
|
1381
|
+
"无(转独立审计消费者)"
|
|
1382
|
+
],
|
|
1383
|
+
"sideEffects": [
|
|
1384
|
+
"无"
|
|
1385
|
+
],
|
|
1386
|
+
"failureSemantics": [
|
|
1387
|
+
"Foundation 不承载领域审计语义"
|
|
1388
|
+
],
|
|
1389
|
+
"invariants": [
|
|
1390
|
+
"audit-surface 仅做确定性序列化,不含语义"
|
|
1391
|
+
],
|
|
1392
|
+
"ownedByCaller": [
|
|
1393
|
+
"审计语义结论"
|
|
1394
|
+
],
|
|
1395
|
+
"routeElsewhere": [
|
|
1396
|
+
"领域审计:独立审计消费者"
|
|
1397
|
+
]
|
|
1398
|
+
},
|
|
1399
|
+
{
|
|
1400
|
+
"id": "foundation.unsupported.git-writes",
|
|
1401
|
+
"intent": "Git 写操作(stage/commit/push/tag/release)不在 Foundation 范围,仅提供只读探测",
|
|
1402
|
+
"useWhen": [],
|
|
1403
|
+
"doNotUseWhen": [
|
|
1404
|
+
"任何需要 Foundation 执行 Git 写操作的场景"
|
|
1405
|
+
],
|
|
1406
|
+
"prerequisites": [
|
|
1407
|
+
"无"
|
|
1408
|
+
],
|
|
1409
|
+
"inputs": [
|
|
1410
|
+
"无"
|
|
1411
|
+
],
|
|
1412
|
+
"outputs": [
|
|
1413
|
+
"无(转 Git 生命周期指南授权流程)"
|
|
1414
|
+
],
|
|
1415
|
+
"sideEffects": [
|
|
1416
|
+
"无"
|
|
1417
|
+
],
|
|
1418
|
+
"failureSemantics": [
|
|
1419
|
+
"Foundation 不提供 Git 写入入口"
|
|
1420
|
+
],
|
|
1421
|
+
"invariants": [
|
|
1422
|
+
"harness HARNESS_EXCLUSIONS 含 git-writes;kit git-init/commit/push/tag 为禁写"
|
|
1423
|
+
],
|
|
1424
|
+
"ownedByCaller": [
|
|
1425
|
+
"Git 写操作授权"
|
|
1426
|
+
],
|
|
1427
|
+
"routeElsewhere": [
|
|
1428
|
+
"Git 写操作:Git 生命周期指南"
|
|
1429
|
+
]
|
|
1430
|
+
},
|
|
1431
|
+
{
|
|
1432
|
+
"id": "foundation.contracts.quickstart-profile-candidate",
|
|
1433
|
+
"intent": "通过 skill-family-contracts/candidate/quickstart-profile 公开候选 Quickstart Resource、Task 与 Result Schema,供锁定精确版本的接入试验使用",
|
|
1434
|
+
"useWhen": [
|
|
1435
|
+
"需要在提议进入冻结登记表前检查或校验候选 Resource、Task、Result 形状",
|
|
1436
|
+
"调用方能够锁定 skill-family-contracts 精确版本,并把 candidate 导入隔离在自身稳定 API 之外"
|
|
1437
|
+
],
|
|
1438
|
+
"doNotUseWhen": [
|
|
1439
|
+
"需要已进入登记表或兼容性已冻结的合同",
|
|
1440
|
+
"需要 Foundation 解释领域审计语义"
|
|
1441
|
+
],
|
|
1442
|
+
"prerequisites": [
|
|
1443
|
+
"安装导出 skill-family-contracts/candidate/quickstart-profile 的精确 skill-family-contracts 版本",
|
|
1444
|
+
"Node >= 22.22.2"
|
|
1445
|
+
],
|
|
1446
|
+
"inputs": [
|
|
1447
|
+
"文档种类:resource、task 或 result",
|
|
1448
|
+
"待校验的候选文档"
|
|
1449
|
+
],
|
|
1450
|
+
"outputs": [
|
|
1451
|
+
"候选 Schema 副本,或包含 valid、errors 与规范化 data 的校验结果"
|
|
1452
|
+
],
|
|
1453
|
+
"sideEffects": [
|
|
1454
|
+
"不写文件系统、Git、网络或进程状态"
|
|
1455
|
+
],
|
|
1456
|
+
"failureSemantics": [
|
|
1457
|
+
"未知文档种类抛出 TypeError",
|
|
1458
|
+
"候选文档无效时返回 valid:false 与 Ajv 发现"
|
|
1459
|
+
],
|
|
1460
|
+
"invariants": [
|
|
1461
|
+
"候选 Schema 不进入 src/registry.json,也不扩张 18 类稳定对象",
|
|
1462
|
+
"稳定性为 candidate:后续小版本可以修改或移除该子路径"
|
|
1463
|
+
],
|
|
1464
|
+
"ownedByCaller": [
|
|
1465
|
+
"method、parameters、evidence 与 domainResult 的领域含义",
|
|
1466
|
+
"是否采用或封装候选 API 的决定"
|
|
1467
|
+
],
|
|
1468
|
+
"routeElsewhere": [
|
|
1469
|
+
"冻结的生产合同:使用 skill-family-contracts 稳定包根导出",
|
|
1470
|
+
"领域审计结论:转独立审计消费者"
|
|
1471
|
+
]
|
|
1472
|
+
},
|
|
1473
|
+
{
|
|
1474
|
+
"id": "foundation.harness.quickstart-profile-candidate",
|
|
1475
|
+
"intent": "通过 skill-family-harness-node/candidate/quickstart-profile 构造并复验绑定 observation 的候选 Task/Result 交换",
|
|
1476
|
+
"useWhen": [
|
|
1477
|
+
"需要开展早期接入试验,把受收容的 observation 文件绑定到候选 Task 与终态 Result",
|
|
1478
|
+
"需要为锁定精确版本的候选交换取得结构化、不抛出的复验结果"
|
|
1479
|
+
],
|
|
1480
|
+
"doNotUseWhen": [
|
|
1481
|
+
"需要领域审计器、method 选择器、重试编排或生命周期所有者",
|
|
1482
|
+
"需要兼容性已冻结的 Quickstart API"
|
|
1483
|
+
],
|
|
1484
|
+
"prerequisites": [
|
|
1485
|
+
"安装精确匹配的 skill-family-harness-node 与 skill-family-contracts 版本",
|
|
1486
|
+
"observation 路径受 supplied root 收容"
|
|
1487
|
+
],
|
|
1488
|
+
"inputs": [
|
|
1489
|
+
"受收容根与 observation 路径",
|
|
1490
|
+
"operation 身份、method、parameters 与 run/stage/attempt correlation",
|
|
1491
|
+
"待复验的候选 Task 与 Result 文档"
|
|
1492
|
+
],
|
|
1493
|
+
"outputs": [
|
|
1494
|
+
"Observation Resource、候选 Task、终态 Result 或结构化交换复验结果"
|
|
1495
|
+
],
|
|
1496
|
+
"sideEffects": [
|
|
1497
|
+
"读取受收容的 observation 文件,以计算或复验 sha256 摘要",
|
|
1498
|
+
"不写文件,不访问 Git 或网络"
|
|
1499
|
+
],
|
|
1500
|
+
"failureSemantics": [
|
|
1501
|
+
"Profile 或绑定无效时,抛出式 API 以 SFC2004 与 details.kind=invalid-result 失败关闭",
|
|
1502
|
+
"verifyQuickstartExchange 把失败转成 {valid:false, code, message, details}"
|
|
1503
|
+
],
|
|
1504
|
+
"invariants": [
|
|
1505
|
+
"Result 必须绑定精确 Task 摘要、observation 摘要、operation 身份与 correlation 字段",
|
|
1506
|
+
"稳定性为 candidate:后续小版本可以修改或移除该子路径"
|
|
1507
|
+
],
|
|
1508
|
+
"ownedByCaller": [
|
|
1509
|
+
"审计 method 语义与 domainResult 解释",
|
|
1510
|
+
"重试、调度与生命周期决定"
|
|
1511
|
+
],
|
|
1512
|
+
"routeElsewhere": [
|
|
1513
|
+
"稳定通用机制:使用 skill-family-harness-node 包根导出",
|
|
1514
|
+
"业务编排:转调用方或相应编排层"
|
|
1515
|
+
]
|
|
1516
|
+
},
|
|
1517
|
+
{
|
|
1518
|
+
"id": "foundation.kit.quickstart-profile-candidate",
|
|
1519
|
+
"intent": "通过 skill-family-engineering-kit/candidate/quickstart-profile 构建确定、自包含的 Quickstart 投影 manifest",
|
|
1520
|
+
"useWhen": [
|
|
1521
|
+
"需要通过稳定投影授权边界,在目标中试用候选 Quickstart Schema 与 runner",
|
|
1522
|
+
"需要取得候选投影包的来源摘要、运行依赖闭包摘要与 bundle 摘要"
|
|
1523
|
+
],
|
|
1524
|
+
"doNotUseWhen": [
|
|
1525
|
+
"需要稳定 Quickstart API 或第五个 Kit 顶层命令",
|
|
1526
|
+
"需要绕过目标 manifest 授权或手写文件保护"
|
|
1527
|
+
],
|
|
1528
|
+
"prerequisites": [
|
|
1529
|
+
"安装精确匹配的三个 Foundation 包版本",
|
|
1530
|
+
"targetPrefix 是受收容的 POSIX 相对路径"
|
|
1531
|
+
],
|
|
1532
|
+
"inputs": [
|
|
1533
|
+
"可选的受收容 targetPrefix",
|
|
1534
|
+
"已安装 Contracts、Harness 与 Kit 的精确包字节"
|
|
1535
|
+
],
|
|
1536
|
+
"outputs": [
|
|
1537
|
+
"投影 manifest 与 provenance 记录,包含 source、运行依赖和 bundle 摘要"
|
|
1538
|
+
],
|
|
1539
|
+
"sideEffects": [
|
|
1540
|
+
"在内存中构建 manifest,并读取已安装包文件",
|
|
1541
|
+
"不执行写入;调用方把 manifest 交给稳定 runProjection 后才发生受权写入"
|
|
1542
|
+
],
|
|
1543
|
+
"failureSemantics": [
|
|
1544
|
+
"targetPrefix 无效时抛出 TypeError",
|
|
1545
|
+
"已安装依赖闭包缺失或不一致时拒绝构建;runProjection 另行报告稳定投影失败"
|
|
1546
|
+
],
|
|
1547
|
+
"invariants": [
|
|
1548
|
+
"辅助函数不增加 Kit 顶层命令,也不绕过 runProjection",
|
|
1549
|
+
"稳定性为 candidate:后续小版本可以修改或移除该子路径"
|
|
1550
|
+
],
|
|
1551
|
+
"ownedByCaller": [
|
|
1552
|
+
"返回 manifest 的检查与授权",
|
|
1553
|
+
"目标 file-registry 与 managed-file 声明"
|
|
1554
|
+
],
|
|
1555
|
+
"routeElsewhere": [
|
|
1556
|
+
"普通受管投影:使用 Kit 稳定包根导出的 runProjection",
|
|
1557
|
+
"远端发布:转 release-skill"
|
|
1558
|
+
]
|
|
1559
|
+
}
|
|
1560
|
+
]
|
|
1561
|
+
}
|