@tangle-network/agent-runtime 0.200.0 → 0.201.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.
- package/dist/{activation-Ct-BTTzF.js → activation-C_FN2aqK.js} +2 -2
- package/dist/{activation-Ct-BTTzF.js.map → activation-C_FN2aqK.js.map} +1 -1
- package/dist/candidate-execution/index.d.ts +2 -2
- package/dist/candidate-execution/index.js +3 -3
- package/dist/{improvement-cycle-yia1ST3c.js → improvement-cycle-VH_ZGcIj.js} +2 -2
- package/dist/{improvement-cycle-yia1ST3c.js.map → improvement-cycle-VH_ZGcIj.js.map} +1 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +10 -5
- package/dist/index.js.map +1 -1
- package/dist/intelligence.d.ts +2 -2
- package/dist/intelligence.js +4 -4
- package/dist/{prepare-CAO1yXov.js → prepare-Dc30WRB0.js} +6 -3
- package/dist/prepare-Dc30WRB0.js.map +1 -0
- package/dist/{protected-model-port-BtXp2dUY.d.ts → protected-model-port-BlLP8ja6.d.ts} +2 -2
- package/dist/{protected-model-port-B5avcRiQ.js → protected-model-port-D5gDcnrH.js} +2 -2
- package/dist/{protected-model-port-B5avcRiQ.js.map → protected-model-port-D5gDcnrH.js.map} +1 -1
- package/dist/testing.js +10 -10
- package/dist/{types-1s_29INY.d.ts → types-CuXu5zuS.d.ts} +3 -2
- package/dist/{workspace-archive-BMOnloFf.js → workspace-archive-CBX0hwL_.js} +2 -2
- package/dist/{workspace-archive-BMOnloFf.js.map → workspace-archive-CBX0hwL_.js.map} +1 -1
- package/package.json +6 -6
- package/dist/prepare-CAO1yXov.js.map +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -4,7 +4,7 @@ import { o as ImprovementProposalSource } from "./types-zWfqDjeL.js";
|
|
|
4
4
|
import { Ap as AgentEvalErrorCode, Bp as RuntimeRunStateError, Fp as PlannerError, Ip as RetainedInteractiveAdmissionError, Lo as SuperviseOptions, Lp as RetainedInteractiveBindingError, Mp as ConfigError, Np as JudgeError, Pp as NotFoundError, Qp as DeliverableSpec, Rp as RetainedRunAdmissionError, Vp as ValidationError, Wr as StructuralRolloutPolicy, ds as SupervisorProfile, jp as BackendTransportError, kp as AgentEvalError, zp as RetainedRunDispatchBindingError } from "./index-Br191WbE.js";
|
|
5
5
|
import { $i as sanitizeAgentRuntimeEvent, Ai as OtelExporter, Bi as loopEventToOtelSpan, Ci as EvalRunGeneration, Di as LoopSpanNode, Ei as INTELLIGENCE_WIRE_VERSION, Fi as buildRuntimeEventOtelSpans, Gi as RuntimeStreamEventCollector, Hi as padTraceId, Ii as createOpenInferenceFileExporter, Ji as RuntimeTelemetryOptions, Ki as RuntimeStreamEventSink, Li as createOtelExporter, Mi as RuntimeEventOtelOptions, Ni as buildLoopOtelSpans, Oi as OtelAttribute, Pi as buildLoopSpanNodes, Qi as createRuntimeStreamEventCollector, Qn as Redactor, Ri as exportEvalRuns, Si as EvalRunEvent, Ti as EvalRunsExportResult, Ui as toOtelAttributes, Vi as padSpanId, Wi as RuntimeEventCollector, Xi as SanitizedKnowledgeRequirement, Yi as SanitizedKnowledgeReadinessReport, Zi as createRuntimeEventCollector, Zr as SupervisedResult, Zt as WorktreeCheckRunner, ea as sanitizeKnowledgeReadinessReport, h as ExecutorConfig, ir as Budget, ji as OtelSpan, ki as OtelExportConfig, pr as ExecutorFactory, qi as RuntimeStreamEventSummary, ta as sanitizeRuntimeStreamEvent, wi as EvalRunsExportConfig, zi as generateSpanId } from "./stream-agent-turn-CJWthifS.js";
|
|
6
6
|
import { a as RuntimeHookErrorContext, c as RuntimeHookTarget, d as defineRuntimeHooks, f as notifyRuntimeDecisionPoint, i as RuntimeHookContext, l as RuntimeHooks, n as RuntimeDecisionKind, o as RuntimeHookEvent, p as notifyRuntimeHookEvent, r as RuntimeDecisionPoint, s as RuntimeHookPhase, t as RuntimeDecisionEvidenceRef, u as composeRuntimeHooks } from "./runtime-hooks-Bj6wJHlH.js";
|
|
7
|
-
import { y as AgentCandidateOutputArtifactPort } from "./types-
|
|
7
|
+
import { y as AgentCandidateOutputArtifactPort } from "./types-CuXu5zuS.js";
|
|
8
8
|
import { $ as ImprovementProfilePopulationLineageNode, A as ImproveMethodResult, B as ImproveSkillsOptions, C as ImproveCost, D as ImproveMethodFactory, E as ImproveMethodContext, F as ImproveProfileComponents, G as ImprovementProfileCandidate, H as ImprovementCandidate, I as ImproveProfileSurface, J as ImprovementProfileCandidatePopulationUnavailable, K as ImprovementProfileCandidatePopulation, L as ImproveResult, M as ImproveOptimizationRunOptions, N as ImproveOptions, O as ImproveMethodLineage, P as ImproveProfileAgent, Q as ImprovementProfilePopulationLineage, R as ImproveRuntimeCodeGeneratorOptions, S as ImproveCodeRunOptions, T as ImproveLineage, U as ImprovementCodeCandidate, V as ImproveSurface, W as ImprovementMaterializedProfilePopulationCandidate, X as ImprovementProfilePopulationCandidate, Y as ImprovementProfilePopulationArtifactSource, Z as ImprovementProfilePopulationCandidateSource, _ as ImproveCandidateValidationInput, at as AgenticGeneratorOptions, b as ImproveCodeOptions, ct as AgenticGeneratorShotReceipt, dt as agenticGenerator, et as ImprovementProfilePopulationObservationSource, ft as commandVerifier, g as improve, i as AgentImprovementActivationTransition, it as AgenticGeneratorExecutorForWorktree, j as ImproveMethodSource, k as ImproveMethodOptions, lt as Verifier, mt as CandidateGenerator, n as AgentImprovementActivationResultStore, nt as DeepReadonly, ot as AgenticGeneratorShotDisposition, pt as defaultBuildPrompt, q as ImprovementProfileCandidatePopulationAvailable, rt as ReadonlyAgentProfile, st as AgenticGeneratorShotExecution, t as AgentImprovementActivationReconciliation, tt as ImprovementRefusedProfilePopulationCandidate, ut as VerifyResult, v as ImproveCandidateValidator, w as ImproveCustomCodeGeneratorOptions, x as ImproveCodeResult, y as ImproveCodeBaseOptions, z as ImproveScenarioPartitions } from "./activation-BPxs-Iu2.js";
|
|
9
9
|
import { _ as researchLoopRunner, a as DELEGATED_LOOP_MODES, c as DelegatedLoopResult, d as ResearchLoopRunnerOptions, f as RunDelegatedLoopOptions, g as isDelegatedLoopMode, h as auditLoopRunner, i as runLoopRunnerCli, l as DelegatedLoopRunner, m as WorktreeLoopRunnerOptions, n as LoopRunnerCliResult, o as DelegatedLoopMode, p as VetoedFact, r as parseLoopRunnerArgv, s as DelegatedLoopRegistry, t as LoopRunnerCliArgs, u as ResearchLoopResult, v as runDelegatedLoop, y as worktreeLoopRunner } from "./loop-runner-bin-BNRdsDOn.js";
|
|
10
10
|
import { n as mcpToolsForRuntimeMcpSubset, t as mcpToolsForRuntimeMcp } from "./openai-tools-CRQhVT_V.js";
|
|
@@ -935,6 +935,7 @@ interface KnowledgeImprovementJobResult {
|
|
|
935
935
|
}
|
|
936
936
|
interface KnowledgeImprovementCandidatePair {
|
|
937
937
|
reference: AgentCandidateKnowledge['candidate'];
|
|
938
|
+
stateScope?: AgentCandidateKnowledge['stateScope'];
|
|
938
939
|
evaluation: AgentCandidateCapturedArtifact;
|
|
939
940
|
baseline: AgentCandidateKnowledge['snapshot'];
|
|
940
941
|
candidate: AgentCandidateKnowledge['snapshot'];
|
package/dist/index.js
CHANGED
|
@@ -4,11 +4,11 @@ import { A as streamAgentTurn, D as optimizerMethod, F as newRuntimeSession, I a
|
|
|
4
4
|
import { t as assertExecutableAgentProfile } from "./model-policy-DKDyr-fc.js";
|
|
5
5
|
import { Ft as connectStdioMcp, Pt as McpSpawnFault } from "./runtime-DeqdBVeC.js";
|
|
6
6
|
import { i as notifyRuntimeHookEvent, n as defineRuntimeHooks, r as notifyRuntimeDecisionPoint, t as composeRuntimeHooks } from "./runtime-hooks-tXpAarhW.js";
|
|
7
|
-
import { B as ROLLOUT_POLICY_EXTENSION, G as structuralRolloutPolicyFromProfile, H as normalizeRolloutPolicy, J as defaultBuildPrompt, K as agenticGenerator, L as improve, R as withMethodRuntimeControls, U as parseRolloutPolicy, V as applyRolloutPolicyToProfile, W as serializeRolloutPolicy, q as commandVerifier, z as rawTraceDistiller } from "./improvement-cycle-
|
|
7
|
+
import { B as ROLLOUT_POLICY_EXTENSION, G as structuralRolloutPolicyFromProfile, H as normalizeRolloutPolicy, J as defaultBuildPrompt, K as agenticGenerator, L as improve, R as withMethodRuntimeControls, U as parseRolloutPolicy, V as applyRolloutPolicyToProfile, W as serializeRolloutPolicy, q as commandVerifier, z as rawTraceDistiller } from "./improvement-cycle-VH_ZGcIj.js";
|
|
8
8
|
import { a as canonicalCandidateBytes, d as omitTopLevelDigest, l as embeddedCandidateArtifact, o as canonicalCandidateDigest$1, u as immutableCandidateValue } from "./protected-redaction-wGo44k2K.js";
|
|
9
|
-
import { d as persistCandidateOutputArtifact } from "./prepare-
|
|
10
|
-
import { t as createAgentImprovementActivationResult } from "./activation-
|
|
11
|
-
import { i as sealAgentCandidateBundle, t as captureAgentCandidateWorkspace } from "./workspace-archive-
|
|
9
|
+
import { d as persistCandidateOutputArtifact } from "./prepare-Dc30WRB0.js";
|
|
10
|
+
import { t as createAgentImprovementActivationResult } from "./activation-C_FN2aqK.js";
|
|
11
|
+
import { i as sealAgentCandidateBundle, t as captureAgentCandidateWorkspace } from "./workspace-archive-CBX0hwL_.js";
|
|
12
12
|
import { n as supervise } from "./supervise-DmFO50N6.js";
|
|
13
13
|
import { a as isDelegatedLoopMode, c as worktreeLoopRunner, i as auditLoopRunner, n as runLoopRunnerCli, o as researchLoopRunner, r as DELEGATED_LOOP_MODES, s as runDelegatedLoop, t as parseLoopRunnerArgv } from "./loop-runner-bin-jQ8hXO9J.js";
|
|
14
14
|
import { n as mcpToolsForRuntimeMcpSubset, t as mcpToolsForRuntimeMcp } from "./openai-tools-DoQ32vpe.js";
|
|
@@ -21,7 +21,7 @@ import { isAbsolute, relative, resolve, sep } from "node:path";
|
|
|
21
21
|
import { realpath } from "node:fs/promises";
|
|
22
22
|
import { isDeepStrictEqual } from "node:util";
|
|
23
23
|
import { gepaOptimizationMethod, skillOptOptimizationMethod } from "@tangle-network/agent-eval/campaign";
|
|
24
|
-
import { evaluateKnowledgeBaseReadiness, fromAgentCandidateKnowledgeRef, improveKnowledgeBase, knowledgeImprovementCandidateRef, loadKnowledgeImprovementActivationResult, promoteKnowledgeCandidate, restoreKnowledgeCandidateBaseline, toAgentCandidateKnowledgeRef, withKnowledgeImprovementComparison } from "@tangle-network/agent-knowledge";
|
|
24
|
+
import { evaluateKnowledgeBaseReadiness, fromAgentCandidateKnowledgeRef, improveKnowledgeBase, knowledgeImprovementCandidateRef, loadKnowledgeImprovementActivationResult, normalizeKnowledgeStateScope, promoteKnowledgeCandidate, restoreKnowledgeCandidateBaseline, toAgentCandidateKnowledgeRef, withKnowledgeImprovementComparison } from "@tangle-network/agent-knowledge";
|
|
25
25
|
//#region src/runtime/profile-execution-backend.ts
|
|
26
26
|
/**
|
|
27
27
|
* Bind one exact profile and Runtime executor to the stable `AgentExecutionBackend` contract used
|
|
@@ -2250,6 +2250,7 @@ function buildKnowledgeImprovementExperimentBundles(bundle, knowledge) {
|
|
|
2250
2250
|
const input = omitTopLevelDigest(bundle);
|
|
2251
2251
|
const withSnapshot = (snapshot) => agentCandidateKnowledgeSchema.parse({
|
|
2252
2252
|
candidate: knowledge.reference,
|
|
2253
|
+
...knowledge.stateScope ? { stateScope: knowledge.stateScope } : {},
|
|
2253
2254
|
snapshot,
|
|
2254
2255
|
evaluation: knowledge.evaluation
|
|
2255
2256
|
});
|
|
@@ -2284,10 +2285,14 @@ async function freezeKnowledgeCandidatePair(root, improvement, artifacts, signal
|
|
|
2284
2285
|
candidate: candidateRef,
|
|
2285
2286
|
metric: comparison.evaluation
|
|
2286
2287
|
}), "knowledge-evaluation", `knowledge-${candidate.candidateId}`, artifacts, signal);
|
|
2288
|
+
const normalizedScope = normalizeKnowledgeStateScope(comparison.stateScope);
|
|
2289
|
+
const defaultScope = normalizeKnowledgeStateScope();
|
|
2290
|
+
const stateScope = normalizedScope.pagesDirectory === defaultScope.pagesDirectory && normalizedScope.researchState === defaultScope.researchState ? void 0 : Object.freeze(normalizedScope);
|
|
2287
2291
|
const baseline = await freeze("baseline");
|
|
2288
2292
|
const proposed = await freeze("candidate");
|
|
2289
2293
|
return Object.freeze({
|
|
2290
2294
|
reference: candidateRef,
|
|
2295
|
+
...stateScope ? { stateScope } : {},
|
|
2291
2296
|
evaluation,
|
|
2292
2297
|
baseline,
|
|
2293
2298
|
candidate: proposed
|