effect-agent 0.1.0-beta.97 → 0.1.0-beta.99

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 (143) hide show
  1. package/dist/{AgentRuntime-B64362Id.d.mts → AgentRuntime-BMzrJos6.d.mts} +2 -2
  2. package/dist/{AgentRuntime-Cdvqw7l_.mjs → AgentRuntime-BWOnNc0d.mjs} +78 -42
  3. package/dist/AgentRuntime-BWOnNc0d.mjs.map +1 -0
  4. package/dist/{DurableAgentRuntime-DbUvZHDZ.mjs → DurableAgentRuntime-BE_OjQjz.mjs} +471 -252
  5. package/dist/DurableAgentRuntime-BE_OjQjz.mjs.map +1 -0
  6. package/dist/{DurableFailpoint-DQJet828.d.mts → DurableFailpoint-mx3-nsxU.d.mts} +3 -3
  7. package/dist/{EventSource-D6PAAEyK.d.mts → EventSource-BZ73J0s5.d.mts} +3 -3
  8. package/dist/{PreparedInputAdmission-omMbwd--.d.mts → PreparedInputAdmission-BkeI-Xvr.d.mts} +4 -4
  9. package/dist/{Records-CV49DgQK.d.mts → Records-BIiRLqlz.d.mts} +92 -128
  10. package/dist/{Records-BAutSSnJ.mjs → Records-DR1xtbXY.mjs} +35 -8
  11. package/dist/Records-DR1xtbXY.mjs.map +1 -0
  12. package/dist/{RunJournal-DRRRZmG7.mjs → RunJournal-DNs3PM4K.mjs} +80 -23
  13. package/dist/RunJournal-DNs3PM4K.mjs.map +1 -0
  14. package/dist/{RunOptions-Clj8cLsp.d.mts → RunOptions-Bruk54SE.d.mts} +13 -4
  15. package/dist/{Schedule-DePbGfgd.d.mts → Schedule-BNFlluAl.d.mts} +2 -2
  16. package/dist/{Scheduling-C3QpYn0W.mjs → Scheduling-HFH0pST1.mjs} +2 -2
  17. package/dist/{Scheduling-C3QpYn0W.mjs.map → Scheduling-HFH0pST1.mjs.map} +1 -1
  18. package/dist/{Subagent-Cbfzylz1.mjs → Subagent-C2s8PFrd.mjs} +2 -2
  19. package/dist/{Subagent-Cbfzylz1.mjs.map → Subagent-C2s8PFrd.mjs.map} +1 -1
  20. package/dist/{Subagent-Bm1dRecN.d.mts → Subagent-m7ywTCe4.d.mts} +3 -3
  21. package/dist/{Subscription-BR_8Cxh3.d.mts → Subscription-BCQ3L9Zp.d.mts} +3 -3
  22. package/dist/{SubscriptionInput-B95sQbuk.d.mts → SubscriptionInput-Cqu4_RW3.d.mts} +3 -3
  23. package/dist/{ToolReconciler-DQVaJfpE.d.mts → ToolReconciler-BmVRAHKs.d.mts} +8 -4
  24. package/dist/agent-registration-cXpB8cBU.mjs +199 -0
  25. package/dist/agent-registration-cXpB8cBU.mjs.map +1 -0
  26. package/dist/capabilities/Commands.d.mts +1 -1
  27. package/dist/capabilities/RunHooks.d.mts +1 -1
  28. package/dist/capabilities/Subagent.d.mts +1 -1
  29. package/dist/capabilities/Subagent.mjs +1 -1
  30. package/dist/durable/ActivityStore.d.mts +1 -1
  31. package/dist/durable/ActivityStore.mjs +1 -1
  32. package/dist/durable/Admin.d.mts +1 -1
  33. package/dist/durable/Admin.mjs +12 -10
  34. package/dist/durable/Admin.mjs.map +1 -1
  35. package/dist/durable/AgentRegistration.d.mts +2 -2
  36. package/dist/durable/AgentRegistration.mjs +4 -8
  37. package/dist/durable/AgentRegistration.mjs.map +1 -1
  38. package/dist/durable/Certification.d.mts +2 -2
  39. package/dist/durable/CommittedActivity.d.mts +1 -1
  40. package/dist/durable/CommittedActivity.mjs +1 -1
  41. package/dist/durable/Digest.d.mts +1 -1
  42. package/dist/durable/Digest.mjs +1 -1
  43. package/dist/durable/DurableAgentRuntime.d.mts +1 -1
  44. package/dist/durable/DurableAgentRuntime.mjs +1 -1
  45. package/dist/durable/DurableFailpoint.d.mts +1 -1
  46. package/dist/durable/DurableFailpoint.mjs +2 -0
  47. package/dist/durable/DurableFailpoint.mjs.map +1 -1
  48. package/dist/durable/DurableFailpointTestControl.d.mts +1 -1
  49. package/dist/durable/EventSource.d.mts +1 -1
  50. package/dist/durable/EventSource.mjs +1 -1
  51. package/dist/durable/GitHubWorkflowSource.d.mts +3 -3
  52. package/dist/durable/GitHubWorkflowSource.mjs +1 -1
  53. package/dist/durable/MessageDelivery.d.mts +3 -3
  54. package/dist/durable/MessageDelivery.mjs +1 -1
  55. package/dist/durable/MessageDeliveryStoreConformance.d.mts +39 -39
  56. package/dist/durable/MessageDeliveryStoreConformance.mjs +1 -1
  57. package/dist/durable/PersistentHistory.d.mts +1 -1
  58. package/dist/durable/PersistentHistory.mjs +2 -2
  59. package/dist/durable/PreparedInputAdmission.d.mts +1 -1
  60. package/dist/durable/Records.d.mts +2 -2
  61. package/dist/durable/Records.mjs +2 -2
  62. package/dist/durable/Recovery.d.mts +1 -1
  63. package/dist/durable/Recovery.mjs +9 -9
  64. package/dist/durable/Recovery.mjs.map +1 -1
  65. package/dist/durable/RunJournal.d.mts +2 -2
  66. package/dist/durable/RunJournal.mjs +2 -2
  67. package/dist/durable/Schedule.d.mts +1 -1
  68. package/dist/durable/Schedule.mjs +1 -1
  69. package/dist/durable/ScheduleStoreConformance.d.mts +1 -1
  70. package/dist/durable/ScheduleStoreConformance.mjs +1 -1
  71. package/dist/durable/ScheduleTransition.d.mts +1 -1
  72. package/dist/durable/ScheduleTransition.mjs +1 -1
  73. package/dist/durable/Scheduling.d.mts +2 -2
  74. package/dist/durable/Scheduling.mjs +1 -1
  75. package/dist/durable/SqlStorageV2Upgrade.d.mts +2 -2
  76. package/dist/durable/SqlStorageV2Upgrade.mjs +1 -1
  77. package/dist/durable/SqlSubscriptionStore.d.mts +2 -2
  78. package/dist/durable/SqlSubscriptionStore.mjs +1 -1
  79. package/dist/durable/SubmissionLedger.d.mts +1 -1
  80. package/dist/durable/SubmissionLedger.mjs +14 -13
  81. package/dist/durable/SubmissionLedger.mjs.map +1 -1
  82. package/dist/durable/SubmissionLedgerConformance.d.mts +1 -1
  83. package/dist/durable/SubmissionLedgerConformance.mjs +9 -2
  84. package/dist/durable/SubmissionLedgerConformance.mjs.map +1 -1
  85. package/dist/durable/SubmissionStatus.d.mts +1 -1
  86. package/dist/durable/Subscription.d.mts +1 -1
  87. package/dist/durable/Subscription.mjs +1 -1
  88. package/dist/durable/SubscriptionInput.d.mts +1 -1
  89. package/dist/durable/SubscriptionInput.mjs +2 -2
  90. package/dist/durable/SubscriptionStoreConformance.d.mts +1 -1
  91. package/dist/durable/SubscriptionStoreConformance.mjs +1 -1
  92. package/dist/durable/SubscriptionTools.d.mts +3 -3
  93. package/dist/durable/SubscriptionTransition.d.mts +1 -1
  94. package/dist/durable/SubscriptionTransition.mjs +1 -1
  95. package/dist/durable/Subscriptions.d.mts +5 -5
  96. package/dist/durable/Subscriptions.mjs +1 -1
  97. package/dist/durable/ThreadContextHistory.d.mts +1 -1
  98. package/dist/durable/ThreadContextHistory.mjs +1 -1
  99. package/dist/durable/ThreadContextHistoryProjection.d.mts +1 -1
  100. package/dist/durable/ThreadContextHistoryProjection.mjs +1 -1
  101. package/dist/durable/ThreadInvariants.d.mts +4 -2
  102. package/dist/durable/ThreadInvariants.mjs +49 -3
  103. package/dist/durable/ThreadInvariants.mjs.map +1 -1
  104. package/dist/durable/ThreadProjection.d.mts +1 -1
  105. package/dist/durable/ThreadProjection.mjs +1 -1
  106. package/dist/durable/ThreadProjectionMaintenance.d.mts +1 -1
  107. package/dist/durable/ThreadStore.d.mts +1 -1
  108. package/dist/durable/ThreadStore.mjs +1 -1
  109. package/dist/durable/ThreadStoreConformance.d.mts +1 -1
  110. package/dist/durable/ThreadStoreConformance.mjs +1 -1
  111. package/dist/durable/ToolReconciler.d.mts +1 -1
  112. package/dist/durable/ToolReconciler.mjs +9 -5
  113. package/dist/durable/ToolReconciler.mjs.map +1 -1
  114. package/dist/durable/WorkerHost.d.mts +1 -1
  115. package/dist/engine/AgentRuntime.d.mts +1 -1
  116. package/dist/engine/AgentRuntime.mjs +1 -1
  117. package/dist/engine/RunOptions.d.mts +1 -1
  118. package/dist/engine/RunOptions.mjs.map +1 -1
  119. package/dist/index.d.mts +11 -11
  120. package/dist/index.mjs +6 -6
  121. package/package.json +1 -1
  122. package/src/durable/Admin.ts +20 -11
  123. package/src/durable/AgentRegistration.ts +1 -5
  124. package/src/durable/DurableAgentRuntime.ts +947 -464
  125. package/src/durable/DurableFailpoint.ts +2 -0
  126. package/src/durable/Records.ts +30 -5
  127. package/src/durable/Recovery.ts +8 -8
  128. package/src/durable/RunJournal.ts +128 -51
  129. package/src/durable/SubmissionLedger.ts +13 -12
  130. package/src/durable/SubmissionLedgerConformance.ts +13 -2
  131. package/src/durable/ThreadInvariants.ts +70 -5
  132. package/src/durable/ToolReconciler.ts +7 -3
  133. package/src/durable/internal/agent-registration.ts +65 -414
  134. package/src/durable/internal/messaging-host.ts +0 -2
  135. package/src/durable/internal/worker-host.ts +34 -96
  136. package/src/engine/RunOptions.ts +13 -3
  137. package/src/engine/internal/agent-runtime.ts +160 -106
  138. package/dist/AgentRuntime-Cdvqw7l_.mjs.map +0 -1
  139. package/dist/DurableAgentRuntime-DbUvZHDZ.mjs.map +0 -1
  140. package/dist/Records-BAutSSnJ.mjs.map +0 -1
  141. package/dist/RunJournal-DRRRZmG7.mjs.map +0 -1
  142. package/dist/agent-registration-CXGDwvJH.mjs +0 -379
  143. package/dist/agent-registration-CXGDwvJH.mjs.map +0 -1
