@agentproto/corpus-cli 0.2.0 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -104,6 +104,11 @@
104
104
  "items": { "$ref": "#/$defs/option" },
105
105
  "description": "Independent typed knobs the CLI accepts. The host picks any subset per turn via OPERATOR.runtime.config.options. Patches apply in declaration order, AFTER mode patches."
106
106
  },
107
+ "presets": {
108
+ "type": "array",
109
+ "items": { "$ref": "#/$defs/preset" },
110
+ "description": "AIP-45 gateway presets this adapter can drive (Anthropic/OpenAI-compatible backends). Merged into the provider-preset catalog (agentproto presets list / list_provider_presets) alongside the built-in registry, deduped by id (built-in wins on collision). Lets an external adapter surface a gateway the built-in registry doesn't know about."
111
+ },
107
112
  "continuation": { "$ref": "#/$defs/continuation" },
108
113
  "requires": { "$ref": "https://agentproto.sh/docs/aip-29/CLI.schema.json#/properties/requires" },
109
114
  "examples": {
@@ -259,6 +264,11 @@
259
264
  "description": "Stable id. The operator config references this id."
260
265
  },
261
266
  "description": { "type": "string" },
267
+ "bin_args_prepend": {
268
+ "type": "array",
269
+ "items": { "type": "string" },
270
+ "description": "Extra argv prepended before the manifest's bin_args when this mode is active."
271
+ },
262
272
  "bin_args_append": {
263
273
  "type": "array",
264
274
  "items": { "type": "string" },
@@ -268,6 +278,19 @@
268
278
  "type": "object",
269
279
  "additionalProperties": { "type": "string" },
270
280
  "description": "Extra env vars merged into the spawn env when this mode is active."
281
+ },
282
+ "env_unset": {
283
+ "type": "array",
284
+ "items": { "type": "string" },
285
+ "description": "Env keys to DELETE from the spawn env when this mode is active. Applied at the runtime's env-merge point after ambient process.env + mode/option env are combined, so a mode can scrub a credential that must never reach a non-native endpoint (e.g. a gateway mode scrubbing ANTHROPIC_API_KEY so it can't leak to a third-party Anthropic-compatible host). Unlike `env`, deletion is the only safe semantics for scrubbing."
286
+ },
287
+ "status": {
288
+ "enum": ["active", "noop", "planned"],
289
+ "description": "Honest support status surfaced to clients. active = does what its description claims; noop = declared and accepted but measured to have no effect; planned = declared surface not wired yet. Absent ⇒ treated as active."
290
+ },
291
+ "status_note": {
292
+ "type": "string",
293
+ "description": "Human-readable reason backing `status` (e.g. what was measured)."
271
294
  }
272
295
  }
273
296
  },
@@ -303,6 +326,11 @@
303
326
  "type": "integer",
304
327
  "description": "Upper bound when type=integer."
305
328
  },
329
+ "bin_args_prepend": {
330
+ "type": "array",
331
+ "items": { "type": "string" },
332
+ "description": "Argv template prepended before the manifest's bin_args when the option has a non-default value. The literal token `{value}` is replaced with the option's value (stringified)."
333
+ },
306
334
  "bin_args_template": {
307
335
  "type": "array",
308
336
  "items": { "type": "string" },
@@ -317,6 +345,11 @@
317
345
  "type": "object",
318
346
  "additionalProperties": { "type": "string" },
319
347
  "description": "Env vars to merge when the option has a non-default value. Values may contain `{value}` for templating."
348
+ },
349
+ "env_unset": {
350
+ "type": "array",
351
+ "items": { "type": "string" },
352
+ "description": "Env keys to DELETE from the spawn env when the option has a non-default value. Symmetric with mode.env_unset and applied at the same runtime env-merge point. Lets a value-bearing option (e.g. base_url pointing at a third-party Anthropic-compatible gateway) scrub the ambient credential (ANTHROPIC_API_KEY) it must displace, without forcing the operator to also pick a preset mode."
320
353
  }
321
354
  },
322
355
  "allOf": [
@@ -326,6 +359,35 @@
326
359
  }
327
360
  ]
328
361
  },
362
+ "preset": {
363
+ "type": "object",
364
+ "additionalProperties": false,
365
+ "required": ["id", "label", "schemaFlavor", "baseUrl", "keyEnv"],
366
+ "description": "A gateway preset this adapter can drive — a backend an Anthropic/OpenAI-compatible client can front. Declared in the manifest so the catalog surfaces adapter-contributed presets alongside the built-in registry. No adapter projection (env/env_unset/bin_args) here; that stays in modes/options.",
367
+ "properties": {
368
+ "id": {
369
+ "type": "string",
370
+ "minLength": 1,
371
+ "description": "Stable preset id. SHOULD equal the mode id if the adapter projects this preset as a mode. Catalog dedupes built-in vs adapter-declared by id; an adapter-declared id colliding with a built-in is ignored in favor of the built-in (registry is source of truth for canonical providers)."
372
+ },
373
+ "label": { "type": "string", "minLength": 1, "description": "Human label for the catalog UI." },
374
+ "description": { "type": "string" },
375
+ "schemaFlavor": { "enum": ["anthropic", "openai"], "description": "API schema flavor — selects which adapter family can consume the preset." },
376
+ "baseUrl": { "type": "string", "minLength": 1, "description": "Base URL the client hits." },
377
+ "keyEnv": {
378
+ "type": "string",
379
+ "minLength": 1,
380
+ "description": "Conventional env var holding this provider's API key. Catalog status is derived from its presence in the daemon's environment (ready vs available)."
381
+ },
382
+ "scrubEnv": {
383
+ "type": "array",
384
+ "items": { "type": "string" },
385
+ "description": "Env vars to scrub when this preset is active. Optional — an adapter that scrubs in code may omit it. Not surfaced to catalog clients."
386
+ },
387
+ "defaultModel": { "type": "string", "description": "Conventional default model id for this provider, if any." },
388
+ "homepage": { "type": "string", "description": "Optional homepage/docs URL for the catalog UI." }
389
+ }
390
+ },
329
391
  "continuation": {
330
392
  "type": "object",
331
393
  "additionalProperties": false,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agentproto/corpus-cli",
3
- "version": "0.2.0",
3
+ "version": "0.3.0",
4
4
  "description": "@agentproto/corpus-cli — the `corpus` binary. Validate, lint, and operate an AIP-10 corpus workspace from the command line. Local-topology host for @agentproto/corpus — pair with a local backing engine (qdrant docker / gbrain) for a fully offline corpus runtime.",
5
5
  "keywords": [
6
6
  "agentproto",
@@ -52,8 +52,8 @@
52
52
  "gray-matter": "^4.0.3",
53
53
  "zod": "^4.4.3",
54
54
  "@agentproto/cli-exec": "0.1.0-alpha.1",
55
- "@agentproto/corpus": "0.2.0",
56
- "@agentproto/corpus-presets": "0.2.0"
55
+ "@agentproto/corpus": "0.2.1",
56
+ "@agentproto/corpus-presets": "0.2.1"
57
57
  },
58
58
  "devDependencies": {
59
59
  "@types/node": "^25.6.2",