@tangle-network/agent-runtime 0.133.6 → 0.133.8
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-yW1CcPiM.js → activation-CbgOt7bK.js} +2 -2
- package/dist/{activation-yW1CcPiM.js.map → activation-CbgOt7bK.js.map} +1 -1
- package/dist/agent.d.ts +1 -1
- package/dist/agent.js +2 -2
- package/dist/{authoring-Cbz3BYqD.js → authoring-DI2ZcORJ.js} +2 -2
- package/dist/{authoring-Cbz3BYqD.js.map → authoring-DI2ZcORJ.js.map} +1 -1
- package/dist/candidate-execution/index.js +1 -1
- package/dist/{candidate-execution-y946fuY1.js → candidate-execution-_u2HIWeX.js} +27 -2
- package/dist/candidate-execution-_u2HIWeX.js.map +1 -0
- package/dist/{graph-BcwxFLW_.js → graph-CnLcp2Tl.js} +2 -2
- package/dist/{graph-BcwxFLW_.js.map → graph-CnLcp2Tl.js.map} +1 -1
- package/dist/{improvement-cycle-DJQqqICz.js → improvement-cycle-ekj_ODWY.js} +3 -3
- package/dist/{improvement-cycle-DJQqqICz.js.map → improvement-cycle-ekj_ODWY.js.map} +1 -1
- package/dist/{index-DLjXduyp.d.ts → index-CP8LBWD1.d.ts} +2 -2
- package/dist/{index-kMp8g-jT.d.ts → index-Cgo-tyB8.d.ts} +41 -2
- package/dist/index.d.ts +3 -3
- package/dist/index.js +8 -8
- package/dist/intelligence.js +3 -3
- package/dist/kernel.d.ts +2 -2
- package/dist/kernel.js +7 -7
- package/dist/{knowledge-CD5Xx1J3.js → knowledge-BdJoVN9q.js} +3 -3
- package/dist/{knowledge-CD5Xx1J3.js.map → knowledge-BdJoVN9q.js.map} +1 -1
- package/dist/knowledge.d.ts +1 -1
- package/dist/knowledge.js +1 -1
- package/dist/{loop-runner-bin-CC5c39zY.d.ts → loop-runner-bin-BX_266wJ.d.ts} +2 -2
- package/dist/{loop-runner-bin-BrF0g950.js → loop-runner-bin-C1uQcY_O.js} +3 -3
- package/dist/{loop-runner-bin-BrF0g950.js.map → loop-runner-bin-C1uQcY_O.js.map} +1 -1
- 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 +4 -4
- package/dist/{openai-tools-BEeoh5i0.js → openai-tools-BTznyT19.js} +2 -2
- package/dist/{openai-tools-BEeoh5i0.js.map → openai-tools-BTznyT19.js.map} +1 -1
- package/dist/{runtime-BX5c47Qm.js → runtime-Br49sl8u.js} +79 -17
- package/dist/runtime-Br49sl8u.js.map +1 -0
- package/dist/{structural-rollout-CHq3qJau.js → structural-rollout-C4_mifPH.js} +2 -2
- package/dist/{structural-rollout-CHq3qJau.js.map → structural-rollout-C4_mifPH.js.map} +1 -1
- package/dist/{supervise-D-e9RIuG.js → supervise-BTwl4Cdi.js} +19 -5
- package/dist/supervise-BTwl4Cdi.js.map +1 -0
- package/dist/{supervisor-GBIOnjUo.js → supervisor-BA87pb7g.js} +39 -3
- package/dist/supervisor-BA87pb7g.js.map +1 -0
- package/dist/testing.d.ts +1 -1
- package/dist/testing.js +11 -11
- package/package.json +1 -1
- package/dist/candidate-execution-y946fuY1.js.map +0 -1
- package/dist/runtime-BX5c47Qm.js.map +0 -1
- package/dist/supervise-D-e9RIuG.js.map +0 -1
- package/dist/supervisor-GBIOnjUo.js.map +0 -1
|
@@ -6,13 +6,13 @@ import { i as redactProtectedValue, r as redactProtectedReason } from "./protect
|
|
|
6
6
|
import { a as notifySandboxEventObserver, c as parseCanonicalTransportEvent, s as extractTransportEventIdentity } from "./sandbox-events-vIwmuPdl.js";
|
|
7
7
|
import { c as profileProviderModel, i as concreteModelId, s as profileModelExecutionSettings, t as assertExecutableAgentProfile } from "./model-policy-Bv1DU2fw.js";
|
|
8
8
|
import { T as executableAgentSpecSnapshot, w as executableAgentProfileSnapshot } from "./materialization-D2bdTfkK.js";
|
|
9
|
-
import {
|
|
9
|
+
import { F as createExecutor, I as createExecutorRegistry, K as createPushTraceSource, R as createWorktreeCliExecutor, T as rollingDispatch, at as routerBrain, et as defaultSelectWinner, h as settledToIteration, l as withDriverExecutor, n as createSupervisor, nt as createSandboxLineage, ot as runBrainLoop, rt as probeSandboxCapabilities, st as canonicalObservedModel, tt as runAgentRounds } from "./supervisor-BA87pb7g.js";
|
|
10
10
|
import "./environment-provider-DTJA4ZiM.js";
|
|
11
11
|
import { i as notifyRuntimeHookEvent } from "./runtime-hooks-C7iJOWm3.js";
|
|
12
|
-
import { C as observe, O as strategyAuthorMethod, T as profileChatClient, b as sample, v as refine, x as sampleThenRefine, y as runAgentic } from "./structural-rollout-
|
|
13
|
-
import { It as gateOnDeliverable, Lt as mapExecutorResult, n as supervise } from "./supervise-
|
|
14
|
-
import "./authoring-
|
|
15
|
-
import "./graph-
|
|
12
|
+
import { C as observe, O as strategyAuthorMethod, T as profileChatClient, b as sample, v as refine, x as sampleThenRefine, y as runAgentic } from "./structural-rollout-C4_mifPH.js";
|
|
13
|
+
import { It as gateOnDeliverable, Lt as mapExecutorResult, n as supervise } from "./supervise-BTwl4Cdi.js";
|
|
14
|
+
import "./authoring-DI2ZcORJ.js";
|
|
15
|
+
import "./graph-CnLcp2Tl.js";
|
|
16
16
|
import { CODING_HARNESSES, InMemoryTraceStore, OUTPUT_VALUE, benjaminiHochberg, buildTrajectory, computeFindingId as computeFindingId$1, confidenceInterval, expandProfileAxes, makeFinding as makeFinding$1, pairedBootstrap, paretoFrontier, wilcoxonSignedRank, wilson } from "@tangle-network/agent-eval";
|
|
17
17
|
import { heldoutSignificance, runProfileMatrix } from "@tangle-network/agent-eval/campaign";
|
|
18
18
|
import { AgentEnvironmentCapabilitiesSchema, AgentExactRunControlRefSchema, AgentNativeContextContinuationResultSchema, AgentRunCancellationAcknowledgementSchema, AgentRunCancellationRequestSchema, AgentTurnResultSchema, InteractionAcknowledgementSchema, InteractionResponseCommandSchema, NativeContextBoundaryProofSchema, NativeContextContinuationRequestSchema, RuntimeEventEnvelopeSchema, agentNativeContextContinuationResultMatchesRequest, agentProfileSchema, agentRunCancellationAcknowledgementMatchesRequest, agentRunCancellationRequestDigest, canonicalAgentProfileDigest, canonicalCandidateDigest, nativeContextContinuationTurnDigest, validateAgentProfileSecurity } from "@tangle-network/agent-interface";
|
|
@@ -3596,15 +3596,28 @@ async function exactSessionResult(session) {
|
|
|
3596
3596
|
return session.result();
|
|
3597
3597
|
}
|
|
3598
3598
|
function assertEventBinding(source, controlRef) {
|
|
3599
|
-
const
|
|
3600
|
-
|
|
3601
|
-
|
|
3602
|
-
|
|
3603
|
-
|
|
3604
|
-
|
|
3599
|
+
const transport = isRecord(source) ? source : void 0;
|
|
3600
|
+
const payload = isRecord(source.data) ? source.data : void 0;
|
|
3601
|
+
const providerEvent = isRecord(source.providerEvent) ? source.providerEvent : void 0;
|
|
3602
|
+
const bindings = [
|
|
3603
|
+
{
|
|
3604
|
+
value: transport,
|
|
3605
|
+
checkSessionId: true
|
|
3606
|
+
},
|
|
3607
|
+
{
|
|
3608
|
+
value: payload,
|
|
3609
|
+
checkSessionId: source.type !== "session.updated"
|
|
3610
|
+
},
|
|
3611
|
+
{
|
|
3612
|
+
value: providerEvent,
|
|
3613
|
+
checkSessionId: true
|
|
3614
|
+
}
|
|
3615
|
+
];
|
|
3616
|
+
for (const { value, checkSessionId } of bindings) {
|
|
3617
|
+
if (value === void 0) continue;
|
|
3605
3618
|
if (value.runId !== void 0 && value.runId !== controlRef.runId) throw new Error("provider returned an event for another retained run");
|
|
3606
3619
|
if (value.executionId !== void 0 && value.executionId !== controlRef.executionId) throw new Error("provider returned an event for another retained execution");
|
|
3607
|
-
if (value.sessionId !== void 0 && value.sessionId !== controlRef.sessionId) throw new Error("provider returned an event for another retained session");
|
|
3620
|
+
if (checkSessionId && value.sessionId !== void 0 && value.sessionId !== controlRef.sessionId) throw new Error("provider returned an event for another retained session");
|
|
3608
3621
|
}
|
|
3609
3622
|
}
|
|
3610
3623
|
function isRecord(value) {
|
|
@@ -3922,11 +3935,60 @@ async function startRetainedRun(options) {
|
|
|
3922
3935
|
}
|
|
3923
3936
|
throw new Error(`provider "${options.provider.name}" does not expose detached session control`);
|
|
3924
3937
|
}
|
|
3938
|
+
return dispatchRetainedRun({
|
|
3939
|
+
provider: options.provider,
|
|
3940
|
+
environment,
|
|
3941
|
+
environmentIdempotencyKey: options.environment.idempotencyKey,
|
|
3942
|
+
turn: options.turn,
|
|
3943
|
+
identity,
|
|
3944
|
+
onAdmission: options.onAdmission,
|
|
3945
|
+
capabilities,
|
|
3946
|
+
now: options.now
|
|
3947
|
+
});
|
|
3948
|
+
}
|
|
3949
|
+
/**
|
|
3950
|
+
* Dispatch a fresh retained session inside an existing provider environment.
|
|
3951
|
+
*
|
|
3952
|
+
* This operation reuses only the environment. It does not append to a prior
|
|
3953
|
+
* harness chat and does not claim native conversation continuity. The caller
|
|
3954
|
+
* must use `RetainedRunHandle.continueNative` for a verified same-chat turn.
|
|
3955
|
+
*
|
|
3956
|
+
* @stable
|
|
3957
|
+
*/
|
|
3958
|
+
async function startRetainedRunInEnvironment(options) {
|
|
3959
|
+
assertStableText(options.environment.id, "retained environment id");
|
|
3960
|
+
assertStableText(options.environment.idempotencyKey, "environment idempotency key");
|
|
3961
|
+
assertStableText(options.turn.turnId, "turn idempotency key");
|
|
3962
|
+
if (options.identity !== void 0) {
|
|
3963
|
+
assertStableText(options.identity.sessionId, "retained session id");
|
|
3964
|
+
assertStableText(options.identity.executionId, "retained execution id");
|
|
3965
|
+
}
|
|
3966
|
+
if (typeof options.onAdmission !== "function") throw new Error("startRetainedRunInEnvironment requires an awaited onAdmission durability hook");
|
|
3967
|
+
const identity = options.identity ?? mintRetainedIdentity(options.environment.idempotencyKey, options.turn.turnId);
|
|
3968
|
+
const capabilities = await assertRetainedCapabilities(options.provider);
|
|
3969
|
+
if (!options.provider.get) throw new Error(`provider "${options.provider.name}" cannot reconstruct an environment by id`);
|
|
3970
|
+
const environment = await options.provider.get(options.environment.id);
|
|
3971
|
+
if (!environment) throw new Error(`provider "${options.provider.name}" no longer holds environment "${options.environment.id}"`);
|
|
3972
|
+
if (environment.id !== options.environment.id || environment.provider !== options.provider.name) throw new Error("provider reconstructed a different retained environment");
|
|
3973
|
+
if (!environment.dispatch || !environment.session) throw new Error(`provider "${options.provider.name}" does not expose detached session control`);
|
|
3974
|
+
return dispatchRetainedRun({
|
|
3975
|
+
provider: options.provider,
|
|
3976
|
+
environment,
|
|
3977
|
+
environmentIdempotencyKey: options.environment.idempotencyKey,
|
|
3978
|
+
turn: options.turn,
|
|
3979
|
+
identity,
|
|
3980
|
+
onAdmission: options.onAdmission,
|
|
3981
|
+
capabilities,
|
|
3982
|
+
now: options.now
|
|
3983
|
+
});
|
|
3984
|
+
}
|
|
3985
|
+
async function dispatchRetainedRun(options) {
|
|
3986
|
+
const { environment, identity } = options;
|
|
3925
3987
|
await admitDurably(options.onAdmission, {
|
|
3926
3988
|
phase: "environment",
|
|
3927
3989
|
provider: options.provider.name,
|
|
3928
3990
|
environmentId: environment.id,
|
|
3929
|
-
idempotencyKey: options.
|
|
3991
|
+
idempotencyKey: options.environmentIdempotencyKey,
|
|
3930
3992
|
turnId: options.turn.turnId,
|
|
3931
3993
|
sessionId: identity.sessionId,
|
|
3932
3994
|
executionId: identity.executionId
|
|
@@ -3962,10 +4024,10 @@ async function startRetainedRun(options) {
|
|
|
3962
4024
|
await admitDurably(options.onAdmission, {
|
|
3963
4025
|
phase: "dispatched",
|
|
3964
4026
|
controlRef: freezeControlRef(exact.controlRef),
|
|
3965
|
-
idempotencyKey: options.
|
|
4027
|
+
idempotencyKey: options.environmentIdempotencyKey,
|
|
3966
4028
|
turnId: options.turn.turnId
|
|
3967
4029
|
});
|
|
3968
|
-
return createRetainedRunHandle(environment, exact.session, exact.controlRef, capabilities, options.now);
|
|
4030
|
+
return createRetainedRunHandle(environment, exact.session, exact.controlRef, options.capabilities, options.now);
|
|
3969
4031
|
}
|
|
3970
4032
|
/**
|
|
3971
4033
|
* Await one admission record through the caller's durability hook. A rejection
|
|
@@ -6590,6 +6652,6 @@ function tail(s) {
|
|
|
6590
6652
|
return s.slice(-400);
|
|
6591
6653
|
}
|
|
6592
6654
|
//#endregion
|
|
6593
|
-
export {
|
|
6655
|
+
export { FileCorpus as $, pickChampion as A, renderLeaderboardMarkdown as At, runBenchmark as B, envKeyProvider as Bt, analyzeTrace as C, completionAuthorizes as Ct, chatWorkerSeam as D, leaderboard as Dt, chatTransportExecutor as E, stopSentinel as Et, strategyAuthorContract as F, McpSpawnFault as Ft, promotionGate as G, recoverRetainedRun as H, resolveMcpServerLaunch as Ht, strategyAuthorSystemPrompt as I, connectStdioMcp as It, definePersona as J, equalKOnCost as K, SandboxRunAbortError as L, materializeLocalMcp as Lt, selectChampion as M, renderPairwiseMarkdown as Mt, assertStrategyContract as N, auditIntent as Nt, createChatSessionStore as O, pairwiseSignificance as Ot, authorStrategy as P, defaultAuditorInstruction as Pt, registerShape as Q, openSandboxRun as R, createMcpEnvironment as Rt, withUntrackedArtifacts as S, superviseDispatch as St, runCoderChecks as T, sentinelCompletion as Tt, startRetainedRun as U, resolveSecretEnv as Ut, reconnectRetainedRun as V, mcpSecretEnvMetadataKey as Vt, startRetainedRunInEnvironment as W, secretEnvOfMcpServer as Wt, builtinShapes as X, runPersonified as Y, createShapeRegistry as Z, VERIFY_TAIL_CHARS as _, resolveSandboxClient as _t, localShell as a, panel as at, settledWorkerOut as b, loopCampaignDispatch as bt, createVerifierEnvironment as c, verify as ct, harvestSurfaceDiffs as d, buildSteerContext as dt, InMemoryCorpus as et, failuresAnalyst as f, createScopeAnalyst as ft, NOTE_MAX_CHARS as g, defineLeaderboard as gt, EVIDENCE_MAX_CHARS as h, harvestCorpus as ht, jjWorkspace as i, loopUntil as it, runStrategyEvolution as j, renderLeaderboardSvg as jt, discriminatingMeans as k, renderLeaderboardHtml as kt, boxSurfaceReader as l, widen as lt, worktreeFanout as m, inProcessSandboxClient as mt, makeFinding$1 as n, fanout as nt, runInWorkspace as o, pipeline as ot, superviseSurface as p, registryScopeAnalyst as pt, trajectoryReport as q, gitWorkspace as r, flatWidenGate as rt, createWaterfallCollector as s, selectValidWinner as st, computeFindingId$1 as t, renderCorpusToInstructions as tt, fsSurfaceReader as u, assertTraceDerivedFindings as ut, closingWorkerNote as v, localSandboxClient as vt, patchDelivered as w, deterministicCompletion as wt, copyUntrackedIntoClone as x, loopDispatch as xt, composeWorkerEvidence as y, inlineSandboxClient as yt, printBenchmarkReport as z, sanitizeMcpToolSchema as zt };
|
|
6594
6656
|
|
|
6595
|
-
//# sourceMappingURL=runtime-
|
|
6657
|
+
//# sourceMappingURL=runtime-Br49sl8u.js.map
|