@@ -105,7 +105,6 @@ import {
105
105
  } from "../WorkerHost.ts";
106
106
  import {
107
107
  definitionDigestsEqual,
108
- bindingSupports,
109
108
  resolveDefinitionBinding,
110
109
  type ResolvedBinding,
111
110
  } from "./agent-registration.ts";
@@ -381,11 +380,10 @@ export const makeWorkerRuntime = Effect.fn("WorkerHost.make")(function* (
381
380
  };
382
381
  });
383
382
 
384
- const firstThreadInput = (history: Effect.Success<ReturnType<typeof read>>) => {
385
- const first = history.records.find(({ record }) => record.payload._tag === "UserInputRecorded")
386
- ?.record.payload;
383
+ const currentBinding = (agentId: AgentId): ResolvedBinding | undefined => {
384
+ const matches = deps.bindings.filter((entry) => entry.agentId === agentId);
387
385
 
388
- return first?._tag === "UserInputRecorded" ? first.input : undefined;
386
+ return matches.length === 1 ? matches[0] : undefined;
389
387
  };
390
388
 
391
389
  const sourceAuthority = Effect.fn("WorkerHost.sourceAuthority")(function* (
@@ -397,11 +395,7 @@ export const makeWorkerRuntime = Effect.fn("WorkerHost.make")(function* (
397
395
 
398
396
  if (created?._tag !== "ThreadCreated") return yield* failure("start", "not-found");
399
397
 
400
- const binding = deps.bindings.find(
401
- (entry) =>
402
- entry.agentId === created.agentId &&
403
- bindingSupports(entry, created.definitions, undefined, firstThreadInput(current)),
404
- );
398
+ const binding = currentBinding(created.agentId);
405
399
 
406
400
  const worker = current.records.find(
407
401
  ({ record }) => record.payload._tag === "WorkerOriginRecorded",
@@ -444,18 +438,7 @@ export const makeWorkerRuntime = Effect.fn("WorkerHost.make")(function* (
444
438
  }
445
439
 
446
440
  const ownerBinding =
447
- ownerSubmission === undefined
448
- ? undefined
449
- : deps.bindings.find(
450
- (entry) =>
451
- entry.agentId === ownerSubmission.agentId &&
452
- bindingSupports(
453
- entry,
454
- ownerSubmission.agentDigests,
455
- undefined,
456
- ownerSubmission.inputPayload,
457
- ),
458
- );
441
+ ownerSubmission === undefined ? undefined : currentBinding(ownerSubmission.agentId);
459
442
 
460
443
  const selectedBinding = ownerBinding ?? binding;
461
444
 
@@ -734,6 +717,7 @@ export const makeWorkerRuntime = Effect.fn("WorkerHost.make")(function* (
734
717
  inputDigest: Digest,
735
718
  input: PersistedJson,
736
719
  principal: Principal,
720
+ retainedFrameworkInput: boolean,
737
721
  ): Effect.fn.Return<void, WorkerError> {
738
722
  const origin = admission.origin;
739
723
  const id = `worker-input:${admission.messageId}`;
@@ -779,17 +763,16 @@ export const makeWorkerRuntime = Effect.fn("WorkerHost.make")(function* (
779
763
 
780
764
  const sourceBinding = source.binding;
781
765
 
782
- const targetBinding = deps.bindings.find(
783
- (entry) =>
784
- entry.agentId === origin.worker.targetAgentId &&
785
- bindingSupports(entry, origin.targetDigests, undefined, input),
786
- );
766
+ const targetBinding = currentBinding(origin.worker.targetAgentId);
787
767
 
788
768
  if (sourceBinding === undefined || targetBinding === undefined)
789
769
  return yield* failure("start", "declaration-unavailable");
790
- yield* Schema.decodeEffect(Schema.toEncoded(targetBinding.definition.input))(input).pipe(
791
- Effect.mapError(() => failure("start", "corrupt")),
792
- );
770
+ // Standard reports and updates retain the owner's original input bytes. Their
771
+ // framework message carries the new information independently of the current input codec.
772
+ if (!retainedFrameworkInput)
773
+ yield* Schema.decodeEffect(Schema.toEncoded(targetBinding.definition.input))(input).pipe(
774
+ Effect.mapError(() => failure("start", "corrupt")),
775
+ );
793
776
 
794
777
  const targetRequest = {
795
778
  definition: targetBinding.definition,
@@ -1040,7 +1023,11 @@ export const makeWorkerRuntime = Effect.fn("WorkerHost.make")(function* (
1040
1023
  admission.deliveryPrincipal !== options.principal)
1041
1024
  )
1042
1025
  return yield* failure("start", "worker-mismatch");
1043
- yield* reservation(admission, inputDigest, input, options.principal);
1026
+ const retainedFrameworkInput = Schema.is(FrameworkMessage)(options.messageAdmission);
1027
+
1028
+ if (retainedFrameworkInput && admission.reportKind !== "update")
1029
+ yield* validateCompletion(options.messageAdmission, options, agentId, inputDigest);
1030
+ yield* reservation(admission, inputDigest, input, options.principal, retainedFrameworkInput);
1044
1031
 
1045
1032
  return admission;
1046
1033
  });
@@ -1068,29 +1055,11 @@ export const makeWorkerRuntime = Effect.fn("WorkerHost.make")(function* (
1068
1055
  first.admission.sourceSubmissionId,
1069
1056
  );
1070
1057
 
1071
- if (
1072
- source.binding === undefined ||
1073
- source.submission === undefined ||
1074
- !bindingSupports(
1075
- source.binding,
1076
- intent.sourceDigests,
1077
- undefined,
1078
- source.submission?.inputPayload,
1079
- )
1080
- )
1058
+ if (source.binding === undefined || source.submission === undefined)
1081
1059
  return yield* failure("followUp", "declaration-unavailable");
1082
1060
 
1083
- const sourceBinding = deps.bindings.find(
1084
- (entry) =>
1085
- entry.agentId === origin.source.agentId &&
1086
- bindingSupports(entry, intent.sourceDigests, undefined, source.submission?.inputPayload),
1087
- );
1088
-
1089
- const targetBinding = deps.bindings.find(
1090
- (entry) =>
1091
- entry.agentId === origin.worker.targetAgentId &&
1092
- bindingSupports(entry, origin.targetDigests, undefined, submission.inputPayload),
1093
- );
1061
+ const sourceBinding = currentBinding(origin.source.agentId);
1062
+ const targetBinding = currentBinding(origin.worker.targetAgentId);
1094
1063
 
1095
1064
  const reports =
1096
1065
  sourceBinding?.reporting?.filter(
@@ -1124,14 +1093,7 @@ export const makeWorkerRuntime = Effect.fn("WorkerHost.make")(function* (
1124
1093
  );
1125
1094
 
1126
1095
  if (now >= deadlineAtMillis) return yield* failure("followUp", "denied");
1127
- const sourceSubmission = source.submission;
1128
-
1129
- const input = yield* Schema.decodeEffect(Schema.toEncoded(sourceBinding.definition.input))(
1130
- source.submission.inputPayload,
1131
- ).pipe(
1132
- Effect.flatMap(() => Schema.decodeEffect(PersistedJson)(sourceSubmission.inputPayload)),
1133
- Effect.mapError(() => failure("followUp", "corrupt")),
1134
- );
1096
+ const input = source.submission.inputPayload;
1135
1097
 
1136
1098
  let workerAdmission: WorkerAdmission | undefined;
1137
1099
  let principal = submission.principal;
@@ -1283,28 +1245,10 @@ export const makeWorkerRuntime = Effect.fn("WorkerHost.make")(function* (
1283
1245
  firstInput.admission.sourceSubmissionId,
1284
1246
  );
1285
1247
 
1286
- if (
1287
- source.binding === undefined ||
1288
- !bindingSupports(
1289
- source.binding,
1290
- intent.sourceDigests,
1291
- undefined,
1292
- source.submission?.inputPayload,
1293
- )
1294
- )
1295
- return refused("declaration-unavailable");
1296
-
1297
- const sourceBinding = deps.bindings.find(
1298
- (entry) =>
1299
- entry.agentId === origin.source.agentId &&
1300
- bindingSupports(entry, intent.sourceDigests, undefined, source.submission?.inputPayload),
1301
- );
1248
+ if (source.binding === undefined) return refused("declaration-unavailable");
1302
1249
 
1303
- const targetBinding = deps.bindings.find(
1304
- (entry) =>
1305
- entry.agentId === origin.worker.targetAgentId &&
1306
- bindingSupports(entry, origin.targetDigests, undefined, hostSubmission.inputPayload),
1307
- );
1250
+ const sourceBinding = currentBinding(origin.source.agentId);
1251
+ const targetBinding = currentBinding(origin.worker.targetAgentId);
1308
1252
 
1309
1253
  const reports =
1310
1254
  sourceBinding?.reporting?.filter(
@@ -1420,12 +1364,13 @@ export const makeWorkerRuntime = Effect.fn("WorkerHost.make")(function* (
1420
1364
  ? source.submission?.inputPayload
1421
1365
  : projection.value.encodedInput;
1422
1366
 
1423
- const validated = yield* Schema.decodeEffect(
1424
- Schema.toEncoded(sourceBinding.definition.input),
1425
- )(reportInput).pipe(
1426
- Effect.flatMap(() => Schema.decodeUnknownEffect(PersistedJson)(reportInput)),
1427
- Effect.option,
1428
- );
1367
+ const validated = yield* (
1368
+ descriptor.mode === "standard"
1369
+ ? Schema.decodeUnknownEffect(PersistedJson)(reportInput)
1370
+ : Schema.decodeEffect(Schema.toEncoded(sourceBinding.definition.input))(reportInput).pipe(
1371
+ Effect.flatMap(() => Schema.decodeUnknownEffect(PersistedJson)(reportInput)),
1372
+ )
1373
+ ).pipe(Effect.option);
1429
1374
 
1430
1375
  if (Option.isNone(validated)) return refused("input");
1431
1376
  const input = validated.value;
@@ -2084,7 +2029,7 @@ export const makeWorkerRuntime = Effect.fn("WorkerHost.make")(function* (
2084
2029
  threadId: Schema.decodeSync(ThreadId)(messageId),
2085
2030
  },
2086
2031
  source: existing?.envelope.workerAdmission?.origin.source ?? context.source,
2087
- targetDigests: resolved.digests,
2032
+ targetDigests: previousOrigin?.targetDigests ?? resolved.digests,
2088
2033
  policy: request.policy,
2089
2034
  budget: request.budget,
2090
2035
  ...(request.budgetScope === undefined ? {} : { budgetScope: request.budgetScope }),
@@ -2432,14 +2377,7 @@ export const makeWorkerRuntime = Effect.fn("WorkerHost.make")(function* (
2432
2377
  ? undefined
2433
2378
  : yield* sourceAuthority(sourceThreadId, request.sourceSubmissionId);
2434
2379
 
2435
- const resolved =
2436
- selected === undefined
2437
- ? deps.bindings.find(
2438
- (entry) =>
2439
- entry.agentId === created.agentId &&
2440
- bindingSupports(entry, created.definitions, undefined, firstThreadInput(current)),
2441
- )
2442
- : selected.binding;
2380
+ const resolved = selected === undefined ? currentBinding(created.agentId) : selected.binding;
2443
2381
 
2444
2382
  if (resolved === undefined) return yield* failure("context", "declaration-unavailable");
2445
2383
 
@@ -611,9 +611,9 @@ export interface RunDurabilityHook<Error = never, Requirements = never> {
611
611
  /**
612
612
  * `DefinitionDigests`-shaped digests of one child Agent Binding in plain
613
613
  * string form. The durable coordinator's thread-owned digest Schema never
614
- * crosses inward: the coordinator resolves these digests from the exact
615
- * registered target and stores and verifies them
616
- * byte-for-byte (SUB-023 exact-digest binding resolution).
614
+ * crosses inward: the coordinator captures these digests from the admitted target
615
+ * and verifies them byte-for-byte as immutable provenance. Current executable
616
+ * selection uses the stable Agent identity, independently of historical definitions.
617
617
  */
618
618
  export interface RunSubagentDigests {
619
619
  readonly agent: string;
@@ -829,6 +829,8 @@ export type RunResumeUsage = typeof RunResumeUsageSchema.Type;
829
829
  * proceeds through the normal continuation.
830
830
  */
831
831
  export interface RunTurnResume {
832
+ /** A successful settled call whose original operation contract still supports completion projection. */
833
+ readonly settledCompletion?: ToolCallId | undefined;
832
834
  /** Canonical rejection evidence, matched to the exact call; never permits handler execution. */
833
835
  readonly toolParameterRejections?: ReadonlyArray<ToolParameterRejection> | undefined;
834
836
  readonly toolExposure?: Snapshot | undefined;
@@ -919,6 +921,14 @@ export interface RunOptions<HookError = never, HookRequirements = never> {
919
921
  /** Host-validated worker message; application input still supplies instructions and policy context. */
920
922
  readonly frameworkMessage?: FrameworkMessage;
921
923
 
924
+ /**
925
+ * Original admitted JSON for a durable continuation or verified framework message. Static
926
+ * instructions can resume without decoding a future input Schema; input-dependent instructions
927
+ * still require that Schema. The original value remains the policy input, and a saved prompt
928
+ * is restored through `context` instead of rerendering the application's input prompt.
929
+ */
930
+ readonly retainedInput?: Schema.Json | undefined;
931
+
922
932
  /** Initial or canonically restored run-scoped native selection. */
923
933
  readonly toolSelection?: Selection | undefined;
924
934
  /**