@holokai/neuron-sdk 0.3.0 → 0.5.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.
@@ -13,6 +13,27 @@ declare const CapabilitySchema: z.ZodObject<{
13
13
  onBehalfOf: string;
14
14
  }>]>;
15
15
  concurrency: z.ZodNumber;
16
+ /**
17
+ * Plain-language contract advertisement (HOL-2926). All three fields
18
+ * are optional and additive: older neurons keep sending
19
+ * `{ type, scope, concurrency }` and the gateway accepts both shapes.
20
+ * When present they flow (fire-and-forget) to Moku's
21
+ * `capability_catalog` so registry-sourced capabilities render with a
22
+ * real contract in the supervisor catalog instead of type-only stubs.
23
+ *
24
+ * Omit rather than null — the fields are `.optional()`, not
25
+ * `.nullable()`, and a `null` description fails validation.
26
+ */
27
+ description: z.ZodOptional<z.ZodString>;
28
+ /**
29
+ * JSON Schema for the capability's input payload — opaque on the wire,
30
+ * but `null` is rejected: the reconcile push to Moku is last-writer-wins
31
+ * per present key, so a null here could wipe a stored schema.
32
+ * (`description` already rejects null via `z.string()`.)
33
+ */
34
+ inputSchema: z.ZodOptional<z.ZodEffects<z.ZodUnknown, unknown, unknown>>;
35
+ /** JSON Schema for the capability's output payload — same rules as inputSchema. */
36
+ outputSchema: z.ZodOptional<z.ZodEffects<z.ZodUnknown, unknown, unknown>>;
16
37
  /**
17
38
  * Per-capability lease TTL override in milliseconds (HOL-356).
18
39
  * The gateway uses this when minting a lease's `expiresAt`; absent
@@ -33,6 +54,9 @@ declare const CapabilitySchema: z.ZodObject<{
33
54
  onBehalfOf: string;
34
55
  };
35
56
  concurrency: number;
57
+ description?: string | undefined;
58
+ inputSchema?: unknown;
59
+ outputSchema?: unknown;
36
60
  leaseTtlMs?: number | undefined;
37
61
  }, {
38
62
  type: string;
@@ -40,6 +64,9 @@ declare const CapabilitySchema: z.ZodObject<{
40
64
  onBehalfOf: string;
41
65
  };
42
66
  concurrency: number;
67
+ description?: string | undefined;
68
+ inputSchema?: unknown;
69
+ outputSchema?: unknown;
43
70
  leaseTtlMs?: number | undefined;
44
71
  }>;
45
72
  type Capability = z.infer<typeof CapabilitySchema>;
@@ -145,6 +172,9 @@ declare const RegisterFrameSchema: z.ZodObject<{
145
172
  onBehalfOf: string;
146
173
  }>]>;
147
174
  concurrency: z.ZodNumber;
175
+ description: z.ZodOptional<z.ZodString>;
176
+ inputSchema: z.ZodOptional<z.ZodEffects<z.ZodUnknown, unknown, unknown>>;
177
+ outputSchema: z.ZodOptional<z.ZodEffects<z.ZodUnknown, unknown, unknown>>;
148
178
  leaseTtlMs: z.ZodOptional<z.ZodNumber>;
149
179
  }, "strict", z.ZodTypeAny, {
150
180
  type: string;
@@ -152,6 +182,9 @@ declare const RegisterFrameSchema: z.ZodObject<{
152
182
  onBehalfOf: string;
153
183
  };
154
184
  concurrency: number;
185
+ description?: string | undefined;
186
+ inputSchema?: unknown;
187
+ outputSchema?: unknown;
155
188
  leaseTtlMs?: number | undefined;
156
189
  }, {
157
190
  type: string;
@@ -159,6 +192,9 @@ declare const RegisterFrameSchema: z.ZodObject<{
159
192
  onBehalfOf: string;
160
193
  };
161
194
  concurrency: number;
195
+ description?: string | undefined;
196
+ inputSchema?: unknown;
197
+ outputSchema?: unknown;
162
198
  leaseTtlMs?: number | undefined;
163
199
  }>, "many">, {
164
200
  type: string;
@@ -166,6 +202,9 @@ declare const RegisterFrameSchema: z.ZodObject<{
166
202
  onBehalfOf: string;
167
203
  };
168
204
  concurrency: number;
205
+ description?: string | undefined;
206
+ inputSchema?: unknown;
207
+ outputSchema?: unknown;
169
208
  leaseTtlMs?: number | undefined;
170
209
  }[], {
171
210
  type: string;
@@ -173,6 +212,9 @@ declare const RegisterFrameSchema: z.ZodObject<{
173
212
  onBehalfOf: string;
174
213
  };
175
214
  concurrency: number;
215
+ description?: string | undefined;
216
+ inputSchema?: unknown;
217
+ outputSchema?: unknown;
176
218
  leaseTtlMs?: number | undefined;
177
219
  }[]>;
178
220
  }, "strict", z.ZodTypeAny, {
@@ -185,6 +227,9 @@ declare const RegisterFrameSchema: z.ZodObject<{
185
227
  onBehalfOf: string;
186
228
  };
187
229
  concurrency: number;
230
+ description?: string | undefined;
231
+ inputSchema?: unknown;
232
+ outputSchema?: unknown;
188
233
  leaseTtlMs?: number | undefined;
189
234
  }[];
190
235
  }, {
@@ -197,6 +242,9 @@ declare const RegisterFrameSchema: z.ZodObject<{
197
242
  onBehalfOf: string;
198
243
  };
199
244
  concurrency: number;
245
+ description?: string | undefined;
246
+ inputSchema?: unknown;
247
+ outputSchema?: unknown;
200
248
  leaseTtlMs?: number | undefined;
201
249
  }[];
202
250
  }>;
@@ -214,6 +262,9 @@ declare const UpdateCapabilityFrameSchema: z.ZodObject<{
214
262
  onBehalfOf: string;
215
263
  }>]>;
216
264
  concurrency: z.ZodNumber;
265
+ description: z.ZodOptional<z.ZodString>;
266
+ inputSchema: z.ZodOptional<z.ZodEffects<z.ZodUnknown, unknown, unknown>>;
267
+ outputSchema: z.ZodOptional<z.ZodEffects<z.ZodUnknown, unknown, unknown>>;
217
268
  leaseTtlMs: z.ZodOptional<z.ZodNumber>;
218
269
  }, "strict", z.ZodTypeAny, {
219
270
  type: string;
@@ -221,6 +272,9 @@ declare const UpdateCapabilityFrameSchema: z.ZodObject<{
221
272
  onBehalfOf: string;
222
273
  };
223
274
  concurrency: number;
275
+ description?: string | undefined;
276
+ inputSchema?: unknown;
277
+ outputSchema?: unknown;
224
278
  leaseTtlMs?: number | undefined;
225
279
  }, {
226
280
  type: string;
@@ -228,6 +282,9 @@ declare const UpdateCapabilityFrameSchema: z.ZodObject<{
228
282
  onBehalfOf: string;
229
283
  };
230
284
  concurrency: number;
285
+ description?: string | undefined;
286
+ inputSchema?: unknown;
287
+ outputSchema?: unknown;
231
288
  leaseTtlMs?: number | undefined;
232
289
  }>;
233
290
  }, "strict", z.ZodTypeAny, {
@@ -238,6 +295,9 @@ declare const UpdateCapabilityFrameSchema: z.ZodObject<{
238
295
  onBehalfOf: string;
239
296
  };
240
297
  concurrency: number;
298
+ description?: string | undefined;
299
+ inputSchema?: unknown;
300
+ outputSchema?: unknown;
241
301
  leaseTtlMs?: number | undefined;
242
302
  };
243
303
  neuronId: string;
@@ -249,6 +309,9 @@ declare const UpdateCapabilityFrameSchema: z.ZodObject<{
249
309
  onBehalfOf: string;
250
310
  };
251
311
  concurrency: number;
312
+ description?: string | undefined;
313
+ inputSchema?: unknown;
314
+ outputSchema?: unknown;
252
315
  leaseTtlMs?: number | undefined;
253
316
  };
254
317
  neuronId: string;
@@ -384,6 +447,9 @@ declare const ServerToNeuronFrameSchema: z.ZodDiscriminatedUnion<"type", [z.ZodO
384
447
  onBehalfOf: string;
385
448
  }>]>;
386
449
  concurrency: z.ZodNumber;
450
+ description: z.ZodOptional<z.ZodString>;
451
+ inputSchema: z.ZodOptional<z.ZodEffects<z.ZodUnknown, unknown, unknown>>;
452
+ outputSchema: z.ZodOptional<z.ZodEffects<z.ZodUnknown, unknown, unknown>>;
387
453
  leaseTtlMs: z.ZodOptional<z.ZodNumber>;
388
454
  }, "strict", z.ZodTypeAny, {
389
455
  type: string;
@@ -391,6 +457,9 @@ declare const ServerToNeuronFrameSchema: z.ZodDiscriminatedUnion<"type", [z.ZodO
391
457
  onBehalfOf: string;
392
458
  };
393
459
  concurrency: number;
460
+ description?: string | undefined;
461
+ inputSchema?: unknown;
462
+ outputSchema?: unknown;
394
463
  leaseTtlMs?: number | undefined;
395
464
  }, {
396
465
  type: string;
@@ -398,6 +467,9 @@ declare const ServerToNeuronFrameSchema: z.ZodDiscriminatedUnion<"type", [z.ZodO
398
467
  onBehalfOf: string;
399
468
  };
400
469
  concurrency: number;
470
+ description?: string | undefined;
471
+ inputSchema?: unknown;
472
+ outputSchema?: unknown;
401
473
  leaseTtlMs?: number | undefined;
402
474
  }>, "many">;
403
475
  acceptedAt: z.ZodString;
@@ -409,6 +481,9 @@ declare const ServerToNeuronFrameSchema: z.ZodDiscriminatedUnion<"type", [z.ZodO
409
481
  onBehalfOf: string;
410
482
  };
411
483
  concurrency: number;
484
+ description?: string | undefined;
485
+ inputSchema?: unknown;
486
+ outputSchema?: unknown;
412
487
  leaseTtlMs?: number | undefined;
413
488
  }[];
414
489
  sessionId: string;
@@ -421,6 +496,9 @@ declare const ServerToNeuronFrameSchema: z.ZodDiscriminatedUnion<"type", [z.ZodO
421
496
  onBehalfOf: string;
422
497
  };
423
498
  concurrency: number;
499
+ description?: string | undefined;
500
+ inputSchema?: unknown;
501
+ outputSchema?: unknown;
424
502
  leaseTtlMs?: number | undefined;
425
503
  }[];
426
504
  sessionId: string;
@@ -612,7 +690,10 @@ interface HandlerContext {
612
690
  log: NeuronLogger;
613
691
  /**
614
692
  * Send a `progress` frame to the gateway. Non-blocking; safe to call
615
- * many times during a long-running handler.
693
+ * many times during a long-running handler. Frames are sent one at a time
694
+ * in call order, each bounded by a timeout, and the lease's ack or nack
695
+ * waits until they have gone. A cancelled lease drops the frames it has
696
+ * not started sending and nacks at once.
616
697
  */
