@tangle-network/agent-runtime 3.0.40 → 3.0.41
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{activation-CCttbkSj.d.ts → activation-C1_GUwX8.d.ts} +2 -2
- package/dist/{activation-n22lMRhH.js → activation-CiM6hSrn.js} +2 -2
- package/dist/{activation-n22lMRhH.js.map → activation-CiM6hSrn.js.map} +1 -1
- package/dist/agent.d.ts +1 -1
- package/dist/agent.js +3 -3
- package/dist/{coordination-manager-C_ohXf63.js → coordination-manager-_PcKOR-S.js} +4 -4
- package/dist/{coordination-manager-C_ohXf63.js.map → coordination-manager-_PcKOR-S.js.map} +1 -1
- package/dist/{delegate-BYLjG7Ev.js → delegate-VmOpqr4q.js} +2 -2
- package/dist/{delegate-BYLjG7Ev.js.map → delegate-VmOpqr4q.js.map} +1 -1
- package/dist/durable.d.ts +1 -1
- package/dist/durable.js +6 -6
- package/dist/{graph-T1-PBhLx.js → graph-C3K0vEg-.js} +5 -5
- package/dist/{graph-T1-PBhLx.js.map → graph-C3K0vEg-.js.map} +1 -1
- package/dist/{improve-BqMfcxh1.js → improve-DhTBR1p-.js} +6 -6
- package/dist/{improve-BqMfcxh1.js.map → improve-DhTBR1p-.js.map} +1 -1
- package/dist/index.d.ts +4 -4
- package/dist/index.js +8 -8
- package/dist/intelligence.d.ts +2 -2
- package/dist/intelligence.js +4 -4
- package/dist/kernel.d.ts +2 -2
- package/dist/kernel.js +11 -11
- package/dist/{loop-runner-CGa71-66.js → loop-runner-BCNdBh8P.js} +2 -2
- package/dist/{loop-runner-CGa71-66.js.map → loop-runner-BCNdBh8P.js.map} +1 -1
- package/dist/{loop-runner-CRZ3pF7w.d.ts → loop-runner-DMBWRkx0.d.ts} +2 -2
- package/dist/loop-runner-bin.d.ts +1 -1
- package/dist/loop-runner-bin.js +1 -1
- package/dist/mcp/bin.js +3 -3
- package/dist/mcp/index.d.ts +1 -1
- package/dist/mcp/index.js +5 -5
- package/dist/profiles.d.ts +1 -1
- package/dist/{provision-supervisor-Dl6oYQDN.js → provision-supervisor-wJp8ECNK.js} +4 -4
- package/dist/{provision-supervisor-Dl6oYQDN.js.map → provision-supervisor-wJp8ECNK.js.map} +1 -1
- package/dist/{run-cancellation-BzmmqlM8.js → run-cancellation-Xh0hv_aO.js} +2 -2
- package/dist/{run-cancellation-BzmmqlM8.js.map → run-cancellation-Xh0hv_aO.js.map} +1 -1
- package/dist/{runtime-DoUb4SOs.js → runtime-C_bXuIBi.js} +11 -11
- package/dist/{runtime-DoUb4SOs.js.map → runtime-C_bXuIBi.js.map} +1 -1
- package/dist/{scope-BGWRFiYt.js → scope-D04GkJ6P.js} +21 -21
- package/dist/scope-D04GkJ6P.js.map +1 -0
- package/dist/{search-executor-DPBewC3S.js → search-executor-Dzhi0WRa.js} +3 -3
- package/dist/{search-executor-DPBewC3S.js.map → search-executor-Dzhi0WRa.js.map} +1 -1
- package/dist/{server-M9dG-WG9.js → server-BQhawXPP.js} +3 -3
- package/dist/{server-M9dG-WG9.js.map → server-BQhawXPP.js.map} +1 -1
- package/dist/{structural-rollout-BylGQ_wK.js → structural-rollout-xXWwKM4G.js} +3 -3
- package/dist/{structural-rollout-BylGQ_wK.js.map → structural-rollout-xXWwKM4G.js.map} +1 -1
- package/dist/{supervise-BfT708zt.js → supervise-Dh8Mp3v8.js} +5 -5
- package/dist/{supervise-BfT708zt.js.map → supervise-Dh8Mp3v8.js.map} +1 -1
- package/dist/{supervision-discovery-C2Tjw6LX.js → supervision-discovery-CcTLSYff.js} +2 -2
- package/dist/{supervision-discovery-C2Tjw6LX.js.map → supervision-discovery-CcTLSYff.js.map} +1 -1
- package/dist/{supervisor-BDnqTl_R.js → supervisor-BQz8lkcd.js} +59 -63
- package/dist/supervisor-BQz8lkcd.js.map +1 -0
- package/dist/testing.d.ts +1 -1
- package/dist/testing.js +11 -11
- package/dist/{top-web-Ms-SgnGN.js → top-web-D-QEIh-x.js} +13 -6
- package/dist/{top-web-Ms-SgnGN.js.map → top-web-D-QEIh-x.js.map} +1 -1
- package/dist/tui/bin.js +3 -3
- package/dist/tui/index.d.ts +1 -1
- package/dist/tui/index.js +2 -2
- package/dist/{types-CQviVtZC.d.ts → types-CRCOBzGj.d.ts} +15581 -15578
- package/package.json +2 -2
- package/dist/scope-BGWRFiYt.js.map +0 -1
- package/dist/supervisor-BDnqTl_R.js.map +0 -1
|
@@ -10074,6 +10074,7 @@ function registerScopeRetainedOwner(scope, args) {
|
|
|
10074
10074
|
const attempt = events.slice(start);
|
|
10075
10075
|
const admissions = attempt.flatMap((event) => event.kind === "execution-admitted" ? [event.admission] : []);
|
|
10076
10076
|
const acceptedRef = [...attempt].reverse().find((event) => event.kind === "execution-result");
|
|
10077
|
+
let observed = events.flatMap((event) => event.kind === "driver-attempt" ? [event.record] : []).filter((record) => record.observed).at(-1)?.observed;
|
|
10077
10078
|
const priorSession = taskEvent === void 0 ? void 0 : committedSession(events, start);
|
|
10078
10079
|
let sequence = Math.max(0, ...events.map((event) => "seq" in event ? event.seq : 0));
|
|
10079
10080
|
const traceRoots = traceRootWriter(args.blobs, args.nodeId);
|
|
@@ -10118,6 +10119,12 @@ function registerScopeRetainedOwner(scope, args) {
|
|
|
10118
10119
|
at: new Date(args.now()).toISOString()
|
|
10119
10120
|
});
|
|
10120
10121
|
},
|
|
10122
|
+
get observed() {
|
|
10123
|
+
return observed;
|
|
10124
|
+
},
|
|
10125
|
+
onObserved: (position) => {
|
|
10126
|
+
observed = position;
|
|
10127
|
+
},
|
|
10121
10128
|
onAdmission: async (admission) => {
|
|
10122
10129
|
scope.signal.throwIfAborted();
|
|
10123
10130
|
const prior = admissions.find((record) => record.phase === admission.phase);
|
|
@@ -10184,13 +10191,9 @@ function registerScopeRetainedOwner(scope, args) {
|
|
|
10184
10191
|
};
|
|
10185
10192
|
owners.set(scope, state);
|
|
10186
10193
|
}
|
|
10187
|
-
/**
|
|
10188
|
-
*
|
|
10189
|
-
*
|
|
10190
|
-
* which never committed one. A live process keeps the same session across an abandonment, so a
|
|
10191
|
-
* resumed one must derive it the same way or its replay of the next invocation would not match
|
|
10192
|
-
* the material that invocation admitted.
|
|
10193
|
-
*/
|
|
10194
|
+
/** The environment admission an invocation starting at `before` continues in: the latest earlier
|
|
10195
|
+
* committed invocation's, past abandoned ones. A live process keeps its session across an
|
|
10196
|
+
* abandonment, so a resumed one derives it the same way or its replay would not match. */
|
|
10194
10197
|
function committedSession(events, before) {
|
|
10195
10198
|
let end = before;
|
|
10196
10199
|
for (;;) {
|
|
@@ -10207,16 +10210,10 @@ function committedSession(events, before) {
|
|
|
10207
10210
|
}
|
|
10208
10211
|
/** Bounds the stop Runtime asks for before abandoning a dispatched invocation. */
|
|
10209
10212
|
const ABANDON_STOP_TIMEOUT_MS = 3e4;
|
|
10210
|
-
/**
|
|
10211
|
-
*
|
|
10212
|
-
*
|
|
10213
|
-
*
|
|
10214
|
-
* Runtime abandons only after the provider confirms the dispatched execution stopped or is no
|
|
10215
|
-
* longer live. An intent without a dispatch reference, or an unconfirmed stop, keeps the original
|
|
10216
|
-
* invocation recoverable under the same identity. The journal refuses every later admission or
|
|
10217
|
-
* result of an abandoned invocation, so only its replacement can commit a result. Answers `false`,
|
|
10218
|
-
* journaling nothing, when there is no unfinished invocation or its native stop is unconfirmed.
|
|
10219
|
-
*/
|
|
10213
|
+
/** Abandon the owner's in-flight invocation when its reconciliation keeps failing the same way
|
|
10214
|
+
* (`DriverRetryRun.resolvePending`), only once the provider confirms the dispatched execution
|
|
10215
|
+
* stopped or is not live; the journal then refuses its later admissions and results. Answers
|
|
10216
|
+
* `false`, journaling nothing, without an unfinished invocation or a confirmed native stop. */
|
|
10220
10217
|
async function abandonScopeRetainedOwnerInvocation(scope, failure, failures) {
|
|
10221
10218
|
const state = owners.get(scope);
|
|
10222
10219
|
if (state === void 0 || state.inputSequence === void 0) return false;
|
|
@@ -10225,7 +10222,8 @@ async function abandonScopeRetainedOwnerInvocation(scope, failure, failures) {
|
|
|
10225
10222
|
const latestInput = [...owned].reverse().find((event) => event.kind === "execution-input");
|
|
10226
10223
|
if (latestInput?.kind !== "execution-input" || latestInput.seq !== state.inputSequence) return false;
|
|
10227
10224
|
const attempt = owned.slice(owned.indexOf(latestInput));
|
|
10228
|
-
|
|
10225
|
+
const closing = /* @__PURE__ */ new Set(["execution-result", "execution-abandoned"]);
|
|
10226
|
+
if (attempt.some((event) => closing.has(event.kind))) return false;
|
|
10229
10227
|
const dispatched = [...attempt].reverse().flatMap((event) => event.kind === "execution-admitted" && event.admission.phase === "dispatched" ? [event.admission] : [])[0];
|
|
10230
10228
|
const stop = dispatched === void 0 || state.provider === void 0 ? void 0 : await stopRetainedNativeExecution({
|
|
10231
10229
|
provider: state.provider,
|
|
@@ -16721,14 +16719,16 @@ function reservationOwnerFloor(args) {
|
|
|
16721
16719
|
function bindOwnerJournalRecorders(scope, args, now) {
|
|
16722
16720
|
let driverAttemptSeq;
|
|
16723
16721
|
driverAttemptRecorders.set(scope, async (record) => {
|
|
16724
|
-
if (driverAttemptSeq === void 0) driverAttemptSeq = (await args.journal.loadTree(args.root) ?? []).
|
|
16722
|
+
if (driverAttemptSeq === void 0) driverAttemptSeq = (await args.journal.loadTree(args.root) ?? []).filter((e) => e.kind === "driver-attempt" && e.id === args.parentId).reduce((next, event) => Math.max(next, event.seq + 1), 0);
|
|
16725
16723
|
const attemptId = ownerMaterializationStates.get(scope)?.attemptId;
|
|
16724
|
+
const observed = owners.get(scope)?.context.observed;
|
|
16726
16725
|
await args.journal.appendEvent(args.root, {
|
|
16727
16726
|
kind: "driver-attempt",
|
|
16728
16727
|
id: args.parentId,
|
|
16729
16728
|
record: {
|
|
16730
16729
|
...record,
|
|
16731
|
-
...record.error === void 0 ? {} : { error: errorText(record.error) }
|
|
16730
|
+
...record.error === void 0 ? {} : { error: errorText(record.error) },
|
|
16731
|
+
...observed === void 0 ? {} : { observed }
|
|
16732
16732
|
},
|
|
16733
16733
|
...attemptId === void 0 ? {} : { attemptId },
|
|
16734
16734
|
seq: driverAttemptSeq++,
|
|
@@ -16792,4 +16792,4 @@ async function recoverRetainedChildren(args, children, spawn, next) {
|
|
|
16792
16792
|
}
|
|
16793
16793
|
export { deriveNodeExecutionIdentity as $, awaitAbortable$1 as $i, persistHarnessTranscript as $n, DISPATCH_NOT_ADMITTED_CODE as $r, insideCursorNamespace as $t, nestedScopeSeamKey as A, mapSandboxToolEvent as Ai, workerTraceEnv as An, recordRuntimeOwnedProviderDispatchNotStarted as Ar, beginScopeRetainedOwnerDrive as At, beginScopeOwnerAttempt as B, createSandboxUsageLedger as Bi, flatOtelSpan as Bn, unknownMaterializationReceipt as Br, retainedOwnerWorkspaceRetentionSeamKey as Bt, writeWorkerSteerAcknowledgement as C, meterUsageEvent as Ci, nativeCopyDelayMs as Cn, inheritRuntimeOwnedExecutorAttestation as Cr, environmentReader as Ct, isTraceAnalysisStore as D, assertValidBudget as Di, openSlotGroup as Dn, providerAttemptEvidence as Dr, prepareScopeRetainedOwnerTask as Dt, replaySpawnTree as E, spendFromUsageTotals as Ei, createWorkerSlots as En, newExecutionAttemptId as Er, consumeScopeRetainedOwnerResult as Et, recoverRetainedInteractiveRun as F, canonicalStreamEventFromSandboxEvent as Fi, buildLoopOtelSpans as Fn, runtimeOwnedExecutorMaterialization as Fr, scopeRetainedOwnerRestorePoint as Ft, scopeOwnerExecutorNodeContext as G, sandboxEventServedBackend as Gi, sanitizeKnowledgeReadinessReport as Gn, runtimeFlowBrain as Gr, materializeTreeView as Gt, noteScopeOwnerPlannedExecution as H, isSandboxTerminalEvent as Hi, loopEventToOtelSpan as Hn, executableAgentSpecSnapshot as Hr, scopeRetainedOwnerJournalRoot as Ht, startRetainedInteractiveRun as I, extractTransportEventIdentity as Ii, buildLoopSpanNodes as In, runtimeOwnedExecutorProviderEvidence as Ir, noteScopeRetainedOwnerCoordination as It, providerVisibleProfile as J, decodeHarnessUsage as Ji, captureBoundHarnessTranscript as Jn, runtimeFailureCauseSchema as Jr, nestedDriverTreeRoot as Jt, coordinationMcpAlias as K, sandboxTerminalUsageField as Ki, sanitizeRuntimeStreamEvent as Kn, reportedFailureCause as Kr, attestNestedDriverTreeOwner as Kt, FileSpawnJournal as L, assertSandboxServedModel as Li, buildRuntimeEventOtelSpans as Ln, runtimeOwnedPendingExecutorMaterialization as Lr, scopeRetainedOwnerCheckpointing as Lt, attachWorker as M, sandboxOutputMarker as Mi, createPropagatingTraceEmitter as Mn, recordRuntimeOwnedProviderModel as Mr, scopeRetainedOwnerTurnEnded as Mt, readWorkerInteractiveBinding as N, sandboxProgressEvents as Ni, mergeTraceEnv as Nn, runtimeOwnedDriveHarnessProviderEvidence as Nr, assertRetainedOwnerCoordinationRekey as Nt, parseWorkerToolTraceArtifact as O, createSandboxToolPartState as Oi, resolveWorkerSlots as On, recordRuntimeOwnedDriveHarnessProviderEvidence as Or, scopeRetainedOwnerPriorSpend as Ot, reconnectRetainedInteractiveRun as P, terminalTextFromSandboxEvent as Pi, readTraceContextFromEnv as Pn, runtimeOwnedExecutorExecutionBinding as Pr, reconcileScopeRetainedOwnerEnvironment as Pt, assertRecursiveReservationPolicy as Q, assertEventBinding as Qi, harnessTranscriptUnavailable as Qn, DISPATCH_EXECUTION_CHANGED_CODE as Qr, closesCursorSlot as Qt, appendSpawnEvents as R, canonicalSandboxUsageMode as Ri, createOpenInferenceFileExporter as Rn, runtimeOwnedScopeOwnerRuntime as Rr, bindScopeRetainedOwnerEnvironmentId as Rt, writeWorkerSteer as S, createBudgetPool as Si, captureProviderWorkspaceSnapshot as Sn, finalizeRuntimeOwnedPendingExecutor as Sr, scopeRetainedOwnerResourceReader as St, sumSpendFromEvents as T, spendFromUsageEvents as Ti, workspaceCaptureReceipt as Tn, knownMaterializationReceipt as Tr, abandonScopeRetainedOwnerInvocation as Tt, recordScopeOwnerMaterialization as U, notifySandboxEventObserver as Ui, createRuntimeEventCollector as Un, isRuntimeFlowBrain as Ur, loadSpawnForest as Ut, finalizeScopeOwnerMaterialization as V, extractLlmCallEvent as Vi, generateSpanId as Vn, executableAgentProfileSnapshot as Vr, scopeRetainedOwnerContext as Vt, restoreScopeOwnerAcceptedExecution as W, sameModelId as Wi, createRuntimeStreamEventCollector as Wn, runtimeFlowAgent as Wr, ownedTreeRootSpawn as Wt, reenteredWorkers as X, recordValue as Xi, harnessTranscriptArtifact as Xn, runtimeProviderCode as Xr, encodeResultBlob as Xt, runtimeGraphMetadataKey as Y, parseCodexUsageRecord as Yi, captureHarnessTranscript as Yn, runtimeFailureRemediationSchema as Yr, FileResultBlobStore as Yt, settledToIteration as Z, RetainedRunProviderContractError as Zi, harnessTranscriptFromLines as Zn, settlementFailureCause as Zr, SpawnEventIndex as Zt, supervisorRunDir as _, contentRef as _i, destroyInteractiveEnvironment as _n, attestRuntimeOwnedExecutor as _r, startScopeRecoveries as _t, readRootStream as a, abortReason as aa, retainedExecutorContext as ai, reconnectRetainedRun as an, DEFAULT_STALL_AFTER_MS as ar, hasRetriableTeardowns as at, workerInboxFileFromEventDir as b, credentialCommandExit as bi, assertProviderWorkspaceRetentionPort as bn, authoredAgentIdentity as br, prepareScopeRetainedOwnerSeatSwitch as bt, cancelWorker as c, signalAbortError as ca, UNAVAILABLE_STATUSES as ci, startRetainedRunInEnvironment as cn, readWorkerProgress as cr, recordScopeOwnerBarrenPause as ct, legacySupervisorRunsRoot as d, providerMessageText as da, unavailablePauseMs as di, offerInteractiveControl as dn, SeatChain as dr, registerNestedTeardownScope as dt, exactSession as ea, RetainedExecutionPendingError as ei, verifyWorkspaceMarker as en, readHarnessTranscript as er, freeSlots as et, readWorkerCancelRequests as f, unavailableResumeAt as fi, prepareInteractiveDelegation as fn, SeatChainExhaustedError as fr, releaseHeldEnvironments as ft, safeWorkerFile as g, contentAddress as gi, verifyObserverRecords as gn, attestRuntimeOwnedDeferredExecutor as gr, settleManagerWork as gt, readWorkerSteerRequests as h, TRACE_SUMMARY_SCHEMA as hi, observerRecordDigest as hn, subscriptionUsageLimitSignal as hr, retryUnconfirmedTeardowns as ht, nodeStreamFile as i, RunCancellationReason as ia, registerRetainedExecutorPreparation as ii, mintRetainedIdentity as in, retainHarnessTranscript as ir, closeScopeAdmission as it, interactiveAdmissionSeamKey as j, sandboxLeafOutputFromEvents as ji, workerTraceHeaders as jn, recordRuntimeOwnedProviderIdentityConflict as jr, scopeRetainedOwnerSettled as jt, workerTraceAnalysisStore as k, mapSandboxEvent as ki, WORKER_TRACE_PROPAGATION as kn, recordRuntimeOwnedProviderAttemptStart as kr, scopeRetainedOwnerResult as kt, claimWorkerSteerDelivery as l, promptFromAgentTurnInput as la, cappedDoublingMs as li, retainedCreateMaterial as ln, isLiveNodeStatus as lr, recordScopeOwnerDriverAttempt as lt, readWorkerSteerAcknowledgement as m, TRACE_ROOT_SCHEMA as mi, createFileObserverHooks as mn, seatExecutionProfile as mr, releaseRetainedEnvironments as mt, ROOT_STREAM_FILE as n, isTerminalSessionStatus as na, isProvisioningRefusal as ni, stopRetainedNativeExecution as nn, readBoundHarnessSessions as nr, rollingDispatch as nt, readRootStreamReceipt as o, linkAbort as oa, retainedExecutorSeamKey as oi, recoverRetainedRun as on, createActivityLog as or, meterRuntimeOwnedAccounting as ot, readWorkerCancellation as p, unavailableSignalOfFailure as pi, FileObserverJournal as pn, authoredSeatStages as pr, releaseManagerEnvironment as pt, coordinationProfileToolPrefix as q, sumSandboxUsage as qi, HARNESS_TRANSCRIPT_SETTLE_TIMEOUT_MS as qn, runtimeFailureCause as qr, driverRuntime as qt, createRootStreamSink as r, sameControlCoordinates as ra, isSchemaRejection as ri, assertRetainedRunReplayMaterial as rn, resolveHarnessTranscriptCapture as rr, closeRetainedSlots as rt, appendWorkerControlEvent as s, runAbortable as sa, UNAVAILABLE_CODES as si, startRetainedRun as sn, describeToolArgs as sr, meterRuntimeOwnedProviderAttempt as st, createScope as t, freezeControlRef as ta, TRANSPORT_ERROR_CODES as ti, describeRetainedNativeStops as tn, HARNESS_TRANSCRIPT_READ_LIMITS as tr, queueOf as tt, legacySupervisorRunDir as u, promptOptionsFromAgentTurnInput as ua, jitteredMs as ui, acceptedInteractiveControl as un, isTerminalNodeStatus as ur, recordScopeOwnerPause as ut, supervisorRunsRoot as v, executorFailure as vi, environmentGone as vn, attestRuntimeOwnedPendingExecutor as vr, unconfirmedTeardowns as vt, prepareScopeResume as w, newUsageTotals as wi, openNativeMirror as wn, knownExecutionBindingReceipt as wr, resolveSpawnResourcePaths as wt, writeWorkerCancellation as x, isCredentialRefusal as xi, captureProviderLiveWorkspace as xn, authoredProfileDigest as xr, releaseScopeRetainedOwnerForSeatPause as xt, workerCancellationsDir as y, hashJson as yi, DEFAULT_NATIVE_CAPTURE_INTERVAL_MS as yn, attestRuntimeOwnedScopeOwner as yr, waitForScopeChildren as yt, spawnJournalRecordEvents as z, createSandboxTurnEventCollector as zi, createOtelExporter as zn, unknownExecutionBindingReceipt as zr, bindScopeRetainedOwnerProvider as zt };
|
|
16794
16794
|
|
|
16795
|
-
//# sourceMappingURL=scope-
|
|
16795
|
+
//# sourceMappingURL=scope-D04GkJ6P.js.map
|