@yaklabs-ai/plugin-sdk 0.8.5 → 0.9.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.
package/README.md CHANGED
@@ -13,7 +13,7 @@ it under the name your plugin code actually imports:
13
13
  ```json
14
14
  {
15
15
  "dependencies": {
16
- "@kay/plugin-sdk": "npm:@yaklabs-ai/plugin-sdk@^0.8.5"
16
+ "@kay/plugin-sdk": "npm:@yaklabs-ai/plugin-sdk@^0.9.0"
17
17
  }
18
18
  }
19
19
  ```
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "schemaVersion": 1,
3
3
  "package": "@yaklabs-ai/plugin-sdk",
4
- "version": "0.8.5",
4
+ "version": "0.9.0",
5
5
  "target": "npm",
6
6
  "firstPartyLicense": "MIT",
7
7
  "bundled": [
@@ -2700,6 +2700,24 @@ declare interface UriModule {
2700
2700
  readonly authActions?: UriAuthActionPolicy;
2701
2701
  /** Pure route/payload validation applied before a consequential permission ask. */
2702
2702
  readonly preflight?: UriOperationPreflightPolicy;
2703
+ /**
2704
+ * Structured facts naming the WHOLE consequence of this call, or `undefined` when
2705
+ * the route cannot honestly be described on a one-line approval surface. The module
2706
+ * owns the static action phrase, target resolution, payload decoding and declaration
2707
+ * of covered payload fields and query parameters. Unknown fields cost the summary.
2708
+ * The host owns framing, the whole-quote fit (no elision) and display-safety admission.
2709
+ *
2710
+ * Unlike preflight, this hook is async and may do I/O. Resolve names through `ctx`,
2711
+ * the same dispatch context used by execution, never an ambient or cached account.
2712
+ * The host calls it once before raising the ask, enforces the short `ctx.signal`
2713
+ * deadline and discards late answers. A throw yields no summary and a module-attributed
2714
+ * diagnostic; declining costs a click into the app, never an under-described approval.
2715
+ */
2716
+ describeOperation?(request: {
2717
+ readonly operation: UriOperation;
2718
+ readonly uri: string;
2719
+ readonly payload: unknown;
2720
+ }, ctx: UriResolveContext): Promise<UriOperationDescription | undefined>;
2703
2721
  /**
2704
2722
  * Per-resource observability: does a `format: "observation"` read of THIS
2705
2723
  * uri render source-native material ({@link UriResolveContext.format})?
@@ -2813,6 +2831,22 @@ declare interface UriNormalizeResult {
2813
2831
 
2814
2832
  declare type UriOperation = "help" | "read" | "write" | "edit" | "list" | "search" | "delete";
2815
2833
 
2834
+ declare interface UriOperationDescription {
2835
+ /** Static verb phrase authored by the module. Never interpolated from input. */
2836
+ readonly action: string;
2837
+ /** Human name resolved through the connection that will execute the call. */
2838
+ readonly target: string;
2839
+ /** Model-authored content; the host flattens, budgets, elides and bounds it. */
2840
+ readonly quote?: string;
2841
+ /** What this description accounts for; the host refuses undeclared input. */
2842
+ readonly accounts: {
2843
+ /** The payload actually read by the module, after its own decoding. */
2844
+ readonly payload: unknown;
2845
+ readonly payloadFields: readonly string[];
2846
+ readonly queryParams?: readonly string[];
2847
+ };
2848
+ }
2849
+
2816
2850
  /**
2817
2851
  * Pure, route-aware validation that runs before permission policy can surface an ask.
2818
2852
  *
@@ -2563,6 +2563,24 @@ declare interface UriModule {
2563
2563
  readonly authActions?: UriAuthActionPolicy;
2564
2564
  /** Pure route/payload validation applied before a consequential permission ask. */
2565
2565
  readonly preflight?: UriOperationPreflightPolicy;
2566
+ /**
2567
+ * Structured facts naming the WHOLE consequence of this call, or `undefined` when
2568
+ * the route cannot honestly be described on a one-line approval surface. The module
2569
+ * owns the static action phrase, target resolution, payload decoding and declaration
2570
+ * of covered payload fields and query parameters. Unknown fields cost the summary.
2571
+ * The host owns framing, the whole-quote fit (no elision) and display-safety admission.
2572
+ *
2573
+ * Unlike preflight, this hook is async and may do I/O. Resolve names through `ctx`,
2574
+ * the same dispatch context used by execution, never an ambient or cached account.
2575
+ * The host calls it once before raising the ask, enforces the short `ctx.signal`
2576
+ * deadline and discards late answers. A throw yields no summary and a module-attributed
2577
+ * diagnostic; declining costs a click into the app, never an under-described approval.
2578
+ */
2579
+ describeOperation?(request: {
2580
+ readonly operation: UriOperation;
2581
+ readonly uri: string;
2582
+ readonly payload: unknown;
2583
+ }, ctx: UriResolveContext): Promise<UriOperationDescription | undefined>;
2566
2584
  /**
2567
2585
  * Per-resource observability: does a `format: "observation"` read of THIS
2568
2586
  * uri render source-native material ({@link UriResolveContext.format})?
@@ -2676,6 +2694,22 @@ declare interface UriNormalizeResult {
2676
2694
 
2677
2695
  declare type UriOperation = "help" | "read" | "write" | "edit" | "list" | "search" | "delete";
2678
2696
 
2697
+ declare interface UriOperationDescription {
2698
+ /** Static verb phrase authored by the module. Never interpolated from input. */
2699
+ readonly action: string;
2700
+ /** Human name resolved through the connection that will execute the call. */
2701
+ readonly target: string;
2702
+ /** Model-authored content; the host flattens, budgets, elides and bounds it. */
2703
+ readonly quote?: string;
2704
+ /** What this description accounts for; the host refuses undeclared input. */
2705
+ readonly accounts: {
2706
+ /** The payload actually read by the module, after its own decoding. */
2707
+ readonly payload: unknown;
2708
+ readonly payloadFields: readonly string[];
2709
+ readonly queryParams?: readonly string[];
2710
+ };
2711
+ }
2712
+
2679
2713
  /**
2680
2714
  * Pure, route-aware validation that runs before permission policy can surface an ask.
2681
2715
  *
@@ -4323,6 +4323,24 @@ export declare interface UriModule {
4323
4323
  readonly authActions?: UriAuthActionPolicy;
4324
4324
  /** Pure route/payload validation applied before a consequential permission ask. */
