@tangle-network/agent-runtime 3.0.27 → 3.0.29

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 (60) hide show
  1. package/dist/{activation-CqrX_rjw.js → activation-C9FgGgEW.js} +2 -2
  2. package/dist/{activation-CqrX_rjw.js.map → activation-C9FgGgEW.js.map} +1 -1
  3. package/dist/{activation-CBcWaDyp.d.ts → activation-D0dnzmz_.d.ts} +2 -2
  4. package/dist/agent.d.ts +1 -1
  5. package/dist/agent.js +3 -3
  6. package/dist/{coordination-manager-D141UBzE.js → coordination-manager-3IBT4fOp.js} +4 -4
  7. package/dist/{coordination-manager-D141UBzE.js.map → coordination-manager-3IBT4fOp.js.map} +1 -1
  8. package/dist/{delegate-DGPuRCKg.js → delegate-fqRbRQME.js} +2 -2
  9. package/dist/{delegate-DGPuRCKg.js.map → delegate-fqRbRQME.js.map} +1 -1
  10. package/dist/durable.d.ts +1 -1
  11. package/dist/durable.js +6 -6
  12. package/dist/{graph-D-LohH0j.js → graph-CsSgkyoo.js} +8 -6
  13. package/dist/{graph-D-LohH0j.js.map → graph-CsSgkyoo.js.map} +1 -1
  14. package/dist/{improve-D_3wjXiP.js → improve-qZ9t6oxk.js} +6 -6
  15. package/dist/{improve-D_3wjXiP.js.map → improve-qZ9t6oxk.js.map} +1 -1
  16. package/dist/index.d.ts +3 -3
  17. package/dist/index.js +8 -8
  18. package/dist/intelligence.d.ts +2 -2
  19. package/dist/intelligence.js +4 -4
  20. package/dist/kernel.d.ts +1 -1
  21. package/dist/kernel.js +11 -11
  22. package/dist/{loop-runner-CE_S4Gun.js → loop-runner-Dp2soI-W.js} +2 -2
  23. package/dist/{loop-runner-CE_S4Gun.js.map → loop-runner-Dp2soI-W.js.map} +1 -1
  24. package/dist/{loop-runner-CgGtE2SB.d.ts → loop-runner-_3NabgWH.d.ts} +2 -2
  25. package/dist/loop-runner-bin.d.ts +1 -1
  26. package/dist/loop-runner-bin.js +1 -1
  27. package/dist/mcp/bin.js +3 -3
  28. package/dist/mcp/index.d.ts +1 -1
  29. package/dist/mcp/index.js +5 -5
  30. package/dist/profiles.d.ts +1 -1
  31. package/dist/{provision-supervisor-BT5Xcej8.js → provision-supervisor-ZNQrlbVI.js} +4 -4
  32. package/dist/{provision-supervisor-BT5Xcej8.js.map → provision-supervisor-ZNQrlbVI.js.map} +1 -1
  33. package/dist/{run-cancellation-cK_pnwLY.js → run-cancellation-C1Kc3xSa.js} +2 -2
  34. package/dist/{run-cancellation-cK_pnwLY.js.map → run-cancellation-C1Kc3xSa.js.map} +1 -1
  35. package/dist/{runtime-S74rNVKC.js → runtime-Boj_Xnu4.js} +11 -11
  36. package/dist/{runtime-S74rNVKC.js.map → runtime-Boj_Xnu4.js.map} +1 -1
  37. package/dist/{scope-DrU_M6r3.js → scope-wHHAJDCW.js} +62 -58
  38. package/dist/{scope-DrU_M6r3.js.map → scope-wHHAJDCW.js.map} +1 -1
  39. package/dist/{search-executor-C7u2UZP-.js → search-executor-CL4WALN1.js} +3 -3
  40. package/dist/{search-executor-C7u2UZP-.js.map → search-executor-CL4WALN1.js.map} +1 -1
  41. package/dist/{server-Br_imyE9.js → server-kvuX-VZP.js} +3 -3
  42. package/dist/{server-Br_imyE9.js.map → server-kvuX-VZP.js.map} +1 -1
  43. package/dist/{structural-rollout-Bn9MAIMS.js → structural-rollout-C3DLc7aS.js} +3 -3
  44. package/dist/{structural-rollout-Bn9MAIMS.js.map → structural-rollout-C3DLc7aS.js.map} +1 -1
  45. package/dist/{supervise-Tc0zimhk.js → supervise-CQRfWPkR.js} +60 -45
  46. package/dist/supervise-CQRfWPkR.js.map +1 -0
  47. package/dist/{supervision-discovery-D6AOCESM.js → supervision-discovery-BIaIjS6X.js} +2 -2
  48. package/dist/{supervision-discovery-D6AOCESM.js.map → supervision-discovery-BIaIjS6X.js.map} +1 -1
  49. package/dist/{supervisor-B5VVDFGE.js → supervisor-yqA4QDyx.js} +2 -2
  50. package/dist/{supervisor-B5VVDFGE.js.map → supervisor-yqA4QDyx.js.map} +1 -1
  51. package/dist/testing.d.ts +1 -1
  52. package/dist/testing.js +11 -11
  53. package/dist/{top-web-Dp8lrmPw.js → top-web-yUlMaJfx.js} +4 -4
  54. package/dist/{top-web-Dp8lrmPw.js.map → top-web-yUlMaJfx.js.map} +1 -1
  55. package/dist/tui/bin.js +3 -3
  56. package/dist/tui/index.d.ts +1 -1
  57. package/dist/tui/index.js +2 -2
  58. package/dist/{types-3ZVht8Pk.d.ts → types-DQ4JHRDD.d.ts} +79 -74
  59. package/package.json +1 -1
  60. package/dist/supervise-Tc0zimhk.js.map +0 -1
