@agentproto/corpus-cli 0.10.2 → 0.11.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/dist/cli.mjs +164 -93
- package/dist/cli.mjs.map +1 -1
- package/dist/ports/index.d.ts +37 -1
- package/dist/ports/index.mjs +141 -74
- package/dist/ports/index.mjs.map +1 -1
- package/dist/specs/resources/aip-10/draft/KNOWLEDGE.schema.json +2 -2
- package/dist/specs/resources/aip-18/draft/COLLECTION.schema.json +9 -2
- package/dist/specs/resources/aip-19/draft/SECRETS.schema.json +8 -2
- package/dist/specs/resources/aip-20/draft/WORK.schema.json +232 -206
- package/dist/specs/resources/aip-34/draft/EXPORT.schema.json +29 -0
- package/dist/specs/resources/aip-34/draft/LOCK.schema.json +76 -0
- package/dist/specs/resources/aip-34/draft/TYPES.schema.json +78 -0
- package/dist/specs/resources/aip-34/draft/WORKSPACE.schema.json +236 -105
- package/dist/specs/resources/aip-42/draft/AGENT.schema.json +5 -0
- package/dist/specs/resources/aip-49/draft/ASSET.schema.json +10 -0
- package/dist/specs/resources/aip-53/draft/APP.schema.json +862 -43
- package/dist/specs/resources/aip-58/draft/event.schema.json +3 -2
- package/dist/specs/resources/aip-62/draft/ATTESTATION.schema.json +368 -62
- package/dist/specs/resources/aip-62/draft/REVIEW.schema.json +201 -43
- package/dist/specs/resources/aip-63/draft/BROWSER.schema.json +427 -0
- package/dist/specs/resources/aip-63/draft/RECORDING.schema.json +292 -0
- package/dist/specs/resources/aip-7/draft/GOVERNANCE.schema.json +2 -2
- package/dist/specs/resources/pending/memory/draft/MEMORY.schema.json +321 -0
- package/dist/specs/resources/pending/services/SERVICES.schema.json +35 -0
- package/package.json +7 -7
|
@@ -4,7 +4,10 @@
|
|
|
4
4
|
"title": "APP.md frontmatter — app/v1 (agent app bundle + UI surface)",
|
|
5
5
|
"description": "Validates the YAML frontmatter portion of an AIP-53 APP.md manifest — the on-disk form of an AppDefinition. Codifies shipped behaviour: `agents` may be empty for a UI-only app when `ui` is present (packages/app-kit/src/define-app.ts:49-52), and `data` / `category` are carried verbatim (packages/app-kit/src/types.ts).",
|
|
6
6
|
"type": "object",
|
|
7
|
-
"required": [
|
|
7
|
+
"required": [
|
|
8
|
+
"schema",
|
|
9
|
+
"version"
|
|
10
|
+
],
|
|
8
11
|
"additionalProperties": false,
|
|
9
12
|
"properties": {
|
|
10
13
|
"schema": {
|
|
@@ -34,11 +37,21 @@
|
|
|
34
37
|
"type": "array",
|
|
35
38
|
"items": {
|
|
36
39
|
"type": "object",
|
|
37
|
-
"required": [
|
|
40
|
+
"required": [
|
|
41
|
+
"id",
|
|
42
|
+
"path"
|
|
43
|
+
],
|
|
38
44
|
"additionalProperties": false,
|
|
39
45
|
"properties": {
|
|
40
|
-
"id": {
|
|
41
|
-
|
|
46
|
+
"id": {
|
|
47
|
+
"type": "string",
|
|
48
|
+
"minLength": 1
|
|
49
|
+
},
|
|
50
|
+
"path": {
|
|
51
|
+
"type": "string",
|
|
52
|
+
"minLength": 1,
|
|
53
|
+
"description": "Path to the AGENT.md, relative to the app dir."
|
|
54
|
+
}
|
|
42
55
|
}
|
|
43
56
|
},
|
|
44
57
|
"description": "`{ id, path }` refs, one per bundled agent. MAY be empty ONLY when `ui` is present (UI-only app) — see the allOf guard below."
|
|
@@ -47,11 +60,21 @@
|
|
|
47
60
|
"type": "array",
|
|
48
61
|
"items": {
|
|
49
62
|
"type": "object",
|
|
50
|
-
"required": [
|
|
63
|
+
"required": [
|
|
64
|
+
"id",
|
|
65
|
+
"path"
|
|
66
|
+
],
|
|
51
67
|
"additionalProperties": false,
|
|
52
68
|
"properties": {
|
|
53
|
-
"id": {
|
|
54
|
-
|
|
69
|
+
"id": {
|
|
70
|
+
"type": "string",
|
|
71
|
+
"minLength": 1
|
|
72
|
+
},
|
|
73
|
+
"path": {
|
|
74
|
+
"type": "string",
|
|
75
|
+
"minLength": 1,
|
|
76
|
+
"description": "Path to the WORKFLOW.md, relative to the app dir."
|
|
77
|
+
}
|
|
55
78
|
}
|
|
56
79
|
},
|
|
57
80
|
"description": "`{ id, path }` refs, one per bundled workflow. Every bundled workflow MUST be referenced by at least one agent's workflows[] (attachment invariant, both directions)."
|
|
@@ -62,14 +85,88 @@
|
|
|
62
85
|
"description": "Optional home workspace id (AIP-34). When set, a sibling WORKSPACE.md exists at the app dir root."
|
|
63
86
|
},
|
|
64
87
|
"requires": {
|
|
65
|
-
"
|
|
66
|
-
"
|
|
67
|
-
|
|
68
|
-
|
|
88
|
+
"description": "What the app needs from its host. Either a flat array of APP ids this app depends on (legacy form), or an object { browser?, fs?, gpu?, secrets?, apps? }. Each `apps` entry is a bare id (dependency only) or an object { id, version?, workflows? }: `version` is a semver range (exact \"1.2.3\", caret \"^1\"/\"^1.2\"/\"^1.2.3\", or tilde \"~1\"/\"~1.2\"/\"~1.2.3\") the provider's installed version must satisfy; `workflows` lists which of the provider's `exposes.workflows` this consumer may call via the app_call tool — omitted/empty means the dependency carries no call permission.",
|
|
89
|
+
"anyOf": [
|
|
90
|
+
{
|
|
91
|
+
"type": "array",
|
|
92
|
+
"items": {
|
|
93
|
+
"type": "string",
|
|
94
|
+
"minLength": 1
|
|
95
|
+
},
|
|
96
|
+
"uniqueItems": true
|
|
97
|
+
},
|
|
98
|
+
{
|
|
99
|
+
"type": "object",
|
|
100
|
+
"additionalProperties": false,
|
|
101
|
+
"properties": {
|
|
102
|
+
"browser": {
|
|
103
|
+
"type": "boolean",
|
|
104
|
+
"description": "Needs the user's real browser."
|
|
105
|
+
},
|
|
106
|
+
"fs": {
|
|
107
|
+
"type": "boolean",
|
|
108
|
+
"description": "Needs the user's local filesystem beyond app data."
|
|
109
|
+
},
|
|
110
|
+
"gpu": {
|
|
111
|
+
"type": "boolean",
|
|
112
|
+
"description": "Needs a GPU."
|
|
113
|
+
},
|
|
114
|
+
"secrets": {
|
|
115
|
+
"type": "array",
|
|
116
|
+
"items": {
|
|
117
|
+
"type": "string",
|
|
118
|
+
"minLength": 1
|
|
119
|
+
},
|
|
120
|
+
"description": "Env/secret names the app needs."
|
|
121
|
+
},
|
|
122
|
+
"apps": {
|
|
123
|
+
"type": "array",
|
|
124
|
+
"description": "Other app ids this app depends on — bare ids or { id, version?, workflows? } objects.",
|
|
125
|
+
"items": {
|
|
126
|
+
"anyOf": [
|
|
127
|
+
{
|
|
128
|
+
"type": "string",
|
|
129
|
+
"minLength": 1
|
|
130
|
+
},
|
|
131
|
+
{
|
|
132
|
+
"type": "object",
|
|
133
|
+
"required": [
|
|
134
|
+
"id"
|
|
135
|
+
],
|
|
136
|
+
"additionalProperties": false,
|
|
137
|
+
"properties": {
|
|
138
|
+
"id": {
|
|
139
|
+
"type": "string",
|
|
140
|
+
"minLength": 1,
|
|
141
|
+
"description": "The depended-on app id."
|
|
142
|
+
},
|
|
143
|
+
"version": {
|
|
144
|
+
"type": "string",
|
|
145
|
+
"minLength": 1,
|
|
146
|
+
"description": "Optional semver range the provider's installed version must satisfy: exact (\"1.2.3\"), caret (\"^1\", \"^1.2\", \"^1.2.3\"), or tilde (\"~1\", \"~1.2\", \"~1.2.3\")."
|
|
147
|
+
},
|
|
148
|
+
"workflows": {
|
|
149
|
+
"type": "array",
|
|
150
|
+
"items": {
|
|
151
|
+
"type": "string",
|
|
152
|
+
"minLength": 1
|
|
153
|
+
},
|
|
154
|
+
"description": "Provider workflows (ids from its exposes.workflows) this consumer may call via app_call. Omitted/empty = dependency only, no call permission."
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
]
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
]
|
|
69
164
|
},
|
|
70
165
|
"ui": {
|
|
71
166
|
"type": "object",
|
|
72
|
-
"required": [
|
|
167
|
+
"required": [
|
|
168
|
+
"path"
|
|
169
|
+
],
|
|
73
170
|
"additionalProperties": false,
|
|
74
171
|
"properties": {
|
|
75
172
|
"path": {
|
|
@@ -77,11 +174,18 @@
|
|
|
77
174
|
"const": ".agentproto/ui/index.html",
|
|
78
175
|
"description": "The UI surface entry point."
|
|
79
176
|
},
|
|
80
|
-
"title": {
|
|
81
|
-
|
|
177
|
+
"title": {
|
|
178
|
+
"type": "string"
|
|
179
|
+
},
|
|
180
|
+
"description": {
|
|
181
|
+
"type": "string"
|
|
182
|
+
},
|
|
82
183
|
"tools": {
|
|
83
184
|
"type": "array",
|
|
84
|
-
"items": {
|
|
185
|
+
"items": {
|
|
186
|
+
"type": "string",
|
|
187
|
+
"minLength": 1
|
|
188
|
+
},
|
|
85
189
|
"description": "The ui_tool_call / app_tool_call allowlist — every tool a UI-originated call may reach. Enforced server-side on every call."
|
|
86
190
|
},
|
|
87
191
|
"port": {
|
|
@@ -94,49 +198,99 @@
|
|
|
94
198
|
"type": "object",
|
|
95
199
|
"additionalProperties": false,
|
|
96
200
|
"properties": {
|
|
97
|
-
"connectDomains": {
|
|
98
|
-
|
|
201
|
+
"connectDomains": {
|
|
202
|
+
"type": "array",
|
|
203
|
+
"items": {
|
|
204
|
+
"type": "string"
|
|
205
|
+
}
|
|
206
|
+
},
|
|
207
|
+
"resourceDomains": {
|
|
208
|
+
"type": "array",
|
|
209
|
+
"items": {
|
|
210
|
+
"type": "string"
|
|
211
|
+
}
|
|
212
|
+
}
|
|
99
213
|
}
|
|
214
|
+
},
|
|
215
|
+
"toolScope": {
|
|
216
|
+
"type": "object",
|
|
217
|
+
"additionalProperties": {
|
|
218
|
+
"type": "object",
|
|
219
|
+
"additionalProperties": {
|
|
220
|
+
"type": "string",
|
|
221
|
+
"pattern": "^\\$link\\.[A-Za-z0-9_]+$"
|
|
222
|
+
}
|
|
223
|
+
},
|
|
224
|
+
"description": "Argument-level refinement of `tools`, keyed by tool id (which MUST also be in `tools`): argName -> \"$link.<claim>\" reference into a scoped app-link token's claims. Enforced only for calls made under a valid link/session token (AIP-53 link-token scoping); unaffected otherwise."
|
|
100
225
|
}
|
|
101
226
|
},
|
|
102
227
|
"description": "The UI surface. `html` (the full document) is required on the in-memory AppDefinition at defineApp time and is NOT carried in APP.md frontmatter — it is emitted to `ui.path`. Its non-emptiness is enforced by defineApp (conformance rule 5)."
|
|
103
228
|
},
|
|
104
229
|
"artifact": {
|
|
105
230
|
"type": "object",
|
|
106
|
-
"required": [
|
|
231
|
+
"required": [
|
|
232
|
+
"path"
|
|
233
|
+
],
|
|
107
234
|
"additionalProperties": false,
|
|
108
235
|
"properties": {
|
|
109
|
-
"path": {
|
|
110
|
-
|
|
111
|
-
|
|
236
|
+
"path": {
|
|
237
|
+
"type": "string",
|
|
238
|
+
"minLength": 1,
|
|
239
|
+
"description": "Emitted bundle path .agentproto/artifact/index.html."
|
|
240
|
+
},
|
|
241
|
+
"title": {
|
|
242
|
+
"type": "string"
|
|
243
|
+
},
|
|
244
|
+
"description": {
|
|
245
|
+
"type": "string"
|
|
246
|
+
}
|
|
112
247
|
}
|
|
113
248
|
},
|
|
114
249
|
"skill": {
|
|
115
250
|
"type": "object",
|
|
116
|
-
"required": [
|
|
251
|
+
"required": [
|
|
252
|
+
"path"
|
|
253
|
+
],
|
|
117
254
|
"additionalProperties": false,
|
|
118
255
|
"properties": {
|
|
119
|
-
"path": {
|
|
120
|
-
|
|
121
|
-
|
|
256
|
+
"path": {
|
|
257
|
+
"type": "string",
|
|
258
|
+
"minLength": 1,
|
|
259
|
+
"description": "Emitted bundle path .agentproto/skill (must contain a SKILL.md)."
|
|
260
|
+
},
|
|
261
|
+
"title": {
|
|
262
|
+
"type": "string"
|
|
263
|
+
},
|
|
264
|
+
"description": {
|
|
265
|
+
"type": "string"
|
|
266
|
+
}
|
|
122
267
|
}
|
|
123
268
|
},
|
|
124
269
|
"artifacts": {
|
|
125
270
|
"type": "array",
|
|
126
271
|
"items": {
|
|
127
272
|
"type": "object",
|
|
128
|
-
"required": [
|
|
273
|
+
"required": [
|
|
274
|
+
"type"
|
|
275
|
+
],
|
|
129
276
|
"additionalProperties": false,
|
|
130
277
|
"properties": {
|
|
131
|
-
"type": {
|
|
132
|
-
|
|
278
|
+
"type": {
|
|
279
|
+
"type": "string",
|
|
280
|
+
"minLength": 1
|
|
281
|
+
},
|
|
282
|
+
"description": {
|
|
283
|
+
"type": "string"
|
|
284
|
+
}
|
|
133
285
|
}
|
|
134
286
|
},
|
|
135
287
|
"description": "Artifact types this app's agents may produce, declared for discovery."
|
|
136
288
|
},
|
|
137
289
|
"dev": {
|
|
138
290
|
"type": "object",
|
|
139
|
-
"required": [
|
|
291
|
+
"required": [
|
|
292
|
+
"launch"
|
|
293
|
+
],
|
|
140
294
|
"additionalProperties": false,
|
|
141
295
|
"properties": {
|
|
142
296
|
"launch": {
|
|
@@ -144,20 +298,81 @@
|
|
|
144
298
|
"minItems": 1,
|
|
145
299
|
"items": {
|
|
146
300
|
"type": "object",
|
|
147
|
-
"required": [
|
|
301
|
+
"required": [
|
|
302
|
+
"name",
|
|
303
|
+
"runtimeExecutable"
|
|
304
|
+
],
|
|
148
305
|
"additionalProperties": false,
|
|
149
306
|
"properties": {
|
|
150
|
-
"name": {
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
"
|
|
307
|
+
"name": {
|
|
308
|
+
"type": "string",
|
|
309
|
+
"minLength": 1
|
|
310
|
+
},
|
|
311
|
+
"runtimeExecutable": {
|
|
312
|
+
"type": "string",
|
|
313
|
+
"minLength": 1
|
|
314
|
+
},
|
|
315
|
+
"runtimeArgs": {
|
|
316
|
+
"type": "array",
|
|
317
|
+
"items": {
|
|
318
|
+
"type": "string"
|
|
319
|
+
}
|
|
320
|
+
},
|
|
321
|
+
"port": {
|
|
322
|
+
"type": "integer",
|
|
323
|
+
"minimum": 1,
|
|
324
|
+
"maximum": 65535
|
|
325
|
+
},
|
|
326
|
+
"url": {
|
|
327
|
+
"type": "string"
|
|
328
|
+
}
|
|
155
329
|
}
|
|
156
|
-
}
|
|
330
|
+
},
|
|
331
|
+
"description": "Dev-only launch recipes. Carried verbatim; NEVER executed by app-kit — `defineApp` validates the shape only (packages/app-kit/src/define-app.ts:62-64) and no loader/emit path runs it. The production hosting surface is `services` (below), not this."
|
|
157
332
|
}
|
|
158
333
|
},
|
|
159
334
|
"description": "Dev-launch configuration, carried verbatim in frontmatter."
|
|
160
335
|
},
|
|
336
|
+
"services": {
|
|
337
|
+
"type": "array",
|
|
338
|
+
"minItems": 1,
|
|
339
|
+
"uniqueItems": true,
|
|
340
|
+
"items": {
|
|
341
|
+
"type": "object",
|
|
342
|
+
"required": [
|
|
343
|
+
"name",
|
|
344
|
+
"entry"
|
|
345
|
+
],
|
|
346
|
+
"additionalProperties": false,
|
|
347
|
+
"properties": {
|
|
348
|
+
"name": {
|
|
349
|
+
"type": "string",
|
|
350
|
+
"pattern": "^[a-z][a-z0-9-]*$",
|
|
351
|
+
"description": "Service identifier — kebab-case slug, unique across the array."
|
|
352
|
+
},
|
|
353
|
+
"entry": {
|
|
354
|
+
"type": "string",
|
|
355
|
+
"minLength": 1,
|
|
356
|
+
"description": "Non-empty shell command line that starts the service (e.g. `pnpm --filter x start`, `node dist/server.js`). Carried verbatim; the loader/`defineApp` never executes it."
|
|
357
|
+
},
|
|
358
|
+
"port": {
|
|
359
|
+
"type": "integer",
|
|
360
|
+
"minimum": 1,
|
|
361
|
+
"maximum": 65535,
|
|
362
|
+
"description": "Optional TCP port the service listens on. Omitted = a service that does not listen. One process per entry, one port."
|
|
363
|
+
}
|
|
364
|
+
}
|
|
365
|
+
},
|
|
366
|
+
"description": "Production hosting surface: one supervised service process per entry — NO dependency graph, NO scaling, NO scheduler. The host (NOT app-kit) spawns exactly one keep-alive service-owner session per entry at install time (later work item) that runs `entry`; `dev.launch` is NOT executed by the loader and is not this surface. Names MUST be unique. See the pending SERVICES schema draft (pending upstream spec PR)."
|
|
367
|
+
},
|
|
368
|
+
"setup": {
|
|
369
|
+
"type": "array",
|
|
370
|
+
"minItems": 1,
|
|
371
|
+
"items": {
|
|
372
|
+
"$ref": "#/$defs/setupStep"
|
|
373
|
+
},
|
|
374
|
+
"description": "OPTIONAL ordered, idempotent post-install configuration pipeline (modelled on the AIP-29 `setup` block). Step ids MUST be unique; `when.step` MUST reference an earlier id. Root `additionalProperties` stays false: this property is added explicitly and only `x-*` vendor steps are open. See AIP-53 § Setup steps."
|
|
375
|
+
},
|
|
161
376
|
"data": {
|
|
162
377
|
"type": "object",
|
|
163
378
|
"additionalProperties": false,
|
|
@@ -172,7 +387,10 @@
|
|
|
172
387
|
},
|
|
173
388
|
"externalReadRoots": {
|
|
174
389
|
"type": "array",
|
|
175
|
-
"items": {
|
|
390
|
+
"items": {
|
|
391
|
+
"type": "string",
|
|
392
|
+
"minLength": 1
|
|
393
|
+
},
|
|
176
394
|
"uniqueItems": true,
|
|
177
395
|
"description": "Host directories the app is granted READ-ONLY access to outside its sandboxed dir (absolute or ~-relative). Carried verbatim in frontmatter by emit/load; validated to exist at install time. Read-only everywhere — there is no write/delete path for these roots."
|
|
178
396
|
},
|
|
@@ -180,6 +398,575 @@
|
|
|
180
398
|
"type": "string",
|
|
181
399
|
"minLength": 1,
|
|
182
400
|
"description": "Coarse grouping surfaced in host catalogs/trees (e.g. `book`). Freeform — not validated against a fixed enum."
|
|
401
|
+
},
|
|
402
|
+
"exposes": {
|
|
403
|
+
"type": "object",
|
|
404
|
+
"additionalProperties": false,
|
|
405
|
+
"properties": {
|
|
406
|
+
"agents": {
|
|
407
|
+
"type": "array",
|
|
408
|
+
"items": {
|
|
409
|
+
"type": "string",
|
|
410
|
+
"minLength": 1
|
|
411
|
+
},
|
|
412
|
+
"description": "Agent ids this app exposes. Every id must name one of the app's own agents."
|
|
413
|
+
},
|
|
414
|
+
"workflows": {
|
|
415
|
+
"type": "array",
|
|
416
|
+
"items": {
|
|
417
|
+
"type": "string",
|
|
418
|
+
"minLength": 1
|
|
419
|
+
},
|
|
420
|
+
"description": "Workflow ids this app exposes — the callable surface other apps' requires.apps[].workflows entries may name (consumed via the app_call tool). Every id must name one of the app's own workflows."
|
|
421
|
+
}
|
|
422
|
+
},
|
|
423
|
+
"description": "A2A-visible agents/workflows. Ids must exist in the app's agents / workflows."
|
|
424
|
+
}
|
|
425
|
+
},
|
|
426
|
+
"$defs": {
|
|
427
|
+
"stepId": {
|
|
428
|
+
"type": "string",
|
|
429
|
+
"pattern": "^[a-z][a-z0-9-]*$",
|
|
430
|
+
"description": "Stable step identifier, kebab-case, unique across `setup[]`. Appears in the ledger, audit logs and `--only`."
|
|
431
|
+
},
|
|
432
|
+
"skipIf": {
|
|
433
|
+
"type": "object",
|
|
434
|
+
"required": [
|
|
435
|
+
"cmd"
|
|
436
|
+
],
|
|
437
|
+
"additionalProperties": false,
|
|
438
|
+
"properties": {
|
|
439
|
+
"cmd": {
|
|
440
|
+
"type": "string",
|
|
441
|
+
"minLength": 1
|
|
442
|
+
},
|
|
443
|
+
"exit_code": {
|
|
444
|
+
"type": "integer",
|
|
445
|
+
"default": 0
|
|
446
|
+
}
|
|
447
|
+
},
|
|
448
|
+
"description": "AIP-29 `skip_if`: when `cmd` exits with `exit_code` (default 0) the step is skipped and ledgered as `skippedViaSkipIf`."
|
|
449
|
+
},
|
|
450
|
+
"when": {
|
|
451
|
+
"type": "object",
|
|
452
|
+
"required": [
|
|
453
|
+
"step"
|
|
454
|
+
],
|
|
455
|
+
"additionalProperties": false,
|
|
456
|
+
"properties": {
|
|
457
|
+
"step": {
|
|
458
|
+
"type": "string",
|
|
459
|
+
"description": "Id of an EARLIER step."
|
|
460
|
+
},
|
|
461
|
+
"equals": {
|
|
462
|
+
"description": "Run only when that step's recorded answer equals this value."
|
|
463
|
+
},
|
|
464
|
+
"done": {
|
|
465
|
+
"type": "boolean",
|
|
466
|
+
"description": "Run only when that step is (true) / is not (false) complete."
|
|
467
|
+
}
|
|
468
|
+
},
|
|
469
|
+
"oneOf": [
|
|
470
|
+
{
|
|
471
|
+
"required": [
|
|
472
|
+
"equals"
|
|
473
|
+
]
|
|
474
|
+
},
|
|
475
|
+
{
|
|
476
|
+
"required": [
|
|
477
|
+
"done"
|
|
478
|
+
]
|
|
479
|
+
}
|
|
480
|
+
],
|
|
481
|
+
"description": "Run the step only if the condition on an earlier step holds. Exactly one of `equals` / `done`."
|
|
482
|
+
},
|
|
483
|
+
"persist": {
|
|
484
|
+
"type": "object",
|
|
485
|
+
"additionalProperties": false,
|
|
486
|
+
"minProperties": 1,
|
|
487
|
+
"maxProperties": 1,
|
|
488
|
+
"properties": {
|
|
489
|
+
"env": {
|
|
490
|
+
"type": "string",
|
|
491
|
+
"pattern": "^[A-Z_][A-Z0-9_]*$"
|
|
492
|
+
},
|
|
493
|
+
"secret_slug": {
|
|
494
|
+
"type": "string",
|
|
495
|
+
"minLength": 1
|
|
496
|
+
},
|
|
497
|
+
"cmd": {
|
|
498
|
+
"type": "string",
|
|
499
|
+
"minLength": 1,
|
|
500
|
+
"description": "Run with `${value}` substituted (shell-escaped)."
|
|
501
|
+
},
|
|
502
|
+
"answer": {
|
|
503
|
+
"type": "string",
|
|
504
|
+
"minLength": 1,
|
|
505
|
+
"description": "Dotted key under which the NON-SECRET value is recorded in the setup record's `answers`. MUST NOT be used for `type: secret`."
|
|
506
|
+
}
|
|
507
|
+
},
|
|
508
|
+
"description": "Where the captured value lands. Exactly one slot."
|
|
509
|
+
},
|
|
510
|
+
"option": {
|
|
511
|
+
"type": "object",
|
|
512
|
+
"required": [
|
|
513
|
+
"value",
|
|
514
|
+
"label"
|
|
515
|
+
],
|
|
516
|
+
"additionalProperties": false,
|
|
517
|
+
"properties": {
|
|
518
|
+
"value": {
|
|
519
|
+
"type": "string",
|
|
520
|
+
"minLength": 1
|
|
521
|
+
},
|
|
522
|
+
"label": {
|
|
523
|
+
"type": "string",
|
|
524
|
+
"minLength": 1
|
|
525
|
+
},
|
|
526
|
+
"description": {
|
|
527
|
+
"type": "string"
|
|
528
|
+
}
|
|
529
|
+
}
|
|
530
|
+
},
|
|
531
|
+
"setupStep": {
|
|
532
|
+
"oneOf": [
|
|
533
|
+
{
|
|
534
|
+
"title": "cmd step",
|
|
535
|
+
"type": "object",
|
|
536
|
+
"required": [
|
|
537
|
+
"id",
|
|
538
|
+
"kind",
|
|
539
|
+
"cmd"
|
|
540
|
+
],
|
|
541
|
+
"additionalProperties": false,
|
|
542
|
+
"properties": {
|
|
543
|
+
"id": {
|
|
544
|
+
"$ref": "#/$defs/stepId"
|
|
545
|
+
},
|
|
546
|
+
"kind": {
|
|
547
|
+
"const": "cmd"
|
|
548
|
+
},
|
|
549
|
+
"title": {
|
|
550
|
+
"type": "string",
|
|
551
|
+
"minLength": 1
|
|
552
|
+
},
|
|
553
|
+
"description": {
|
|
554
|
+
"type": "string"
|
|
555
|
+
},
|
|
556
|
+
"optional": {
|
|
557
|
+
"type": "boolean",
|
|
558
|
+
"default": false,
|
|
559
|
+
"description": "An optional step may be declined or left pending without blocking `ready`."
|
|
560
|
+
},
|
|
561
|
+
"when": {
|
|
562
|
+
"$ref": "#/$defs/when"
|
|
563
|
+
},
|
|
564
|
+
"cmd": {
|
|
565
|
+
"type": "string",
|
|
566
|
+
"minLength": 1
|
|
567
|
+
},
|
|
568
|
+
"skip_if": {
|
|
569
|
+
"$ref": "#/$defs/skipIf"
|
|
570
|
+
},
|
|
571
|
+
"persist": {
|
|
572
|
+
"$ref": "#/$defs/persist"
|
|
573
|
+
}
|
|
574
|
+
}
|
|
575
|
+
},
|
|
576
|
+
{
|
|
577
|
+
"title": "prompt step",
|
|
578
|
+
"type": "object",
|
|
579
|
+
"required": [
|
|
580
|
+
"id",
|
|
581
|
+
"kind",
|
|
582
|
+
"prompt"
|
|
583
|
+
],
|
|
584
|
+
"additionalProperties": false,
|
|
585
|
+
"properties": {
|
|
586
|
+
"id": {
|
|
587
|
+
"$ref": "#/$defs/stepId"
|
|
588
|
+
},
|
|
589
|
+
"kind": {
|
|
590
|
+
"const": "prompt"
|
|
591
|
+
},
|
|
592
|
+
"title": {
|
|
593
|
+
"type": "string",
|
|
594
|
+
"minLength": 1
|
|
595
|
+
},
|
|
596
|
+
"description": {
|
|
597
|
+
"type": "string"
|
|
598
|
+
},
|
|
599
|
+
"optional": {
|
|
600
|
+
"type": "boolean",
|
|
601
|
+
"default": false,
|
|
602
|
+
"description": "An optional step may be declined or left pending without blocking `ready`."
|
|
603
|
+
},
|
|
604
|
+
"when": {
|
|
605
|
+
"$ref": "#/$defs/when"
|
|
606
|
+
},
|
|
607
|
+
"type": {
|
|
608
|
+
"enum": [
|
|
609
|
+
"text",
|
|
610
|
+
"select",
|
|
611
|
+
"boolean",
|
|
612
|
+
"secret"
|
|
613
|
+
],
|
|
614
|
+
"default": "text"
|
|
615
|
+
},
|
|
616
|
+
"prompt": {
|
|
617
|
+
"type": "string",
|
|
618
|
+
"minLength": 1
|
|
619
|
+
},
|
|
620
|
+
"default": {},
|
|
621
|
+
"options": {
|
|
622
|
+
"type": "array",
|
|
623
|
+
"items": {
|
|
624
|
+
"$ref": "#/$defs/option"
|
|
625
|
+
}
|
|
626
|
+
},
|
|
627
|
+
"skip_if": {
|
|
628
|
+
"$ref": "#/$defs/skipIf"
|
|
629
|
+
},
|
|
630
|
+
"persist": {
|
|
631
|
+
"$ref": "#/$defs/persist"
|
|
632
|
+
}
|
|
633
|
+
}
|
|
634
|
+
},
|
|
635
|
+
{
|
|
636
|
+
"title": "choice step",
|
|
637
|
+
"type": "object",
|
|
638
|
+
"required": [
|
|
639
|
+
"id",
|
|
640
|
+
"kind",
|
|
641
|
+
"prompt",
|
|
642
|
+
"options",
|
|
643
|
+
"default"
|
|
644
|
+
],
|
|
645
|
+
"additionalProperties": false,
|
|
646
|
+
"properties": {
|
|
647
|
+
"id": {
|
|
648
|
+
"$ref": "#/$defs/stepId"
|
|
649
|
+
},
|
|
650
|
+
"kind": {
|
|
651
|
+
"const": "choice"
|
|
652
|
+
},
|
|
653
|
+
"title": {
|
|
654
|
+
"type": "string",
|
|
655
|
+
"minLength": 1
|
|
656
|
+
},
|
|
657
|
+
"description": {
|
|
658
|
+
"type": "string"
|
|
659
|
+
},
|
|
660
|
+
"optional": {
|
|
661
|
+
"type": "boolean",
|
|
662
|
+
"default": false,
|
|
663
|
+
"description": "An optional step may be declined or left pending without blocking `ready`."
|
|
664
|
+
},
|
|
665
|
+
"when": {
|
|
666
|
+
"$ref": "#/$defs/when"
|
|
667
|
+
},
|
|
668
|
+
"prompt": {
|
|
669
|
+
"type": "string",
|
|
670
|
+
"minLength": 1
|
|
671
|
+
},
|
|
672
|
+
"options": {
|
|
673
|
+
"type": "array",
|
|
674
|
+
"minItems": 2,
|
|
675
|
+
"items": {
|
|
676
|
+
"$ref": "#/$defs/option"
|
|
677
|
+
}
|
|
678
|
+
},
|
|
679
|
+
"default": {
|
|
680
|
+
"type": "string",
|
|
681
|
+
"description": "The `value` of one option. Pre-selected, and applied by `--yes`."
|
|
682
|
+
},
|
|
683
|
+
"persist": {
|
|
684
|
+
"$ref": "#/$defs/persist"
|
|
685
|
+
}
|
|
686
|
+
}
|
|
687
|
+
},
|
|
688
|
+
{
|
|
689
|
+
"title": "auth-profile step",
|
|
690
|
+
"type": "object",
|
|
691
|
+
"required": [
|
|
692
|
+
"id",
|
|
693
|
+
"kind"
|
|
694
|
+
],
|
|
695
|
+
"additionalProperties": false,
|
|
696
|
+
"properties": {
|
|
697
|
+
"id": {
|
|
698
|
+
"$ref": "#/$defs/stepId"
|
|
699
|
+
},
|
|
700
|
+
"kind": {
|
|
701
|
+
"const": "auth-profile"
|
|
702
|
+
},
|
|
703
|
+
"title": {
|
|
704
|
+
"type": "string",
|
|
705
|
+
"minLength": 1
|
|
706
|
+
},
|
|
707
|
+
"description": {
|
|
708
|
+
"type": "string"
|
|
709
|
+
},
|
|
710
|
+
"optional": {
|
|
711
|
+
"type": "boolean",
|
|
712
|
+
"default": false,
|
|
713
|
+
"description": "An optional step may be declined or left pending without blocking `ready`."
|
|
714
|
+
},
|
|
715
|
+
"when": {
|
|
716
|
+
"$ref": "#/$defs/when"
|
|
717
|
+
},
|
|
718
|
+
"min": {
|
|
719
|
+
"type": "integer",
|
|
720
|
+
"minimum": 1,
|
|
721
|
+
"default": 1,
|
|
722
|
+
"description": "Complete when at least this many enabled auth profiles exist."
|
|
723
|
+
},
|
|
724
|
+
"harnesses": {
|
|
725
|
+
"type": "array",
|
|
726
|
+
"items": {
|
|
727
|
+
"type": "string",
|
|
728
|
+
"minLength": 1
|
|
729
|
+
},
|
|
730
|
+
"description": "Only count profiles usable by these harness slugs. Absent = any."
|
|
731
|
+
}
|
|
732
|
+
}
|
|
733
|
+
},
|
|
734
|
+
{
|
|
735
|
+
"title": "pairing step",
|
|
736
|
+
"type": "object",
|
|
737
|
+
"required": [
|
|
738
|
+
"id",
|
|
739
|
+
"kind",
|
|
740
|
+
"channel"
|
|
741
|
+
],
|
|
742
|
+
"additionalProperties": false,
|
|
743
|
+
"properties": {
|
|
744
|
+
"id": {
|
|
745
|
+
"$ref": "#/$defs/stepId"
|
|
746
|
+
},
|
|
747
|
+
"kind": {
|
|
748
|
+
"const": "pairing"
|
|
749
|
+
},
|
|
750
|
+
"title": {
|
|
751
|
+
"type": "string",
|
|
752
|
+
"minLength": 1
|
|
753
|
+
},
|
|
754
|
+
"description": {
|
|
755
|
+
"type": "string"
|
|
756
|
+
},
|
|
757
|
+
"optional": {
|
|
758
|
+
"type": "boolean",
|
|
759
|
+
"default": false,
|
|
760
|
+
"description": "An optional step may be declined or left pending without blocking `ready`."
|
|
761
|
+
},
|
|
762
|
+
"when": {
|
|
763
|
+
"$ref": "#/$defs/when"
|
|
764
|
+
},
|
|
765
|
+
"channel": {
|
|
766
|
+
"type": "string",
|
|
767
|
+
"minLength": 1,
|
|
768
|
+
"description": "Open set. `telegram` is defined by AIP-53; other values are host-defined."
|
|
769
|
+
},
|
|
770
|
+
"display": {
|
|
771
|
+
"enum": [
|
|
772
|
+
"qr",
|
|
773
|
+
"link",
|
|
774
|
+
"code"
|
|
775
|
+
],
|
|
776
|
+
"default": "qr"
|
|
777
|
+
},
|
|
778
|
+
"timeout_sec": {
|
|
779
|
+
"type": "integer",
|
|
780
|
+
"minimum": 1,
|
|
781
|
+
"default": 300
|
|
782
|
+
},
|
|
783
|
+
"persist": {
|
|
784
|
+
"$ref": "#/$defs/persist"
|
|
785
|
+
}
|
|
786
|
+
}
|
|
787
|
+
},
|
|
788
|
+
{
|
|
789
|
+
"title": "oauth step",
|
|
790
|
+
"type": "object",
|
|
791
|
+
"required": [
|
|
792
|
+
"id",
|
|
793
|
+
"kind",
|
|
794
|
+
"secret_slug"
|
|
795
|
+
],
|
|
796
|
+
"additionalProperties": false,
|
|
797
|
+
"properties": {
|
|
798
|
+
"id": {
|
|
799
|
+
"$ref": "#/$defs/stepId"
|
|
800
|
+
},
|
|
801
|
+
"kind": {
|
|
802
|
+
"const": "oauth"
|
|
803
|
+
},
|
|
804
|
+
"title": {
|
|
805
|
+
"type": "string",
|
|
806
|
+
"minLength": 1
|
|
807
|
+
},
|
|
808
|
+
"description": {
|
|
809
|
+
"type": "string"
|
|
810
|
+
},
|
|
811
|
+
"optional": {
|
|
812
|
+
"type": "boolean",
|
|
813
|
+
"default": false,
|
|
814
|
+
"description": "An optional step may be declined or left pending without blocking `ready`."
|
|
815
|
+
},
|
|
816
|
+
"when": {
|
|
817
|
+
"$ref": "#/$defs/when"
|
|
818
|
+
},
|
|
819
|
+
"secret_slug": {
|
|
820
|
+
"type": "string",
|
|
821
|
+
"minLength": 1
|
|
822
|
+
}
|
|
823
|
+
}
|
|
824
|
+
},
|
|
825
|
+
{
|
|
826
|
+
"title": "external step",
|
|
827
|
+
"type": "object",
|
|
828
|
+
"required": [
|
|
829
|
+
"id",
|
|
830
|
+
"kind",
|
|
831
|
+
"url"
|
|
832
|
+
],
|
|
833
|
+
"additionalProperties": false,
|
|
834
|
+
"properties": {
|
|
835
|
+
"id": {
|
|
836
|
+
"$ref": "#/$defs/stepId"
|
|
837
|
+
},
|
|
838
|
+
"kind": {
|
|
839
|
+
"const": "external"
|
|
840
|
+
},
|
|
841
|
+
"title": {
|
|
842
|
+
"type": "string",
|
|
843
|
+
"minLength": 1
|
|
844
|
+
},
|
|
845
|
+
"description": {
|
|
846
|
+
"type": "string"
|
|
847
|
+
},
|
|
848
|
+
"optional": {
|
|
849
|
+
"type": "boolean",
|
|
850
|
+
"default": false,
|
|
851
|
+
"description": "An optional step may be declined or left pending without blocking `ready`."
|
|
852
|
+
},
|
|
853
|
+
"when": {
|
|
854
|
+
"$ref": "#/$defs/when"
|
|
855
|
+
},
|
|
856
|
+
"url": {
|
|
857
|
+
"type": "string",
|
|
858
|
+
"pattern": "^https://"
|
|
859
|
+
},
|
|
860
|
+
"persist": {
|
|
861
|
+
"$ref": "#/$defs/persist"
|
|
862
|
+
}
|
|
863
|
+
}
|
|
864
|
+
},
|
|
865
|
+
{
|
|
866
|
+
"title": "check step",
|
|
867
|
+
"type": "object",
|
|
868
|
+
"required": [
|
|
869
|
+
"id",
|
|
870
|
+
"kind",
|
|
871
|
+
"check"
|
|
872
|
+
],
|
|
873
|
+
"additionalProperties": false,
|
|
874
|
+
"properties": {
|
|
875
|
+
"id": {
|
|
876
|
+
"$ref": "#/$defs/stepId"
|
|
877
|
+
},
|
|
878
|
+
"kind": {
|
|
879
|
+
"const": "check"
|
|
880
|
+
},
|
|
881
|
+
"title": {
|
|
882
|
+
"type": "string",
|
|
883
|
+
"minLength": 1
|
|
884
|
+
},
|
|
885
|
+
"description": {
|
|
886
|
+
"type": "string"
|
|
887
|
+
},
|
|
888
|
+
"optional": {
|
|
889
|
+
"type": "boolean",
|
|
890
|
+
"default": false,
|
|
891
|
+
"description": "An optional step may be declined or left pending without blocking `ready`."
|
|
892
|
+
},
|
|
893
|
+
"when": {
|
|
894
|
+
"$ref": "#/$defs/when"
|
|
895
|
+
},
|
|
896
|
+
"check": {
|
|
897
|
+
"type": "object",
|
|
898
|
+
"additionalProperties": false,
|
|
899
|
+
"minProperties": 1,
|
|
900
|
+
"maxProperties": 1,
|
|
901
|
+
"properties": {
|
|
902
|
+
"cmd": {
|
|
903
|
+
"type": "object",
|
|
904
|
+
"required": [
|
|
905
|
+
"run"
|
|
906
|
+
],
|
|
907
|
+
"additionalProperties": false,
|
|
908
|
+
"properties": {
|
|
909
|
+
"run": {
|
|
910
|
+
"type": "string",
|
|
911
|
+
"minLength": 1
|
|
912
|
+
},
|
|
913
|
+
"exit_code": {
|
|
914
|
+
"type": "integer",
|
|
915
|
+
"default": 0
|
|
916
|
+
}
|
|
917
|
+
}
|
|
918
|
+
},
|
|
919
|
+
"tool": {
|
|
920
|
+
"type": "object",
|
|
921
|
+
"required": [
|
|
922
|
+
"id"
|
|
923
|
+
],
|
|
924
|
+
"additionalProperties": false,
|
|
925
|
+
"properties": {
|
|
926
|
+
"id": {
|
|
927
|
+
"type": "string",
|
|
928
|
+
"minLength": 1
|
|
929
|
+
},
|
|
930
|
+
"args": {
|
|
931
|
+
"type": "object"
|
|
932
|
+
},
|
|
933
|
+
"expect": {
|
|
934
|
+
"type": "object",
|
|
935
|
+
"description": "Subset the tool's result object MUST contain."
|
|
936
|
+
}
|
|
937
|
+
}
|
|
938
|
+
}
|
|
939
|
+
}
|
|
940
|
+
},
|
|
941
|
+
"severity": {
|
|
942
|
+
"enum": [
|
|
943
|
+
"required",
|
|
944
|
+
"warn"
|
|
945
|
+
],
|
|
946
|
+
"default": "required"
|
|
947
|
+
}
|
|
948
|
+
}
|
|
949
|
+
},
|
|
950
|
+
{
|
|
951
|
+
"title": "vendor step",
|
|
952
|
+
"type": "object",
|
|
953
|
+
"required": [
|
|
954
|
+
"id",
|
|
955
|
+
"kind"
|
|
956
|
+
],
|
|
957
|
+
"additionalProperties": true,
|
|
958
|
+
"properties": {
|
|
959
|
+
"id": {
|
|
960
|
+
"$ref": "#/$defs/stepId"
|
|
961
|
+
},
|
|
962
|
+
"kind": {
|
|
963
|
+
"type": "string",
|
|
964
|
+
"pattern": "^x-[a-z0-9-]+$"
|
|
965
|
+
}
|
|
966
|
+
},
|
|
967
|
+
"description": "Vendor extension. The ONLY place in APP.md where unknown keys are tolerated. A host that does not implement the kind MUST fail with `setup_unsupported_step`, never skip it silently (unless `optional: true`)."
|
|
968
|
+
}
|
|
969
|
+
]
|
|
183
970
|
}
|
|
184
971
|
},
|
|
185
972
|
"allOf": [
|
|
@@ -188,23 +975,55 @@
|
|
|
188
975
|
"description": "An app with an empty or absent `agents` array is conforming ONLY when `ui` is present (codifies packages/app-kit/src/define-app.ts:49-52 and the five builtin panels in packages/apps/src/index.ts that ship as agents: []).",
|
|
189
976
|
"if": {
|
|
190
977
|
"anyOf": [
|
|
191
|
-
{
|
|
192
|
-
|
|
978
|
+
{
|
|
979
|
+
"not": {
|
|
980
|
+
"required": [
|
|
981
|
+
"agents"
|
|
982
|
+
]
|
|
983
|
+
}
|
|
984
|
+
},
|
|
985
|
+
{
|
|
986
|
+
"properties": {
|
|
987
|
+
"agents": {
|
|
988
|
+
"maxItems": 0
|
|
989
|
+
}
|
|
990
|
+
}
|
|
991
|
+
}
|
|
193
992
|
]
|
|
194
993
|
},
|
|
195
|
-
"then": {
|
|
994
|
+
"then": {
|
|
995
|
+
"required": [
|
|
996
|
+
"ui"
|
|
997
|
+
]
|
|
998
|
+
}
|
|
196
999
|
},
|
|
197
1000
|
{
|
|
198
1001
|
"title": "Attachment invariant (structural part)",
|
|
199
1002
|
"description": "A UI-only app bundles zero workflows: a bundled workflow with no referencing agent would be an orphan (conformance rule 3).",
|
|
200
1003
|
"if": {
|
|
201
1004
|
"anyOf": [
|
|
202
|
-
{
|
|
203
|
-
|
|
1005
|
+
{
|
|
1006
|
+
"not": {
|
|
1007
|
+
"required": [
|
|
1008
|
+
"agents"
|
|
1009
|
+
]
|
|
1010
|
+
}
|
|
1011
|
+
},
|
|
1012
|
+
{
|
|
1013
|
+
"properties": {
|
|
1014
|
+
"agents": {
|
|
1015
|
+
"maxItems": 0
|
|
1016
|
+
}
|
|
1017
|
+
}
|
|
1018
|
+
}
|
|
204
1019
|
]
|
|
205
1020
|
},
|
|
206
1021
|
"then": {
|
|
207
|
-
"properties": {
|
|
1022
|
+
"properties": {
|
|
1023
|
+
"workflows": {
|
|
1024
|
+
"maxItems": 0
|
|
1025
|
+
}
|
|
1026
|
+
}
|
|
208
1027
|
}
|
|
209
1028
|
}
|
|
210
1029
|
]
|