@genesislcap/ai-assistant 15.40.0 → 15.41.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.
Files changed (73) hide show
  1. package/dist/ai-assistant.api.json +409 -9
  2. package/dist/ai-assistant.d.ts +196 -6
  3. package/dist/chat-driver.cjs +567 -134
  4. package/dist/chat-driver.cjs.map +3 -3
  5. package/dist/chat-driver.mjs +560 -134
  6. package/dist/chat-driver.mjs.map +3 -3
  7. package/dist/custom-elements.json +1258 -687
  8. package/dist/dts/chat-driver-node.d.ts +2 -2
  9. package/dist/dts/chat-driver-node.d.ts.map +1 -1
  10. package/dist/dts/components/ai-driver/ai-driver.d.ts +4 -0
  11. package/dist/dts/components/ai-driver/ai-driver.d.ts.map +1 -1
  12. package/dist/dts/components/chat-driver/chat-driver.d.ts +121 -4
  13. package/dist/dts/components/chat-driver/chat-driver.d.ts.map +1 -1
  14. package/dist/dts/components/chat-driver/interaction-controller.d.ts.map +1 -1
  15. package/dist/dts/components/chat-driver/turn-failures.d.ts +7 -1
  16. package/dist/dts/components/chat-driver/turn-failures.d.ts.map +1 -1
  17. package/dist/dts/components/orchestrating-driver/orchestrating-driver.d.ts +3 -1
  18. package/dist/dts/components/orchestrating-driver/orchestrating-driver.d.ts.map +1 -1
  19. package/dist/dts/genesis/index.d.ts +2 -1
  20. package/dist/dts/genesis/index.d.ts.map +1 -1
  21. package/dist/dts/genesis/register-genesis-assistant.d.ts +21 -0
  22. package/dist/dts/genesis/register-genesis-assistant.d.ts.map +1 -1
  23. package/dist/dts/genesis/review-model.d.ts +40 -0
  24. package/dist/dts/genesis/review-model.d.ts.map +1 -1
  25. package/dist/dts/genesis/review-payload.d.ts +47 -0
  26. package/dist/dts/genesis/review-payload.d.ts.map +1 -0
  27. package/dist/dts/genesis/write-review/write-review.d.ts +75 -11
  28. package/dist/dts/genesis/write-review/write-review.d.ts.map +1 -1
  29. package/dist/dts/genesis/write-review/write-review.styles.d.ts.map +1 -1
  30. package/dist/dts/genesis/write-review/write-review.template.d.ts.map +1 -1
  31. package/dist/dts/genesis/write-tools.d.ts +49 -0
  32. package/dist/dts/genesis/write-tools.d.ts.map +1 -1
  33. package/dist/dts/genesis/write-turn.d.ts +114 -0
  34. package/dist/dts/genesis/write-turn.d.ts.map +1 -0
  35. package/dist/dts/index.d.ts +2 -0
  36. package/dist/dts/index.d.ts.map +1 -1
  37. package/dist/dts/main/budget-controller.d.ts +12 -2
  38. package/dist/dts/main/budget-controller.d.ts.map +1 -1
  39. package/dist/dts/main/main.d.ts +33 -6
  40. package/dist/dts/main/main.d.ts.map +1 -1
  41. package/dist/dts/react.d.ts +2 -1
  42. package/dist/dts/state/ai-assistant-slice.d.ts +15 -0
  43. package/dist/dts/state/ai-assistant-slice.d.ts.map +1 -1
  44. package/dist/dts/state/session-store.d.ts +1 -0
  45. package/dist/dts/state/session-store.d.ts.map +1 -1
  46. package/dist/dts/suggestions/generate-suggestions.d.ts.map +1 -1
  47. package/dist/dts/utils/history-transform.d.ts.map +1 -1
  48. package/dist/esm/chat-driver-node.js +5 -1
  49. package/dist/esm/components/chat-driver/chat-driver.js +431 -92
  50. package/dist/esm/components/chat-driver/interaction-controller.js +25 -2
  51. package/dist/esm/components/chat-driver/turn-failures.js +9 -2
  52. package/dist/esm/components/orchestrating-driver/orchestrating-driver.js +30 -4
  53. package/dist/esm/genesis/register-genesis-assistant.js +38 -2
  54. package/dist/esm/genesis/review-model.js +47 -1
  55. package/dist/esm/genesis/review-payload.js +18 -0
  56. package/dist/esm/genesis/write-review/write-review.js +225 -40
  57. package/dist/esm/genesis/write-review/write-review.styles.js +18 -0
  58. package/dist/esm/genesis/write-review/write-review.template.js +46 -22
  59. package/dist/esm/genesis/write-tools.js +321 -49
  60. package/dist/esm/genesis/write-turn.js +110 -0
  61. package/dist/esm/main/budget-controller.js +39 -5
  62. package/dist/esm/main/main.js +45 -23
  63. package/dist/esm/state/ai-assistant-slice.js +11 -1
  64. package/dist/esm/state/debug-event-log.js +1 -1
  65. package/dist/esm/suggestions/generate-suggestions.js +4 -1
  66. package/dist/esm/utils/history-transform.js +7 -1
  67. package/dist/react.cjs +14 -2
  68. package/dist/react.mjs +14 -2
  69. package/docs/genesis.md +120 -3
  70. package/docs/migration-GENC-1464.md +12 -2
  71. package/docs/sub_agent.md +21 -4
  72. package/package.json +18 -18
  73. package/scripts/smoke-chat-driver-node.mjs +15 -0