4325
4325
  readonly preflight?: UriOperationPreflightPolicy;
4326
+ /**
4327
+ * Structured facts naming the WHOLE consequence of this call, or `undefined` when
4328
+ * the route cannot honestly be described on a one-line approval surface. The module
4329
+ * owns the static action phrase, target resolution, payload decoding and declaration
4330
+ * of covered payload fields and query parameters. Unknown fields cost the summary.
4331
+ * The host owns framing, the whole-quote fit (no elision) and display-safety admission.
4332
+ *
4333
+ * Unlike preflight, this hook is async and may do I/O. Resolve names through `ctx`,
4334
+ * the same dispatch context used by execution, never an ambient or cached account.
4335
+ * The host calls it once before raising the ask, enforces the short `ctx.signal`
4336
+ * deadline and discards late answers. A throw yields no summary and a module-attributed
4337
+ * diagnostic; declining costs a click into the app, never an under-described approval.
4338
+ */
4339
+ describeOperation?(request: {
4340
+ readonly operation: UriOperation;
4341
+ readonly uri: string;
4342
+ readonly payload: unknown;
4343
+ }, ctx: UriResolveContext): Promise<UriOperationDescription | undefined>;
4326
4344
  /**
4327
4345
  * Per-resource observability: does a `format: "observation"` read of THIS
4328
4346
  * uri render source-native material ({@link UriResolveContext.format})?
@@ -4453,6 +4471,22 @@ export declare class UriNotFoundError extends UriError {
4453
4471
 
4454
4472
  export declare type UriOperation = "help" | "read" | "write" | "edit" | "list" | "search" | "delete";
4455
4473
 
4474
+ export declare interface UriOperationDescription {
4475
+ /** Static verb phrase authored by the module. Never interpolated from input. */
4476
+ readonly action: string;
4477
+ /** Human name resolved through the connection that will execute the call. */
4478
+ readonly target: string;
4479
+ /** Model-authored content; the host flattens, budgets, elides and bounds it. */
4480
+ readonly quote?: string;
4481
+ /** What this description accounts for; the host refuses undeclared input. */
4482
+ readonly accounts: {
4483
+ /** The payload actually read by the module, after its own decoding. */
4484
+ readonly payload: unknown;
4485
+ readonly payloadFields: readonly string[];
4486
+ readonly queryParams?: readonly string[];
4487
+ };
4488
+ }
4489
+
4456
4490
  /**
4457
4491
  * Pure, route-aware validation that runs before permission policy can surface an ask.
4458
4492
  *
package/dist/kay-app.d.ts CHANGED
@@ -1083,18 +1083,15 @@ export declare interface KayAppAutomationArtifactItem {
1083
1083
  readonly moduleId: string;
1084
1084
  /**
1085
1085
  * The authoring session. Required on the wire, and load-bearing rather than
1086
- * decorative: it is the identity a reverse `explainArtifactRevision` call
1087
- * resolves back to, and the session an `app:artifact:output` uri must be
1086
+ * decorative: it is the session an `app:artifact:output` uri must be
1088
1087
  * resolved against to open at all.
1089
1088
  */
