@linnlabs/linnkit 0.43.0 → 0.44.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 (90) hide show
  1. package/CHANGELOG.md +44 -0
  2. package/dist/cli.cjs +101 -4
  3. package/dist/cli.cjs.map +1 -1
  4. package/dist/cli.js +101 -4
  5. package/dist/cli.js.map +1 -1
  6. package/dist/context-manager/profiles/agent/context/config.d.cts +1 -1
  7. package/dist/context-manager/profiles/agent/context/config.d.ts +1 -1
  8. package/dist/context-manager.cjs +37 -4
  9. package/dist/context-manager.cjs.map +1 -1
  10. package/dist/context-manager.js +37 -4
  11. package/dist/context-manager.js.map +1 -1
  12. package/dist/contracts/agentSpec.d.cts +5 -5
  13. package/dist/contracts/agentSpec.d.ts +5 -5
  14. package/dist/contracts/audit.d.cts +10 -10
  15. package/dist/contracts/audit.d.ts +10 -10
  16. package/dist/contracts/contextPolicy.d.cts +14 -14
  17. package/dist/contracts/contextPolicy.d.ts +14 -14
  18. package/dist/contracts/events.d.cts +121 -117
  19. package/dist/contracts/events.d.ts +121 -117
  20. package/dist/contracts/execution.d.cts +2 -2
  21. package/dist/contracts/execution.d.ts +2 -2
  22. package/dist/contracts/llm-retry.d.cts +2 -2
  23. package/dist/contracts/llm-retry.d.ts +2 -2
  24. package/dist/contracts/messages.d.cts +256 -32
  25. package/dist/contracts/messages.d.ts +256 -32
  26. package/dist/contracts/sse.d.cts +161 -97
  27. package/dist/contracts/sse.d.ts +161 -97
  28. package/dist/contracts/sub-run-trace-payload.d.cts +8 -8
  29. package/dist/contracts/sub-run-trace-payload.d.ts +8 -8
  30. package/dist/contracts/token-accounting.d.cts +12 -12
  31. package/dist/contracts/token-accounting.d.ts +12 -12
  32. package/dist/contracts.cjs +19 -2
  33. package/dist/contracts.cjs.map +1 -1
  34. package/dist/contracts.d.cts +1 -1
  35. package/dist/contracts.d.ts +1 -1
  36. package/dist/contracts.js +19 -3
  37. package/dist/contracts.js.map +1 -1
  38. package/dist/index.cjs +103 -4
  39. package/dist/index.cjs.map +1 -1
  40. package/dist/index.js +103 -4
  41. package/dist/index.js.map +1 -1
  42. package/dist/quickstart.cjs +101 -4
  43. package/dist/quickstart.cjs.map +1 -1
  44. package/dist/quickstart.js +101 -4
  45. package/dist/quickstart.js.map +1 -1
  46. package/dist/runtime-kernel/events/agentEvents.d.cts +2 -2
  47. package/dist/runtime-kernel/events/agentEvents.d.ts +2 -2
  48. package/dist/runtime-kernel/events.cjs +29 -2
  49. package/dist/runtime-kernel/events.cjs.map +1 -1
  50. package/dist/runtime-kernel/events.js +29 -2
  51. package/dist/runtime-kernel/events.js.map +1 -1
  52. package/dist/runtime-kernel/graph-engine/definitions/pendingUserInput.d.cts +27 -0
  53. package/dist/runtime-kernel/graph-engine/definitions/pendingUserInput.d.ts +27 -0
  54. package/dist/runtime-kernel/graph-engine/engine.d.cts +1 -1
  55. package/dist/runtime-kernel/graph-engine/engine.d.ts +1 -1
  56. package/dist/runtime-kernel/graph-engine/index.d.cts +1 -0
  57. package/dist/runtime-kernel/graph-engine/index.d.ts +1 -0
  58. package/dist/runtime-kernel/graph-engine/types.d.cts +3 -0
  59. package/dist/runtime-kernel/graph-engine/types.d.ts +3 -0
  60. package/dist/runtime-kernel.cjs +101 -4
  61. package/dist/runtime-kernel.cjs.map +1 -1
  62. package/dist/runtime-kernel.d.cts +1 -0
  63. package/dist/runtime-kernel.d.ts +1 -0
  64. package/dist/runtime-kernel.js +101 -4
  65. package/dist/runtime-kernel.js.map +1 -1
  66. package/dist/testkit/agent-harness/scriptedInferenceHarness.d.cts +24 -6
  67. package/dist/testkit/agent-harness/scriptedInferenceHarness.d.ts +24 -6
  68. package/dist/testkit/scenario/graphScenario.d.cts +89 -0
  69. package/dist/testkit/scenario/graphScenario.d.ts +89 -0
  70. package/dist/testkit/scenario/pendingUserInputQueue.d.cts +26 -0
  71. package/dist/testkit/scenario/pendingUserInputQueue.d.ts +26 -0
  72. package/dist/testkit/scenario/runtimeEventRecorder.d.cts +36 -0
  73. package/dist/testkit/scenario/runtimeEventRecorder.d.ts +36 -0
  74. package/dist/testkit/scenario/scriptedToolRuntime.d.cts +51 -0
  75. package/dist/testkit/scenario/scriptedToolRuntime.d.ts +51 -0
  76. package/dist/testkit/scenario/steeringInvariants.d.cts +33 -0
  77. package/dist/testkit/scenario/steeringInvariants.d.ts +33 -0
  78. package/dist/testkit/scenario/timeline.d.cts +27 -0
  79. package/dist/testkit/scenario/timeline.d.ts +27 -0
  80. package/dist/testkit.cjs +671 -17
  81. package/dist/testkit.cjs.map +1 -1
  82. package/dist/testkit.d.cts +7 -1
  83. package/dist/testkit.d.ts +7 -1
  84. package/dist/testkit.js +663 -18
  85. package/dist/testkit.js.map +1 -1
  86. package/docs/integration/README.md +1 -0
  87. package/docs/integration/mid-run-user-input.md +73 -0
  88. package/docs/integration/realtime.md +4 -0
  89. package/docs/integration/testing.md +40 -4
  90. package/package.json +2 -2
