@agentproto/corpus-cli 0.11.0 → 0.11.2

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 (23) hide show
  1. package/dist/specs/resources/aip-10/draft/KNOWLEDGE.schema.json +2 -2
  2. package/dist/specs/resources/aip-18/draft/COLLECTION.schema.json +9 -2
  3. package/dist/specs/resources/aip-19/draft/SECRETS.schema.json +8 -2
  4. package/dist/specs/resources/aip-20/draft/WORK.schema.json +232 -206
  5. package/dist/specs/resources/aip-34/draft/EXPORT.schema.json +29 -0
  6. package/dist/specs/resources/aip-34/draft/LOCK.schema.json +76 -0
  7. package/dist/specs/resources/aip-34/draft/PRESENCE.schema.json +237 -0
  8. package/dist/specs/resources/aip-34/draft/TYPES.schema.json +78 -0
  9. package/dist/specs/resources/aip-34/draft/WORKSPACE.schema.json +252 -95
  10. package/dist/specs/resources/aip-36/draft/SANDBOX.schema.json +8 -1
  11. package/dist/specs/resources/aip-42/draft/AGENT.schema.json +5 -0
  12. package/dist/specs/resources/aip-45/draft/AGENT-CLI.schema.json +5 -0
  13. package/dist/specs/resources/aip-49/draft/ASSET.schema.json +10 -0
  14. package/dist/specs/resources/aip-53/draft/APP.schema.json +841 -65
  15. package/dist/specs/resources/aip-58/draft/event.schema.json +3 -2
  16. package/dist/specs/resources/aip-62/draft/ATTESTATION.schema.json +360 -67
  17. package/dist/specs/resources/aip-62/draft/REVIEW.schema.json +198 -52
  18. package/dist/specs/resources/aip-63/draft/BROWSER.schema.json +5 -1
  19. package/dist/specs/resources/aip-63/draft/RECORDING.schema.json +292 -0
  20. package/dist/specs/resources/aip-7/draft/GOVERNANCE.schema.json +2 -2
  21. package/dist/specs/resources/pending/memory/draft/MEMORY.schema.json +321 -0
  22. package/dist/specs/resources/pending/services/SERVICES.schema.json +55 -0
  23. package/package.json +7 -7