617
698
  progress(update: {
618
699
  percent?: number;
@@ -637,11 +718,16 @@ interface HandlerContext {
637
718
  interface CapabilityRegistration extends Capability {
638
719
  /** JSON Schema validated against the lease input before invoking the
639
720
  * handler. Mismatch produces a `schema-mismatch` nack and the handler
640
- * is never called. */
721
+ * is never called. This is the authority for inbound validation — the
722
+ * `inputSchema` on the lease frame is ignored (HOL-2913). Omit it and
723
+ * input is not validated client-side at all. Also advertised on the
724
+ * register frame (HOL-2926) so the capability catalog knows the
725
+ * contract. */
641
726
  inputSchema?: JsonSchema;
642
727
  /** JSON Schema validated against the handler's return value. Mismatch
643
728
  * produces a `schema-mismatch` nack and the gateway publishes a failed
644
- * TaskResult. */
729
+ * TaskResult. Same authority as `inputSchema`; note the gateway also
730
+ * validates ack output against its own schema regardless. */
645
731
  outputSchema?: JsonSchema;
646
732
  }
647
733
  /**
@@ -653,6 +739,12 @@ interface CapabilityRegistration extends Capability {
653
739
  interface CapabilityHandleOptions {
654
740
  scope?: Capability['scope'];
655
741
  concurrency?: number;
742
+ /**
743
+ * Overrides the def's `description` in the advertised contract
744
+ * (HOL-2926) — e.g. a deployment-specific wording. Rarely needed; the
745
+ * def's description is used when absent.
746
+ */
747
+ description?: string;
656
748
  /**
657
749
  * Per-capability lease TTL override (HOL-356). Wins over the same
658
750
  * field on the def. See `CapabilityDefInit.leaseTtlMs` for shape;
@@ -13,6 +13,27 @@ declare const CapabilitySchema: z.ZodObject<{
13
13
  onBehalfOf: string;
14
14
  }>]>;
15
15
  concurrency: z.ZodNumber;
16
+ /**
17
+ * Plain-language contract advertisement (HOL-2926). All three fields
18
+ * are optional and additive: older neurons keep sending
19
+ * `{ type, scope, concurrency }` and the gateway accepts both shapes.
20
+ * When present they flow (fire-and-forget) to Moku's
21
+ * `capability_catalog` so registry-sourced capabilities render with a
22
+ * real contract in the supervisor catalog instead of type-only stubs.
23
+ *
24
+ * Omit rather than null — the fields are `.optional()`, not
25
+ * `.nullable()`, and a `null` description fails validation.
26
+ */
27
+ description: z.ZodOptional<z.ZodString>;
28
+ /**
29
+ * JSON Schema for the capability's input payload — opaque on the wire,
30
+ * but `null` is rejected: the reconcile push to Moku is last-writer-wins
31
+ * per present key, so a null here could wipe a stored schema.
32
+ * (`description` already rejects null via `z.string()`.)
33
+ */
34
+ inputSchema: z.ZodOptional<z.ZodEffects<z.ZodUnknown, unknown, unknown>>;
35
+ /** JSON Schema for the capability's output payload — same rules as inputSchema. */
36
+ outputSchema: z.ZodOptional<z.ZodEffects<z.ZodUnknown, unknown, unknown>>;
16
37
  /**
17
38
  * Per-capability lease TTL override in milliseconds (HOL-356).
18
39
  * The gateway uses this when minting a lease's `expiresAt`; absent
@@ -33,6 +54,9 @@ declare const CapabilitySchema: z.ZodObject<{
33
54
  onBehalfOf: string;
34
55
  };
35
56
  concurrency: number;
57
+ description?: string | undefined;
58
+ inputSchema?: unknown;
59
+ outputSchema?: unknown;
36
60
  leaseTtlMs?: number | undefined;
37
61
  }, {
38
62
  type: string;
@@ -40,6 +64,9 @@ declare const CapabilitySchema: z.ZodObject<{
40
64
  onBehalfOf: string;
41
65
  };
42
66
  concurrency: number;
67
+ description?: string | undefined;
68
+ inputSchema?: unknown;
69
+ outputSchema?: unknown;
43
70
  leaseTtlMs?: number | undefined;
44
71
  }>;
45
72
  type Capability = z.infer<typeof CapabilitySchema>;
@@ -145,6 +172,9 @@ declare const RegisterFrameSchema: z.ZodObject<{
145
172
  onBehalfOf: string;
146
173
  }>]>;
147
174
  concurrency: z.ZodNumber;
175
+ description: z.ZodOptional<z.ZodString>;
176
+ inputSchema: z.ZodOptional<z.ZodEffects<z.ZodUnknown, unknown, unknown>>;
177
+ outputSchema: z.ZodOptional<z.ZodEffects<z.ZodUnknown, unknown, unknown>>;
148
178
  leaseTtlMs: z.ZodOptional<z.ZodNumber>;
149
179
  }, "strict", z.ZodTypeAny, {
150
180
  type: string;
@@ -152,6 +182,9 @@ declare const RegisterFrameSchema: z.ZodObject<{
152
182
  onBehalfOf: string;
153
183
  };
154
184
  concurrency: number;
185
+ description?: string | undefined;
186
+ inputSchema?: unknown;
187
+ outputSchema?: unknown;
155
188
  leaseTtlMs?: number | undefined;
156
189
  }, {
157
190
  type: string;
@@ -159,6 +192,9 @@ declare const RegisterFrameSchema: z.ZodObject<{
159
192
  onBehalfOf: string;
160
193
  };
161
194
  concurrency: number;
195
+ description?: string | undefined;
196
+ inputSchema?: unknown;
197
+ outputSchema?: unknown;
162
198
  leaseTtlMs?: number | undefined;
163
199
  }>, "many">, {
164
200
  type: string;
@@ -166,6 +202,9 @@ declare const RegisterFrameSchema: z.ZodObject<{
166
202
  onBehalfOf: string;
167
203
  };
168
204
  concurrency: number;
205
+ description?: string | undefined;
206
+ inputSchema?: unknown;
207
+ outputSchema?: unknown;
169
208
  leaseTtlMs?: number | undefined;
170
209
  }[], {
171
210
  type: string;
@@ -173,6 +212,9 @@ declare const RegisterFrameSchema: z.ZodObject<{
173
212
  onBehalfOf: string;
174
213
  };
175
214
  concurrency: number;
215
+ description?: string | undefined;
216
+ inputSchema?: unknown;
217
+ outputSchema?: unknown;
176
218
  leaseTtlMs?: number | undefined;
177
219
  }[]>;
178
220
  }, "strict", z.ZodTypeAny, {
@@ -185,6 +227,9 @@ declare const RegisterFrameSchema: z.ZodObject<{
185
227
  onBehalfOf: string;
186
228
  };
187
229
  concurrency: number;
230
+ description?: string | undefined;
231
+ inputSchema?: unknown;
232
+ outputSchema?: unknown;
188
233
  leaseTtlMs?: number | undefined;
189
234
  }[];
190
235
  }, {
@@ -197,6 +242,9 @@ declare const RegisterFrameSchema: z.ZodObject<{
197
242
  onBehalfOf: string;
198
243
  };
199
244
  concurrency: number;
245
+ description?: string | undefined;
246
+ inputSchema?: unknown;
247
+ outputSchema?: unknown;
200
248
  leaseTtlMs?: number | undefined;
201
249
  }[];
202
250
  }>;
@@ -214,6 +262,9 @@ declare const UpdateCapabilityFrameSchema: z.ZodObject<{
214
262
  onBehalfOf: string;
215
263
  }>]>;
216
264
  concurrency: z.ZodNumber;
265
+ description: z.ZodOptional<z.ZodString>;
266
+ inputSchema: z.ZodOptional<z.ZodEffects<z.ZodUnknown, unknown, unknown>>;
267
+ outputSchema: z.ZodOptional<z.ZodEffects<z.ZodUnknown, unknown, unknown>>;
217
268
  leaseTtlMs: z.ZodOptional<z.ZodNumber>;
218
269
  }, "strict", z.ZodTypeAny, {
219
270
  type: string;
@@ -221,6 +272,9 @@ declare const UpdateCapabilityFrameSchema: z.ZodObject<{
221
272
  onBehalfOf: string;
222
273
  };
223
274
  concurrency: number;
275
+ description?: string | undefined;
276
+ inputSchema?: unknown;
277
+ outputSchema?: unknown;
224
278
  leaseTtlMs?: number | undefined;
225
279
  }, {
226
280
  type: string;
@@ -228,6 +282,9 @@ declare const UpdateCapabilityFrameSchema: z.ZodObject<{
228
282
  onBehalfOf: string;
229
283
  };
230
284
  concurrency: number;
285
+ description?: string | undefined;
286
+ inputSchema?: unknown;
287
+ outputSchema?: unknown;
231
288
  leaseTtlMs?: number | undefined;
232
289
  }>;
233
290
  }, "strict", z.ZodTypeAny, {
@@ -238,6 +295,9 @@ declare const UpdateCapabilityFrameSchema: z.ZodObject<{
238
295
  onBehalfOf: string;
239
296
  };
240
297
  concurrency: number;
298
+ description?: string | undefined;
299
+ inputSchema?: unknown;
300
+ outputSchema?: unknown;
241
301
  leaseTtlMs?: number | undefined;
242
302
  };
243
303
  neuronId: string;
@@ -249,6 +309,9 @@ declare const UpdateCapabilityFrameSchema: z.ZodObject<{
249
309
  onBehalfOf: string;
250
310
  };
251
311
  concurrency: number;
312
+ description?: string | undefined;
313
+ inputSchema?: unknown;
314
+ outputSchema?: unknown;
252
315
  leaseTtlMs?: number | undefined;
253
316
  };
254
317
  neuronId: string;
@@ -384,6 +447,9 @@ declare const ServerToNeuronFrameSchema: z.ZodDiscriminatedUnion<"type", [z.ZodO
384
447
  onBehalfOf: string;
385
448
  }>]>;
386
449
  concurrency: z.ZodNumber;
450
+ description: z.ZodOptional<z.ZodString>;
451
+ inputSchema: z.ZodOptional<z.ZodEffects<z.ZodUnknown, unknown, unknown>>;
452
+ outputSchema: z.ZodOptional<z.ZodEffects<z.ZodUnknown, unknown, unknown>>;
387
453
  leaseTtlMs: z.ZodOptional<z.ZodNumber>;
388
454
  }, "strict", z.ZodTypeAny, {
389
455
  type: string;
@@ -391,6 +457,9 @@ declare const ServerToNeuronFrameSchema: z.ZodDiscriminatedUnion<"type", [z.ZodO
391
457
  onBehalfOf: string;
392
458
  };
393
459
  concurrency: number;
460
+ description?: string | undefined;
461
+ inputSchema?: unknown;
462
+ outputSchema?: unknown;
394
463
  leaseTtlMs?: number | undefined;
395
464
  }, {
396
465
  type: string;
@@ -398,6 +467,9 @@ declare const ServerToNeuronFrameSchema: z.ZodDiscriminatedUnion<"type", [z.ZodO
398
467
  onBehalfOf: string;
399
468
  };
400
469
  concurrency: number;
470
+ description?: string | undefined;
471
+ inputSchema?: unknown;
472
+ outputSchema?: unknown;
401
473
  leaseTtlMs?: number | undefined;
402
474
  }>, "many">;
403
475
  acceptedAt: z.ZodString;
@@ -409,6 +481,9 @@ declare const ServerToNeuronFrameSchema: z.ZodDiscriminatedUnion<"type", [z.ZodO
409
481
  onBehalfOf: string;
410
482
  };
411
483
  concurrency: number;
484
+ description?: string | undefined;
485
+ inputSchema?: unknown;
486
+ outputSchema?: unknown;
412
487
  leaseTtlMs?: number | undefined;
413
488
  }[];
414
489
  sessionId: string;
@@ -421,6 +496,9 @@ declare const ServerToNeuronFrameSchema: z.ZodDiscriminatedUnion<"type", [z.ZodO
421
496
  onBehalfOf: string;
422
497
  };
423
498
  concurrency: number;
499
+ description?: string | undefined;
500
+ inputSchema?: unknown;
501
+ outputSchema?: unknown;
424
502
  leaseTtlMs?: number | undefined;
425
503
  }[];
426
504
  sessionId: string;
@@ -612,7 +690,10 @@ interface HandlerContext {
612
690
  log: NeuronLogger;
613
691
  /**
614
692
  * Send a `progress` frame to the gateway. Non-blocking; safe to call
615
- * many times during a long-running handler.
693
+ * many times during a long-running handler. Frames are sent one at a time
694
+ * in call order, each bounded by a timeout, and the lease's ack or nack
695
+ * waits until they have gone. A cancelled lease drops the frames it has
696
+ * not started sending and nacks at once.
616
697
  */
617
698
  progress(update: {
618
699
  percent?: number;
@@ -637,11 +718,16 @@ interface HandlerContext {
637
718
  interface CapabilityRegistration extends Capability {
638
719
  /** JSON Schema validated against the lease input before invoking the
639
720
  * handler. Mismatch produces a `schema-mismatch` nack and the handler
640
- * is never called. */
721
+ * is never called. This is the authority for inbound validation — the
722
+ * `inputSchema` on the lease frame is ignored (HOL-2913). Omit it and
723
+ * input is not validated client-side at all. Also advertised on the
724
+ * register frame (HOL-2926) so the capability catalog knows the
725
+ * contract. */
641
726
  inputSchema?: JsonSchema;
642
727
  /** JSON Schema validated against the handler's return value. Mismatch
643
728
  * produces a `schema-mismatch` nack and the gateway publishes a failed
644
- * TaskResult. */
729
+ * TaskResult. Same authority as `inputSchema`; note the gateway also
730
+ * validates ack output against its own schema regardless. */
645
731
  outputSchema?: JsonSchema;
646
732
  }
647
733
  /**
@@ -653,6 +739,12 @@ interface CapabilityRegistration extends Capability {
653
739
  interface CapabilityHandleOptions {
654
740
  scope?: Capability['scope'];
655
741
  concurrency?: number;
742
+ /**
743
+ * Overrides the def's `description` in the advertised contract
744
+ * (HOL-2926) — e.g. a deployment-specific wording. Rarely needed; the
745
+ * def's description is used when absent.
746
+ */
747
+ description?: string;
656
748
  /**
657
749
  * Per-capability lease TTL override (HOL-356). Wins over the same
658
750
  * field on the def. See `CapabilityDefInit.leaseTtlMs` for shape;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@holokai/neuron-sdk",
3
- "version": "0.3.0",
3
+ "version": "0.5.0",
4
4
  "description": "SDK for building Holokai neurons — connect to a BigBrain gateway over HTTP+SSE or Electron IPC and execute capability-typed tasks.",
5
5
  "license": "MIT",
6
6
  "author": "Holokai",
@@ -61,8 +61,8 @@
61
61
  "clean": "rm -rf dist",
62
62
  "test": "vitest run && pnpm run check:browser && pnpm run check:no-workspace",
63
63
  "test:watch": "vitest",
64
- "check:browser": "pnpm run build && node scripts/check-browser-build.mjs",
65
- "check:no-workspace": "pnpm run build && node scripts/check-no-workspace-imports.mjs",
64
+ "check:browser": "node scripts/check-browser-build.mjs",
65
+ "check:no-workspace": "node scripts/check-no-workspace-imports.mjs",
66
66
  "lint": "eslint src",
67
67
  "lint:fix": "eslint src --fix",
68
68
  "typecheck": "tsc --noEmit",