@@ -1,13 +1,13 @@
1
- import { $n as persistHarnessTranscript, $r as RetainedExecutionPendingError, At as beginScopeRetainedOwnerDrive, B as beginScopeOwnerAttempt, Ci as newUsageTotals, Cr as inheritRuntimeOwnedExecutorAttestation, Dr as providerAttemptEvidence, Dt as prepareScopeRetainedOwnerTask, Ei as assertValidBudget, Et as consumeScopeRetainedOwnerResult, Fr as runtimeOwnedExecutorMaterialization, Ft as scopeRetainedOwnerRestorePoint, G as scopeOwnerExecutorNodeContext, Gr as runtimeFlowBrain, H as noteScopeOwnerPlannedExecution, Ht as scopeRetainedOwnerJournalRoot, Ir as runtimeOwnedExecutorProviderEvidence, It as noteScopeRetainedOwnerCoordination, J as providerVisibleProfile, K as coordinationMcpAlias, Lr as runtimeOwnedPendingExecutorMaterialization, Mt as scopeRetainedOwnerTurnEnded, Nr as runtimeOwnedDriveHarnessProviderEvidence, Nt as assertRetainedOwnerCoordinationRekey, O as parseWorkerToolTraceArtifact, Or as recordRuntimeOwnedDriveHarnessProviderEvidence, Ot as scopeRetainedOwnerPriorSpend, Pr as runtimeOwnedExecutorExecutionBinding, Pt as reconcileScopeRetainedOwnerEnvironment, Q as assertRecursiveReservationPolicy, Rr as runtimeOwnedScopeOwnerRuntime, Rt as bindScopeRetainedOwnerEnvironmentId, Si as meterUsageEvent, St as scopeRetainedOwnerResourceReader, Ti as spendFromUsageTotals, Tt as abandonScopeRetainedOwnerInvocation, U as recordScopeOwnerMaterialization, Ur as isRuntimeFlowBrain, Vn as generateSpanId, Vt as scopeRetainedOwnerContext, W as restoreScopeOwnerAcceptedExecution, Wr as runtimeFlowAgent, Y as runtimeGraphMetadataKey, Yi as recordValue, _i as executorFailure, a as readRootStream, aa as runAbortable, ai as retainedExecutorSeamKey, br as authoredAgentIdentity, bt as prepareScopeRetainedOwnerSeatSwitch, ci as cappedDoublingMs, ct as recordScopeOwnerBarrenPause, di as unavailableResumeAt, dr as SeatChain, er as readHarnessTranscript, fr as SeatChainExhaustedError, hi as contentAddress, ia as linkAbort, kn as WORKER_TRACE_PROPAGATION, kt as scopeRetainedOwnerResult, li as jitteredMs, lr as isLiveNodeStatus, lt as recordScopeOwnerDriverAttempt, mr as seatExecutionProfile, n as ROOT_STREAM_FILE, na as RunCancellationReason, or as createActivityLog, ot as meterRuntimeOwnedAccounting, pr as authoredSeatStages, q as coordinationProfileToolPrefix, r as createRootStreamSink, ri as registerRetainedExecutorPreparation, st as meterRuntimeOwnedProviderAttempt, ui as unavailablePauseMs, ur as isTerminalNodeStatus, ut as recordScopeOwnerPause, xt as releaseScopeRetainedOwnerForSeatPause, yr as attestRuntimeOwnedScopeOwner, zn as createOtelExporter, zt as bindScopeRetainedOwnerProvider } from "./scope-DrU_M6r3.js";
1
+ import { $n as persistHarnessTranscript, $r as RetainedExecutionPendingError, At as beginScopeRetainedOwnerDrive, B as beginScopeOwnerAttempt, Ci as newUsageTotals, Cr as inheritRuntimeOwnedExecutorAttestation, Dr as providerAttemptEvidence, Dt as prepareScopeRetainedOwnerTask, Ei as assertValidBudget, Et as consumeScopeRetainedOwnerResult, Fr as runtimeOwnedExecutorMaterialization, Ft as scopeRetainedOwnerRestorePoint, G as scopeOwnerExecutorNodeContext, Gr as runtimeFlowBrain, H as noteScopeOwnerPlannedExecution, Ht as scopeRetainedOwnerJournalRoot, Ir as runtimeOwnedExecutorProviderEvidence, It as noteScopeRetainedOwnerCoordination, J as providerVisibleProfile, K as coordinationMcpAlias, Lr as runtimeOwnedPendingExecutorMaterialization, Mt as scopeRetainedOwnerTurnEnded, Nr as runtimeOwnedDriveHarnessProviderEvidence, Nt as assertRetainedOwnerCoordinationRekey, O as parseWorkerToolTraceArtifact, Or as recordRuntimeOwnedDriveHarnessProviderEvidence, Ot as scopeRetainedOwnerPriorSpend, Pr as runtimeOwnedExecutorExecutionBinding, Pt as reconcileScopeRetainedOwnerEnvironment, Q as assertRecursiveReservationPolicy, Rr as runtimeOwnedScopeOwnerRuntime, Rt as bindScopeRetainedOwnerEnvironmentId, Si as meterUsageEvent, St as scopeRetainedOwnerResourceReader, Ti as spendFromUsageTotals, Tt as abandonScopeRetainedOwnerInvocation, U as recordScopeOwnerMaterialization, Ur as isRuntimeFlowBrain, Vn as generateSpanId, Vt as scopeRetainedOwnerContext, W as restoreScopeOwnerAcceptedExecution, Wr as runtimeFlowAgent, Y as runtimeGraphMetadataKey, Yi as recordValue, _i as executorFailure, a as readRootStream, aa as runAbortable, ai as retainedExecutorSeamKey, br as authoredAgentIdentity, bt as prepareScopeRetainedOwnerSeatSwitch, ci as cappedDoublingMs, ct as recordScopeOwnerBarrenPause, di as unavailableResumeAt, dr as SeatChain, er as readHarnessTranscript, fr as SeatChainExhaustedError, hi as contentAddress, ia as linkAbort, kn as WORKER_TRACE_PROPAGATION, kt as scopeRetainedOwnerResult, li as jitteredMs, lr as isLiveNodeStatus, lt as recordScopeOwnerDriverAttempt, mr as seatExecutionProfile, n as ROOT_STREAM_FILE, na as RunCancellationReason, or as createActivityLog, ot as meterRuntimeOwnedAccounting, pr as authoredSeatStages, q as coordinationProfileToolPrefix, r as createRootStreamSink, ri as registerRetainedExecutorPreparation, st as meterRuntimeOwnedProviderAttempt, ui as unavailablePauseMs, ur as isTerminalNodeStatus, ut as recordScopeOwnerPause, xt as releaseScopeRetainedOwnerForSeatPause, yr as attestRuntimeOwnedScopeOwner, zn as createOtelExporter, zt as bindScopeRetainedOwnerProvider } from "./scope-wHHAJDCW.js";
2
2
  import { f as RuntimeRunStateError, i as ConfigError, m as ValidationError } from "./errors-AzSuGI23.js";