@@ -0,0 +1,29 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://agentproto.sh/schemas/aip-34/EXPORT.schema.json",
4
+ "title": "EXPORT.md frontmatter — workspace-export/v1 (sealed/hard node digest)",
5
+ "description": "Validates the YAML frontmatter portion of an EXPORT.md manifest. A `wall: sealed` or `wall: hard` node's ONLY readable surface for its ancestors: the body is free-form prose (summaries), never raw files.",
6
+ "type": "object",
7
+ "required": ["schema", "from", "generated_at"],
8
+ "additionalProperties": false,
9
+ "properties": {
10
+ "schema": { "const": "workspace-export/v1" },
11
+ "from": {
12
+ "type": "string",
13
+ "pattern": "^@[a-z0-9][a-z0-9-]*/[a-z0-9][a-z0-9-]*$",
14
+ "description": "Id of the sealed/hard workspace this export speaks for."
15
+ },
16
+ "generated_at": { "type": "string", "format": "date-time" },
17
+ "generated_by": {
18
+ "type": "string",
19
+ "description": "Agent slug that wrote this export, if any."
20
+ },
21
+ "sections": {
22
+ "type": "array",
23
+ "items": { "type": "string" },
24
+ "default": [],
25
+ "description": "Informational table of contents for the body's `##` headings. Not enforced."
26
+ },
27
+ "metadata": { "type": "object", "additionalProperties": true }
28
+ }
29
+ }
@@ -0,0 +1,76 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://agentproto.sh/schemas/aip-34/LOCK.schema.json",
4
+ "title": "agentproto.lock — agentproto-lock/v1 (tree-wide app/pack lockfile)",
5
+ "description": "Validates agentproto.lock, a plain YAML file (NOT frontmatter — no markdown body) at the tree root. Pins every AIP-53 app and AIP-64 pack installed anywhere in the tree to the exact version, source and attach point it resolved to, so `agentproto workspace check` can flag drift between WORKSPACE.md `apps:` version ranges and what is actually installed.",
6
+ "type": "object",
7
+ "required": ["lockfile", "generated"],
8
+ "additionalProperties": false,
9
+ "properties": {
10
+ "lockfile": { "const": "agentproto-lock/v1" },
11
+ "generated": { "type": "string", "format": "date-time" },
12
+ "apps": {
13
+ "type": "array",
14
+ "items": { "$ref": "#/$defs/lockedApp" },
15
+ "default": []
16
+ },
17
+ "packs": {
18
+ "type": "array",
19
+ "items": { "$ref": "#/$defs/lockedPack" },
20
+ "default": []
21
+ }
22
+ },
23
+ "$defs": {
24
+ "lockedApp": {
25
+ "type": "object",
26
+ "required": ["id", "version", "attach", "dataDir"],
27
+ "additionalProperties": false,
28
+ "properties": {
29
+ "id": {
30
+ "type": "string",
31
+ "pattern": "^@[a-z0-9][a-z0-9-]*/[a-z0-9][a-z0-9-]*$"
32
+ },
33
+ "version": {
34
+ "type": "string",
35
+ "pattern": "^\\d+\\.\\d+\\.\\d+(?:[-+][\\w.\\-]+)?$",
36
+ "description": "Exact resolved version — never a range. The range lives in the consuming WORKSPACE.md's `apps[].version`."
37
+ },
38
+ "source": {
39
+ "type": "string",
40
+ "description": "Where the .agentapp came from (file: path, registry URL, ...)."
41
+ },
42
+ "sha256": { "type": "string", "pattern": "^[a-f0-9]{64}$" },
43
+ "attach": {
44
+ "type": "string",
45
+ "pattern": "^@[a-z0-9][a-z0-9-]*/[a-z0-9][a-z0-9-]*$",
46
+ "description": "Workspace id this install is scoped to (the `scopeId` passed to app_apply)."
47
+ },
48
+ "dataDir": {
49
+ "type": "string",
50
+ "pattern": "^(?!/)(?!.*(^|/)\\.\\.(/|$)).+$",
51
+ "description": "Tree-relative path to this ATTACH's own data directory — one per attach point, never shared across attaches of the same app. Path confinement applies (AIP-34 §Path confinement): no leading `/`, no `..` segment; hosts MUST ALSO realpath-verify containment."
52
+ }
53
+ }
54
+ },
55
+ "lockedPack": {
56
+ "type": "object",
57
+ "required": ["name", "version", "digest", "attach"],
58
+ "additionalProperties": false,
59
+ "properties": {
60
+ "name": { "type": "string" },
61
+ "version": {
62
+ "type": "string",
63
+ "pattern": "^\\d+\\.\\d+\\.\\d+(?:[-+][\\w.\\-]+)?$"
64
+ },
65
+ "digest": {
66
+ "type": "string",
67
+ "pattern": "^agentproto-pack-digest/v1:.+$"
68
+ },
69
+ "attach": {
70
+ "type": "string",
71
+ "pattern": "^@[a-z0-9][a-z0-9-]*/[a-z0-9][a-z0-9-]*$"
72
+ }
73
+ }
74
+ }
75
+ }
76
+ }
@@ -0,0 +1,237 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://agentproto.sh/schemas/aip-34/PRESENCE.schema.json",
4
+ "title": "PRESENCE.md frontmatter (AIP-34, presence/v1)",
5
+ "description": "Validates the YAML frontmatter of a presence/v1 document: the editorial and channel policy of one workspace node (who it talks to, about what, where, how often, in which words). The voice itself lives in the AIP-25 PERSONA.md named by `persona`. The body is markdown and is not validated.",
6
+ "type": "object",
7
+ "required": ["schema", "name", "title", "description", "version", "status"],
8
+ "additionalProperties": false,
9
+ "$defs": {
10
+ "kebab": { "type": "string", "pattern": "^[a-z][a-z0-9-]*[a-z0-9]$", "minLength": 2, "maxLength": 64 },
11
+ "approvalMode": { "type": "string", "pattern": "^(always|policy:.+)$" },
12
+ "cadence": {
13
+ "type": "object",
14
+ "additionalProperties": false,
15
+ "properties": {
16
+ "posts": {
17
+ "type": "object",
18
+ "additionalProperties": false,
19
+ "properties": {
20
+ "perWeek": { "type": "integer", "minimum": 0, "maximum": 50 },
21
+ "maxPerDay": { "type": "integer", "minimum": 0, "maximum": 10 }
22
+ }
23
+ },
24
+ "comments": {
25
+ "type": "object",
26
+ "additionalProperties": false,
27
+ "properties": {
28
+ "perDay": { "type": "integer", "minimum": 0, "maximum": 50 }
29
+ }
30
+ },
31
+ "window": {
32
+ "type": "object",
33
+ "additionalProperties": false,
34
+ "properties": {
35
+ "days": {
36
+ "type": "array",
37
+ "uniqueItems": true,
38
+ "items": { "enum": ["mon", "tue", "wed", "thu", "fri", "sat", "sun"] }
39
+ },
40
+ "hours": { "type": "string", "pattern": "^([01][0-9]|2[0-3]):[0-5][0-9]-([01][0-9]|2[0-3]):[0-5][0-9]$" },
41
+ "timezone": { "type": "string" }
42
+ }
43
+ }
44
+ }
45
+ },
46
+ "channel": {
47
+ "type": "object",
48
+ "required": ["id", "network"],
49
+ "additionalProperties": false,
50
+ "properties": {
51
+ "id": { "$ref": "#/$defs/kebab" },
52
+ "network": { "type": "string", "description": "linkedin, x, instagram, tiktok, youtube, facebook, threads, bluesky, mastodon, or a custom slug." },
53
+ "account": {
54
+ "type": "object",
55
+ "additionalProperties": false,
56
+ "properties": {
57
+ "handle": { "type": "string" },
58
+ "kind": { "enum": ["personal", "brand"] },
59
+ "owner": { "type": "string", "description": "Principal ref, e.g. user:jeremy. Whose account it is." }
60
+ }
61
+ },
62
+ "connection": {
63
+ "type": "object",
64
+ "additionalProperties": false,
65
+ "properties": {
66
+ "provider": { "type": "string", "description": "How an approved action leaves: postiz, chrome-live, manual, or a custom slug." },
67
+ "credentials": { "type": "string", "pattern": "^[a-z][a-z0-9-]*$", "description": "Slug of an AIP-19 secret in this node's SECRETS.md or granted through uses_secrets. Credentials are never inline." }
68
+ }
69
+ },
70
+ "locale": { "type": "string" },
71
+ "formats": { "type": "array", "uniqueItems": true, "items": { "type": "string" } },
72
+ "cadence": { "$ref": "#/$defs/cadence" },
73
+ "actions": {
74
+ "type": "object",
75
+ "additionalProperties": false,
76
+ "description": "Which kinds of action are allowed on this channel. Absent means post and comment are both allowed.",
77
+ "properties": {
78
+ "post": { "type": "boolean" },
79
+ "comment": { "type": "boolean" }
80
+ }
81
+ },
82
+ "publish": {
83
+ "type": "object",
84
+ "additionalProperties": false,
85
+ "description": "Provider per action after approval. Overrides connection.provider.",
86
+ "properties": {
87
+ "post": { "type": "string" },
88
+ "comment": { "type": "string" }
89
+ }
90
+ },
91
+ "approval": { "$ref": "#/$defs/approvalMode" }
92
+ }
93
+ }
94
+ },
95
+ "properties": {
96
+ "schema": { "const": "presence/v1" },
97
+ "name": { "$ref": "#/$defs/kebab" },
98
+ "title": { "type": "string", "minLength": 1, "maxLength": 120 },
99
+ "description": { "type": "string", "minLength": 1, "maxLength": 2000 },
100
+ "version": { "type": "string", "pattern": "^\\d+\\.\\d+\\.\\d+" },
101
+ "status": { "enum": ["draft", "active", "paused"] },
102
+ "extends": { "type": "string", "description": "Relative path to a parent PRESENCE.md (company defaults)." },
103
+ "persona": { "type": "string", "description": "AIP-25 PERSONA.md: a relative path or a ws://personas ref. Required in the effective (merged) document." },
104
+ "audience": {
105
+ "type": "object",
106
+ "additionalProperties": false,
107
+ "properties": {
108
+ "primary": { "type": "string" },
109
+ "pains": { "type": "array", "items": { "type": "string" } },
110
+ "notTargeted": { "type": "array", "items": { "type": "string" } }
111
+ }
112
+ },
113
+ "topics": {
114
+ "type": "object",
115
+ "additionalProperties": false,
116
+ "properties": {
117
+ "pillars": {
118
+ "type": "array",
119
+ "items": {
120
+ "type": "object",
121
+ "required": ["id", "title"],
122
+ "additionalProperties": false,
123
+ "properties": {
124
+ "id": { "$ref": "#/$defs/kebab" },
125
+ "title": { "type": "string" },
126
+ "angle": { "type": "string" }
127
+ }
128
+ }
129
+ },
130
+ "exclude": { "type": "array", "items": { "type": "string" } }
131
+ }
132
+ },
133
+ "lexicon": {
134
+ "type": "object",
135
+ "additionalProperties": false,
136
+ "properties": {
137
+ "forbidden": {
138
+ "type": "array",
139
+ "items": {
140
+ "type": "object",
141
+ "required": ["term"],
142
+ "additionalProperties": false,
143
+ "properties": {
144
+ "term": { "type": "string" },
145
+ "reason": { "type": "string" },
146
+ "instead": { "type": "string" }
147
+ }
148
+ }
149
+ },
150
+ "required": {
151
+ "type": "array",
152
+ "items": {
153
+ "type": "object",
154
+ "required": ["phrase"],
155
+ "additionalProperties": false,
156
+ "properties": {
157
+ "phrase": { "type": "string" },
158
+ "context": { "type": "string" }
159
+ }
160
+ }
161
+ }
162
+ }
163
+ },
164
+ "channels": { "type": "array", "items": { "$ref": "#/$defs/channel" } },
165
+ "watch": {
166
+ "type": "object",
167
+ "additionalProperties": false,
168
+ "properties": {
169
+ "keywords": { "type": "array", "items": { "type": "string" } },
170
+ "accounts": { "type": "array", "items": { "type": "string" } },
171
+ "hashtags": { "type": "array", "items": { "type": "string" } },
172
+ "communities": { "type": "array", "items": { "type": "string" } },
173
+ "commentRules": { "type": "array", "items": { "type": "string" } }
174
+ }
175
+ },
176
+ "approval": {
177
+ "type": "object",
178
+ "additionalProperties": false,
179
+ "properties": {
180
+ "mode": { "$ref": "#/$defs/approvalMode" },
181
+ "approver": { "type": "string", "description": "Principal ref, e.g. user:jeremy." }
182
+ }
183
+ },
184
+ "gates": {
185
+ "type": "array",
186
+ "items": {
187
+ "type": "object",
188
+ "required": ["id", "description", "status", "blocks"],
189
+ "additionalProperties": false,
190
+ "properties": {
191
+ "id": { "$ref": "#/$defs/kebab" },
192
+ "description": { "type": "string" },
193
+ "status": { "enum": ["open", "cleared"] },
194
+ "blocks": {
195
+ "type": "array",
196
+ "minItems": 1,
197
+ "items": { "type": "string", "pattern": "^(links|posts|comments|channel:[a-z][a-z0-9-]*)$" }
198
+ }
199
+ }
200
+ }
201
+ },
202
+ "examples": {
203
+ "type": "object",
204
+ "additionalProperties": false,
205
+ "properties": {
206
+ "good": {
207
+ "type": "array",
208
+ "items": {
209
+ "type": "object",
210
+ "required": ["text"],
211
+ "additionalProperties": false,
212
+ "properties": { "channel": { "type": "string" }, "text": { "type": "string" }, "why": { "type": "string" } }
213
+ }
214
+ },
215
+ "bad": {
216
+ "type": "array",
217
+ "items": {
218
+ "type": "object",
219
+ "required": ["text", "why"],
220
+ "additionalProperties": false,
221
+ "properties": { "channel": { "type": "string" }, "text": { "type": "string" }, "why": { "type": "string" } }
222
+ }
223
+ }
224
+ }
225
+ },
226
+ "review": {
227
+ "type": "object",
228
+ "additionalProperties": false,
229
+ "properties": {
230
+ "cadence": { "enum": ["weekly", "monthly"] },
231
+ "day": { "enum": ["mon", "tue", "wed", "thu", "fri", "sat", "sun"] },
232
+ "kpis": { "type": "array", "items": { "type": "string" } }
233
+ }
234
+ },
235
+ "metadata": { "type": "object" }
236
+ }
237
+ }
@@ -0,0 +1,78 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://agentproto.sh/schemas/aip-34/TYPES.schema.json",
4
+ "title": "TYPES.md frontmatter — workspace-types/v1 (tree node-type registry)",
5
+ "description": "Validates the YAML frontmatter portion of a TYPES.md manifest. Exactly one per tree, at the root. Declares the node `type` values a workspace/v2 WORKSPACE.md may use, their allowed parent types, their default wall level, required sibling files, and a 'starter' shape a `ws new` command materializes. Each entry conceptually compiles to an AIP-40 EXTENSION.md; this file is the authoring surface.",
6
+ "type": "object",
7
+ "required": ["schema", "types"],
8
+ "additionalProperties": false,
9
+ "properties": {
10
+ "schema": { "const": "workspace-types/v1" },
11
+ "types": {
12
+ "type": "object",
13
+ "minProperties": 1,
14
+ "propertyNames": { "pattern": "^[a-z][a-z0-9-]*$" },
15
+ "additionalProperties": { "$ref": "#/$defs/typeEntry" }
16
+ }
17
+ },
18
+ "$defs": {
19
+ "typeEntry": {
20
+ "type": "object",
21
+ "additionalProperties": false,
22
+ "properties": {
23
+ "parents": {
24
+ "type": "array",
25
+ "items": { "type": "string" },
26
+ "description": "Type names this node MAY nest under (nearest ancestor WITH a WORKSPACE.md). Empty array = root-only type."
27
+ },
28
+ "extends": {
29
+ "type": "string",
30
+ "description": "Another type this one inherits unset fields from (e.g. a `client` type extending `project`)."
31
+ },
32
+ "default_wall": {
33
+ "enum": ["shared", "isolated", "sealed", "hard"],
34
+ "description": "Wall level a node of this type gets when its own WORKSPACE.md omits `wall`. A node MAY tighten, MUST NOT loosen below this."
35
+ },
36
+ "max_per_tree": {
37
+ "type": "integer",
38
+ "minimum": 1,
39
+ "description": "Cap on how many nodes of this type may exist in one tree (e.g. root: 1)."
40
+ },
41
+ "requires_files": {
42
+ "type": "array",
43
+ "items": { "type": "string" },
44
+ "default": [],
45
+ "description": "Sibling files `agentproto workspace check` requires at a node of this type (e.g. company → [COMPANY.md]). A project node's status is checked via its `work:` field (AIP-20 WORK.md), not a requires_files entry."
46
+ },
47
+ "starter": {
48
+ "type": "object",
49
+ "additionalProperties": false,
50
+ "properties": {
51
+ "agents": {
52
+ "type": "array",
53
+ "items": {
54
+ "type": "object",
55
+ "additionalProperties": false,
56
+ "properties": { "template": { "type": "string" } }
57
+ }
58
+ },
59
+ "routines": {
60
+ "type": "array",
61
+ "items": {
62
+ "type": "object",
63
+ "additionalProperties": false,
64
+ "properties": { "template": { "type": "string" } }
65
+ }
66
+ }
67
+ },
68
+ "description": "What `ws new <type>` seeds by default. Informational to the spec; normative to the CLI that implements `ws new`."
69
+ },
70
+ "adds_fields": {
71
+ "type": "object",
72
+ "additionalProperties": { "type": "string" },
73
+ "description": "Extra frontmatter fields a node of this type MAY carry beyond the base workspace/v2 shape, as a field-name → type-hint map. Validated loosely here; a host MAY compile this into a stricter per-type JSON Schema."
74
+ }
75
+ }
76
+ }
77
+ }
78
+ }