@@ -3237,7 +3237,7 @@
3237
3237
  {
3238
3238
  "kind": "MethodSignature",
3239
3239
  "canonicalReference": "@genesislcap/ai-assistant!AiDriver#continueFromHistory:member(1)",
3240
- "docComment": "/**\n * Continue the tool loop from the current history without appending a new user message. Used by `OrchestratingDriver` on agent handoffs — the handoff context is already in history; `transientPrimer` is injected as an invisible one-shot message for this call only.\n */\n",
3240
+ "docComment": "/**\n * Continue the tool loop from the current history without appending a new user message. Used by `OrchestratingDriver` on agent handoffs — the handoff context is already in history; `transientPrimer` is injected as an invisible one-shot message for this call only.\n *\n * A handoff continues the same user message, so tool handlers keep its `turnSignal`. A continuation after the user stopped that message is not part of it, and gets a fresh one.\n */\n",
3241
3241
  "excerptTokens": [
3242
3242
  {
3243
3243
  "kind": "Content",
@@ -5268,6 +5268,32 @@
5268
5268
  "endIndex": 2
5269
5269
  }
5270
5270
  },
5271
+ {
5272
+ "kind": "TypeAlias",
5273
+ "canonicalReference": "@genesislcap/ai-assistant!BlockedCause:type",
5274
+ "docComment": "/**\n * Why the assistant is blocked, as the composer placeholder needs to know it (GENC-1611).\n *\n * @beta\n */\n",
5275
+ "excerptTokens": [
5276
+ {
5277
+ "kind": "Content",
5278
+ "text": "export type BlockedCause = "
5279
+ },
5280
+ {
5281
+ "kind": "Content",
5282
+ "text": "'budget' | 'other'"
5283
+ },
5284
+ {
5285
+ "kind": "Content",
5286
+ "text": ";"
5287
+ }
5288
+ ],
5289
+ "fileUrlPath": "src/state/ai-assistant-slice.ts",
5290
+ "releaseTag": "Beta",
5291
+ "name": "BlockedCause",
5292
+ "typeTokenRange": {
5293
+ "startIndex": 1,
5294
+ "endIndex": 2
5295
+ }
5296
+ },
5271
5297
  {
5272
5298
  "kind": "TypeAlias",
5273
5299
  "canonicalReference": "@genesislcap/ai-assistant!CachePolicyInput:type",
@@ -5476,7 +5502,7 @@
5476
5502
  {
5477
5503
  "kind": "Method",
5478
5504
  "canonicalReference": "@genesislcap/ai-assistant!ChatDriver#cancel:member(1)",
5479
- "docComment": "/**\n * Stop the current turn (user \"stop\" button). Aborts the in-flight provider request immediately; if a tool is mid-execution it runs to completion and the loop bails at the next boundary (tools are atomic). No-op when idle. The driver stays usable for the next message.\n */\n",
5505
+ "docComment": "/**\n * Stop the current turn (user \"stop\" button). Aborts the in-flight provider request immediately; if a tool is mid-execution it runs to completion and the loop bails at the next boundary (tools are atomic). When idle it only ends the message (see below) and appends nothing. The driver stays usable for the next message.\n */\n",
5480
5506
  "excerptTokens": [
5481
5507
  {
5482
5508
  "kind": "Content",
@@ -6281,6 +6307,15 @@
6281
6307
  "text": "ProviderRefusedDetail",
6282
6308
  "canonicalReference": "@genesislcap/ai-assistant!~ProviderRefusedDetail:type"
6283
6309
  },
6310
+ {
6311
+ "kind": "Content",
6312
+ "text": ";\n aiServiceError?: "
6313
+ },
6314
+ {
6315
+ "kind": "Reference",
6316
+ "text": "AIServiceWall",
6317
+ "canonicalReference": "@genesislcap/ai-assistant!~AIServiceWall:type"
6318
+ },
6284
6319
  {
6285
6320
  "kind": "Content",
6286
6321
  "text": ";\n } | undefined"
@@ -6293,7 +6328,7 @@
6293
6328
  "isStatic": false,
6294
6329
  "returnTypeTokenRange": {
6295
6330
  "startIndex": 1,
6296
- "endIndex": 8
6331
+ "endIndex": 10
6297
6332
  },
6298
6333
  "releaseTag": "Public",
6299
6334
  "isProtected": false,
@@ -6740,6 +6775,73 @@
6740
6775
  "isAbstract": false,
6741
6776
  "name": "recordExternalCost"
6742
6777
  },
6778
+ {
6779
+ "kind": "Method",
6780
+ "canonicalReference": "@genesislcap/ai-assistant!ChatDriver#reportAIServiceError:member(1)",
6781
+ "docComment": "/**\n * A terminal AI service error hit **outside** the tool loop — `OrchestratingDriver`'s classification phase (GENC-1611). The same log line, debug-log entry, sentence and result as the in-loop branch.\n *\n * @param pendingUserMessage - the user's message when it has NOT been appended yet, for the reason `reportBudgetExhausted` gives.\n */\n",
6782
+ "excerptTokens": [
6783
+ {
6784
+ "kind": "Content",
6785
+ "text": "reportAIServiceError(e: "
6786
+ },
6787
+ {
6788
+ "kind": "Reference",
6789
+ "text": "AIServiceError",
6790
+ "canonicalReference": "@genesislcap/foundation-ai!AIServiceError:class"
6791
+ },
6792
+ {
6793
+ "kind": "Content",
6794
+ "text": ", pendingUserMessage?: "
6795
+ },
6796
+ {
6797
+ "kind": "Reference",
6798
+ "text": "ChatMessage",
6799
+ "canonicalReference": "@genesislcap/foundation-ai!ChatMessage:interface"
6800
+ },
6801
+ {
6802
+ "kind": "Content",
6803
+ "text": "): "
6804
+ },
6805
+ {
6806
+ "kind": "Reference",
6807
+ "text": "ChatDriverResult",
6808
+ "canonicalReference": "@genesislcap/foundation-ai!ChatDriverResult:type"
6809
+ },
6810
+ {
6811
+ "kind": "Content",
6812
+ "text": ";"
6813
+ }
6814
+ ],
6815
+ "isStatic": false,
6816
+ "returnTypeTokenRange": {
6817
+ "startIndex": 5,
6818
+ "endIndex": 6
6819
+ },
6820
+ "releaseTag": "Public",
6821
+ "isProtected": false,
6822
+ "overloadIndex": 1,
6823
+ "parameters": [
6824
+ {
6825
+ "parameterName": "e",
6826
+ "parameterTypeTokenRange": {
6827
+ "startIndex": 1,
6828
+ "endIndex": 2
6829
+ },
6830
+ "isOptional": false
6831
+ },
6832
+ {
6833
+ "parameterName": "pendingUserMessage",
6834
+ "parameterTypeTokenRange": {
6835
+ "startIndex": 3,
6836
+ "endIndex": 4
6837
+ },
6838
+ "isOptional": true
6839
+ }
6840
+ ],
6841
+ "isOptional": false,
6842
+ "isAbstract": false,
6843
+ "name": "reportAIServiceError"
6844
+ },
6743
6845
  {
6744
6846
  "kind": "Method",
6745
6847
  "canonicalReference": "@genesislcap/ai-assistant!ChatDriver#reportBudgetExhausted:member(1)",
@@ -7433,6 +7535,56 @@
7433
7535
  "endIndex": 2
7434
7536
  }
7435
7537
  },
7538
+ {
7539
+ "kind": "PropertySignature",
7540
+ "canonicalReference": "@genesislcap/ai-assistant!ChatDriverConfig#aiServiceErrorMessages:member",
7541
+ "docComment": "/**\n * Replaces the transcript sentence for any of the AI service's error codes or access refusals (GENC-1611) — see `DEFAULT_AI_SERVICE_ERROR_MESSAGES`. A code with no entry keeps the default.\n */\n",
7542
+ "excerptTokens": [
7543
+ {
7544
+ "kind": "Content",
7545
+ "text": "aiServiceErrorMessages?: "
7546
+ },
7547
+ {
7548
+ "kind": "Reference",
7549
+ "text": "Partial",
7550
+ "canonicalReference": "!Partial:type"
7551
+ },
7552
+ {
7553
+ "kind": "Content",
7554
+ "text": "<"
7555
+ },
7556
+ {
7557
+ "kind": "Reference",
7558
+ "text": "Record",
7559
+ "canonicalReference": "!Record:type"
7560
+ },
7561
+ {
7562
+ "kind": "Content",
7563
+ "text": "<"
7564
+ },
7565
+ {
7566
+ "kind": "Reference",
7567
+ "text": "AIServiceRefusal",
7568
+ "canonicalReference": "@genesislcap/foundation-ai!AIServiceRefusal:type"
7569
+ },
7570
+ {
7571
+ "kind": "Content",
7572
+ "text": ", string>>"
7573
+ },
7574
+ {
7575
+ "kind": "Content",
7576
+ "text": ";"
7577
+ }
7578
+ ],
7579
+ "isReadonly": false,
7580
+ "isOptional": true,
7581
+ "releaseTag": "Beta",
7582
+ "name": "aiServiceErrorMessages",
7583
+ "propertyTypeTokenRange": {
7584
+ "startIndex": 1,
7585
+ "endIndex": 7
7586
+ }
7587
+ },
7436
7588
  {
7437
7589
  "kind": "PropertySignature",
7438
7590
  "canonicalReference": "@genesislcap/ai-assistant!ChatDriverConfig#budgetExhaustedMessage:member",
@@ -9379,6 +9531,59 @@
9379
9531
  "isProtected": false,
9380
9532
  "isAbstract": false
9381
9533
  },
9534
+ {
9535
+ "kind": "Property",
9536
+ "canonicalReference": "@genesislcap/ai-assistant!FoundationAiAssistant#aiServiceErrorMessages:member",
9537
+ "docComment": "/**\n * Replaces the transcript sentence shown when the app's AI service refuses a request with one of `AI_SERVICE_ERROR_CODES`, or its router with one of `AI_SERVICE_ACCESS_REFUSALS` (GENC-1611), per code; a code with no entry keeps `DEFAULT_AI_SERVICE_ERROR_MESSAGES`. Read when the driver is created, so set it before the element connects.\n */\n",
9538
+ "excerptTokens": [
9539
+ {
9540
+ "kind": "Content",
9541
+ "text": "aiServiceErrorMessages?: "
9542
+ },
9543
+ {
9544
+ "kind": "Reference",
9545
+ "text": "Partial",
9546
+ "canonicalReference": "!Partial:type"
9547
+ },
9548
+ {
9549
+ "kind": "Content",
9550
+ "text": "<"
9551
+ },
9552
+ {
9553
+ "kind": "Reference",
9554
+ "text": "Record",
9555
+ "canonicalReference": "!Record:type"
9556
+ },
9557
+ {
9558
+ "kind": "Content",
9559
+ "text": "<"
9560
+ },
9561
+ {
9562
+ "kind": "Reference",
9563
+ "text": "AIServiceRefusal",
9564
+ "canonicalReference": "@genesislcap/foundation-ai!AIServiceRefusal:type"
9565
+ },
9566
+ {
9567
+ "kind": "Content",
9568
+ "text": ", string>>"
9569
+ },
9570
+ {
9571
+ "kind": "Content",
9572
+ "text": ";"
9573
+ }
9574
+ ],
9575
+ "isReadonly": false,
9576
+ "isOptional": true,
9577
+ "releaseTag": "Beta",
9578
+ "name": "aiServiceErrorMessages",
9579
+ "propertyTypeTokenRange": {
9580
+ "startIndex": 1,
9581
+ "endIndex": 7
9582
+ },
9583
+ "isStatic": false,
9584
+ "isProtected": false,
9585
+ "isAbstract": false
9586
+ },
9382
9587
  {
9383
9588
  "kind": "Property",
9384
9589
  "canonicalReference": "@genesislcap/ai-assistant!FoundationAiAssistant#appSettingsProvider:member",
@@ -9613,7 +9818,7 @@
9613
9818
  {
9614
9819
  "kind": "Property",
9615
9820
  "canonicalReference": "@genesislcap/ai-assistant!FoundationAiAssistant#blocked:member",
9616
- "docComment": "/**\n * Whether the assistant is blocked by a backend condition and cannot send — today, an exhausted AI-spend budget (GENC-1464). While true the composer is disabled, `send`/`submitMessage` refuse, suggestions stop being fetched, and a persistent banner (`part=\"blocked-banner\"`) sits above the composer explaining why. The transcript stays visible and scrollable throughout — unlike `compacting` and `restoring`, this does not replace the conversation.\n *\n * **Latched.** Nothing in the element clears it: not a new turn, not \"Clear\" / \"New chat\", not a pop-in/out. It stays set until the host writes `false` — because nothing the user can do inside the assistant refills a budget. Hosts typically set it from their own pre-flight budget check on mount, and clear it once a later check shows headroom again.\n *\n * The driver also latches it automatically when a turn ends with the `'budget-exhausted'` failure reason — off the `tool-loop-end` activity bus (which also covers a sub-agent wall, a turn this element did not start, and an element swapped in mid-turn) and off the driver's return value (which covers a wall hit during multi-agent classification, where no tool loop ran and so no bus event fires). So a host that does no pre-flight at all still gets a correct locked UI the moment the first 402 lands. The bus topic is tab-scoped, so a wall hit in a popped-out window latches the main window too — correct for a shared spend cap.\n *\n * **Lifetime — read this before relying on it as your source of truth.** The latch is in-memory and per-`stateKey`:\n *\n * - It does **not** survive `switchSession`. Switching away tears the outgoing session's store down entirely, so switching back yields a fresh, unblocked store. - It does **not** survive a page reload. It is deliberately absent from the persisted session snapshot: the snapshot is long-lived, so a persisted latch would outlive an out-of-band budget raise with no in-element way to clear it — a stale lock is worse than re-deriving the state.\n *\n * The durable source of truth is therefore the **host's pre-flight**, which should run on mount and on every session switch. See `docs/migration-GENC-1464.md` §\"How to adopt\", Option B.\n *\n * @beta\n */\n",
9821
+ "docComment": "/**\n * Whether the assistant is blocked by a backend condition and cannot send — today, an exhausted AI-spend budget (GENC-1464). While true the composer is disabled, `send`/`submitMessage` refuse, suggestions stop being fetched, and a persistent banner (`part=\"blocked-banner\"`) sits above the composer explaining why. The transcript stays visible and scrollable throughout — unlike `compacting` and `restoring`, this does not replace the conversation.\n *\n * **Latched.** Nothing in the element clears it: not a new turn, not \"Clear\" / \"New chat\", not a pop-in/out. It stays set until the host writes `false` — because nothing the user can do inside the assistant refills a budget. Hosts typically set it from their own pre-flight budget check on mount, and clear it once a later check shows headroom again. Such a host should use `setBlocked(true, reason, { cause: 'budget' })`: a plain `blocked = true` is taken for a budget wall only while per-vendor budget walls cover every vendor the assistant can reach (GENC-1611).\n *\n * The driver also latches it automatically when a turn ends with the `'budget-exhausted'` failure reason — off the `tool-loop-end` activity bus (which also covers a sub-agent wall, a turn this element did not start, and an element swapped in mid-turn) and off the driver's return value (which covers a wall hit during multi-agent classification, where no tool loop ran and so no bus event fires). So a host that does no pre-flight at all still gets a correct locked UI the moment the first 402 lands. The bus topic is tab-scoped, so a wall hit in a popped-out window latches the main window too — correct for a shared spend cap.\n *\n * **Lifetime — read this before relying on it as your source of truth.** The latch is in-memory and per-`stateKey`:\n *\n * - It does **not** survive `switchSession`. Switching away tears the outgoing session's store down entirely, so switching back yields a fresh, unblocked store. - It does **not** survive a page reload. It is deliberately absent from the persisted session snapshot: the snapshot is long-lived, so a persisted latch would outlive an out-of-band budget raise with no in-element way to clear it — a stale lock is worse than re-deriving the state.\n *\n * The durable source of truth is therefore the **host's pre-flight**, which should run on mount and on every session switch. See `docs/migration-GENC-1464.md` §\"How to adopt\", Option B.\n *\n * @beta\n */\n",
9617
9822
  "excerptTokens": [
9618
9823
  {
9619
9824
  "kind": "Content",
@@ -14235,7 +14440,7 @@
14235
14440
  {
14236
14441
  "kind": "Method",
14237
14442
  "canonicalReference": "@genesislcap/ai-assistant!FoundationAiAssistant#setBlocked:member(1)",
14238
- "docComment": "/**\n * Block or unblock the assistant, optionally with custom banner copy. Equivalent to the {@link FoundationAiAssistant.blocked} setter, plus the reason in one atomic write.\n *\n * Blocking writes the **vendor-agnostic** block — what a host with one budget pot means — and does not populate {@link FoundationAiAssistant.blockedVendors}. Unblocking clears the per-vendor walls as well, so a host asserting \"the wall is gone\" after its own pre-flight cannot be silently overruled by a driver latch it never saw.\n *\n * @beta\n */\n",
14443
+ "docComment": "/**\n * Block or unblock the assistant, optionally with custom banner copy. Equivalent to the {@link FoundationAiAssistant.blocked} setter, plus the reason in one atomic write.\n *\n * Blocking writes the **vendor-agnostic** block and does not populate {@link FoundationAiAssistant.blockedVendors}. Unblocking clears the per-vendor walls as well, so a host asserting \"the wall is gone\" after its own pre-flight cannot be silently overruled by a driver latch it never saw.\n *\n * `options.cause` says why (GENC-1611). Pass `'budget'` for a spend wall, so the composer reads \"AI usage limit reached\"; any other block reads \"Assistant unavailable\". Omitted, a block keeps the cause it already has, and a new one reads as a budget wall only while per-vendor budget walls cover every vendor the assistant can reach.\n *\n * @beta\n */\n",
14239
14444
  "excerptTokens": [
14240
14445
  {
14241
14446
  "kind": "Content",
@@ -14253,6 +14458,23 @@
14253
14458
  "kind": "Content",
14254
14459
  "text": "string | null"
14255
14460
  },
14461
+ {
14462
+ "kind": "Content",
14463
+ "text": ", options?: "
14464
+ },
14465
+ {
14466
+ "kind": "Content",
14467
+ "text": "{\n cause?: "
14468
+ },
14469
+ {
14470
+ "kind": "Reference",
14471
+ "text": "BlockedCause",
14472
+ "canonicalReference": "@genesislcap/ai-assistant!BlockedCause:type"
14473
+ },
14474
+ {
14475
+ "kind": "Content",
14476
+ "text": ";\n }"
14477
+ },
14256
14478
  {
14257
14479
  "kind": "Content",
14258
14480
  "text": "): "
@@ -14268,8 +14490,8 @@
14268
14490
  ],
14269
14491
  "isStatic": false,
14270
14492
  "returnTypeTokenRange": {
14271
- "startIndex": 5,
14272
- "endIndex": 6
14493
+ "startIndex": 9,
14494
+ "endIndex": 10
14273
14495
  },
14274
14496
  "releaseTag": "Beta",
14275
14497
  "isProtected": false,
@@ -14290,6 +14512,14 @@
14290
14512
  "endIndex": 4
14291
14513
  },
14292
14514
  "isOptional": true
14515
+ },
14516
+ {
14517
+ "parameterName": "options",
14518
+ "parameterTypeTokenRange": {
14519
+ "startIndex": 5,
14520
+ "endIndex": 8
14521
+ },
14522
+ "isOptional": true
14293
14523
  }
14294
14524
  ],
14295
14525
  "isOptional": false,
@@ -16976,6 +17206,78 @@
16976
17206
  "endIndex": 2
16977
17207
  }
16978
17208
  },
17209
+ {
17210
+ "kind": "Interface",
17211
+ "canonicalReference": "@genesislcap/ai-assistant!GenesisChangeRequest:interface",
17212
+ "docComment": "/**\n * What the user sends with \"Ask for changes\".\n *\n * @beta\n */\n",
17213
+ "excerptTokens": [
17214
+ {
17215
+ "kind": "Content",
17216
+ "text": "export interface GenesisChangeRequest "
17217
+ }
17218
+ ],
17219
+ "fileUrlPath": "src/genesis/review-payload.ts",
17220
+ "releaseTag": "Beta",
17221
+ "name": "GenesisChangeRequest",
17222
+ "preserveMemberOrder": false,
17223
+ "members": [
17224
+ {
17225
+ "kind": "PropertySignature",
17226
+ "canonicalReference": "@genesislcap/ai-assistant!GenesisChangeRequest#changes:member",
17227
+ "docComment": "/**\n * What the user typed: the change they want made before they will approve.\n */\n",
17228
+ "excerptTokens": [
17229
+ {
17230
+ "kind": "Content",
17231
+ "text": "changes: "
17232
+ },
17233
+ {
17234
+ "kind": "Content",
17235
+ "text": "string"
17236
+ },
17237
+ {
17238
+ "kind": "Content",
17239
+ "text": ";"
17240
+ }
17241
+ ],
17242
+ "isReadonly": false,
17243
+ "isOptional": false,
17244
+ "releaseTag": "Beta",
17245
+ "name": "changes",
17246
+ "propertyTypeTokenRange": {
17247
+ "startIndex": 1,
17248
+ "endIndex": 2
17249
+ }
17250
+ },
17251
+ {
17252
+ "kind": "PropertySignature",
17253
+ "canonicalReference": "@genesislcap/ai-assistant!GenesisChangeRequest#rowsTicked:member",
17254
+ "docComment": "/**\n * The rows the user had ticked when they asked, by the review's own row indexes. Context for the next proposal, and NOT an approval: nothing is written on a change request.\n */\n",
17255
+ "excerptTokens": [
17256
+ {
17257
+ "kind": "Content",
17258
+ "text": "rowsTicked?: "
17259
+ },
17260
+ {
17261
+ "kind": "Content",
17262
+ "text": "number[]"
17263
+ },
17264
+ {
17265
+ "kind": "Content",
17266
+ "text": ";"
17267
+ }
17268
+ ],
17269
+ "isReadonly": false,
17270
+ "isOptional": true,
17271
+ "releaseTag": "Beta",
17272
+ "name": "rowsTicked",
17273
+ "propertyTypeTokenRange": {
17274
+ "startIndex": 1,
17275
+ "endIndex": 2
17276
+ }
17277
+ }
17278
+ ],
17279
+ "extendsTokenRanges": []
17280
+ },
16979
17281
  {
16980
17282
  "kind": "Variable",
16981
17283
  "canonicalReference": "@genesislcap/ai-assistant!genesisIconSvg:var",
@@ -17003,6 +17305,77 @@
17003
17305
  "endIndex": 0
17004
17306
  }
17005
17307
  },
17308
+ {
17309
+ "kind": "TypeAlias",
17310
+ "canonicalReference": "@genesislcap/ai-assistant!GenesisReviewPayload:type",
17311
+ "docComment": "/**\n * What the write review resolves with: the chosen row indexes on an approval, a change request when the user asks for changes, nothing at all on a denial.\n *\n * @beta\n */\n",
17312
+ "excerptTokens": [
17313
+ {
17314
+ "kind": "Content",
17315
+ "text": "export type GenesisReviewPayload = "
17316
+ },
17317
+ {
17318
+ "kind": "Content",
17319
+ "text": "number[] | "
17320
+ },
17321
+ {
17322
+ "kind": "Reference",
17323
+ "text": "GenesisChangeRequest",
17324
+ "canonicalReference": "@genesislcap/ai-assistant!GenesisChangeRequest:interface"
17325
+ },
17326
+ {
17327
+ "kind": "Content",
17328
+ "text": ";"
17329
+ }
17330
+ ],
17331
+ "fileUrlPath": "src/genesis/review-payload.ts",
17332
+ "releaseTag": "Beta",
17333
+ "name": "GenesisReviewPayload",
17334
+ "typeTokenRange": {
17335
+ "startIndex": 1,
17336
+ "endIndex": 3
17337
+ }
17338
+ },
17339
+ {
17340
+ "kind": "TypeAlias",
17341
+ "canonicalReference": "@genesislcap/ai-assistant!GenesisWriteReviewCompletedEventDetail:type",
17342
+ "docComment": "/**\n * The detail of the write review's `interaction-completed` event.\n *\n * @beta\n */\n",
17343
+ "excerptTokens": [
17344
+ {
17345
+ "kind": "Content",
17346
+ "text": "export type GenesisWriteReviewCompletedEventDetail = "
17347
+ },
17348
+ {
17349
+ "kind": "Reference",
17350
+ "text": "InteractionResult",
17351
+ "canonicalReference": "@genesislcap/foundation-ai!InteractionResult:type"
17352
+ },
17353
+ {
17354
+ "kind": "Content",
17355
+ "text": "<"
17356
+ },
17357
+ {
17358
+ "kind": "Reference",
17359
+ "text": "GenesisReviewPayload",
17360
+ "canonicalReference": "@genesislcap/ai-assistant!GenesisReviewPayload:type"
17361
+ },
17362
+ {
17363
+ "kind": "Content",
17364
+ "text": ">"
17365
+ },
17366
+ {
17367
+ "kind": "Content",
17368
+ "text": ";"
17369
+ }
17370
+ ],
17371
+ "fileUrlPath": "src/genesis/review-payload.ts",
17372
+ "releaseTag": "Beta",
17373
+ "name": "GenesisWriteReviewCompletedEventDetail",
17374
+ "typeTokenRange": {
17375
+ "startIndex": 1,
17376
+ "endIndex": 5
17377
+ }
17378
+ },
17006
17379
  {
17007
17380
  "kind": "Function",
17008
17381
  "canonicalReference": "@genesislcap/ai-assistant!getAiPopoutManager:function(1)",
@@ -17692,7 +18065,34 @@
17692
18065
  },
17693
18066
  {
17694
18067
  "kind": "Content",
17695
- "text": ";\n budgetExhaustedMessage?: string;\n }"
18068
+ "text": ";\n budgetExhaustedMessage?: string;\n aiServiceErrorMessages?: "
18069
+ },
18070
+ {
18071
+ "kind": "Reference",
18072
+ "text": "Partial",
18073
+ "canonicalReference": "!Partial:type"
18074
+ },
18075
+ {
18076
+ "kind": "Content",
18077
+ "text": "<"
18078
+ },
18079
+ {
18080
+ "kind": "Reference",
18081
+ "text": "Record",
18082
+ "canonicalReference": "!Record:type"
18083
+ },
18084
+ {
18085
+ "kind": "Content",
18086
+ "text": "<"
18087
+ },
18088
+ {
18089
+ "kind": "Reference",
18090
+ "text": "AIServiceRefusal",
18091
+ "canonicalReference": "@genesislcap/foundation-ai!AIServiceRefusal:type"
18092
+ },
18093
+ {
18094
+ "kind": "Content",
18095
+ "text": ", string>>;\n }"
17696
18096
  },
17697
18097
  {
17698
18098
  "kind": "Content",
@@ -17723,7 +18123,7 @@
17723
18123
  "parameterName": "options",
17724
18124
  "parameterTypeTokenRange": {
17725
18125
  "startIndex": 6,
17726
- "endIndex": 9
18126
+ "endIndex": 15
17727
18127
  },
17728
18128
  "isOptional": true
17729
18129
  }