@@ -0,0 +1,27 @@
1
+ /**
2
+ * 运行中途由 Host 交给 Graph 的用户输入(插话)。
3
+ *
4
+ * `id` 直接成为送达后 `user_input` 事实的事件身份:同一条插话因提交失败被重新取用时,
5
+ * 事件身份不变,Host 可以据此去重。
6
+ */
7
+ interface PendingUserInput {
8
+ readonly id: string;
9
+ readonly content: string;
10
+ readonly timestamp?: number;
11
+ }
12
+ /**
13
+ * 运行中插话的 Host 端口(可选运行能力,不进入 checkpoint)。
14
+ *
15
+ * Graph 只在一批工具全部结算、即将回到模型时取用:
16
+ * - `claim` 取走当前待送达的输入;在 `confirm` 前这些条目仍归 Host 所有,不得被撤回后又送达。
17
+ * - 边界提交成功后调用 `confirm`;提交失败调用 `release`,条目回到待送达。
18
+ *
19
+ * 没有装配该端口的 Host 行为不变。子运行不接收插话。
20
+ */
21
+ interface PendingUserInputPort {
22
+ claim(): Promise<readonly PendingUserInput[]> | readonly PendingUserInput[];
23
+ confirm(ids: readonly string[]): Promise<void> | void;
24
+ release(ids: readonly string[]): Promise<void> | void;
25
+ }
26
+
27
+ export type { PendingUserInput, PendingUserInputPort };
@@ -0,0 +1,27 @@
1
+ /**
2
+ * 运行中途由 Host 交给 Graph 的用户输入(插话)。
3
+ *
4
+ * `id` 直接成为送达后 `user_input` 事实的事件身份:同一条插话因提交失败被重新取用时,
5
+ * 事件身份不变,Host 可以据此去重。
6
+ */
7
+ interface PendingUserInput {
8
+ readonly id: string;
9
+ readonly content: string;
10
+ readonly timestamp?: number;
11
+ }
12
+ /**
13
+ * 运行中插话的 Host 端口(可选运行能力,不进入 checkpoint)。
14
+ *
15
+ * Graph 只在一批工具全部结算、即将回到模型时取用:
16
+ * - `claim` 取走当前待送达的输入;在 `confirm` 前这些条目仍归 Host 所有,不得被撤回后又送达。
17
+ * - 边界提交成功后调用 `confirm`;提交失败调用 `release`,条目回到待送达。
18
+ *
19
+ * 没有装配该端口的 Host 行为不变。子运行不接收插话。
20
+ */
21
+ interface PendingUserInputPort {
22
+ claim(): Promise<readonly PendingUserInput[]> | readonly PendingUserInput[];
23
+ confirm(ids: readonly string[]): Promise<void> | void;
24
+ release(ids: readonly string[]): Promise<void> | void;
25
+ }
26
+
27
+ export type { PendingUserInput, PendingUserInputPort };
@@ -34,7 +34,7 @@ interface GraphExecutorConfig {
34
34
  interface GraphContinuationInput {
35
35
  readonly expectedRevision: number;
36
36
  /** 只能重建运行能力,不能覆盖持久请求、历史、模型或预算。 */
37
- readonly capabilities: Pick<EngineLocalState, 'signal' | 'toolContext' | 'runtimeEventSink' | 'runtimeEventCommitPort' | 'runtimeFailureFactSink' | 'summarizationCallbacks' | 'toolRecoveryPort'>;
37
+ readonly capabilities: Pick<EngineLocalState, 'signal' | 'toolContext' | 'runtimeEventSink' | 'runtimeEventCommitPort' | 'runtimeFailureFactSink' | 'summarizationCallbacks' | 'toolRecoveryPort' | 'pendingUserInputPort'>;
38
38
  }
39
39
  declare class GraphExecutor {
40
40
  private readonly checkpointer;
@@ -34,7 +34,7 @@ interface GraphExecutorConfig {
34
34
  interface GraphContinuationInput {
35
35
  readonly expectedRevision: number;
36
36
  /** 只能重建运行能力,不能覆盖持久请求、历史、模型或预算。 */
37
- readonly capabilities: Pick<EngineLocalState, 'signal' | 'toolContext' | 'runtimeEventSink' | 'runtimeEventCommitPort' | 'runtimeFailureFactSink' | 'summarizationCallbacks' | 'toolRecoveryPort'>;
37
+ readonly capabilities: Pick<EngineLocalState, 'signal' | 'toolContext' | 'runtimeEventSink' | 'runtimeEventCommitPort' | 'runtimeFailureFactSink' | 'summarizationCallbacks' | 'toolRecoveryPort' | 'pendingUserInputPort'>;
38
38
  }
39
39
  declare class GraphExecutor {
40
40
  private readonly checkpointer;
@@ -17,4 +17,5 @@ export { parseEngineCheckpoint } from './functions/parseEngineCheckpoint.cjs';
17
17
  export { isRuntimeFailureFact } from './functions/runtimeFailureFact.cjs';
18
18
  export { ENGINE_STATE_SCHEMA_VERSION, EngineState, ExecutorLlmInvocationKind, ExecutorLocalPatch, ExecutorLocalState, GraphNode, RuntimeEventCommitPort, RuntimeEventSink, RuntimeFailureFact, RuntimeFailureFactSink, ToolBatchCompletionMode } from './types.cjs';
19
19
  export { ExecutionCheckpointPort, RunPauseRequested, RunRecoveryBlockedError, ToolRecoveryDecision, ToolRecoveryPort, isRunPauseSignal } from './definitions/runContinuation.cjs';
20
+ export { PendingUserInput, PendingUserInputPort } from './definitions/pendingUserInput.cjs';
20
21
  export { GraphContextCompactionCandidate, GraphExecutorContextApplyInput, GraphExecutorContextApplyOutput, GraphExecutorContextBuildInput, GraphExecutorContextBuildOutput, GraphExecutorContextBuilder, GraphExecutorOutputProcessor } from './executorContextBuilder.cjs';
@@ -17,4 +17,5 @@ export { parseEngineCheckpoint } from './functions/parseEngineCheckpoint.js';
17
17
  export { isRuntimeFailureFact } from './functions/runtimeFailureFact.js';
18
18
  export { ENGINE_STATE_SCHEMA_VERSION, EngineState, ExecutorLlmInvocationKind, ExecutorLocalPatch, ExecutorLocalState, GraphNode, RuntimeEventCommitPort, RuntimeEventSink, RuntimeFailureFact, RuntimeFailureFactSink, ToolBatchCompletionMode } from './types.js';
19
19
  export { ExecutionCheckpointPort, RunPauseRequested, RunRecoveryBlockedError, ToolRecoveryDecision, ToolRecoveryPort, isRunPauseSignal } from './definitions/runContinuation.js';
20
+ export { PendingUserInput, PendingUserInputPort } from './definitions/pendingUserInput.js';
20
21
  export { GraphContextCompactionCandidate, GraphExecutorContextApplyInput, GraphExecutorContextApplyOutput, GraphExecutorContextBuildInput, GraphExecutorContextBuildOutput, GraphExecutorContextBuilder, GraphExecutorOutputProcessor } from './executorContextBuilder.js';
@@ -1,5 +1,6 @@
1
1
  import { ToolExecutionContext } from '../tools/toolExecutionContext.cjs';
2
2
  import { ToolRecoveryPort } from './definitions/runContinuation.cjs';
3
+ import { PendingUserInputPort } from './definitions/pendingUserInput.cjs';
3
4
  import { RunId, ToolCallId } from '../../contracts/identity/definitions.cjs';
4
5
  import { AgentSpecSystemReminderPolicy, AgentSpecToolObservationGovernancePolicy } from '../../contracts/contextPolicy.cjs';
5
6
  import { RuntimeEvent, RoutedRuntimeEvent } from '../../contracts/events.cjs';
@@ -85,6 +86,8 @@ interface EngineLocalState extends Record<string, unknown> {
85
86
  /** Graph 注入的短提交边界,ToolNode 每个 call 前后复用;不序列化能力。 */
86
87
  commitExecutionBoundary?: (state: EngineState) => Promise<void>;
87
88
  toolRecoveryPort?: ToolRecoveryPort;
89
+ /** 运行中插话:一批工具结算完、回到模型前取用 Host 的待送达输入;不序列化能力。 */
90
+ pendingUserInputPort?: PendingUserInputPort;
88
91
  /** 意图已提交但结果未提交的原始 call;重启时必须经过工具 owner 对账。 */
89
92
  executingToolCallId?: ToolCallId;
90
93
  runtimeFailureFactSink?: RuntimeFailureFactSink;
@@ -1,5 +1,6 @@
1
1
  import { ToolExecutionContext } from '../tools/toolExecutionContext.js';
2
2
  import { ToolRecoveryPort } from './definitions/runContinuation.js';
3
+ import { PendingUserInputPort } from './definitions/pendingUserInput.js';
3
4
  import { RunId, ToolCallId } from '../../contracts/identity/definitions.js';
4
5
  import { AgentSpecSystemReminderPolicy, AgentSpecToolObservationGovernancePolicy } from '../../contracts/contextPolicy.js';
5
6
  import { RuntimeEvent, RoutedRuntimeEvent } from '../../contracts/events.js';
@@ -85,6 +86,8 @@ interface EngineLocalState extends Record<string, unknown> {
85
86
  /** Graph 注入的短提交边界,ToolNode 每个 call 前后复用;不序列化能力。 */
86
87
  commitExecutionBoundary?: (state: EngineState) => Promise<void>;
87
88
  toolRecoveryPort?: ToolRecoveryPort;
89
+ /** 运行中插话:一批工具结算完、回到模型前取用 Host 的待送达输入;不序列化能力。 */
90
+ pendingUserInputPort?: PendingUserInputPort;
88
91
  /** 意图已提交但结果未提交的原始 call;重启时必须经过工具 owner 对账。 */
89
92
  executingToolCallId?: ToolCallId;
90
93
  runtimeFailureFactSink?: RuntimeFailureFactSink;
@@ -902,6 +902,10 @@ var UserInputMessage = BaseMessage.extend({
902
902
  type: zod.z.literal("user_input"),
903
903
  attachments: RuntimeResourceRefs.optional()
904
904
  });
905
+ var UserSteerMessage = BaseMessage.extend({
906
+ role: zod.z.literal("user"),
907
+ type: zod.z.literal("user_steer")
908
+ });
905
909
  var UserContextMessage = BaseMessage.extend({
906
910
  role: zod.z.literal("user"),
907
911
  // 产品上下文种类由 Host fence metadata 表达,不进入框架消息枚举。
@@ -910,7 +914,7 @@ var UserContextMessage = BaseMessage.extend({
910
914
  "task_request"
911
915
  ])
912
916
  });
913
- var UserMessage = zod.z.union([UserInputMessage, UserContextMessage]);
917
+ var UserMessage = zod.z.union([UserInputMessage, UserSteerMessage, UserContextMessage]);
914
918
  var AssistantMessage = BaseMessage.extend({
915
919
  role: zod.z.literal("assistant"),
916
920
  type: zod.z.enum(["thought", "final_answer", "tool_code", "tool_calls", "task_completion"])
@@ -1512,7 +1516,12 @@ var RuntimeEventShape = zod.z.discriminatedUnion("type", [
1512
1516
  content: zod.z.string(),
1513
1517
  raw_content: zod.z.string().optional(),
1514
1518
  source: zod.z.enum(["user", "editor", "system"]).default("user"),
1515
- attachments: RuntimeResourceRefs.optional()
1519
+ attachments: RuntimeResourceRefs.optional(),
1520
+ /**
1521
+ * 运行中途送达的用户输入(插话)。缺省表示运行起点的输入。
1522
+ * 上下文里投影为 `user_steer`,不改变“当前轮从哪条 user_input 开始”的判定。
1523
+ */
1524
+ delivery: zod.z.literal("mid_run").optional()
1516
1525
  }),
1517
1526
  BaseEvent.extend({
1518
1527
  type: zod.z.literal("thought"),
@@ -1972,6 +1981,11 @@ zod.z.object({
1972
1981
  run_id: RunIdSchema,
1973
1982
  execution_id: ExecutionIdSchema
1974
1983
  });
1984
+ var SSEUserInputEvent = BaseSSEEvent.extend({
1985
+ type: zod.z.literal("user_input"),
1986
+ content: zod.z.string(),
1987
+ delivery: zod.z.literal("mid_run")
1988
+ });
1975
1989
  var SSEThoughtEvent = BaseSSEEvent.extend({
1976
1990
  type: zod.z.literal("thought"),
1977
1991
  thought_message_id: ThoughtMessageIdSchema.optional(),
@@ -2126,6 +2140,7 @@ var SSESummarizationErrorEvent = BaseSSEEvent.extend({
2126
2140
  error: zod.z.string()
2127
2141
  });
2128
2142
  zod.z.discriminatedUnion("type", [
2143
+ SSEUserInputEvent,
2129
2144
  SSEThoughtEvent,
2130
2145
  SSEFinalAnswerChunkEvent,
2131
2146
  SSEFinalAnswerResetEvent,
@@ -2448,6 +2463,7 @@ var NON_CHECKPOINT_LOCAL_KEYS = [
2448
2463
  "runtimeEventCommitPort",
2449
2464
  "commitExecutionBoundary",
2450
2465
  "toolRecoveryPort",
2466
+ "pendingUserInputPort",
2451
2467
  "runtimeFailureFactSink",
2452
2468
  "signal",
2453
2469
  "summarizationCallbacks",
@@ -6658,6 +6674,8 @@ function describeRuntimeEventLifecycle(event) {
6658
6674
  case "run_execution_metrics":
6659
6675
  case "history_summary":
6660
6676
  return "event_bus_sse";
6677
+ case "user_input":
6678
+ return event.type === "user_input" && event.delivery === "mid_run" ? "event_bus_sse" : "none";
6661
6679
  case "audit_envelope":
6662
6680
  return "none";
6663
6681
  default:
@@ -7101,6 +7119,16 @@ function requireEventTimestamp(value) {
7101
7119
  function applyRuntimeEventToMemory(event, memory) {
7102
7120
  switch (event.type) {
7103
7121
  case "user_input": {
7122
+ if (event.delivery === "mid_run") {
7123
+ memory.appendMessage({
7124
+ id: event.id,
7125
+ role: "user",
7126
+ type: "user_steer",
7127
+ content: event.content,
7128
+ timestamp: event.timestamp
7129
+ });
7130
+ break;
7131
+ }
7104
7132
  memory.addUserMessage(event.content, event.id, event.attachments);
7105
7133
  break;
7106
7134
  }
@@ -8808,6 +8836,62 @@ async function commitToolBoundary(state, result) {
8808
8836
  await state.local.commitExecutionBoundary(state);
8809
8837
  }
8810
8838
 
8839
+ // src/runtime-kernel/graph-engine/nodes/toolNode.pendingUserInput.ts
8840
+ function isPendingUserInputPort(value) {
8841
+ return !!value && typeof value === "object" && typeof Reflect.get(value, "claim") === "function" && typeof Reflect.get(value, "confirm") === "function" && typeof Reflect.get(value, "release") === "function";
8842
+ }
8843
+ function readRemainingSteps(state) {
8844
+ const value = state.local?.executorLocal?.remainingSteps;
8845
+ return typeof value === "number" && Number.isFinite(value) ? value : void 0;
8846
+ }
8847
+ function readIdentity(value, field) {
8848
+ if (typeof value !== "string" || value.trim().length === 0) {
8849
+ throw new Error(`ToolNode pending user input requires ${field}`);
8850
+ }
8851
+ return value;
8852
+ }
8853
+ async function claimPendingUserInputs(state, result) {
8854
+ if (result.kind !== "route" || result.nextNodeId !== "llm") return void 0;
8855
+ const local = state.local;
8856
+ const port = local?.pendingUserInputPort;
8857
+ if (!isPendingUserInputPort(port)) return void 0;
8858
+ const signal = local?.signal;
8859
+ if (signal?.aborted || isRunPauseSignal(signal)) return void 0;
8860
+ const remainingSteps = readRemainingSteps(state);
8861
+ if (remainingSteps !== void 0 && remainingSteps < 1) return void 0;
8862
+ const inputs = await port.claim();
8863
+ if (inputs.length === 0) return void 0;
8864
+ const ids = inputs.map((input) => input.id);
8865
+ try {
8866
+ const conversationId = readIdentity(local?.conversationId, "conversationId");
8867
+ const turnId = readIdentity(local?.turnId, "turnId");
8868
+ const sink = requireRuntimeEventSink(local);
8869
+ const events = inputs.map((input) => sink(
8870
+ createUserInputEvent(readIdentity(input.id, "input id"), conversationId, turnId, input.content, {
8871
+ timestamp: input.timestamp ?? Date.now(),
8872
+ delivery: "mid_run"
8873
+ }),
8874
+ "ToolNode.pending_user_input"
8875
+ ));
8876
+ state.local = {
8877
+ ...state.local,
8878
+ history: appendWorkingHistory(parseRuntimeEvents(state.local?.history ?? []), events)
8879
+ };
8880
+ return {
8881
+ events,
8882
+ confirm: async () => {
8883
+ await port.confirm(ids);
8884
+ },
8885
+ release: async () => {
8886
+ await port.release(ids);
8887
+ }
8888
+ };
8889
+ } catch (error) {
8890
+ await port.release(ids);
8891
+ throw error;
8892
+ }
8893
+ }
8894
+
8811
8895
  // src/runtime-kernel/graph-engine/nodes/toolNode.ts
8812
8896
  var logger11 = new Logger("ToolNode");
8813
8897
  function isAbortSignal(value) {
@@ -8975,7 +9059,19 @@ var ToolNode = class {
8975
9059
  });
8976
9060
  throw result.error;
8977
9061
  }
8978
- await commitToolBoundary(state, result);
9062
+ const steering = await claimPendingUserInputs(state, result);
9063
+ if (steering) {
9064
+ result = { ...result, events: [...result.events ?? [], ...steering.events] };
9065
+ try {
9066
+ await commitToolBoundary(state, result);
9067
+ } catch (error) {
9068
+ await steering.release();
9069
+ throw error;
9070
+ }
9071
+ await steering.confirm();
9072
+ } else {
9073
+ await commitToolBoundary(state, result);
9074
+ }
8979
9075
  if (Array.isArray(result.events) && result.events.length > 0) {
8980
9076
  events.push(...result.events);
8981
9077
  }
@@ -9733,7 +9829,8 @@ function parseEngineCheckpoint(value) {
9733
9829
  "runtimeFailureFactSink",
9734
9830
  "summarizationCallbacks",
9735
9831
  "commitExecutionBoundary",
9736
- "toolRecoveryPort"
9832
+ "toolRecoveryPort",
9833
+ "pendingUserInputPort"
9737
9834
  ]) {
9738
9835
  if (result.local && Object.hasOwn(result.local, key)) {
9739
9836
  throw new Error(`Checkpoint must not contain execution capability: ${key}`);