1090
1089
  readonly sessionId: string;
1091
1090
  /** Collapsed by precedence: `deleted` > `created` > `updated`. */
1092
1091
  readonly action: "created" | "updated" | "deleted";
1093
1092
  /**
1094
- * One real revision of the group, carrying the action above, so a reverse
1095
- * `explainArtifactRevision` read still resolves from this row. Not
1096
- * necessarily the newest: the projection stores no ordering for the several
1097
- * revisions of one target.
1093
+ * One real revision of the group, carrying the action above. Not
1094
+ * necessarily the newest revision of the target.
1098
1095
  */
1099
1096
  readonly revision: string;
1100
1097
  /** How many revisions this row collapsed. Always at least 1. */
@@ -1238,7 +1235,7 @@ export declare type KayAppAutomationEffectInput = {
1238
1235
  * widening of it: an external resource has no revision, no Kay uri module, and
1239
1236
  * nothing on this machine to re-read.
1240
1237
  *
1241
- * `kind` mirrors the projection's closed external-resource vocabulary and names
1238
+ * `kind` is the run-detail wire's closed external-resource vocabulary and names
1242
1239
  * the host as well as the thing. There is deliberately no `offBranch`: an
1243
1240
  * abandoned transcript branch does not un-open a pull request, so branch
1244
1241
  * membership is never consulted for these facts.
@@ -1361,6 +1358,7 @@ export declare interface KayAppAutomationRunOptions {
1361
1358
 
1362
1359
  export declare type KayAppAutomationRunOutcome = {
1363
1360
  readonly status: "succeeded";
1361
+ readonly summary?: KayAppRunSummary | undefined;
1364
1362
  readonly daemonRunId?: string | undefined;
1365
1363
  /** Present on a script run: which source this run actually executed. */
1366
1364
  readonly script?: {
@@ -1369,11 +1367,12 @@ export declare type KayAppAutomationRunOutcome = {
1369
1367
  } | undefined;
1370
1368
  } | {
1371
1369
  readonly status: "failed";
1370
+ readonly summary?: KayAppRunSummary | undefined;
1372
1371
  readonly reason: "executor_failed" | "permission_denied" | "surface_unavailable" | "target_gone";
1373
1372
  readonly message?: string | undefined;
1374
1373
  } | {
1375
1374
  readonly status: "skipped";
1376
- readonly reason: "already_running" | "binding_inactive" | "circuit_breaker" | "concurrency_capped" | "guard_not_satisfied" | "missed_window";
1375
+ readonly reason: "already_running" | "binding_inactive" | "circuit_breaker" | "concurrency_capped" | "guard_not_satisfied" | "missed_window" | "timer_cancelled";
1377
1376
  } | {
1378
1377
  readonly status: "abandoned";
1379
1378
  readonly reason: "daemon_restart";
@@ -1407,6 +1406,7 @@ export declare interface KayAppAutomations {
1407
1406
  get(id: string, ctx: KayAppAutomationContext): Promise<KayAppAutomationBinding | undefined>;
1408
1407
  create(input: {
1409
1408
  readonly name: string;
1409
+ readonly description?: string;
1410
1410
  readonly condition: KayAppAutomationConditionInput;
1411
1411
  readonly effect: KayAppAutomationEffectInput;
1412
1412
  readonly enabled?: boolean;
@@ -1468,13 +1468,13 @@ export declare interface KayAppAutomations {
1468
1468
  readonly nextCursor?: string;
1469
1469
  }>;
1470
1470
  /**
1471
- * One run's provenance detail (RFC Release 2): the sessions that run drove
1472
- * (direct and child, shared-run marked) and the Git-backed artifact
1473
- * revisions those sessions produced, with explicit projection coverage and
1474
- * gaps. A PUBLIC read like {@link listRuns}: it resolves the binding's
1475
- * actual owner rather than the caller's. Null when no retained run matches
1476
- * `bindingId` + `runId`. Coverage reports `rebuilding`/`partial` honestly
1477
- * while the projection catches up — it never blocks or fabricates.
1471
+ * One run's detail (RFC Release 2): the sessions that run drove (direct and
1472
+ * child, shared-run marked), the artifacts, external resources and skill
1473
+ * suggestions those sessions produced, and explicit coverage and gaps. A
1474
+ * PUBLIC read like {@link listRuns}: it resolves the binding's actual owner
1475
+ * rather than the caller's. Null when no retained run matches `bindingId` +
1476
+ * `runId`. Coverage reports `partial` honestly when some of the run's work
1477
+ * cannot be read — it never blocks or fabricates.
1478
1478
  */
1479
1479
  getRun(bindingId: string, runId: string, ctx: KayAppAutomationContext, options?: KayAppAutomationRunDetailOptions): Promise<KayAppAutomationRunDetail | null>;
1480
1480
  }
@@ -1613,10 +1613,15 @@ export declare interface KayAppConfig {
1613
1613
  * path of the winning file. A JSON-safe twin of the runtime's `KayConfigValueOrigin`
1614
1614
  * (`@kay/product-catalog`) — this SDK cannot import that package, so the shape is re-declared
1615
1615
  * here and an assignability test in `@kay/agent-runtime` pins the two together. The level union
1616
- * is the closed, protocol-owned fold precedence stack (`learned < global < project`).
1616
+ * is the closed, protocol-owned fold precedence stack (`baseline < learned < global < project`).
1617
+ * `"baseline"` names a host-composed, in-memory, build/channel-scoped default with no file
1618
+ * behind it (`KayConfigStoreOptions.baselineDefaults`) — a plugin can still be handed one as a
1619
+ * winner for a FIELD within its own declared section that neither it nor the user ever set
1620
+ * (e.g. hindsight's `handlers.signals`, defaulted on by the host for this release channel), so
1621
+ * `path` for that level is a synthetic label, never a real file path.
1617
1622
  */
1618
1623
  export declare interface KayAppConfigOrigin {
1619
- readonly level: "learned" | "global" | "project";
1624
+ readonly level: "baseline" | "learned" | "global" | "project";
1620
1625
  readonly path: string;
1621
1626
  }
1622
1627
 
@@ -1683,7 +1688,10 @@ export declare interface KayAppContextContributor {
1683
1688
  export declare interface KayAppCorpus {
1684
1689
  /** Enumerate every stored session, newest-first. */
1685
1690
  listSessions(): AsyncIterable<KayAppCorpusSession>;
1686
- /** Stream one session's full entry log oldest→newest; an unknown id yields nothing. */
1691
+ /**
1692
+ * Stream one session's full entry log oldest→newest; an unknown id yields nothing. Treat the
1693
+ * entries as read-only: for a session the daemon holds in memory they are its live objects.
1694
+ */
1687
1695
  readEntries(sessionId: string): AsyncIterable<SessionTreeEntry>;
1688
1696
  /**
1689
1697
  * Read a cheap transcript change marker without loading the entry log. Unknown or deleted
@@ -2452,9 +2460,9 @@ export declare interface KayAppPluginEvents {
2452
2460
  export declare type KayAppProcessingSpeed = "standard" | "fast";
2453
2461
 
2454
2462
  /**
2455
- * A gap reason on the run-detail wire. Adapter-determined codes come from the
2456
- * projection's stored gap vocabulary; the remaining four are derived at query
2457
- * time from current evidence and checkpoint coverage.
2463
+ * A gap reason on the run-detail wire: something about the run's work the
2464
+ * daemon could not establish from its session transcripts. The vocabulary is
2465
+ * closed; a daemon may emit only some of these codes.
2458
2466
  */
2459
2467
  export declare type KayAppProvenanceGapCode = "legacy-run-id-missing" | "mutation-revision-missing" | "partial-git-provenance" | "git-session-stamp-missing"
2460
2468
  /** A run created something off this machine that the transcript cannot name. */
@@ -2537,6 +2545,14 @@ export declare interface KayAppResolvedCredential {
2537
2545
  readonly fields?: Readonly<Record<string, string>>;
2538
2546
  }
2539
2547
 
2548
+ export declare interface KayAppRunSummary {
2549
+ /** One plain-text line, at most 100 characters. */
2550
+ readonly headline: string;
2551
+ /** Optional plain-text explanation, at most 600 characters. */
2552
+ readonly details?: string | undefined;
2553
+ readonly author: "automation" | "kay";
2554
+ }
2555
+
2540
2556
  /**
2541
2557
  * The session provenance vocabulary, as the plugin protocol declares it. These used to be spelled
2542
2558
  * out here because the canonical schemas lived in `@kay/agent-runtime-protocol`, which this
@@ -3006,8 +3022,9 @@ export declare interface KayAppSignalDetector {
3006
3022
  * - `classified`: Jev answered; `answers`, `model`, and `usage` are the vendor's verbatim
3007
3023
  * response, and `stored` says whether the row landed in the durable store.
3008
3024
  * - `unavailable`: Jev could not answer (no key, refused grant, timeout, vendor error, or a
3009
- * malformed response). `reason` names the host's classification; no row is written, so the
3010
- * same input can be observed again later without a conflict.
3025
+ * malformed response), or the host has no signals store at all (`reason: "no-store"`).
3026
+ * `reason` names the host's classification; no row is written, so the same input can be
3027
+ * observed again later without a conflict.
3011
3028
  * - `invalid`: the input breaks the recorded-name grammar (see {@link invalidObservation}), and
3012
3029
  * `reason` says which name and why. The caller's mistake, not the environment's: Jev is never
3013
3030
  * called, no row is written, and the same input is refused again. `detector` and `source`
@@ -3030,7 +3047,11 @@ export declare interface KayAppSignalObservation {
3030
3047
  } | undefined;
3031
3048
  readonly tookMs?: number | undefined;
3032
3049
  readonly reason?: string | undefined;
3033
- /** True when the row landed in the durable store; false when the host composed no store. */
3050
+ /**
3051
+ * True when the row landed in the durable store; false when a composed store's own write
3052
+ * failed after Jev already answered (rare -- a host with no store at all instead answers
3053
+ * `unavailable` with reason `"no-store"`, never reaching `classified`).
3054
+ */
3034
3055
  readonly stored: boolean;
3035
3056
  /** True when this call returned an already-stored row instead of running inference. */
3036
3057
  readonly deduplicated: boolean;
@@ -3531,10 +3552,22 @@ export declare interface KayAppWorkflowContext {
3531
3552
 
3532
3553
  export declare interface KayAppWorkflowDefinition {
3533
3554
  readonly name: string;
3555
+ /** Plain-text purpose, at most 280 characters. */
3556
+ readonly description: string;
3557
+ readonly instructions?: readonly KayAppWorkflowInstruction[];
3558
+ readonly perRunNote?: string;
3534
3559
  readonly trigger: Extract<KayAppAutomationConditionInput, {
3535
3560
  readonly kind: "time";
3536
3561
  }>;
3537
- readonly run: (context: KayAppWorkflowContext) => void | Promise<void>;
3562
+ readonly run: (context: KayAppWorkflowContext) => Promise<{
3563
+ readonly summary: KayAppRunSummary;
3564
+ }>;
3565
+ }
3566
+
3567
+ /** Fail a workflow while retaining its own explanation beside this attempt. */
3568
+ export declare class KayAppWorkflowFailure extends Error {
3569
+ readonly summary: KayAppRunSummary;
3570
+ constructor(summary: Omit<KayAppRunSummary, "author">, options?: ErrorOptions);
3538
3571
  }
3539
3572
 
3540
3573
  export declare interface KayAppWorkflowInspection {
@@ -3548,6 +3581,20 @@ export declare interface KayAppWorkflowInspectOptions {
3548
3581
  readonly limit?: number;
3549
3582
  }
3550
3583
 
3584
+ export declare type KayAppWorkflowInstruction = {
3585
+ readonly label: string;
3586
+ readonly kind: "prompt";
3587
+ readonly text: string;
3588
+ } | {
3589
+ readonly label: string;
3590
+ readonly kind: "agent";
3591
+ readonly agent: KayAppAgentDefinitionRef;
3592
+ } | {
3593
+ readonly label: string;
3594
+ readonly kind: "script";
3595
+ readonly ref: KayAppAutomationScriptRef;
3596
+ };
3597
+
3551
3598
  export declare interface KayAppWorkflows {
3552
3599
  define(localId: string, definition: KayAppWorkflowDefinition): void;
3553
3600
  inspect(localId: string, options?: KayAppWorkflowInspectOptions): Promise<KayAppWorkflowInspection>;
@@ -5412,6 +5459,17 @@ export declare interface UriModule {
5412
5459
  readonly permission?: UriOperationPermissionPolicy;
5413
5460
  /** Pure route/payload validation applied before a consequential permission ask. */
5414
5461
  readonly preflight?: UriOperationPreflightPolicy;
5462
+ /**
5463
+ * Supply structured action facts and explicit input coverage for a one-line approval.
5464
+ * The host composes and admits the line; see the protocol's UriModule contract.
5465
+ * Names must be resolved through this call's dispatch context. The host enforces
5466
+ * `ctx.signal`'s deadline and treats a throw or late answer as no summary.
5467
+ */
5468
+ describeOperation?(request: {
5469
+ readonly operation: UriOperation;
5470
+ readonly uri: string;
5471
+ readonly payload: unknown;
5472
+ }, ctx: UriResolveContext): Promise<UriOperationDescription | undefined>;
5415
5473
  /**
5416
5474
  * Set false when the generic write tool must reject `source` copies before
5417
5475
  * fetching the source. Inline `content` writes remain available.
@@ -5584,6 +5642,22 @@ export declare class UriNotFoundError extends UriError {
5584
5642
 
5585
5643
  declare type UriOperation = "help" | "read" | "write" | "edit" | "list" | "search" | "delete";
5586
5644
 
5645
+ declare interface UriOperationDescription {
5646
+ /** Static verb phrase authored by the module. Never interpolated from input. */
5647
+ readonly action: string;
5648
+ /** Human name resolved through the connection that will execute the call. */
5649
+ readonly target: string;
5650
+ /** Model-authored content; the host flattens, budgets, elides and bounds it. */
5651
+ readonly quote?: string;
5652
+ /** What this description accounts for; the host refuses undeclared input. */
5653
+ readonly accounts: {
5654
+ /** The payload actually read by the module, after its own decoding. */
5655
+ readonly payload: unknown;
5656
+ readonly payloadFields: readonly string[];
5657
+ readonly queryParams?: readonly string[];
5658
+ };
5659
+ }
5660
+
5587
5661
  declare interface UriOperationPermissionClassification {
5588
5662
  /**
5589
5663
  * The operation's real effect. The permission classifier only accepts a
package/dist/kay-app.js CHANGED
@@ -387,6 +387,16 @@ function transcriptRoleLabel(role) {
387
387
  return role === "user" ? "User" : "Assistant";
388
388
  }
389
389
 
390
+ // packages/plugin-sdk/dist/kay-app/workflows.js
391
+ var KayAppWorkflowFailure = class extends Error {
392
+ summary;
393
+ constructor(summary, options) {
394
+ super(summary.details ?? summary.headline, options);
395
+ this.name = "KayAppWorkflowFailure";
396
+ this.summary = { ...summary, author: "automation" };
397
+ }
398
+ };
399
+
390
400
  // packages/plugin-protocol/dist/app-data.js
391
401
  var KAY_APP_DATA_SNAPSHOT_MAX_BYTES = 16 * 1024 * 1024;
392
402
  var KAY_APP_DATA_CHANGE_MAX_BYTES = 256 * 1024;
@@ -406,6 +416,7 @@ var KAY_APP_AUTOMATION_CONDITION_KINDS = [
406
416
  export {
407
417
  KAY_APP_AUTOMATION_CONDITION_KINDS,
408
418
  KAY_APP_DATA_CHANGE_MAX_BYTES,
419
+ KayAppWorkflowFailure,
409
420
  MAX_CHOICE_LABELS,
410
421
  SIGNAL_TIME_MAX_MS,
411
422
  UriConflictError,
package/dist/signals.d.ts CHANGED
@@ -67,8 +67,9 @@ export declare interface KayAppSignalDetector {
67
67
  * - `classified`: Jev answered; `answers`, `model`, and `usage` are the vendor's verbatim
68
68
  * response, and `stored` says whether the row landed in the durable store.
69
69
  * - `unavailable`: Jev could not answer (no key, refused grant, timeout, vendor error, or a
70
- * malformed response). `reason` names the host's classification; no row is written, so the
71
- * same input can be observed again later without a conflict.
70
+ * malformed response), or the host has no signals store at all (`reason: "no-store"`).
71
+ * `reason` names the host's classification; no row is written, so the same input can be
72
+ * observed again later without a conflict.
72
73
  * - `invalid`: the input breaks the recorded-name grammar (see {@link invalidObservation}), and
73
74
  * `reason` says which name and why. The caller's mistake, not the environment's: Jev is never
74
75
  * called, no row is written, and the same input is refused again. `detector` and `source`
@@ -91,7 +92,11 @@ export declare interface KayAppSignalObservation {
91
92
  } | undefined;
92
93
  readonly tookMs?: number | undefined;
93
94
  readonly reason?: string | undefined;
94
- /** True when the row landed in the durable store; false when the host composed no store. */
95
+ /**
96
+ * True when the row landed in the durable store; false when a composed store's own write
97
+ * failed after Jev already answered (rare -- a host with no store at all instead answers
98
+ * `unavailable` with reason `"no-store"`, never reaching `classified`).
99
+ */
95
100
  readonly stored: boolean;
96
101
  /** True when this call returned an already-stored row instead of running inference. */
97
102
  readonly deduplicated: boolean;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yaklabs-ai/plugin-sdk",
3
- "version": "0.8.5",
3
+ "version": "0.9.0",
4
4
  "description": "The Kay plugin SDK — types and helpers for authoring a Kay directory plugin.",
5
5
  "author": "YakLabs",
6
6
  "type": "module",