3
3
  import { $ as isAsyncIterable, Dt as teardownExecutor, G as chargedTokens, Ot as teardownSurfaces, St as armDeadlineTimer, Tt as isDeadlineAbortReason, U as addSpend, Y as errorMessage, at as sleep, bt as DEFAULT_SUCCESSFUL_SHUTDOWN_MS, dt as zeroSpend, gt as withBudgetResources, ht as resourceTelemetry, lt as unmeteredSpend, pt as addResourceSpend, tt as promptCacheTokenClasses, ut as withTimeout } from "./workspace-streams-8ALHaZzx.js";
4
4
  import { d as detachedSnapshot, h as errorHttpStatus, m as errMessage } from "./jsonl-file-BBP9Dz9w.js";
5
- import { $t as promptModelProfileMaterialization, At as bridgeModelRouteRefusal, B as createRouterTranscript, C as createExecutor, Ct as admitContinuationPolicy, Et as createContinuationKeeper, F as codeModeArguments, I as codeModeModelOutput, Jt as controlProfileMaterialization, Kt as assertProfileMaterialization, L as createCodeModeTools, Qt as promptControlProfileMaterialization, Rt as bridgeRuntimeAttachmentsKey, S as captureReusableExecutorConfig, St as CONTINUATIONS_DIR, Tt as checkVerdictOf, U as resolveAgentEnvironmentProvider, V as routerBrain, X as createInbox, Xt as fullProfileMaterialization, Y as INBOX_RECEIPT_KEY, Yt as defineProfileMaterializationContract, Zt as profileMaterializationAxes$1, _t as CheckUnavailableError, a as assertRunParking, c as sleepScopeWait, ct as HarnessTurnFailedError, d as runFinalizer, dt as classifyDriverFailure, en as renderUnsupported, et as PEER_MAIL_WIRE_KEY, f as runTree, ft as isContentFilterRefusal, g as isDriverSpec, gt as preflightPublicCoordination, h as driverExecutorFactory, ht as upstreamUnavailableSignal, i as RunParkedError, in as worktreeCliProfileMaterialization, kt as bridgeAdmissionRefusal, l as withRunParking, lt as abandonablePending, m as driverChild, mt as undispatchedCredentialExit, n as createSupervisor, nn as sandboxProfileMaterialization, o as bindScopeParkingDrain, p as createRootHandle, pt as summarizeDriverAttempts, rn as unsupportedProfileDimensions, rt as isPeerMailEnvelope, st as DriverAttemptsExhaustedError, u as bestDelivered, ut as causedByPartialFailure, vt as gateFactoryOnDeliverable, w as snapshotExecutorConfig, wt as bestComposite, x as bindReusableExecutorExecutionId, z as toolResultText, zt as bridgeStopSignalKey } from "./supervisor-B5VVDFGE.js";
5
+ import { $t as promptModelProfileMaterialization, At as bridgeModelRouteRefusal, B as createRouterTranscript, C as createExecutor, Ct as admitContinuationPolicy, Et as createContinuationKeeper, F as codeModeArguments, I as codeModeModelOutput, Jt as controlProfileMaterialization, Kt as assertProfileMaterialization, L as createCodeModeTools, Qt as promptControlProfileMaterialization, Rt as bridgeRuntimeAttachmentsKey, S as captureReusableExecutorConfig, St as CONTINUATIONS_DIR, Tt as checkVerdictOf, U as resolveAgentEnvironmentProvider, V as routerBrain, X as createInbox, Xt as fullProfileMaterialization, Y as INBOX_RECEIPT_KEY, Yt as defineProfileMaterializationContract, Zt as profileMaterializationAxes$1, _t as CheckUnavailableError, a as assertRunParking, c as sleepScopeWait, ct as HarnessTurnFailedError, d as runFinalizer, dt as classifyDriverFailure, en as renderUnsupported, et as PEER_MAIL_WIRE_KEY, f as runTree, ft as isContentFilterRefusal, g as isDriverSpec, gt as preflightPublicCoordination, h as driverExecutorFactory, ht as upstreamUnavailableSignal, i as RunParkedError, in as worktreeCliProfileMaterialization, kt as bridgeAdmissionRefusal, l as withRunParking, lt as abandonablePending, m as driverChild, mt as undispatchedCredentialExit, n as createSupervisor, nn as sandboxProfileMaterialization, o as bindScopeParkingDrain, p as createRootHandle, pt as summarizeDriverAttempts, rn as unsupportedProfileDimensions, rt as isPeerMailEnvelope, st as DriverAttemptsExhaustedError, u as bestDelivered, ut as causedByPartialFailure, vt as gateFactoryOnDeliverable, w as snapshotExecutorConfig, wt as bestComposite, x as bindReusableExecutorExecutionId, z as toolResultText, zt as bridgeStopSignalKey } from "./supervisor-yqA4QDyx.js";
6
6
  import { _ as agentHarness, a as concreteProfileModel, c as profileModelExecutionSettings, l as profileProviderModel, n as assertModelAllowed, o as enforceTokenLimits, r as assertProfileModelsAllowed, s as profileBridgeWireModel, t as assertExecutableAgentProfile, v as harnessRunsAgent } from "./model-policy-C-RGAUW4.js";
7
7
  import { n as createStdioToolServer } from "./tool-server-CZWd_Opp.js";
8
8
  import { t as composeRuntimeHooks } from "./runtime-hooks-CsW2pfFk.js";
9
- import { _ as workerAssignmentNamespace, c as writeRunCancellation, d as coordinationEventId, f as externalExecutionId, g as supervisionRunNamespace, h as rootCoordinationOwner, i as readRunCancellation, l as canonicalExecution, m as freezeDetachedProfile, p as freezeDetached, r as readRunCancelRequest, s as watchRunCancellation, t as applyRunCancellation, u as childCoordinationOwner } from "./run-cancellation-cK_pnwLY.js";
10
- import { c as createSteerAcknowledger, d as coordinationVerbNames, f as createFileRunContext, l as budgetOverspendText, m as withRunContext, n as createCoordinationToolsForManager, p as createInMemoryRunContext, s as createCancelAcknowledger, t as createCoordinationTools, u as normalizeAnalyzeOnSettle } from "./coordination-manager-D141UBzE.js";
9
+ import { _ as workerAssignmentNamespace, c as writeRunCancellation, d as coordinationEventId, f as externalExecutionId, g as supervisionRunNamespace, h as rootCoordinationOwner, i as readRunCancellation, l as canonicalExecution, m as freezeDetachedProfile, p as freezeDetached, r as readRunCancelRequest, s as watchRunCancellation, t as applyRunCancellation, u as childCoordinationOwner } from "./run-cancellation-C1Kc3xSa.js";
10
+ import { c as createSteerAcknowledger, d as coordinationVerbNames, f as createFileRunContext, l as budgetOverspendText, m as withRunContext, n as createCoordinationToolsForManager, p as createInMemoryRunContext, s as createCancelAcknowledger, t as createCoordinationTools, u as normalizeAnalyzeOnSettle } from "./coordination-manager-3IBT4fOp.js";
11
11
  import { o as safeJsonText } from "./coordination-map-routing-BllzcZov.js";
12
12
  import { a as graphRegistry, c as loadGraph } from "./graph-registry-D6y6zffC.js";
13
13
  import { ATTR, agentIdentityAttributes } from "@tangle-network/agent-trace-contract";
@@ -52,6 +52,7 @@ const superviseOptionKeySet = /* @__PURE__ */ new Set([
52
52
  "extraTools",
53
53
  "finalizer",
54
54
  "graphRegistry",
55
+ "promptRegistry",
55
56
  "hooks",
56
57
  "inheritSpawnRights",
57
58
  "journal",
@@ -128,7 +129,28 @@ function captureDeliverable(deliverable, context) {
128
129
  ...deliverable.checkState === void 0 ? {} : { checkState: deliverable.checkState }
129
130
  });
130
131
  }
131
- Object.freeze([...[
132
+ /**
133
+ * Every `SuperviseOptions` key whose value IS a callback, as data.
134
+ *
135
+ * `captureSuperviseOptions` detaches its decision data with `detachedSnapshot`, which
136
+ * structured-clones. A function cannot be structured-cloned, so a callback key that the capture
137
+ * does not lift out of the remainder makes `supervise()` throw
138
+ * `supervise options: input must be structured-cloneable` before any compute — a refusal that names
139
+ * the snapshot rather than the option, so a caller reads it as a bad value and not as a capability
140
+ * the entry point cannot carry.
141
+ *
142
+ * That is what happened to the retired `onUnmetContract`: added with the re-prompt path in 0.186.0,
143
+ * accepted by the option-key check, forwarded by `supervisorAgent`, read by the retry loop, and
144
+ * never destructured here. Every `supervisePursuit` run that passed the callback failed at
145
+ * construction on 0.186.0, 0.187.1 and 0.188.0, and the only working configuration was the number
146
+ * alone.
147
+ *
148
+ * The assignment below fails to COMPILE, naming the offender, when a callback-valued option is not
149
+ * in this list, so the next one cannot be added silently. The list is not merely documentation:
150
+ * {@link assertNoUncapturedExecutableOption} refuses at runtime any callback that still reaches the
151
+ * snapshot, including one nested in an option this type test cannot see.
152
+ */
153
+ const superviseExecutableOptionKeys = [
132
154
  "authorizeMessage",
133
155
  "authorizeSpawn",
134
156
  "decideGate",
@@ -150,7 +172,26 @@ Object.freeze([...[
150
172
  "selectSeat",
151
173
  "resolveSupervisorTools",
152
174
  "stopRule"
153
- ]]);
175
+ ];
176
+ Object.freeze([...superviseExecutableOptionKeys]);
177
+ /** The options captured as the exact references selected at intake, never deep-snapshot: every
178
+ * callback, plus live collaborators. Stores, journals and registries resolve lazily, hooks and
179
+ * otel exporters are process objects, and a shared `workerSlots` allocator is held by other runs
180
+ * too. Object-valued options that only contain callbacks are captured field by field below. */
181
+ const superviseReferenceOptionKeys = /* @__PURE__ */ new Set([
182
+ ...superviseExecutableOptionKeys,
183
+ "blobs",
184
+ "hooks",
185
+ "journal",
186
+ "otel",
187
+ "promptRegistry",
188
+ "registry",
189
+ "resume",
190
+ "rootHandle",
191
+ "runContext",
192
+ "signal",
193
+ "workerSlots"
194
+ ]);
154
195
  /**
155
196
  * Refuse a callback that reached the decision-data remainder, naming the option.
156
197
  *
@@ -161,7 +202,7 @@ Object.freeze([...[
161
202
  */
162
203
  function assertNoUncapturedExecutableOption(decisionData) {
163
204
  const carried = Object.entries(decisionData).filter(([, value]) => typeof value === "function").map(([key]) => key);
164
- if (carried.length > 0) throw new ValidationError(`supervise: option ${carried.sort().join(", ")} carries a callback that the option capture does not forward, so the run would fail on a structured-clone refusal that names the snapshot instead of the option; lift the key out of the decision data in captureSuperviseOptions and add it to superviseExecutableOptionKeys`);
205
+ if (carried.length > 0) throw new ValidationError(`supervise: option ${carried.sort().join(", ")} carries a callback that the option capture does not forward, so the run would fail on a structured-clone refusal that names the snapshot instead of the option; add the key to superviseExecutableOptionKeys`);
165
206
  }
166
207
  /** Capture the public one-call configuration before any asynchronous work starts. Decision data is
167
208
  * detached and frozen; executable ports are copied as the exact references selected at intake.
@@ -169,7 +210,11 @@ function assertNoUncapturedExecutableOption(decisionData) {
169
210
  * mutable options object can no longer change an in-flight run. */
170
211
  function captureSuperviseOptions(opts) {
171
212
  assertSuperviseOptionKeys(opts, "supervise");
172
- const { backend, selectSeat, coordination, driverBackend, deliverable, resolveDeliverable, router, compaction, watchWorkers, analysts, makeWorkerAgent, makeLeafAgent, recoverExecutor, resume, resolveSpawnProfile, blobs, journal, runContext, registry, hooks, otel, authorizeSpawn, authorizeMessage, driveHarness, resolveDriveHarness, resolveSupervisorTools, escalateQuestion, decideGate, onCoordinationEvent, executeExtraTool, stopRule, onProgressStop, onDriverAttempt, continuation, workerRetry, onWorkerRetry, finalizer, now, signal, rootHandle, workerSlots, ...decisionData } = opts;
213
+ const { backend, coordination, driverBackend, deliverable, router, compaction, watchWorkers, analysts, continuation, workerRetry, ...rest } = opts;
214
+ const references = {};
215
+ const decisionData = {};
216
+ for (const [key, value] of Object.entries(rest)) if (!superviseReferenceOptionKeys.has(key)) decisionData[key] = value;
217
+ else if (value !== void 0) references[key] = value;
173
218
  assertNoUncapturedExecutableOption(decisionData);
174
219
  const capturedData = detachedSnapshot(decisionData, "supervise options");
175
220
  const capturedCoordination = coordination === void 0 ? void 0 : (() => {
@@ -229,47 +274,17 @@ function captureSuperviseOptions(opts) {
229
274
  })();
230
275
  return Object.freeze({
231
276
  ...capturedData,
277
+ ...references,
232
278
  ...capturedCoordination === void 0 ? {} : { coordination: capturedCoordination },
233
279
  ...capturedBackend === void 0 ? {} : { backend: capturedBackend },
234
- ...selectSeat === void 0 ? {} : { selectSeat },
235
280
  ...capturedDriverBackend === void 0 ? {} : { driverBackend: capturedDriverBackend },
236
281
  ...capturedDeliverable === void 0 ? {} : { deliverable: capturedDeliverable },
237
- ...resolveDeliverable === void 0 ? {} : { resolveDeliverable },
238
282
  ...capturedRouter === void 0 ? {} : { router: capturedRouter },
239
283
  ...capturedCompaction === void 0 ? {} : { compaction: capturedCompaction },
240
284
  ...capturedWatchWorkers === void 0 ? {} : { watchWorkers: capturedWatchWorkers },
241
285
  ...capturedAnalysts === void 0 ? {} : { analysts: capturedAnalysts },
242
- ...makeWorkerAgent === void 0 ? {} : { makeWorkerAgent },
243
- ...makeLeafAgent === void 0 ? {} : { makeLeafAgent },
244
- ...recoverExecutor === void 0 ? {} : { recoverExecutor },
245
- ...resolveSpawnProfile === void 0 ? {} : { resolveSpawnProfile },
246
- ...blobs === void 0 ? {} : { blobs },
247
- ...journal === void 0 ? {} : { journal },
248
- ...resume === void 0 ? {} : { resume },
249
- ...runContext === void 0 ? {} : { runContext },
250
- ...workerSlots === void 0 ? {} : { workerSlots },
251
- ...authorizeSpawn === void 0 ? {} : { authorizeSpawn },
252
- ...authorizeMessage === void 0 ? {} : { authorizeMessage },
253
- ...driveHarness === void 0 ? {} : { driveHarness },
254
- ...resolveDriveHarness === void 0 ? {} : { resolveDriveHarness },
255
- ...resolveSupervisorTools === void 0 ? {} : { resolveSupervisorTools },
256
- ...escalateQuestion === void 0 ? {} : { escalateQuestion },
257
- ...decideGate === void 0 ? {} : { decideGate },
258
- ...onCoordinationEvent === void 0 ? {} : { onCoordinationEvent },
259
- ...executeExtraTool === void 0 ? {} : { executeExtraTool },
260
- ...stopRule === void 0 ? {} : { stopRule },
261
- ...onProgressStop === void 0 ? {} : { onProgressStop },
262
- ...onDriverAttempt === void 0 ? {} : { onDriverAttempt },
263
286
  ...capturedContinuation === void 0 ? {} : { continuation: capturedContinuation },
264
- ...capturedWorkerRetry === void 0 ? {} : { workerRetry: capturedWorkerRetry },
265
- ...onWorkerRetry === void 0 ? {} : { onWorkerRetry },
266
- ...finalizer === void 0 ? {} : { finalizer },
267
- ...now === void 0 ? {} : { now },
268
- ...signal === void 0 ? {} : { signal },
269
- ...rootHandle === void 0 ? {} : { rootHandle },
270
- ...registry === void 0 ? {} : { registry },
271
- ...hooks === void 0 ? {} : { hooks },
272
- ...otel === void 0 ? {} : { otel }
287
+ ...capturedWorkerRetry === void 0 ? {} : { workerRetry: capturedWorkerRetry }
273
288
  });
274
289
  }
275
290
  // src/runtime/supervise/otel-spans.ts
@@ -7597,11 +7612,12 @@ function createSuperviseWorkers(setup, cancelDurableRun) {
7597
7612
  const { options, canonicalProfile, rootExecution, guidanceComposer, deliverable, analysts, journal, runId, rootOwnerId, now } = setup;
7598
7613
  const recoveryFactories = /* @__PURE__ */ new WeakMap();
7599
7614
  const graphOverlays = /* @__PURE__ */ new Set();
7615
+ const subtaskDirectives = options.promptRegistry ?? kernelPromptRegistry();
7600
7616
  const graphSubtasks = options.makeWorkerAgent === void 0 ? { prepare: async (input) => {
7601
7617
  try {
7602
7618
  const topology = input.graphDigest === void 0 ? parseGraphSubtaskTopology(input.graph) : await storedGraphTopology(options.graphRegistry, input.graphDigest);
7603
7619
  const prepared = prepareGraphSubtask(topology, {
7604
- registry: kernelPromptRegistry(),
7620
+ registry: subtaskDirectives,
7605
7621
  ...analysts ? { analysts } : {},
7606
7622
  ...guidanceComposer ? { guidance: guidanceComposer } : {}
7607
7623
  });
@@ -7622,10 +7638,9 @@ function createSuperviseWorkers(setup, cancelDurableRun) {
7622
7638
  } } : void 0;
7623
7639
  const productAuthority = productSpawnAuthority(options.authorizeSpawn);
7624
7640
  const graphOverlayFor = (topology) => {
7625
- const registry = kernelPromptRegistry();
7626
- const validated = validateGraphSubtask(topology, registry, analysts);
7641
+ const validated = validateGraphSubtask(topology, subtaskDirectives, analysts);
7627
7642
  const overlay = createGraphOverlay(validated, {
7628
- registry,
7643
+ registry: subtaskDirectives,
7629
7644
  journal,
7630
7645
  runId,
7631
7646
  now,
@@ -9432,4 +9447,4 @@ function superviseWithContext(profile, task, opts, brain) {
9432
9447
  }
9433
9448
  export { analyzesFindingsReportPrompt as A, anyOf as B, flowRootProfile as C, defaultEdgeTraversalCap as D, validateFlowGraph as E, formatPromptHandle as F, bestSoFar as G, plateau as H, kernelPromptRegistry as I, createSupervisorSpanRecorder as J, plateauLength as K, naiveContinuationPrompt as L, delegatesWorkerBriefPrompt as M, dumbContinuationFailPrompt as N, graphRootProfile as O, dumbContinuationPassPrompt as P, promptHandle as R, createFlowRun as S, routeFlowOf as T, anytimeReport as U, noProgressFor as V, areaUnderCurve as W, coordinationControlToolNames as _, superviseRootProfile as a, createGraphOverlay as b, retryPreSpawnRefusals as c, supervisorAgent as d, supervisorAgentWithTestBrain as f, serveCoordinationMcp as g, composeReentryTask as h, profileGuidanceComposer as i, createPromptRegistry as j, validateGraphTopology as k, withWorkerSpawnRetry as l, UNPROVEN_CONTINUITY as m, superviseFleetCapabilities as n, isPreSpawnExecutorFailure as o, runToolSpans as p, renderAnytimeTable as q, superviseWithTestBrain as r, resolveWorkerSpawnRetry as s, supervise as t, workerFromBackend as u, driverAgent as v, journaledGateDecider as w, GraphRouteError as x, runBrainLoop as y, allWorkersStalled as z };
9434
9449
 
9435
- //# sourceMappingURL=supervise-Tc0zimhk.js.map
9450
+ //# sourceMappingURL=supervise-CQRfWPkR.js.map