@tangle-network/agent-runtime 0.138.0 → 0.139.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-BHoMDzMv.js → activation-eLJ6uRlP.js} +3 -3
- package/dist/{activation-BHoMDzMv.js.map → activation-eLJ6uRlP.js.map} +1 -1
- package/dist/agent.d.ts +4 -4
- package/dist/agent.js +3 -3
- package/dist/{analyst-loop-Dk6_xfhI.js → analyst-loop-DtOEXGzR.js} +3 -3
- package/dist/{analyst-loop-Dk6_xfhI.js.map → analyst-loop-DtOEXGzR.js.map} +1 -1
- package/dist/analyst-loop.d.ts +1 -1
- package/dist/analyst-loop.js +1 -1
- package/dist/{authoring-rEOOEWn6.js → authoring-J93uFAwd.js} +3 -3
- package/dist/{authoring-rEOOEWn6.js.map → authoring-J93uFAwd.js.map} +1 -1
- package/dist/candidate-execution/index.d.ts +3 -3
- package/dist/candidate-execution/index.js +4 -4
- package/dist/{candidate-execution-CyCLYLfK.js → candidate-execution-uuUeFSc6.js} +5 -5
- package/dist/{candidate-execution-CyCLYLfK.js.map → candidate-execution-uuUeFSc6.js.map} +1 -1
- package/dist/{conversation-DIUtiLkC.js → conversation-C3eZCvLd.js} +8 -6
- package/dist/conversation-C3eZCvLd.js.map +1 -0
- package/dist/conversation.d.ts +1 -1
- package/dist/conversation.js +1 -1
- package/dist/durable.d.ts +34 -1
- package/dist/durable.js +82 -1
- package/dist/durable.js.map +1 -1
- package/dist/{environment-provider-CLNVqp6H.js → environment-provider-BAO8wt1_.js} +147 -48
- package/dist/environment-provider-BAO8wt1_.js.map +1 -0
- package/dist/{environment-provider-DA8LqBV-.d.ts → environment-provider-Bu3S3v78.d.ts} +3 -3
- package/dist/environment-provider.d.ts +1 -1
- package/dist/environment-provider.js +1 -1
- package/dist/{errors-CVIDr7GQ.js → errors-CDZ8XsVj.js} +34 -9
- package/dist/errors-CDZ8XsVj.js.map +1 -0
- package/dist/{graph-yaEG0ZiR.js → graph-BbMjq7-x.js} +5 -5
- package/dist/{graph-yaEG0ZiR.js.map → graph-BbMjq7-x.js.map} +1 -1
- package/dist/{improvement-cycle-BeVj-EGJ.js → improvement-cycle-D6rhMJR0.js} +67 -66
- package/dist/improvement-cycle-D6rhMJR0.js.map +1 -0
- package/dist/{index-Bdgpx2Dx.d.ts → index-C6yfz0QN.d.ts} +5 -5
- package/dist/{index-BOgzou1U.d.ts → index-COnuT0h7.d.ts} +263 -82
- package/dist/{index-CETQJlqT.d.ts → index-CTz17pH6.d.ts} +11 -11
- package/dist/{index-DQxQgKDs.d.ts → index-DQv7iCeE.d.ts} +6 -6
- package/dist/index.d.ts +85 -15
- package/dist/index.js +109 -18
- package/dist/index.js.map +1 -1
- package/dist/intelligence.d.ts +736 -681
- package/dist/intelligence.js +113 -8
- package/dist/intelligence.js.map +1 -1
- package/dist/jsonl-file-DtxhdAkZ.js +57 -0
- package/dist/jsonl-file-DtxhdAkZ.js.map +1 -0
- package/dist/kernel.d.ts +7 -7
- package/dist/kernel.js +12 -12
- package/dist/{knowledge-C1TcOBf6.js → knowledge-CD-_FbJT.js} +7 -7
- package/dist/{knowledge-C1TcOBf6.js.map → knowledge-CD-_FbJT.js.map} +1 -1
- package/dist/knowledge.d.ts +1 -1
- package/dist/knowledge.js +1 -1
- package/dist/{loop-runner-bin-DhUWzpNp.js → loop-runner-bin-BBz_ACfQ.js} +5 -5
- package/dist/{loop-runner-bin-DhUWzpNp.js.map → loop-runner-bin-BBz_ACfQ.js.map} +1 -1
- package/dist/{loop-runner-bin-OH61zEVw.d.ts → loop-runner-bin-DUNxyuaG.d.ts} +3 -3
- package/dist/loop-runner-bin.d.ts +1 -1
- package/dist/loop-runner-bin.js +1 -1
- package/dist/{materialization-BP5zspr2.js → materialization-CrdcfWXp.js} +4 -4
- package/dist/{materialization-BP5zspr2.js.map → materialization-CrdcfWXp.js.map} +1 -1
- package/dist/mcp/bin.js +4 -4
- package/dist/mcp/index.d.ts +5 -5
- package/dist/mcp/index.js +8 -8
- package/dist/mcp/memory-bin.js +1 -1
- package/dist/{memory-server-Cdpy7Uu8.js → memory-server-DsKOhzGf.js} +3 -3
- package/dist/{memory-server-Cdpy7Uu8.js.map → memory-server-DsKOhzGf.js.map} +1 -1
- package/dist/{model-policy-UTTc9Z-A.js → model-policy-DgRJIJse.js} +2 -2
- package/dist/{model-policy-UTTc9Z-A.js.map → model-policy-DgRJIJse.js.map} +1 -1
- package/dist/{openai-tools-K38wcStR.js → openai-tools-DIKr72_l.js} +2 -2
- package/dist/{openai-tools-K38wcStR.js.map → openai-tools-DIKr72_l.js.map} +1 -1
- package/dist/{openai-tools-DU3TZvFY.d.ts → openai-tools-yoRRzAUW.d.ts} +2 -2
- package/dist/{prepare-Czki1LBy.js → prepare-DK1qnk7-.js} +3 -3
- package/dist/{prepare-Czki1LBy.js.map → prepare-DK1qnk7-.js.map} +1 -1
- package/dist/primeintellect/index.d.ts +1 -1
- package/dist/profiles.d.ts +1 -1
- package/dist/profiles.js +1 -1
- package/dist/{protected-model-port-DEsTWOFs.d.ts → protected-model-port-B8ssMyUg.d.ts} +7 -7
- package/dist/{protected-model-port-OhS0l_6m.js → protected-model-port-DHeCm_UF.js} +2 -2
- package/dist/{protected-model-port-OhS0l_6m.js.map → protected-model-port-DHeCm_UF.js.map} +1 -1
- package/dist/{redact-BwEdhuVH.d.ts → redact-CLw2B7Qj.d.ts} +9 -9
- package/dist/{researcher-DBfKdnAz.js → researcher-CiSY6Wzb.js} +3 -3
- package/dist/{researcher-DBfKdnAz.js.map → researcher-CiSY6Wzb.js.map} +1 -1
- package/dist/retained-run-binding-Dp2e8xne.js +268 -0
- package/dist/retained-run-binding-Dp2e8xne.js.map +1 -0
- package/dist/{runtime-DhPCNvuH.d.ts → runtime-CVNWEw16.d.ts} +4 -4
- package/dist/{runtime-yCuqlhou.js → runtime-tTA2iCZQ.js} +650 -222
- package/dist/runtime-tTA2iCZQ.js.map +1 -0
- package/dist/{sandbox-events-CA2amHoA.js → sandbox-events-DPmXlcKw.js} +24 -2
- package/dist/sandbox-events-DPmXlcKw.js.map +1 -0
- package/dist/{snapshot-BOIprwBk.js → snapshot-cK9K420n.js} +2 -2
- package/dist/{snapshot-BOIprwBk.js.map → snapshot-cK9K420n.js.map} +1 -1
- package/dist/{spawn-journal-ZKEKel8N.js → spawn-journal-DGXei3xG.js} +5 -58
- package/dist/spawn-journal-DGXei3xG.js.map +1 -0
- package/dist/{stream-agent-turn-Q5ellSUu.js → stream-agent-turn-4kUH8Nnn.js} +77 -34
- package/dist/stream-agent-turn-4kUH8Nnn.js.map +1 -0
- package/dist/{stream-agent-turn-DhPlvHwp.d.ts → stream-agent-turn-RjrKGk6S.d.ts} +5 -8
- package/dist/{structural-rollout-2Z6J5ttt.js → structural-rollout-7LP9Ex0F.js} +9 -9
- package/dist/structural-rollout-7LP9Ex0F.js.map +1 -0
- package/dist/{supervise-to2ynnCG.js → supervise-Cx1QY_hj.js} +10 -9
- package/dist/{supervise-to2ynnCG.js.map → supervise-Cx1QY_hj.js.map} +1 -1
- package/dist/{supervisor-BfJNS2Z3.js → supervisor-BV72aDmP.js} +13 -9
- package/dist/supervisor-BV72aDmP.js.map +1 -0
- package/dist/testing.d.ts +2 -2
- package/dist/testing.js +12 -12
- package/dist/{tool-server-Dh-NcbHr.js → tool-server-DEmLr9YY.js} +2 -2
- package/dist/{tool-server-Dh-NcbHr.js.map → tool-server-DEmLr9YY.js.map} +1 -1
- package/dist/{types-CxU37Uzr.d.ts → types-19ZOddS3.d.ts} +2 -2
- package/dist/{types-BBwGSiAj.d.ts → types-C244Huc9.d.ts} +16 -7
- package/dist/{types-BCkweg3w.d.ts → types-D4arYjUl.d.ts} +6 -6
- package/dist/{workspace-archive-B_JDld25.js → workspace-archive-HYlsPhfm.js} +2 -2
- package/dist/{workspace-archive-B_JDld25.js.map → workspace-archive-HYlsPhfm.js.map} +1 -1
- package/package.json +4 -4
- package/dist/conversation-DIUtiLkC.js.map +0 -1
- package/dist/environment-provider-CLNVqp6H.js.map +0 -1
- package/dist/errors-CVIDr7GQ.js.map +0 -1
- package/dist/improvement-cycle-BeVj-EGJ.js.map +0 -1
- package/dist/runtime-yCuqlhou.js.map +0 -1
- package/dist/sandbox-events-CA2amHoA.js.map +0 -1
- package/dist/spawn-journal-ZKEKel8N.js.map +0 -1
- package/dist/stream-agent-turn-Q5ellSUu.js.map +0 -1
- package/dist/structural-rollout-2Z6J5ttt.js.map +0 -1
- package/dist/supervisor-BfJNS2Z3.js.map +0 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { V as AgentExecutionBackend,
|
|
2
|
-
import { d as ExecutorFactory } from "./types-
|
|
3
|
-
import { AgentProfile
|
|
1
|
+
import { V as AgentExecutionBackend, it as RuntimeSessionStore } from "./types-C244Huc9.js";
|
|
2
|
+
import { d as ExecutorFactory } from "./types-D4arYjUl.js";
|
|
3
|
+
import { AgentProfile } from "@tangle-network/agent-interface";
|
|
4
|
+
import { AgentProfile as AgentProfile$1, MaximumCharge } from "@tangle-network/agent-eval";
|
|
4
5
|
import { ProfileDispatchFn, Scenario } from "@tangle-network/agent-eval/campaign";
|
|
5
|
-
import { AgentProfile as AgentProfile$1 } from "@tangle-network/agent-interface";
|
|
6
6
|
//#region src/runtime/profile-execution-backend.d.ts
|
|
7
7
|
/**
|
|
8
8
|
* Bind one exact profile and Runtime executor to the stable `AgentExecutionBackend` contract used
|
|
@@ -16,7 +16,7 @@ import { AgentProfile as AgentProfile$1 } from "@tangle-network/agent-interface"
|
|
|
16
16
|
* @stable
|
|
17
17
|
*/
|
|
18
18
|
declare function createProfileExecutionBackend(options: {
|
|
19
|
-
profile: AgentProfile
|
|
19
|
+
profile: AgentProfile;
|
|
20
20
|
executor: ExecutorFactory<unknown>;
|
|
21
21
|
}): AgentExecutionBackend;
|
|
22
22
|
//#endregion
|
|
@@ -595,19 +595,19 @@ declare function runConversationStream(conversation: Conversation, options: RunC
|
|
|
595
595
|
* (an LLM user-sim) or a deterministic script of user turns (the fast-path). */
|
|
596
596
|
type PersonaDriver = {
|
|
597
597
|
kind: 'profile';
|
|
598
|
-
profile: AgentProfile;
|
|
598
|
+
profile: AgentProfile$1;
|
|
599
599
|
} | {
|
|
600
600
|
kind: 'scripted';
|
|
601
601
|
turns: string[];
|
|
602
602
|
};
|
|
603
603
|
interface RunPersonaConversationOptions {
|
|
604
604
|
/** The agent under test. Metered; its rendered prompt leads its turns. */
|
|
605
|
-
worker: AgentProfile;
|
|
605
|
+
worker: AgentProfile$1;
|
|
606
606
|
/** The simulated user driving the dialogue. */
|
|
607
607
|
persona: PersonaDriver;
|
|
608
608
|
/** Resolve transport/executable ports for the exact profile. Runtime still materializes the
|
|
609
609
|
* profile and owns every model call. Applied to the worker and a profile-driven persona. */
|
|
610
|
-
executorFor: (profile: AgentProfile, role: 'worker' | 'persona') => ExecutorFactory<unknown>;
|
|
610
|
+
executorFor: (profile: AgentProfile$1, role: 'worker' | 'persona') => ExecutorFactory<unknown>;
|
|
611
611
|
/** Speaker-turn cap. Default for a scripted persona = `2 * turns.length`
|
|
612
612
|
* (worker answers each user turn). REQUIRED for a `profile` persona. */
|
|
613
613
|
maxTurns?: number;
|
|
@@ -641,7 +641,7 @@ interface PersonaConversationResult {
|
|
|
641
641
|
declare function runPersonaConversation(opts: RunPersonaConversationOptions): Promise<PersonaConversationResult>;
|
|
642
642
|
interface RunPersonaConfig<TScenario extends Scenario, TArtifact> {
|
|
643
643
|
/** Resolve transport/executable ports for each exact profile. */
|
|
644
|
-
executorFor: (profile: AgentProfile, role: 'worker' | 'persona') => ExecutorFactory<unknown>;
|
|
644
|
+
executorFor: (profile: AgentProfile$1, role: 'worker' | 'persona') => ExecutorFactory<unknown>;
|
|
645
645
|
/** The persona driving each scenario — a driver profile or scripted turns. */
|
|
646
646
|
personaOf: (scenario: TScenario) => PersonaDriver;
|
|
647
647
|
/** Build the scored artifact from the finished transcript. */
|
|
@@ -652,7 +652,7 @@ interface RunPersonaConfig<TScenario extends Scenario, TArtifact> {
|
|
|
652
652
|
workerName?: string;
|
|
653
653
|
/** Provider- or executor-enforced maximum for the whole worker conversation.
|
|
654
654
|
* Required before execution when the enclosing campaign is cost-capped. */
|
|
655
|
-
maximumCharge?: MaximumCharge | ((worker: AgentProfile, scenario: TScenario) => MaximumCharge | undefined);
|
|
655
|
+
maximumCharge?: MaximumCharge | ((worker: AgentProfile$1, scenario: TScenario) => MaximumCharge | undefined);
|
|
656
656
|
}
|
|
657
657
|
/**
|
|
658
658
|
* Wrap {@link runPersonaConversation} as a `ProfileDispatchFn` for
|
|
@@ -686,4 +686,4 @@ declare function turnId(runId: string, index: number, speaker: string): string;
|
|
|
686
686
|
declare function slugifySpeaker(speaker: string): string;
|
|
687
687
|
//#endregion
|
|
688
688
|
export { sleep as $, RunConversationOptions as A, buildForwardHeaders as B, ConversationResult as C, HaltPredicate as D, HaltContext as E, InMemoryConversationJournal as F, CircuitBreakerState as G, readDepth as H, DEFAULT_MAX_DEPTH as I, RetryBackoff as J, CircuitOpenError as K, FORWARD_HEADERS as L, ConversationJournal as M, ConversationJournalEntry as N, HaltReason as O, FileConversationJournal as P, makePerAttemptSignal as Q, ForwardHeaderName as R, ConversationPolicy as S, ConversationTurn as T, BackendCallPolicy as U, isDepthExceeded as V, CircuitBreakerConfig as W, computeBackoff as X, RetryableErrorPredicate as Y, defaultIsRetryable as Z, createConversationBackend as _, RunPersonaConfig as a, ConversationDriveState as b, runPersonaDispatch as c, D1DatabaseLike as d, createProfileExecutionBackend as et, D1StmtLike as f, defineConversation as g, d1ToSqlAdapter as h, PersonaDriver as i, TurnOrder as j, HaltSignal as k, runConversation as l, SqlConversationJournal as m, turnId as n, RunPersonaConversationOptions as o, SqlAdapter as p, DeadlineExceededError as q, PersonaConversationResult as r, runPersonaConversation as s, slugifySpeaker as t, runConversationStream as u, AuthSource as v, ConversationStreamEvent as w, ConversationParticipant as x, Conversation as y, PropagatedHeaders as z };
|
|
689
|
-
//# sourceMappingURL=index-
|
|
689
|
+
//# sourceMappingURL=index-CTz17pH6.d.ts.map
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { C as AgentCandidateExecutionClaim, F as AgentCandidateExecutionTerminalResult, M as AgentCandidateExecutionRecoveryEvidence, N as AgentCandidateExecutionStageResult, O as AgentCandidateExecutionFinishResult, S as AgentCandidateExecutionAttemptRef, T as AgentCandidateExecutionClaimStore, i as AgentCandidateModelGrantReserveInput, j as AgentCandidateExecutionPhaseResult, k as AgentCandidateExecutionLease, t as AgentCandidateModelGrantActivateInput, w as AgentCandidateExecutionClaimResult, x as AgentCandidateExecutionAttemptRecord } from "./protected-model-port-
|
|
2
|
-
import { A as AgentCandidateWorkspacePort, C as AgentCandidateProtectedModelSettlement, F as PreparedAgentCandidateExecution, S as AgentCandidateProtectedModelReservation, V as VerifiedAgentCandidate, a as AgentCandidateExecutionPorts, b as AgentCandidateOutputPurpose, c as AgentCandidateExecutorPort, k as AgentCandidateVerificationPorts, p as AgentCandidateExecutorWorkspaceFile, v as AgentCandidateModelPort, x as AgentCandidateProtectedModelActivation, y as AgentCandidateOutputArtifactPort } from "./types-
|
|
1
|
+
import { C as AgentCandidateExecutionClaim, F as AgentCandidateExecutionTerminalResult, M as AgentCandidateExecutionRecoveryEvidence, N as AgentCandidateExecutionStageResult, O as AgentCandidateExecutionFinishResult, S as AgentCandidateExecutionAttemptRef, T as AgentCandidateExecutionClaimStore, i as AgentCandidateModelGrantReserveInput, j as AgentCandidateExecutionPhaseResult, k as AgentCandidateExecutionLease, t as AgentCandidateModelGrantActivateInput, w as AgentCandidateExecutionClaimResult, x as AgentCandidateExecutionAttemptRecord } from "./protected-model-port-B8ssMyUg.js";
|
|
2
|
+
import { A as AgentCandidateWorkspacePort, C as AgentCandidateProtectedModelSettlement, F as PreparedAgentCandidateExecution, S as AgentCandidateProtectedModelReservation, V as VerifiedAgentCandidate, a as AgentCandidateExecutionPorts, b as AgentCandidateOutputPurpose, c as AgentCandidateExecutorPort, k as AgentCandidateVerificationPorts, p as AgentCandidateExecutorWorkspaceFile, v as AgentCandidateModelPort, x as AgentCandidateProtectedModelActivation, y as AgentCandidateOutputArtifactPort } from "./types-19ZOddS3.js";
|
|
3
|
+
import { AgentCandidateArtifactRef, AgentCandidateBundle, AgentCandidateCapturedArtifact, AgentCandidateCodeDisabled, AgentCandidateCodeNoOp, AgentCandidateExecution, AgentCandidateGitHubRepository, AgentCandidateKnowledge, AgentCandidateMemoryPolicy, AgentCandidateProfile, AgentCandidateResolvedModel, AgentCandidateRunCell, AgentCandidateWorkspaceSnapshotEvidence, AgentProfile, AgentProfileDiff, Sha256Digest } from "@tangle-network/agent-interface";
|
|
3
4
|
import { TraceStore } from "@tangle-network/agent-eval";
|
|
4
5
|
import { CodeSurface } from "@tangle-network/agent-eval/campaign";
|
|
5
|
-
import { AgentCandidateArtifactRef, AgentCandidateBundle, AgentCandidateCapturedArtifact, AgentCandidateCodeDisabled, AgentCandidateCodeNoOp, AgentCandidateExecution, AgentCandidateGitHubRepository, AgentCandidateKnowledge, AgentCandidateMemoryPolicy, AgentCandidateProfile, AgentCandidateResolvedModel, AgentCandidateRunCell, AgentCandidateWorkspaceSnapshotEvidence, AgentProfile as AgentProfile$1, AgentProfileDiff, Sha256Digest } from "@tangle-network/agent-interface";
|
|
6
6
|
import { AgentEnvironmentProvider, AgentExactProcessResources } from "@tangle-network/agent-interface/environment-provider";
|
|
7
7
|
//#region src/candidate-execution/bundle.d.ts
|
|
8
8
|
/** Exact candidate wire shape before the runtime computes its canonical digest. */
|
|
@@ -14,10 +14,10 @@ declare function sealAgentCandidateBundle(input: AgentCandidateBundleInput): Age
|
|
|
14
14
|
/** A complete profile that can be frozen without losing behavior. */
|
|
15
15
|
type AgentCandidateProfileSource = {
|
|
16
16
|
kind: 'profile';
|
|
17
|
-
profile: AgentProfile
|
|
17
|
+
profile: AgentProfile;
|
|
18
18
|
} | {
|
|
19
19
|
kind: 'profile-diffs';
|
|
20
|
-
base: AgentProfile
|
|
20
|
+
base: AgentProfile;
|
|
21
21
|
/** Applied in order before the resulting profile is frozen into the bundle. */
|
|
22
22
|
diffs: readonly AgentProfileDiff[];
|
|
23
23
|
} | {
|
|
@@ -229,4 +229,4 @@ declare function captureAgentCandidateWorkspaceFiles(input: readonly AgentCandid
|
|
|
229
229
|
declare function createAgentCandidateWorkspacePort(options?: CreateAgentCandidateWorkspacePortOptions): AgentCandidateWorkspacePort;
|
|
230
230
|
//#endregion
|
|
231
231
|
export { BuildAgentCandidateBundleInput as A, DisposePreparedAgentCandidateOptions as C, AgentCandidateCodeSource as D, FileAgentCandidateExecutionClaimStoreOptions as E, AgentCandidateBundleInput as M, sealAgentCandidateBundle as N, AgentCandidateCodeSurfaceSource as O, exactProcessProviderAsCandidateExecutor as S, FileAgentCandidateExecutionClaimStore as T, persistCandidateOutputArtifact as _, captureAgentCandidateWorkspace as a, candidateKnowledgeExecutionPaths as b, AGENT_CANDIDATE_EXECUTION_SUPPORT as c, recoverExpiredAgentCandidateExecution as d, AgentCandidateModelGrantRunReservationInput as f, runProtectedAgentCandidateModelGrant as g, RunProtectedAgentCandidateModelGrantResult as h, CreateAgentCandidateWorkspacePortOptions as i, buildAgentCandidateBundle as j, AgentCandidateProfileSource as k, verifyAgentCandidateBundle as l, RunProtectedAgentCandidateModelGrantOptions as m, CaptureAgentCandidateWorkspaceOptions as n, captureAgentCandidateWorkspaceFiles as o, ProtectedAgentCandidateModelGrantContext as p, CapturedAgentCandidateWorkspace as r, createAgentCandidateWorkspacePort as s, AgentCandidateWorkspaceArchiveLimits as t, RecoverExpiredAgentCandidateOptions as u, CANDIDATE_KNOWLEDGE_RETRIEVAL_CONFIG_ENV as v, disposePreparedAgentCandidateExecution as w, ExactProcessCandidateExecutorOptions as x, CANDIDATE_KNOWLEDGE_ROOT_ENV as y };
|
|
232
|
-
//# sourceMappingURL=index-
|
|
232
|
+
//# sourceMappingURL=index-DQv7iCeE.d.ts.map
|
package/dist/index.d.ts
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import { $ as OpenAIChatToolChoice, A as RuntimeRunCompleteInput, B as AgentBackendInput, F as RuntimeRunRow, G as AgentTaskContext, H as AgentKnowledgeProvider, I as RuntimeRunStatus, J as AgentTaskStatus, K as AgentTaskRunResult, L as startRuntimeRun, M as RuntimeRunHandle, N as RuntimeRunOptions, P as RuntimeRunPersistenceAdapter, Q as OpenAIChatTool, R as AgentAdapter, U as AgentRuntimeEvent, V as AgentExecutionBackend, W as AgentRuntimeEventSink, X as KnowledgeReadinessDecision, Y as BackendErrorDetail, Z as OpenAIChatResponseFormat, et as RunAgentTaskOptions, it as
|
|
1
|
+
import { $ as OpenAIChatToolChoice, A as RuntimeRunCompleteInput, B as AgentBackendInput, F as RuntimeRunRow, G as AgentTaskContext, H as AgentKnowledgeProvider, I as RuntimeRunStatus, J as AgentTaskStatus, K as AgentTaskRunResult, L as startRuntimeRun, M as RuntimeRunHandle, N as RuntimeRunOptions, P as RuntimeRunPersistenceAdapter, Q as OpenAIChatTool, R as AgentAdapter, U as AgentRuntimeEvent, V as AgentExecutionBackend, W as AgentRuntimeEventSink, X as KnowledgeReadinessDecision, Y as BackendErrorDetail, Z as OpenAIChatResponseFormat, at as RuntimeStreamEvent, et as RunAgentTaskOptions, it as RuntimeSessionStore, j as RuntimeRunCost, m as LoopResult, nt as RuntimeCanonicalStreamEvent, q as AgentTaskSpec, r as Driver, rt as RuntimeSession, tt as RunAgentTaskStreamOptions, z as AgentBackendContext } from "./types-C244Huc9.js";
|
|
2
2
|
import { i as SurfaceImprovementEdit } from "./improvement-adapter-D5gwwoXQ.js";
|
|
3
3
|
import { o as ImprovementProposalSource } from "./types-zWfqDjeL.js";
|
|
4
|
-
import {
|
|
4
|
+
import { Vl as AnalystRegistry, _f as RetainedInteractiveBindingError, bf as RuntimeRunStateError, cs as FinalizeContext, df as BackendTransportError, ff as ConfigError, gf as RetainedInteractiveAdmissionError, hf as PlannerError, ir as StructuralRolloutPolicy, lf as AgentEvalError, mf as NotFoundError, pf as JudgeError, ql as CoordinationEvent, uf as AgentEvalErrorCode, us as SupervisorFinalizer, vf as RetainedRunAdmissionError, xf as ValidationError, yf as RetainedRunDispatchBindingError } from "./index-COnuT0h7.js";
|
|
5
5
|
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-sbRpjStq.js";
|
|
6
|
-
import { At as exportEvalRuns, Bt as RuntimeTelemetryOptions, Ct as OtelSpan, Dt as buildRuntimeEventOtelSpans, E as ProviderModelExecutionEvidence, Et as buildLoopSpanNodes, Ft as toOtelAttributes, G as SpendGap, Gt as sanitizeAgentRuntimeEvent, Ht as SanitizedKnowledgeRequirement, I as Scope, It as RuntimeEventCollector, J as Supervisor, Kt as sanitizeKnowledgeReadinessReport, L as Settled, Lt as RuntimeStreamEventCollector, Mt as loopEventToOtelSpan, N as RootProviderModelEvidence, Nt as padSpanId, Ot as createOpenInferenceFileExporter, Pt as padTraceId, Rt as RuntimeStreamEventSink, St as OtelExporter, T as ProviderModelAttemptEvidence, Tt as buildLoopOtelSpans, U as Spend, Ut as createRuntimeEventCollector, Vt as SanitizedKnowledgeReadinessReport, W as SpendChannel, Wt as createRuntimeStreamEventCollector, _t as EvalRunsExportResult, bt as OtelAttribute, gt as EvalRunsExportConfig, ht as EvalRunGeneration, i as Budget, jt as generateSpanId, kt as createOtelExporter, m as ExecutorRegistry, mt as EvalRunEvent, nt as WorkerTraceUnavailableReason, q as SupervisedResult, qt as sanitizeRuntimeStreamEvent, r as AgentSpec, s as Executor, tt as WorkerTraceEvidence, vt as INTELLIGENCE_WIRE_VERSION, wt as RuntimeEventOtelOptions, xt as OtelExportConfig, yt as LoopSpanNode, zt as RuntimeStreamEventSummary } from "./types-
|
|
7
|
-
import { M as WorktreeCheckRunner } from "./runtime-
|
|
8
|
-
import { A as BuildAgentCandidateBundleInput, C as DisposePreparedAgentCandidateOptions, D as AgentCandidateCodeSource, E as FileAgentCandidateExecutionClaimStoreOptions, M as AgentCandidateBundleInput, N as sealAgentCandidateBundle, O as AgentCandidateCodeSurfaceSource, S as exactProcessProviderAsCandidateExecutor, T as FileAgentCandidateExecutionClaimStore, _ as persistCandidateOutputArtifact, a as captureAgentCandidateWorkspace, b as candidateKnowledgeExecutionPaths, c as AGENT_CANDIDATE_EXECUTION_SUPPORT, d as recoverExpiredAgentCandidateExecution, f as AgentCandidateModelGrantRunReservationInput, g as runProtectedAgentCandidateModelGrant, h as RunProtectedAgentCandidateModelGrantResult, i as CreateAgentCandidateWorkspacePortOptions, j as buildAgentCandidateBundle, k as AgentCandidateProfileSource, l as verifyAgentCandidateBundle, m as RunProtectedAgentCandidateModelGrantOptions, n as CaptureAgentCandidateWorkspaceOptions, o as captureAgentCandidateWorkspaceFiles, p as ProtectedAgentCandidateModelGrantContext, r as CapturedAgentCandidateWorkspace, s as createAgentCandidateWorkspacePort, t as AgentCandidateWorkspaceArchiveLimits, u as RecoverExpiredAgentCandidateOptions, v as CANDIDATE_KNOWLEDGE_RETRIEVAL_CONFIG_ENV, w as disposePreparedAgentCandidateExecution, x as ExactProcessCandidateExecutorOptions, y as CANDIDATE_KNOWLEDGE_ROOT_ENV } from "./index-
|
|
9
|
-
import { A as AgentCandidateExecutionPhase, B as AgentCandidatePreparationEvidence, C as AgentCandidateExecutionClaim, D as AgentCandidateExecutionFailureClass, E as AgentCandidateExecutionCleanupHandles, F as AgentCandidateExecutionTerminalResult, I as AgentCandidateRetryRejection, L as InMemoryAgentCandidateExecutionClaimStore, M as AgentCandidateExecutionRecoveryEvidence, N as AgentCandidateExecutionStageResult, O as AgentCandidateExecutionFinishResult, P as AgentCandidateExecutionTerminalRecord, R as InMemoryAgentCandidateExecutionClaimStoreOptions, S as AgentCandidateExecutionAttemptRef, T as AgentCandidateExecutionClaimStore, _ as PrepareAgentCandidateExecutionOptions, a as AgentCandidateModelGrantSettleInput, b as executePreparedAgentCandidate, c as agentCandidateProfileAsAgentProfile, d as freezeGenericAgentCandidateProfile, f as omitUndefinedObjectFields, g as parseExactCandidateProfile, h as parseExactAgentProfileDiff, i as AgentCandidateModelGrantReserveInput, j as AgentCandidateExecutionPhaseResult, k as AgentCandidateExecutionLease, l as applyExactAgentProfileDiff, m as parseExactAgentProfile, n as AgentCandidateModelGrantClient, o as CreateProtectedAgentCandidateModelPortOptions, r as AgentCandidateModelGrantReservation, s as createProtectedAgentCandidateModelPort, t as AgentCandidateModelGrantActivateInput, u as assertCandidateProfileBinding, v as prepareAgentCandidateExecution, w as AgentCandidateExecutionClaimResult, x as AgentCandidateExecutionAttemptRecord, y as ExecutePreparedAgentCandidateOptions, z as candidateExecutionClaim } from "./protected-model-port-
|
|
10
|
-
import { A as AgentCandidateWorkspacePort, B as ResolvedAgentCandidateContainer, C as AgentCandidateProtectedModelSettlement, D as AgentCandidateRunFinalization, E as AgentCandidateRepositoryPort, F as PreparedAgentCandidateExecution, H as VerifiedAgentCandidateTaskOutcome, I as PreparedAgentCandidateInstruction, L as PreparedAgentCandidateKnowledge, M as CANDIDATE_TRACE_TAGS, N as CanonicalCandidateDocument, O as AgentCandidateTaskExecution, P as PersistedTaskOutcomeEvidence, R as PreparedAgentCandidateLaunch, S as AgentCandidateProtectedModelReservation, T as AgentCandidateProtectedRunCapture, V as VerifiedAgentCandidate, _ as AgentCandidateModelLimits, a as AgentCandidateExecutionPorts, b as AgentCandidateOutputPurpose, c as AgentCandidateExecutorPort, d as AgentCandidateExecutorStopRequest, f as AgentCandidateExecutorTaskOutcomeCapture, g as AgentCandidateMemoryResetResult, h as AgentCandidateMemoryPort, i as AgentCandidateContainerPort, j as CANDIDATE_TRACE_ENV, k as AgentCandidateVerificationPorts, l as AgentCandidateExecutorProfileFile, m as AgentCandidateExecutorWorkspaceInput, n as AgentCandidateBenchmarkGraderIdentity, o as AgentCandidateExecutorFinalCapture, p as AgentCandidateExecutorWorkspaceFile, r as AgentCandidateBenchmarkGraderPort, s as AgentCandidateExecutorMemoryCapture, t as AgentCandidateArtifactPort, u as AgentCandidateExecutorRequest, v as AgentCandidateModelPort, w as AgentCandidateProtectedModelSettlementCall, x as AgentCandidateProtectedModelActivation, y as AgentCandidateOutputArtifactPort, z as PreparedAgentCandidateTrace } from "./types-
|
|
11
|
-
import { $ as sleep, A as RunConversationOptions, B as buildForwardHeaders, C as ConversationResult, D as HaltPredicate, E as HaltContext, F as InMemoryConversationJournal, G as CircuitBreakerState, H as readDepth, I as DEFAULT_MAX_DEPTH, J as RetryBackoff, K as CircuitOpenError, L as FORWARD_HEADERS, M as ConversationJournal, N as ConversationJournalEntry, O as HaltReason, P as FileConversationJournal, Q as makePerAttemptSignal, R as ForwardHeaderName, S as ConversationPolicy, T as ConversationTurn, U as BackendCallPolicy, V as isDepthExceeded, W as CircuitBreakerConfig, X as computeBackoff, Y as RetryableErrorPredicate, Z as defaultIsRetryable, _ as createConversationBackend, a as RunPersonaConfig, b as ConversationDriveState, c as runPersonaDispatch, d as D1DatabaseLike, et as createProfileExecutionBackend, f as D1StmtLike, g as defineConversation, h as d1ToSqlAdapter, i as PersonaDriver, j as TurnOrder, k as HaltSignal, l as runConversation, m as SqlConversationJournal, n as turnId, o as RunPersonaConversationOptions, p as SqlAdapter, q as DeadlineExceededError, r as PersonaConversationResult, s as runPersonaConversation, t as slugifySpeaker, u as runConversationStream, v as AuthSource, w as ConversationStreamEvent, x as ConversationParticipant, y as Conversation, z as PropagatedHeaders } from "./index-
|
|
12
|
-
import { $ as agenticGenerator, A as ImprovementCandidate, B as ImprovementProfilePopulationLineage, C as ImproveProfileComponents, D as ImproveScenarioPartitions, E as ImproveRuntimeCodeGeneratorOptions, F as ImprovementProfileCandidatePopulationAvailable, G as ReadonlyAgentProfile, H as ImprovementProfilePopulationObservationSource, I as ImprovementProfileCandidatePopulationUnavailable, J as AgenticGeneratorShotDisposition, K as AgenticGeneratorExecutorForWorktree, L as ImprovementProfilePopulationArtifactSource, M as ImprovementMaterializedProfilePopulationCandidate, N as ImprovementProfileCandidate, O as ImproveSkillsOptions, P as ImprovementProfileCandidatePopulation, Q as VerifyResult, R as ImprovementProfilePopulationCandidate, S as ImproveProfileAgent, T as ImproveResult, U as ImprovementRefusedProfilePopulationCandidate, V as ImprovementProfilePopulationLineageNode, W as DeepReadonly, X as AgenticGeneratorShotReceipt, Y as AgenticGeneratorShotExecution, Z as Verifier, _ as ImproveMethodOptions, a as ImproveCandidateValidationInput, b as ImproveOptimizationRunOptions, c as ImproveCodeOptions, d as ImproveCost, et as commandVerifier, f as ImproveCustomCodeGeneratorOptions, g as ImproveMethodLineage, h as ImproveMethodFactory, i as improve, j as ImprovementCodeCandidate, k as ImproveSurface, l as ImproveCodeResult, m as ImproveMethodContext, nt as CandidateGenerator, o as ImproveCandidateValidator, p as ImproveLineage, q as AgenticGeneratorOptions, s as ImproveCodeBaseOptions, t as Redactor, tt as defaultBuildPrompt, u as ImproveCodeRunOptions, v as ImproveMethodResult, w as ImproveProfileSurface, x as ImproveOptions, y as ImproveMethodSource, z as ImprovementProfilePopulationCandidateSource } from "./redact-
|
|
13
|
-
import { C as KnowledgeImprovementActivationExecutor, S as CreateKnowledgeImprovementActivationExecutorOptions, _ as SupervisedKnowledgeUpdater, a as KnowledgeImprovementJobResult, b as knowledgeReadinessDeliverable, c as createAgentKnowledgeReadinessCheck, d as KnowledgeReadinessCheckInput, f as KnowledgeReadinessCheckResult, g as SupervisedKnowledgeUpdateResult, h as SupervisedKnowledgeUpdateOptions, i as KnowledgeImprovementJobMeasurement, l as runKnowledgeImprovementJob, m as SupervisedKnowledgeUpdateInput, n as KnowledgeImprovementCandidatePair, o as RunKnowledgeImprovementJobOptions, p as RESEARCH_SUPERVISOR_SYSTEM_PROMPT, r as KnowledgeImprovementExperimentBundles, s as buildKnowledgeImprovementExperimentBundles, t as AgentKnowledgeReadinessCheckOptions, u as KnowledgeReadinessCheck, v as createSupervisedKnowledgeUpdater, w as createKnowledgeImprovementActivationExecutor, x as runSupervisedKnowledgeUpdate, y as formatSupervisedKnowledgeTask } from "./index-
|
|
14
|
-
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-
|
|
15
|
-
import { n as mcpToolsForRuntimeMcpSubset, t as mcpToolsForRuntimeMcp } from "./openai-tools-
|
|
6
|
+
import { At as exportEvalRuns, Bt as RuntimeTelemetryOptions, Ct as OtelSpan, Dt as buildRuntimeEventOtelSpans, E as ProviderModelExecutionEvidence, Et as buildLoopSpanNodes, Ft as toOtelAttributes, G as SpendGap, Gt as sanitizeAgentRuntimeEvent, Ht as SanitizedKnowledgeRequirement, I as Scope, It as RuntimeEventCollector, J as Supervisor, Kt as sanitizeKnowledgeReadinessReport, L as Settled, Lt as RuntimeStreamEventCollector, Mt as loopEventToOtelSpan, N as RootProviderModelEvidence, Nt as padSpanId, Ot as createOpenInferenceFileExporter, Pt as padTraceId, Rt as RuntimeStreamEventSink, St as OtelExporter, T as ProviderModelAttemptEvidence, Tt as buildLoopOtelSpans, U as Spend, Ut as createRuntimeEventCollector, Vt as SanitizedKnowledgeReadinessReport, W as SpendChannel, Wt as createRuntimeStreamEventCollector, _t as EvalRunsExportResult, bt as OtelAttribute, gt as EvalRunsExportConfig, ht as EvalRunGeneration, i as Budget, jt as generateSpanId, kt as createOtelExporter, m as ExecutorRegistry, mt as EvalRunEvent, nt as WorkerTraceUnavailableReason, q as SupervisedResult, qt as sanitizeRuntimeStreamEvent, r as AgentSpec, s as Executor, tt as WorkerTraceEvidence, vt as INTELLIGENCE_WIRE_VERSION, wt as RuntimeEventOtelOptions, xt as OtelExportConfig, yt as LoopSpanNode, zt as RuntimeStreamEventSummary } from "./types-D4arYjUl.js";
|
|
7
|
+
import { M as WorktreeCheckRunner } from "./runtime-CVNWEw16.js";
|
|
8
|
+
import { A as BuildAgentCandidateBundleInput, C as DisposePreparedAgentCandidateOptions, D as AgentCandidateCodeSource, E as FileAgentCandidateExecutionClaimStoreOptions, M as AgentCandidateBundleInput, N as sealAgentCandidateBundle, O as AgentCandidateCodeSurfaceSource, S as exactProcessProviderAsCandidateExecutor, T as FileAgentCandidateExecutionClaimStore, _ as persistCandidateOutputArtifact, a as captureAgentCandidateWorkspace, b as candidateKnowledgeExecutionPaths, c as AGENT_CANDIDATE_EXECUTION_SUPPORT, d as recoverExpiredAgentCandidateExecution, f as AgentCandidateModelGrantRunReservationInput, g as runProtectedAgentCandidateModelGrant, h as RunProtectedAgentCandidateModelGrantResult, i as CreateAgentCandidateWorkspacePortOptions, j as buildAgentCandidateBundle, k as AgentCandidateProfileSource, l as verifyAgentCandidateBundle, m as RunProtectedAgentCandidateModelGrantOptions, n as CaptureAgentCandidateWorkspaceOptions, o as captureAgentCandidateWorkspaceFiles, p as ProtectedAgentCandidateModelGrantContext, r as CapturedAgentCandidateWorkspace, s as createAgentCandidateWorkspacePort, t as AgentCandidateWorkspaceArchiveLimits, u as RecoverExpiredAgentCandidateOptions, v as CANDIDATE_KNOWLEDGE_RETRIEVAL_CONFIG_ENV, w as disposePreparedAgentCandidateExecution, x as ExactProcessCandidateExecutorOptions, y as CANDIDATE_KNOWLEDGE_ROOT_ENV } from "./index-DQv7iCeE.js";
|
|
9
|
+
import { A as AgentCandidateExecutionPhase, B as AgentCandidatePreparationEvidence, C as AgentCandidateExecutionClaim, D as AgentCandidateExecutionFailureClass, E as AgentCandidateExecutionCleanupHandles, F as AgentCandidateExecutionTerminalResult, I as AgentCandidateRetryRejection, L as InMemoryAgentCandidateExecutionClaimStore, M as AgentCandidateExecutionRecoveryEvidence, N as AgentCandidateExecutionStageResult, O as AgentCandidateExecutionFinishResult, P as AgentCandidateExecutionTerminalRecord, R as InMemoryAgentCandidateExecutionClaimStoreOptions, S as AgentCandidateExecutionAttemptRef, T as AgentCandidateExecutionClaimStore, _ as PrepareAgentCandidateExecutionOptions, a as AgentCandidateModelGrantSettleInput, b as executePreparedAgentCandidate, c as agentCandidateProfileAsAgentProfile, d as freezeGenericAgentCandidateProfile, f as omitUndefinedObjectFields, g as parseExactCandidateProfile, h as parseExactAgentProfileDiff, i as AgentCandidateModelGrantReserveInput, j as AgentCandidateExecutionPhaseResult, k as AgentCandidateExecutionLease, l as applyExactAgentProfileDiff, m as parseExactAgentProfile, n as AgentCandidateModelGrantClient, o as CreateProtectedAgentCandidateModelPortOptions, r as AgentCandidateModelGrantReservation, s as createProtectedAgentCandidateModelPort, t as AgentCandidateModelGrantActivateInput, u as assertCandidateProfileBinding, v as prepareAgentCandidateExecution, w as AgentCandidateExecutionClaimResult, x as AgentCandidateExecutionAttemptRecord, y as ExecutePreparedAgentCandidateOptions, z as candidateExecutionClaim } from "./protected-model-port-B8ssMyUg.js";
|
|
10
|
+
import { A as AgentCandidateWorkspacePort, B as ResolvedAgentCandidateContainer, C as AgentCandidateProtectedModelSettlement, D as AgentCandidateRunFinalization, E as AgentCandidateRepositoryPort, F as PreparedAgentCandidateExecution, H as VerifiedAgentCandidateTaskOutcome, I as PreparedAgentCandidateInstruction, L as PreparedAgentCandidateKnowledge, M as CANDIDATE_TRACE_TAGS, N as CanonicalCandidateDocument, O as AgentCandidateTaskExecution, P as PersistedTaskOutcomeEvidence, R as PreparedAgentCandidateLaunch, S as AgentCandidateProtectedModelReservation, T as AgentCandidateProtectedRunCapture, V as VerifiedAgentCandidate, _ as AgentCandidateModelLimits, a as AgentCandidateExecutionPorts, b as AgentCandidateOutputPurpose, c as AgentCandidateExecutorPort, d as AgentCandidateExecutorStopRequest, f as AgentCandidateExecutorTaskOutcomeCapture, g as AgentCandidateMemoryResetResult, h as AgentCandidateMemoryPort, i as AgentCandidateContainerPort, j as CANDIDATE_TRACE_ENV, k as AgentCandidateVerificationPorts, l as AgentCandidateExecutorProfileFile, m as AgentCandidateExecutorWorkspaceInput, n as AgentCandidateBenchmarkGraderIdentity, o as AgentCandidateExecutorFinalCapture, p as AgentCandidateExecutorWorkspaceFile, r as AgentCandidateBenchmarkGraderPort, s as AgentCandidateExecutorMemoryCapture, t as AgentCandidateArtifactPort, u as AgentCandidateExecutorRequest, v as AgentCandidateModelPort, w as AgentCandidateProtectedModelSettlementCall, x as AgentCandidateProtectedModelActivation, y as AgentCandidateOutputArtifactPort, z as PreparedAgentCandidateTrace } from "./types-19ZOddS3.js";
|
|
11
|
+
import { $ as sleep, A as RunConversationOptions, B as buildForwardHeaders, C as ConversationResult, D as HaltPredicate, E as HaltContext, F as InMemoryConversationJournal, G as CircuitBreakerState, H as readDepth, I as DEFAULT_MAX_DEPTH, J as RetryBackoff, K as CircuitOpenError, L as FORWARD_HEADERS, M as ConversationJournal, N as ConversationJournalEntry, O as HaltReason, P as FileConversationJournal, Q as makePerAttemptSignal, R as ForwardHeaderName, S as ConversationPolicy, T as ConversationTurn, U as BackendCallPolicy, V as isDepthExceeded, W as CircuitBreakerConfig, X as computeBackoff, Y as RetryableErrorPredicate, Z as defaultIsRetryable, _ as createConversationBackend, a as RunPersonaConfig, b as ConversationDriveState, c as runPersonaDispatch, d as D1DatabaseLike, et as createProfileExecutionBackend, f as D1StmtLike, g as defineConversation, h as d1ToSqlAdapter, i as PersonaDriver, j as TurnOrder, k as HaltSignal, l as runConversation, m as SqlConversationJournal, n as turnId, o as RunPersonaConversationOptions, p as SqlAdapter, q as DeadlineExceededError, r as PersonaConversationResult, s as runPersonaConversation, t as slugifySpeaker, u as runConversationStream, v as AuthSource, w as ConversationStreamEvent, x as ConversationParticipant, y as Conversation, z as PropagatedHeaders } from "./index-CTz17pH6.js";
|
|
12
|
+
import { $ as agenticGenerator, A as ImprovementCandidate, B as ImprovementProfilePopulationLineage, C as ImproveProfileComponents, D as ImproveScenarioPartitions, E as ImproveRuntimeCodeGeneratorOptions, F as ImprovementProfileCandidatePopulationAvailable, G as ReadonlyAgentProfile, H as ImprovementProfilePopulationObservationSource, I as ImprovementProfileCandidatePopulationUnavailable, J as AgenticGeneratorShotDisposition, K as AgenticGeneratorExecutorForWorktree, L as ImprovementProfilePopulationArtifactSource, M as ImprovementMaterializedProfilePopulationCandidate, N as ImprovementProfileCandidate, O as ImproveSkillsOptions, P as ImprovementProfileCandidatePopulation, Q as VerifyResult, R as ImprovementProfilePopulationCandidate, S as ImproveProfileAgent, T as ImproveResult, U as ImprovementRefusedProfilePopulationCandidate, V as ImprovementProfilePopulationLineageNode, W as DeepReadonly, X as AgenticGeneratorShotReceipt, Y as AgenticGeneratorShotExecution, Z as Verifier, _ as ImproveMethodOptions, a as ImproveCandidateValidationInput, b as ImproveOptimizationRunOptions, c as ImproveCodeOptions, d as ImproveCost, et as commandVerifier, f as ImproveCustomCodeGeneratorOptions, g as ImproveMethodLineage, h as ImproveMethodFactory, i as improve, j as ImprovementCodeCandidate, k as ImproveSurface, l as ImproveCodeResult, m as ImproveMethodContext, nt as CandidateGenerator, o as ImproveCandidateValidator, p as ImproveLineage, q as AgenticGeneratorOptions, s as ImproveCodeBaseOptions, t as Redactor, tt as defaultBuildPrompt, u as ImproveCodeRunOptions, v as ImproveMethodResult, w as ImproveProfileSurface, x as ImproveOptions, y as ImproveMethodSource, z as ImprovementProfilePopulationCandidateSource } from "./redact-CLw2B7Qj.js";
|
|
13
|
+
import { C as KnowledgeImprovementActivationExecutor, S as CreateKnowledgeImprovementActivationExecutorOptions, _ as SupervisedKnowledgeUpdater, a as KnowledgeImprovementJobResult, b as knowledgeReadinessDeliverable, c as createAgentKnowledgeReadinessCheck, d as KnowledgeReadinessCheckInput, f as KnowledgeReadinessCheckResult, g as SupervisedKnowledgeUpdateResult, h as SupervisedKnowledgeUpdateOptions, i as KnowledgeImprovementJobMeasurement, l as runKnowledgeImprovementJob, m as SupervisedKnowledgeUpdateInput, n as KnowledgeImprovementCandidatePair, o as RunKnowledgeImprovementJobOptions, p as RESEARCH_SUPERVISOR_SYSTEM_PROMPT, r as KnowledgeImprovementExperimentBundles, s as buildKnowledgeImprovementExperimentBundles, t as AgentKnowledgeReadinessCheckOptions, u as KnowledgeReadinessCheck, v as createSupervisedKnowledgeUpdater, w as createKnowledgeImprovementActivationExecutor, x as runSupervisedKnowledgeUpdate, y as formatSupervisedKnowledgeTask } from "./index-C6yfz0QN.js";
|
|
14
|
+
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-DUNxyuaG.js";
|
|
15
|
+
import { n as mcpToolsForRuntimeMcpSubset, t as mcpToolsForRuntimeMcp } from "./openai-tools-yoRRzAUW.js";
|
|
16
|
+
import { AgentProfile, Sha256Digest } from "@tangle-network/agent-interface";
|
|
16
17
|
import { ControlBudget, ControlDecision, ControlEvalResult, ControlEvalResult as ControlEvalResult$1, ControlRunResult, ControlStep, DataAcquisitionPlan, KnowledgeReadinessReport, KnowledgeReadinessReport as KnowledgeReadinessReport$1, KnowledgeRequirement, ProposalFinding, RunRecord, RunRecord as RunRecord$1 } from "@tangle-network/agent-eval";
|
|
17
18
|
import { GepaOptimizationMethodConfig, SkillOptOptimizationMethodConfig } from "@tangle-network/agent-eval/campaign";
|
|
18
|
-
import { AgentProfile as AgentProfile$1 } from "@tangle-network/agent-interface";
|
|
19
19
|
import { MutableSurface, Scenario as Scenario$1, SelfImproveOptions } from "@tangle-network/agent-eval/contract";
|
|
20
20
|
//#region src/backends.d.ts
|
|
21
21
|
/** Wrap any custom async-iterable stream into a typed `AgentExecutionBackend`. @stable */
|
|
@@ -142,6 +142,76 @@ declare const optimizerMethod: string;
|
|
|
142
142
|
*/
|
|
143
143
|
declare const strategyAuthorMethod: string;
|
|
144
144
|
//#endregion
|
|
145
|
+
//#region src/improvement/profile-improvement-harness.d.ts
|
|
146
|
+
interface CreateProfileImprovementHarnessOptions<TScenario extends Scenario$1, TArtifact> {
|
|
147
|
+
/** Exact baseline profile. It is parsed, detached, and frozen at construction. */
|
|
148
|
+
profile: AgentProfile;
|
|
149
|
+
/**
|
|
150
|
+
* Immutable identity of the bound executor, models, tools, component mapping,
|
|
151
|
+
* and every closure or external setting that can change measured behavior.
|
|
152
|
+
*/
|
|
153
|
+
executionRef: Sha256Digest;
|
|
154
|
+
/** Execute one exact materialized profile on one scenario. */
|
|
155
|
+
agent: ImproveProfileAgent<TScenario, TArtifact>;
|
|
156
|
+
/** Optional validator shared by every run from this harness. */
|
|
157
|
+
validateCandidate?: ImproveCandidateValidator;
|
|
158
|
+
}
|
|
159
|
+
type ProfileImprovementHarnessRunOptions<TScenario extends Scenario$1, TArtifact> = Omit<ImproveMethodOptions<TScenario, TArtifact>, 'executionRef' | 'agent' | 'validateCandidate'> & {
|
|
160
|
+
/** Override the harness-level validator for this run. */
|
|
161
|
+
validateCandidate?: ImproveCandidateValidator;
|
|
162
|
+
};
|
|
163
|
+
/**
|
|
164
|
+
* A small, reusable front door over `improve(profile, options)`.
|
|
165
|
+
*
|
|
166
|
+
* The harness freezes the baseline and binds execution identity once, which
|
|
167
|
+
* removes the two easiest sources of accidental experiment drift when a
|
|
168
|
+
* developer runs several methods, surfaces, or held-out suites against the
|
|
169
|
+
* same agent. It does not replace or narrow `improve`; callers retain every
|
|
170
|
+
* method option and may still use the lower-level API directly.
|
|
171
|
+
*/
|
|
172
|
+
interface ProfileImprovementHarness<TScenario extends Scenario$1, TArtifact> {
|
|
173
|
+
/** Detached immutable baseline actually used by every run. */
|
|
174
|
+
readonly profile: ReadonlyAgentProfile;
|
|
175
|
+
/** Canonical digest of the bound baseline profile. */
|
|
176
|
+
readonly profileDigest: Sha256Digest;
|
|
177
|
+
/** Exact execution identity bound at construction. */
|
|
178
|
+
readonly executionRef: Sha256Digest;
|
|
179
|
+
run(options: ProfileImprovementHarnessRunOptions<TScenario, TArtifact>): Promise<ImproveMethodResult>;
|
|
180
|
+
}
|
|
181
|
+
/**
|
|
182
|
+
* Bind one exact profile and executor into a repeatable self-improvement
|
|
183
|
+
* harness. The returned `run` method remains generic over every existing
|
|
184
|
+
* profile surface, optimization method, split, gate, and budget option.
|
|
185
|
+
*/
|
|
186
|
+
declare function createProfileImprovementHarness<TScenario extends Scenario$1, TArtifact>(options: CreateProfileImprovementHarnessOptions<TScenario, TArtifact>): ProfileImprovementHarness<TScenario, TArtifact>;
|
|
187
|
+
//#endregion
|
|
188
|
+
//#region src/improvement/prompt-instructions-profile-components.d.ts
|
|
189
|
+
/** Stable component-name prefix used for `profile.prompt.instructions`. */
|
|
190
|
+
declare const PROMPT_INSTRUCTION_COMPONENT_PREFIX = "prompt.instruction:";
|
|
191
|
+
/**
|
|
192
|
+
* Canonical `ImproveProfileComponents` mapping for the ordered
|
|
193
|
+
* `AgentProfile.prompt.instructions` list.
|
|
194
|
+
*
|
|
195
|
+
* Use it with `surface: 'agent-profile'` when an optimizer should rewrite the
|
|
196
|
+
* exact instruction texts without being allowed to change their count, order,
|
|
197
|
+
* labels, or any unrelated profile field:
|
|
198
|
+
*
|
|
199
|
+
* ```ts
|
|
200
|
+
* await improve(profile, {
|
|
201
|
+
* surface: 'agent-profile',
|
|
202
|
+
* profileComponents: promptInstructionsProfileComponents,
|
|
203
|
+
* // method, scenarios, judge, executionRef, agent, ...
|
|
204
|
+
* })
|
|
205
|
+
* ```
|
|
206
|
+
*
|
|
207
|
+
* Component names are zero-padded and stable. Runtime's existing component
|
|
208
|
+
* materializer requires every candidate to preserve the exact key set and
|
|
209
|
+
* verifies that `apply(read(profile))` reproduces the baseline profile. A
|
|
210
|
+
* profile with no prompt instructions is refused rather than inventing a
|
|
211
|
+
* sentinel instruction that could accidentally ship.
|
|
212
|
+
*/
|
|
213
|
+
declare const promptInstructionsProfileComponents: ImproveProfileComponents;
|
|
214
|
+
//#endregion
|
|
145
215
|
//#region src/improvement/raw-trace-distiller.d.ts
|
|
146
216
|
interface RawTraceDistillerOptions {
|
|
147
217
|
/** Anchor the emitted paths at this run root instead of the generation `runDir`
|
|
@@ -206,7 +276,7 @@ declare function serializeRolloutPolicy(policy: StructuralRolloutPolicy): string
|
|
|
206
276
|
* not opt into structural rollout. */
|
|
207
277
|
declare function structuralRolloutPolicyFromProfile(profile: ReadonlyAgentProfile): StructuralRolloutPolicy | undefined;
|
|
208
278
|
/** Persist a detached policy under the profile extension without mutating the input. */
|
|
209
|
-
declare function applyRolloutPolicyToProfile(profile: ReadonlyAgentProfile, policy: StructuralRolloutPolicy): AgentProfile
|
|
279
|
+
declare function applyRolloutPolicyToProfile(profile: ReadonlyAgentProfile, policy: StructuralRolloutPolicy): AgentProfile;
|
|
210
280
|
//#endregion
|
|
211
281
|
//#region src/model-resolution.d.ts
|
|
212
282
|
/**
|
|
@@ -353,5 +423,5 @@ declare function readinessServerSentEvent(report: KnowledgeReadinessReport$1, op
|
|
|
353
423
|
/** Serialize a `RuntimeStreamEvent` as a Server-Sent Event string. @stable */
|
|
354
424
|
declare function runtimeStreamServerSentEvent(event: RuntimeStreamEvent, options?: RuntimeTelemetryOptions & ServerSentEventOptions): string;
|
|
355
425
|
//#endregion
|
|
356
|
-
export { AGENT_CANDIDATE_EXECUTION_SUPPORT, type AgentAdapter, type AgentBackendContext, type AgentBackendInput, type AgentCandidateArtifactPort, type AgentCandidateBenchmarkGraderIdentity, type AgentCandidateBenchmarkGraderPort, type AgentCandidateBundleInput, type AgentCandidateCodeSource, type AgentCandidateCodeSurfaceSource, type AgentCandidateContainerPort, type AgentCandidateExecutionAttemptRecord, type AgentCandidateExecutionAttemptRef, type AgentCandidateExecutionClaim, type AgentCandidateExecutionClaimResult, type AgentCandidateExecutionClaimStore, type AgentCandidateExecutionCleanupHandles, type AgentCandidateExecutionFailureClass, type AgentCandidateExecutionFinishResult, type AgentCandidateExecutionLease, type AgentCandidateExecutionPhase, type AgentCandidateExecutionPhaseResult, type AgentCandidateExecutionPorts, type AgentCandidateExecutionRecoveryEvidence, type AgentCandidateExecutionStageResult, type AgentCandidateExecutionTerminalRecord, type AgentCandidateExecutionTerminalResult, type AgentCandidateExecutorFinalCapture, type AgentCandidateExecutorMemoryCapture, type AgentCandidateExecutorPort, type AgentCandidateExecutorProfileFile, type AgentCandidateExecutorRequest, type AgentCandidateExecutorStopRequest, type AgentCandidateExecutorTaskOutcomeCapture, type AgentCandidateExecutorWorkspaceFile, type AgentCandidateExecutorWorkspaceInput, type AgentCandidateMemoryPort, type AgentCandidateMemoryResetResult, type AgentCandidateModelGrantActivateInput, type AgentCandidateModelGrantClient, type AgentCandidateModelGrantReservation, type AgentCandidateModelGrantReserveInput, type AgentCandidateModelGrantRunReservationInput, type AgentCandidateModelGrantSettleInput, type AgentCandidateModelLimits, type AgentCandidateModelPort, type AgentCandidateOutputArtifactPort, type AgentCandidateOutputPurpose, type AgentCandidatePreparationEvidence, type AgentCandidateProfileSource, type AgentCandidateProtectedModelActivation, type AgentCandidateProtectedModelReservation, type AgentCandidateProtectedModelSettlement, type AgentCandidateProtectedModelSettlementCall, type AgentCandidateProtectedRunCapture, type AgentCandidateRepositoryPort, type AgentCandidateRetryRejection, type AgentCandidateRunFinalization, type AgentCandidateTaskExecution, type AgentCandidateVerificationPorts, type AgentCandidateWorkspaceArchiveLimits, type AgentCandidateWorkspacePort, AgentEvalError, type AgentEvalErrorCode, type AgentExecutionBackend, type AgentKnowledgeProvider, type AgentKnowledgeReadinessCheckOptions, type AgentRuntimeEvent, type AgentRuntimeEventSink, type AgentSpec, type AgentTaskContext, type AgentTaskRunResult, type AgentTaskSpec, type AgentTaskStatus, type AgenticGeneratorExecutorForWorktree, type AgenticGeneratorOptions, type AgenticGeneratorShotDisposition, type AgenticGeneratorShotExecution, type AgenticGeneratorShotReceipt, type AnalystRegistry, type AuthSource, type BackendCallPolicy, type BackendErrorDetail, BackendTransportError, type Budget, type BuildAgentCandidateBundleInput, type BuildPromptFindingsInput, CANDIDATE_KNOWLEDGE_RETRIEVAL_CONFIG_ENV, CANDIDATE_KNOWLEDGE_ROOT_ENV, CANDIDATE_TRACE_ENV, CANDIDATE_TRACE_TAGS, type CandidateGenerator, type CanonicalCandidateDocument, type CaptureAgentCandidateWorkspaceOptions, type CapturedAgentCandidateWorkspace, type ChatModelCandidate, type ChatModelValidation, type CircuitBreakerConfig, CircuitBreakerState, CircuitOpenError, ConfigError, type ControlBudget, type ControlDecision, type ControlEvalResult, type ControlRunResult, type ControlStep, type Conversation, type ConversationDriveState, type ConversationJournal, type ConversationJournalEntry, type ConversationParticipant, type ConversationPolicy, type ConversationResult, type ConversationStreamEvent, type ConversationTurn, type CoordinationEvent, type CreateAgentCandidateWorkspacePortOptions, type CreateKnowledgeImprovementActivationExecutorOptions, type CreateProtectedAgentCandidateModelPortOptions, type D1DatabaseLike, type D1StmtLike, DEFAULT_MAX_DEPTH, DEFAULT_ROUTER_BASE_URL, DELEGATED_LOOP_MODES, type DataAcquisitionPlan, DeadlineExceededError, type DeepReadonly, type DelegatedLoopMode, type DelegatedLoopRegistry, type DelegatedLoopResult, type DelegatedLoopRunner, type DisposePreparedAgentCandidateOptions, type Driver, type EvalRunEvent, type EvalRunGeneration, type EvalRunsExportConfig, type EvalRunsExportResult, type ExactProcessCandidateExecutorOptions, type ExecutePreparedAgentCandidateOptions, type Executor, type ExecutorRegistry, FORWARD_HEADERS, FileAgentCandidateExecutionClaimStore, type FileAgentCandidateExecutionClaimStoreOptions, FileConversationJournal, type FinalizeContext, type ForwardHeaderName, type HaltContext, type HaltPredicate, type HaltReason, type HaltSignal, INTELLIGENCE_WIRE_VERSION, type ImproveCandidateValidationInput, type ImproveCandidateValidator, type ImproveCodeBaseOptions, type ImproveCodeOptions, type ImproveCodeResult, type ImproveCodeRunOptions, type ImproveCost, type ImproveCustomCodeGeneratorOptions, type ImproveLineage, type ImproveMethodContext, type ImproveMethodFactory, type ImproveMethodLineage, type ImproveMethodOptions, type ImproveMethodResult, type ImproveMethodSource, type ImproveOptimizationRunOptions, type ImproveOptions, type ImproveProfileAgent, type ImproveProfileComponents, type ImproveProfileSurface, type ImproveResult, type ImproveRuntimeCodeGeneratorOptions, type ImproveScenarioPartitions, type ImproveSkillsOptions, type ImproveSurface, type ImprovementCandidate, type ImprovementCodeCandidate, type ImprovementMaterializedProfilePopulationCandidate, type ImprovementProfileCandidate, type ImprovementProfileCandidatePopulation, type ImprovementProfileCandidatePopulationAvailable, type ImprovementProfileCandidatePopulationUnavailable, type ImprovementProfilePopulationArtifactSource, type ImprovementProfilePopulationCandidate, type ImprovementProfilePopulationCandidateSource, type ImprovementProfilePopulationLineage, type ImprovementProfilePopulationLineageNode, type ImprovementProfilePopulationObservationSource, type ImprovementRefusedProfilePopulationCandidate, InMemoryAgentCandidateExecutionClaimStore, type InMemoryAgentCandidateExecutionClaimStoreOptions, InMemoryConversationJournal, InMemoryRuntimeSessionStore, JudgeError, type KnowledgeImprovementActivationExecutor, type KnowledgeImprovementCandidatePair, type KnowledgeImprovementExperimentBundles, type KnowledgeImprovementJobMeasurement, type KnowledgeImprovementJobResult, type KnowledgeReadinessCheck, type KnowledgeReadinessCheckInput, type KnowledgeReadinessCheckResult, type KnowledgeReadinessDecision, type KnowledgeReadinessReport, type KnowledgeRequirement, type LoopResult, type LoopRunnerCliArgs, type LoopRunnerCliResult, type LoopSpanNode, type McpServeSpec, type ModelInfo, NotFoundError, type OfficialGepaOptions, type OfficialOptimizerContextOptions, OfficialOptimizerUnavailableError, type OfficialSensitiveCandidateInput, type OfficialSkillOptOptions, type OpenAIChatResponseFormat, type OpenAIChatTool, type OpenAIChatToolChoice, type OtelAttribute, type OtelExportConfig, type OtelExporter, type OtelSpan, type PersistedTaskOutcomeEvidence, type PersonaConversationResult, type PersonaDriver, PlannerError, type PrepareAgentCandidateExecutionOptions, type PreparedAgentCandidateExecution, type PreparedAgentCandidateInstruction, type PreparedAgentCandidateKnowledge, type PreparedAgentCandidateLaunch, type PreparedAgentCandidateTrace, type PropagatedHeaders, type ProtectedAgentCandidateModelGrantContext, type ProviderModelAttemptEvidence, type ProviderModelExecutionEvidence, RESEARCH_SUPERVISOR_SYSTEM_PROMPT, ROLLOUT_POLICY_EXTENSION, type RawTraceDistillerOptions, type ReadonlyAgentProfile, type RecoverExpiredAgentCandidateOptions, type ReflectiveGeneratorOptions, type ResearchLoopResult, type ResearchLoopRunnerOptions, type ResolvedAgentCandidateContainer, type ResolvedChatModel, RetainedRunAdmissionError, RetainedRunDispatchBindingError, type RetryBackoff, type RetryableErrorPredicate, type RootProviderModelEvidence, type RouterEnv, type RunAgentTaskOptions, type RunAgentTaskStreamOptions, type RunConversationOptions, type RunDelegatedLoopOptions, type RunKnowledgeImprovementJobOptions, type RunPersonaConfig, type RunPersonaConversationOptions, type RunProtectedAgentCandidateModelGrantOptions, type RunProtectedAgentCandidateModelGrantResult, type RunRecord, type RuntimeDecisionEvidenceRef, type RuntimeDecisionKind, type RuntimeDecisionPoint, type RuntimeEventCollector, type RuntimeEventOtelOptions, type RuntimeHookContext, type RuntimeHookErrorContext, type RuntimeHookEvent, type RuntimeHookPhase, type RuntimeHookTarget, type RuntimeHooks, type RuntimeRunCompleteInput, type RuntimeRunCost, type RuntimeRunHandle, type RuntimeRunOptions, type RuntimeRunPersistenceAdapter, type RuntimeRunRow, RuntimeRunStateError, type RuntimeRunStatus, type RuntimeSession, type RuntimeSessionStore, type RuntimeStreamEvent, type RuntimeStreamEventCollector, type RuntimeStreamEventSink, type RuntimeStreamEventSummary, type RuntimeTelemetryOptions, type SanitizedKnowledgeReadinessReport, type SanitizedKnowledgeRequirement, type Scope, type ServerSentEventOptions, type Settled, type Spend, type SpendChannel, type SpendGap, type SqlAdapter, SqlConversationJournal, type SupervisedKnowledgeUpdateInput, type SupervisedKnowledgeUpdateOptions, type SupervisedKnowledgeUpdateResult, type SupervisedKnowledgeUpdater, type SupervisedResult, type Supervisor, type SupervisorFinalizer, type TurnOrder, ValidationError, type VerifiedAgentCandidate, type VerifiedAgentCandidateTaskOutcome, type Verifier, type VerifyResult, type VetoedFact, type WorkerTraceEvidence, type WorkerTraceUnavailableReason, type WorktreeCheckRunner, type WorktreeLoopRunnerOptions, agentCandidateProfileAsAgentProfile, agenticGenerator, applyExactAgentProfileDiff, applyRolloutPolicyToProfile, applyRunRecordDefaults, assertCandidateProfileBinding, auditLoopRunner, buildAgentCandidateBundle, buildForwardHeaders, buildKnowledgeImprovementExperimentBundles, buildLoopOtelSpans, buildLoopSpanNodes, buildRuntimeEventOtelSpans, candidateExecutionClaim, candidateKnowledgeExecutionPaths, captureAgentCandidateWorkspace, captureAgentCandidateWorkspaceFiles, cleanModelId, commandVerifier, composeRuntimeHooks, computeBackoff, createAgentCandidateWorkspacePort, createAgentKnowledgeReadinessCheck, createConversationBackend, createIterableBackend, createKnowledgeImprovementActivationExecutor, createOpenInferenceFileExporter, createOtelExporter, createProfileExecutionBackend, createProtectedAgentCandidateModelPort, createRuntimeEventCollector, createRuntimeStreamEventCollector, createSandboxPromptBackend, createSupervisedKnowledgeUpdater, d1ToSqlAdapter, decideKnowledgeReadiness, defaultBuildPrompt, defaultIsRetryable, defineConversation, defineRuntimeHooks, disposePreparedAgentCandidateExecution, exactProcessProviderAsCandidateExecutor, executePreparedAgentCandidate, exportEvalRuns, findingLines, formatSupervisedKnowledgeTask, freezeGenericAgentCandidateProfile, generateSpanId, getModels, improve, isDelegatedLoopMode, isDepthExceeded, knowledgeReadinessDeliverable, loopEventToOtelSpan, makePerAttemptSignal, mcpBuildPrompt, mcpServeVerifier, mcpToolsForRuntimeMcp, mcpToolsForRuntimeMcpSubset, normalizeRolloutPolicy, notifyRuntimeDecisionPoint, notifyRuntimeHookEvent, officialGepa, officialSkillOpt, omitUndefinedObjectFields, optimizerMethod, padSpanId, padTraceId, parseExactAgentProfile, parseExactAgentProfileDiff, parseExactCandidateProfile, parseLoopRunnerArgv, parseRolloutPolicy, persistCandidateOutputArtifact, prepareAgentCandidateExecution, rawTraceDistiller, readDepth, readinessServerSentEvent, recoverExpiredAgentCandidateExecution, reflectiveGenerator, researchLoopRunner, resolveChatModel, resolveRouterBaseUrl, runAgentTask, runAgentTaskStream, runConversation, runConversationStream, runDelegatedLoop, runKnowledgeImprovementJob, runLoopRunnerCli, runPersonaConversation, runPersonaDispatch, runProtectedAgentCandidateModelGrant, runSupervisedKnowledgeUpdate, runtimeStreamServerSentEvent, sanitizeAgentRuntimeEvent, sanitizeKnowledgeReadinessReport, sanitizeRuntimeStreamEvent, sealAgentCandidateBundle, serializeRolloutPolicy, sleep, slugifySpeaker, startRuntimeRun, strategyAuthorMethod, structuralRolloutPolicyFromProfile, toOtelAttributes, toolBuildPrompt, turnId, validateChatModelId, verifyAgentCandidateBundle, worktreeLoopRunner };
|
|
426
|
+
export { AGENT_CANDIDATE_EXECUTION_SUPPORT, type AgentAdapter, type AgentBackendContext, type AgentBackendInput, type AgentCandidateArtifactPort, type AgentCandidateBenchmarkGraderIdentity, type AgentCandidateBenchmarkGraderPort, type AgentCandidateBundleInput, type AgentCandidateCodeSource, type AgentCandidateCodeSurfaceSource, type AgentCandidateContainerPort, type AgentCandidateExecutionAttemptRecord, type AgentCandidateExecutionAttemptRef, type AgentCandidateExecutionClaim, type AgentCandidateExecutionClaimResult, type AgentCandidateExecutionClaimStore, type AgentCandidateExecutionCleanupHandles, type AgentCandidateExecutionFailureClass, type AgentCandidateExecutionFinishResult, type AgentCandidateExecutionLease, type AgentCandidateExecutionPhase, type AgentCandidateExecutionPhaseResult, type AgentCandidateExecutionPorts, type AgentCandidateExecutionRecoveryEvidence, type AgentCandidateExecutionStageResult, type AgentCandidateExecutionTerminalRecord, type AgentCandidateExecutionTerminalResult, type AgentCandidateExecutorFinalCapture, type AgentCandidateExecutorMemoryCapture, type AgentCandidateExecutorPort, type AgentCandidateExecutorProfileFile, type AgentCandidateExecutorRequest, type AgentCandidateExecutorStopRequest, type AgentCandidateExecutorTaskOutcomeCapture, type AgentCandidateExecutorWorkspaceFile, type AgentCandidateExecutorWorkspaceInput, type AgentCandidateMemoryPort, type AgentCandidateMemoryResetResult, type AgentCandidateModelGrantActivateInput, type AgentCandidateModelGrantClient, type AgentCandidateModelGrantReservation, type AgentCandidateModelGrantReserveInput, type AgentCandidateModelGrantRunReservationInput, type AgentCandidateModelGrantSettleInput, type AgentCandidateModelLimits, type AgentCandidateModelPort, type AgentCandidateOutputArtifactPort, type AgentCandidateOutputPurpose, type AgentCandidatePreparationEvidence, type AgentCandidateProfileSource, type AgentCandidateProtectedModelActivation, type AgentCandidateProtectedModelReservation, type AgentCandidateProtectedModelSettlement, type AgentCandidateProtectedModelSettlementCall, type AgentCandidateProtectedRunCapture, type AgentCandidateRepositoryPort, type AgentCandidateRetryRejection, type AgentCandidateRunFinalization, type AgentCandidateTaskExecution, type AgentCandidateVerificationPorts, type AgentCandidateWorkspaceArchiveLimits, type AgentCandidateWorkspacePort, AgentEvalError, type AgentEvalErrorCode, type AgentExecutionBackend, type AgentKnowledgeProvider, type AgentKnowledgeReadinessCheckOptions, type AgentRuntimeEvent, type AgentRuntimeEventSink, type AgentSpec, type AgentTaskContext, type AgentTaskRunResult, type AgentTaskSpec, type AgentTaskStatus, type AgenticGeneratorExecutorForWorktree, type AgenticGeneratorOptions, type AgenticGeneratorShotDisposition, type AgenticGeneratorShotExecution, type AgenticGeneratorShotReceipt, type AnalystRegistry, type AuthSource, type BackendCallPolicy, type BackendErrorDetail, BackendTransportError, type Budget, type BuildAgentCandidateBundleInput, type BuildPromptFindingsInput, CANDIDATE_KNOWLEDGE_RETRIEVAL_CONFIG_ENV, CANDIDATE_KNOWLEDGE_ROOT_ENV, CANDIDATE_TRACE_ENV, CANDIDATE_TRACE_TAGS, type CandidateGenerator, type CanonicalCandidateDocument, type CaptureAgentCandidateWorkspaceOptions, type CapturedAgentCandidateWorkspace, type ChatModelCandidate, type ChatModelValidation, type CircuitBreakerConfig, CircuitBreakerState, CircuitOpenError, ConfigError, type ControlBudget, type ControlDecision, type ControlEvalResult, type ControlRunResult, type ControlStep, type Conversation, type ConversationDriveState, type ConversationJournal, type ConversationJournalEntry, type ConversationParticipant, type ConversationPolicy, type ConversationResult, type ConversationStreamEvent, type ConversationTurn, type CoordinationEvent, type CreateAgentCandidateWorkspacePortOptions, type CreateKnowledgeImprovementActivationExecutorOptions, type CreateProfileImprovementHarnessOptions, type CreateProtectedAgentCandidateModelPortOptions, type D1DatabaseLike, type D1StmtLike, DEFAULT_MAX_DEPTH, DEFAULT_ROUTER_BASE_URL, DELEGATED_LOOP_MODES, type DataAcquisitionPlan, DeadlineExceededError, type DeepReadonly, type DelegatedLoopMode, type DelegatedLoopRegistry, type DelegatedLoopResult, type DelegatedLoopRunner, type DisposePreparedAgentCandidateOptions, type Driver, type EvalRunEvent, type EvalRunGeneration, type EvalRunsExportConfig, type EvalRunsExportResult, type ExactProcessCandidateExecutorOptions, type ExecutePreparedAgentCandidateOptions, type Executor, type ExecutorRegistry, FORWARD_HEADERS, FileAgentCandidateExecutionClaimStore, type FileAgentCandidateExecutionClaimStoreOptions, FileConversationJournal, type FinalizeContext, type ForwardHeaderName, type HaltContext, type HaltPredicate, type HaltReason, type HaltSignal, INTELLIGENCE_WIRE_VERSION, type ImproveCandidateValidationInput, type ImproveCandidateValidator, type ImproveCodeBaseOptions, type ImproveCodeOptions, type ImproveCodeResult, type ImproveCodeRunOptions, type ImproveCost, type ImproveCustomCodeGeneratorOptions, type ImproveLineage, type ImproveMethodContext, type ImproveMethodFactory, type ImproveMethodLineage, type ImproveMethodOptions, type ImproveMethodResult, type ImproveMethodSource, type ImproveOptimizationRunOptions, type ImproveOptions, type ImproveProfileAgent, type ImproveProfileComponents, type ImproveProfileSurface, type ImproveResult, type ImproveRuntimeCodeGeneratorOptions, type ImproveScenarioPartitions, type ImproveSkillsOptions, type ImproveSurface, type ImprovementCandidate, type ImprovementCodeCandidate, type ImprovementMaterializedProfilePopulationCandidate, type ImprovementProfileCandidate, type ImprovementProfileCandidatePopulation, type ImprovementProfileCandidatePopulationAvailable, type ImprovementProfileCandidatePopulationUnavailable, type ImprovementProfilePopulationArtifactSource, type ImprovementProfilePopulationCandidate, type ImprovementProfilePopulationCandidateSource, type ImprovementProfilePopulationLineage, type ImprovementProfilePopulationLineageNode, type ImprovementProfilePopulationObservationSource, type ImprovementRefusedProfilePopulationCandidate, InMemoryAgentCandidateExecutionClaimStore, type InMemoryAgentCandidateExecutionClaimStoreOptions, InMemoryConversationJournal, InMemoryRuntimeSessionStore, JudgeError, type KnowledgeImprovementActivationExecutor, type KnowledgeImprovementCandidatePair, type KnowledgeImprovementExperimentBundles, type KnowledgeImprovementJobMeasurement, type KnowledgeImprovementJobResult, type KnowledgeReadinessCheck, type KnowledgeReadinessCheckInput, type KnowledgeReadinessCheckResult, type KnowledgeReadinessDecision, type KnowledgeReadinessReport, type KnowledgeRequirement, type LoopResult, type LoopRunnerCliArgs, type LoopRunnerCliResult, type LoopSpanNode, type McpServeSpec, type ModelInfo, NotFoundError, type OfficialGepaOptions, type OfficialOptimizerContextOptions, OfficialOptimizerUnavailableError, type OfficialSensitiveCandidateInput, type OfficialSkillOptOptions, type OpenAIChatResponseFormat, type OpenAIChatTool, type OpenAIChatToolChoice, type OtelAttribute, type OtelExportConfig, type OtelExporter, type OtelSpan, PROMPT_INSTRUCTION_COMPONENT_PREFIX, type PersistedTaskOutcomeEvidence, type PersonaConversationResult, type PersonaDriver, PlannerError, type PrepareAgentCandidateExecutionOptions, type PreparedAgentCandidateExecution, type PreparedAgentCandidateInstruction, type PreparedAgentCandidateKnowledge, type PreparedAgentCandidateLaunch, type PreparedAgentCandidateTrace, type ProfileImprovementHarness, type ProfileImprovementHarnessRunOptions, type PropagatedHeaders, type ProtectedAgentCandidateModelGrantContext, type ProviderModelAttemptEvidence, type ProviderModelExecutionEvidence, RESEARCH_SUPERVISOR_SYSTEM_PROMPT, ROLLOUT_POLICY_EXTENSION, type RawTraceDistillerOptions, type ReadonlyAgentProfile, type RecoverExpiredAgentCandidateOptions, type ReflectiveGeneratorOptions, type ResearchLoopResult, type ResearchLoopRunnerOptions, type ResolvedAgentCandidateContainer, type ResolvedChatModel, RetainedInteractiveAdmissionError, RetainedInteractiveBindingError, RetainedRunAdmissionError, RetainedRunDispatchBindingError, type RetryBackoff, type RetryableErrorPredicate, type RootProviderModelEvidence, type RouterEnv, type RunAgentTaskOptions, type RunAgentTaskStreamOptions, type RunConversationOptions, type RunDelegatedLoopOptions, type RunKnowledgeImprovementJobOptions, type RunPersonaConfig, type RunPersonaConversationOptions, type RunProtectedAgentCandidateModelGrantOptions, type RunProtectedAgentCandidateModelGrantResult, type RunRecord, type RuntimeCanonicalStreamEvent, type RuntimeDecisionEvidenceRef, type RuntimeDecisionKind, type RuntimeDecisionPoint, type RuntimeEventCollector, type RuntimeEventOtelOptions, type RuntimeHookContext, type RuntimeHookErrorContext, type RuntimeHookEvent, type RuntimeHookPhase, type RuntimeHookTarget, type RuntimeHooks, type RuntimeRunCompleteInput, type RuntimeRunCost, type RuntimeRunHandle, type RuntimeRunOptions, type RuntimeRunPersistenceAdapter, type RuntimeRunRow, RuntimeRunStateError, type RuntimeRunStatus, type RuntimeSession, type RuntimeSessionStore, type RuntimeStreamEvent, type RuntimeStreamEventCollector, type RuntimeStreamEventSink, type RuntimeStreamEventSummary, type RuntimeTelemetryOptions, type SanitizedKnowledgeReadinessReport, type SanitizedKnowledgeRequirement, type Scope, type ServerSentEventOptions, type Settled, type Spend, type SpendChannel, type SpendGap, type SqlAdapter, SqlConversationJournal, type SupervisedKnowledgeUpdateInput, type SupervisedKnowledgeUpdateOptions, type SupervisedKnowledgeUpdateResult, type SupervisedKnowledgeUpdater, type SupervisedResult, type Supervisor, type SupervisorFinalizer, type TurnOrder, ValidationError, type VerifiedAgentCandidate, type VerifiedAgentCandidateTaskOutcome, type Verifier, type VerifyResult, type VetoedFact, type WorkerTraceEvidence, type WorkerTraceUnavailableReason, type WorktreeCheckRunner, type WorktreeLoopRunnerOptions, agentCandidateProfileAsAgentProfile, agenticGenerator, applyExactAgentProfileDiff, applyRolloutPolicyToProfile, applyRunRecordDefaults, assertCandidateProfileBinding, auditLoopRunner, buildAgentCandidateBundle, buildForwardHeaders, buildKnowledgeImprovementExperimentBundles, buildLoopOtelSpans, buildLoopSpanNodes, buildRuntimeEventOtelSpans, candidateExecutionClaim, candidateKnowledgeExecutionPaths, captureAgentCandidateWorkspace, captureAgentCandidateWorkspaceFiles, cleanModelId, commandVerifier, composeRuntimeHooks, computeBackoff, createAgentCandidateWorkspacePort, createAgentKnowledgeReadinessCheck, createConversationBackend, createIterableBackend, createKnowledgeImprovementActivationExecutor, createOpenInferenceFileExporter, createOtelExporter, createProfileExecutionBackend, createProfileImprovementHarness, createProtectedAgentCandidateModelPort, createRuntimeEventCollector, createRuntimeStreamEventCollector, createSandboxPromptBackend, createSupervisedKnowledgeUpdater, d1ToSqlAdapter, decideKnowledgeReadiness, defaultBuildPrompt, defaultIsRetryable, defineConversation, defineRuntimeHooks, disposePreparedAgentCandidateExecution, exactProcessProviderAsCandidateExecutor, executePreparedAgentCandidate, exportEvalRuns, findingLines, formatSupervisedKnowledgeTask, freezeGenericAgentCandidateProfile, generateSpanId, getModels, improve, isDelegatedLoopMode, isDepthExceeded, knowledgeReadinessDeliverable, loopEventToOtelSpan, makePerAttemptSignal, mcpBuildPrompt, mcpServeVerifier, mcpToolsForRuntimeMcp, mcpToolsForRuntimeMcpSubset, normalizeRolloutPolicy, notifyRuntimeDecisionPoint, notifyRuntimeHookEvent, officialGepa, officialSkillOpt, omitUndefinedObjectFields, optimizerMethod, padSpanId, padTraceId, parseExactAgentProfile, parseExactAgentProfileDiff, parseExactCandidateProfile, parseLoopRunnerArgv, parseRolloutPolicy, persistCandidateOutputArtifact, prepareAgentCandidateExecution, promptInstructionsProfileComponents, rawTraceDistiller, readDepth, readinessServerSentEvent, recoverExpiredAgentCandidateExecution, reflectiveGenerator, researchLoopRunner, resolveChatModel, resolveRouterBaseUrl, runAgentTask, runAgentTaskStream, runConversation, runConversationStream, runDelegatedLoop, runKnowledgeImprovementJob, runLoopRunnerCli, runPersonaConversation, runPersonaDispatch, runProtectedAgentCandidateModelGrant, runSupervisedKnowledgeUpdate, runtimeStreamServerSentEvent, sanitizeAgentRuntimeEvent, sanitizeKnowledgeReadinessReport, sanitizeRuntimeStreamEvent, sealAgentCandidateBundle, serializeRolloutPolicy, sleep, slugifySpeaker, startRuntimeRun, strategyAuthorMethod, structuralRolloutPolicyFromProfile, toOtelAttributes, toolBuildPrompt, turnId, validateChatModelId, verifyAgentCandidateBundle, worktreeLoopRunner };
|
|
357
427
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.js
CHANGED
|
@@ -1,19 +1,20 @@
|
|
|
1
|
-
import { a as JudgeError, c as
|
|
2
|
-
import { a as normalizeBackendStreamEvent, c as nowIso, i as createSandboxPromptBackend, l as startOrResumeRuntimeSession, o as InMemoryRuntimeSessionStore, r as createIterableBackend, u as touchSession } from "./stream-agent-turn-
|
|
3
|
-
import { $ as parseExactAgentProfile, G as agentCandidateProfileAsAgentProfile, K as applyExactAgentProfileDiff, S as CANDIDATE_TRACE_TAGS, Y as freezeGenericAgentCandidateProfile, Z as omitUndefinedObjectFields, _ as candidateExecutionClaim, a as persistCandidateOutputArtifact, c as CANDIDATE_KNOWLEDGE_ROOT_ENV, et as parseExactAgentProfileDiff, f as verifyAgentCandidateBundle, h as InMemoryAgentCandidateExecutionClaimStore, l as candidateKnowledgeExecutionPaths, n as executePreparedAgentCandidate, q as assertCandidateProfileBinding, rt as canonicalCandidateDigest, s as CANDIDATE_KNOWLEDGE_RETRIEVAL_CONFIG_ENV, t as prepareAgentCandidateExecution, tt as parseExactCandidateProfile, u as AGENT_CANDIDATE_EXECUTION_SUPPORT, x as CANDIDATE_TRACE_ENV } from "./prepare-
|
|
4
|
-
import { i as sealAgentCandidateBundle, n as captureAgentCandidateWorkspaceFiles, r as createAgentCandidateWorkspacePort, t as captureAgentCandidateWorkspace } from "./workspace-archive-
|
|
5
|
-
import { a as buildAgentCandidateBundle, i as FileAgentCandidateExecutionClaimStore, n as runProtectedAgentCandidateModelGrant, r as disposePreparedAgentCandidateExecution, t as recoverExpiredAgentCandidateExecution } from "./candidate-execution-
|
|
6
|
-
import { n as exactProcessProviderAsCandidateExecutor, t as createProtectedAgentCandidateModelPort } from "./protected-model-port-
|
|
7
|
-
import { C as makePerAttemptSignal, S as defaultIsRetryable, T as createProfileExecutionBackend, _ as readDepth, a as FileConversationJournal, b as DeadlineExceededError, c as createConversationBackend, d as slugifySpeaker, f as turnId, g as isDepthExceeded, h as buildForwardHeaders, i as d1ToSqlAdapter, l as runConversation, m as FORWARD_HEADERS, n as runPersonaDispatch, o as InMemoryConversationJournal, p as DEFAULT_MAX_DEPTH, r as SqlConversationJournal, s as defineConversation, t as runPersonaConversation, u as runConversationStream, v as CircuitBreakerState, w as sleep, x as computeBackoff, y as CircuitOpenError } from "./conversation-
|
|
8
|
-
import { At as exportEvalRuns, Bt as sanitizeKnowledgeReadinessReport, Dt as buildRuntimeEventOtelSpans, Et as buildLoopSpanNodes, Ft as padTraceId, It as toOtelAttributes, Lt as createRuntimeEventCollector, Mt as generateSpanId, Nt as loopEventToOtelSpan, Ot as createOpenInferenceFileExporter, Pt as padSpanId, Rt as createRuntimeStreamEventCollector, Tt as buildLoopOtelSpans, Vt as sanitizeRuntimeStreamEvent, kt as createOtelExporter, wt as INTELLIGENCE_WIRE_VERSION, zt as sanitizeAgentRuntimeEvent } from "./supervisor-
|
|
1
|
+
import { a as JudgeError, c as RetainedInteractiveAdmissionError, d as RetainedRunDispatchBindingError, f as RuntimeRunStateError, i as ConfigError, l as RetainedInteractiveBindingError, m as ValidationError, o as NotFoundError, r as BackendTransportError, s as PlannerError, t as AgentEvalError, u as RetainedRunAdmissionError } from "./errors-CDZ8XsVj.js";
|
|
2
|
+
import { a as normalizeBackendStreamEvent, c as nowIso, i as createSandboxPromptBackend, l as startOrResumeRuntimeSession, o as InMemoryRuntimeSessionStore, r as createIterableBackend, u as touchSession } from "./stream-agent-turn-4kUH8Nnn.js";
|
|
3
|
+
import { $ as parseExactAgentProfile, G as agentCandidateProfileAsAgentProfile, K as applyExactAgentProfileDiff, S as CANDIDATE_TRACE_TAGS, Y as freezeGenericAgentCandidateProfile, Z as omitUndefinedObjectFields, _ as candidateExecutionClaim, a as persistCandidateOutputArtifact, c as CANDIDATE_KNOWLEDGE_ROOT_ENV, et as parseExactAgentProfileDiff, f as verifyAgentCandidateBundle, h as InMemoryAgentCandidateExecutionClaimStore, l as candidateKnowledgeExecutionPaths, n as executePreparedAgentCandidate, q as assertCandidateProfileBinding, rt as canonicalCandidateDigest$1, s as CANDIDATE_KNOWLEDGE_RETRIEVAL_CONFIG_ENV, st as immutableCandidateValue, t as prepareAgentCandidateExecution, tt as parseExactCandidateProfile, u as AGENT_CANDIDATE_EXECUTION_SUPPORT, x as CANDIDATE_TRACE_ENV } from "./prepare-DK1qnk7-.js";
|
|
4
|
+
import { i as sealAgentCandidateBundle, n as captureAgentCandidateWorkspaceFiles, r as createAgentCandidateWorkspacePort, t as captureAgentCandidateWorkspace } from "./workspace-archive-HYlsPhfm.js";
|
|
5
|
+
import { a as buildAgentCandidateBundle, i as FileAgentCandidateExecutionClaimStore, n as runProtectedAgentCandidateModelGrant, r as disposePreparedAgentCandidateExecution, t as recoverExpiredAgentCandidateExecution } from "./candidate-execution-uuUeFSc6.js";
|
|
6
|
+
import { n as exactProcessProviderAsCandidateExecutor, t as createProtectedAgentCandidateModelPort } from "./protected-model-port-DHeCm_UF.js";
|
|
7
|
+
import { C as makePerAttemptSignal, S as defaultIsRetryable, T as createProfileExecutionBackend, _ as readDepth, a as FileConversationJournal, b as DeadlineExceededError, c as createConversationBackend, d as slugifySpeaker, f as turnId, g as isDepthExceeded, h as buildForwardHeaders, i as d1ToSqlAdapter, l as runConversation, m as FORWARD_HEADERS, n as runPersonaDispatch, o as InMemoryConversationJournal, p as DEFAULT_MAX_DEPTH, r as SqlConversationJournal, s as defineConversation, t as runPersonaConversation, u as runConversationStream, v as CircuitBreakerState, w as sleep, x as computeBackoff, y as CircuitOpenError } from "./conversation-C3eZCvLd.js";
|
|
8
|
+
import { At as exportEvalRuns, Bt as sanitizeKnowledgeReadinessReport, Dt as buildRuntimeEventOtelSpans, Et as buildLoopSpanNodes, Ft as padTraceId, It as toOtelAttributes, Lt as createRuntimeEventCollector, Mt as generateSpanId, Nt as loopEventToOtelSpan, Ot as createOpenInferenceFileExporter, Pt as padSpanId, Rt as createRuntimeStreamEventCollector, Tt as buildLoopOtelSpans, Vt as sanitizeRuntimeStreamEvent, kt as createOtelExporter, wt as INTELLIGENCE_WIRE_VERSION, zt as sanitizeAgentRuntimeEvent } from "./supervisor-BV72aDmP.js";
|
|
9
9
|
import { i as notifyRuntimeHookEvent, n as defineRuntimeHooks, r as notifyRuntimeDecisionPoint, t as composeRuntimeHooks } from "./runtime-hooks-C7iJOWm3.js";
|
|
10
|
-
import { D as optimizerMethod, O as strategyAuthorMethod } from "./structural-rollout-
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
10
|
+
import { D as optimizerMethod, O as strategyAuthorMethod } from "./structural-rollout-7LP9Ex0F.js";
|
|
11
|
+
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-D6rhMJR0.js";
|
|
12
|
+
import { Bt as connectStdioMcp, zt as McpSpawnFault } from "./runtime-tTA2iCZQ.js";
|
|
13
13
|
import { n as defaultRedactorIdentityMaterial, r as resolveRedactor, t as defaultRedactor } from "./redact-D-u-rrcn.js";
|
|
14
|
-
import { a as createSupervisedKnowledgeUpdater, c as runSupervisedKnowledgeUpdate, i as RESEARCH_SUPERVISOR_SYSTEM_PROMPT, l as createKnowledgeImprovementActivationExecutor, n as createAgentKnowledgeReadinessCheck, o as formatSupervisedKnowledgeTask, r as runKnowledgeImprovementJob, s as knowledgeReadinessDeliverable, t as buildKnowledgeImprovementExperimentBundles } from "./knowledge-
|
|
15
|
-
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-
|
|
16
|
-
import { n as mcpToolsForRuntimeMcpSubset, t as mcpToolsForRuntimeMcp } from "./openai-tools-
|
|
14
|
+
import { a as createSupervisedKnowledgeUpdater, c as runSupervisedKnowledgeUpdate, i as RESEARCH_SUPERVISOR_SYSTEM_PROMPT, l as createKnowledgeImprovementActivationExecutor, n as createAgentKnowledgeReadinessCheck, o as formatSupervisedKnowledgeTask, r as runKnowledgeImprovementJob, s as knowledgeReadinessDeliverable, t as buildKnowledgeImprovementExperimentBundles } from "./knowledge-CD-_FbJT.js";
|
|
15
|
+
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-BBz_ACfQ.js";
|
|
16
|
+
import { n as mcpToolsForRuntimeMcpSubset, t as mcpToolsForRuntimeMcp } from "./openai-tools-DIKr72_l.js";
|
|
17
|
+
import { agentProfileSchema, canonicalAgentProfileDigest } from "@tangle-network/agent-interface";
|
|
17
18
|
import { FAILURE_CLASSES, acquisitionPlansForKnowledgeGaps, blockingKnowledgeEval, canonicalJson, runAgentControlLoop, scoreKnowledgeReadiness, userQuestionsForKnowledgeGaps } from "@tangle-network/agent-eval";
|
|
18
19
|
import { gepaOptimizationMethod, skillOptOptimizationMethod } from "@tangle-network/agent-eval/campaign";
|
|
19
20
|
import { spawnSync } from "node:child_process";
|
|
@@ -329,7 +330,7 @@ function redactJudgeScore(score, redactor) {
|
|
|
329
330
|
}
|
|
330
331
|
function optimizerRedactionPolicyRef(redact, builtInIdentity = defaultRedactorIdentityMaterial()) {
|
|
331
332
|
if (redact === false) return "caller-approved-raw";
|
|
332
|
-
return canonicalCandidateDigest({
|
|
333
|
+
return canonicalCandidateDigest$1({
|
|
333
334
|
kind: redact === void 0 ? "default-redactor" : "caller-redactor-with-default",
|
|
334
335
|
builtIn: builtInIdentity,
|
|
335
336
|
...redact === void 0 ? {} : {
|
|
@@ -339,7 +340,7 @@ function optimizerRedactionPolicyRef(redact, builtInIdentity = defaultRedactorId
|
|
|
339
340
|
});
|
|
340
341
|
}
|
|
341
342
|
function optimizerEvidencePolicyRef(input) {
|
|
342
|
-
return canonicalCandidateDigest({
|
|
343
|
+
return canonicalCandidateDigest$1({
|
|
343
344
|
runtimeEvaluationRef: input.runtimeEvaluationRef,
|
|
344
345
|
redactionPolicyRef: input.redactionPolicyRef,
|
|
345
346
|
describeScenario: callbackSource(input.describeScenario),
|
|
@@ -357,7 +358,7 @@ function withDependencyHelp(optimizer, evaluationRef, redactor, redactionPolicyR
|
|
|
357
358
|
try {
|
|
358
359
|
const judges = input.judges.map((judge) => Object.freeze({
|
|
359
360
|
...judge,
|
|
360
|
-
judgeVersion: canonicalCandidateDigest({
|
|
361
|
+
judgeVersion: canonicalCandidateDigest$1({
|
|
361
362
|
evaluationRef,
|
|
362
363
|
name: judge.name,
|
|
363
364
|
dimensions: judge.dimensions,
|
|
@@ -401,6 +402,96 @@ function isMissingDependency(optimizer, cause) {
|
|
|
401
402
|
return [...common, ...specific].some((fragment) => message.includes(fragment));
|
|
402
403
|
}
|
|
403
404
|
//#endregion
|
|
405
|
+
//#region src/improvement/profile-improvement-harness.ts
|
|
406
|
+
/**
|
|
407
|
+
* Bind one exact profile and executor into a repeatable self-improvement
|
|
408
|
+
* harness. The returned `run` method remains generic over every existing
|
|
409
|
+
* profile surface, optimization method, split, gate, and budget option.
|
|
410
|
+
*/
|
|
411
|
+
function createProfileImprovementHarness(options) {
|
|
412
|
+
const parsed = agentProfileSchema.safeParse(options.profile);
|
|
413
|
+
if (!parsed.success) throw new ConfigError(`createProfileImprovementHarness: invalid AgentProfile: ${parsed.error.message}`);
|
|
414
|
+
if (!/^sha256:[0-9a-f]{64}$/.test(options.executionRef)) throw new ConfigError("createProfileImprovementHarness: executionRef must be a lowercase sha256 digest");
|
|
415
|
+
if (typeof options.agent !== "function") throw new ConfigError("createProfileImprovementHarness: agent must be a function");
|
|
416
|
+
if (options.validateCandidate !== void 0 && typeof options.validateCandidate !== "function") throw new ConfigError("createProfileImprovementHarness: validateCandidate must be a function when present");
|
|
417
|
+
const profile = immutableCandidateValue(parsed.data);
|
|
418
|
+
const executionRef = options.executionRef;
|
|
419
|
+
const agent = options.agent;
|
|
420
|
+
const defaultValidator = options.validateCandidate;
|
|
421
|
+
return Object.freeze({
|
|
422
|
+
profile,
|
|
423
|
+
profileDigest: canonicalAgentProfileDigest(profile),
|
|
424
|
+
executionRef,
|
|
425
|
+
run(runOptions) {
|
|
426
|
+
if (runOptions.validateCandidate !== void 0 && typeof runOptions.validateCandidate !== "function") throw new ConfigError("ProfileImprovementHarness.run: validateCandidate must be a function when present");
|
|
427
|
+
const validateCandidate = runOptions.validateCandidate ?? defaultValidator;
|
|
428
|
+
return improve(profile, {
|
|
429
|
+
...runOptions,
|
|
430
|
+
executionRef,
|
|
431
|
+
agent,
|
|
432
|
+
...validateCandidate === void 0 ? {} : { validateCandidate }
|
|
433
|
+
});
|
|
434
|
+
}
|
|
435
|
+
});
|
|
436
|
+
}
|
|
437
|
+
//#endregion
|
|
438
|
+
//#region src/improvement/prompt-instructions-profile-components.ts
|
|
439
|
+
/** Stable component-name prefix used for `profile.prompt.instructions`. */
|
|
440
|
+
const PROMPT_INSTRUCTION_COMPONENT_PREFIX = "prompt.instruction:";
|
|
441
|
+
const COMPONENT_INDEX_WIDTH = 6;
|
|
442
|
+
function componentName(index) {
|
|
443
|
+
return `${PROMPT_INSTRUCTION_COMPONENT_PREFIX}${String(index).padStart(COMPONENT_INDEX_WIDTH, "0")}`;
|
|
444
|
+
}
|
|
445
|
+
function orderedInstructionValues(components) {
|
|
446
|
+
const entries = Object.entries(components).sort(([left], [right]) => left.localeCompare(right));
|
|
447
|
+
if (entries.length === 0) throw new ConfigError("promptInstructionsProfileComponents: at least one prompt instruction is required");
|
|
448
|
+
for (const [index, [name, value]] of entries.entries()) {
|
|
449
|
+
const expected = componentName(index);
|
|
450
|
+
if (name !== expected) throw new ConfigError(`promptInstructionsProfileComponents: expected component ${JSON.stringify(expected)}, got ${JSON.stringify(name)}`);
|
|
451
|
+
if (typeof value !== "string") throw new ConfigError(`promptInstructionsProfileComponents: component ${JSON.stringify(name)} must be a string`);
|
|
452
|
+
}
|
|
453
|
+
return entries.map(([, value]) => value);
|
|
454
|
+
}
|
|
455
|
+
/**
|
|
456
|
+
* Canonical `ImproveProfileComponents` mapping for the ordered
|
|
457
|
+
* `AgentProfile.prompt.instructions` list.
|
|
458
|
+
*
|
|
459
|
+
* Use it with `surface: 'agent-profile'` when an optimizer should rewrite the
|
|
460
|
+
* exact instruction texts without being allowed to change their count, order,
|
|
461
|
+
* labels, or any unrelated profile field:
|
|
462
|
+
*
|
|
463
|
+
* ```ts
|
|
464
|
+
* await improve(profile, {
|
|
465
|
+
* surface: 'agent-profile',
|
|
466
|
+
* profileComponents: promptInstructionsProfileComponents,
|
|
467
|
+
* // method, scenarios, judge, executionRef, agent, ...
|
|
468
|
+
* })
|
|
469
|
+
* ```
|
|
470
|
+
*
|
|
471
|
+
* Component names are zero-padded and stable. Runtime's existing component
|
|
472
|
+
* materializer requires every candidate to preserve the exact key set and
|
|
473
|
+
* verifies that `apply(read(profile))` reproduces the baseline profile. A
|
|
474
|
+
* profile with no prompt instructions is refused rather than inventing a
|
|
475
|
+
* sentinel instruction that could accidentally ship.
|
|
476
|
+
*/
|
|
477
|
+
const promptInstructionsProfileComponents = Object.freeze({
|
|
478
|
+
read(profile) {
|
|
479
|
+
const instructions = profile.prompt?.instructions ?? [];
|
|
480
|
+
if (instructions.length === 0) throw new ConfigError("promptInstructionsProfileComponents: profile.prompt.instructions must contain at least one instruction");
|
|
481
|
+
return Object.fromEntries(instructions.map((instruction, index) => [componentName(index), instruction]));
|
|
482
|
+
},
|
|
483
|
+
apply(profile, components) {
|
|
484
|
+
const instructions = orderedInstructionValues(components);
|
|
485
|
+
return agentProfileSchema.parse({
|
|
486
|
+
...profile,
|
|
487
|
+
prompt: {
|
|
488
|
+
...profile.prompt,
|
|
489
|
+
instructions
|
|
490
|
+
}
|
|
491
|
+
});
|
|
492
|
+
}
|
|
493
|
+
});
|
|
494
|
+
//#endregion
|
|
404
495
|
//#region src/improvement/reflective-generator.ts
|
|
405
496
|
/**
|
|
406
497
|
*
|
|
@@ -1235,6 +1326,6 @@ function stripNewlines(value) {
|
|
|
1235
1326
|
return value.replace(/[\r\n]/g, " ");
|
|
1236
1327
|
}
|
|
1237
1328
|
//#endregion
|
|
1238
|
-
export { AGENT_CANDIDATE_EXECUTION_SUPPORT, AgentEvalError, BackendTransportError, CANDIDATE_KNOWLEDGE_RETRIEVAL_CONFIG_ENV, CANDIDATE_KNOWLEDGE_ROOT_ENV, CANDIDATE_TRACE_ENV, CANDIDATE_TRACE_TAGS, CircuitBreakerState, CircuitOpenError, ConfigError, DEFAULT_MAX_DEPTH, DEFAULT_ROUTER_BASE_URL, DELEGATED_LOOP_MODES, DeadlineExceededError, FORWARD_HEADERS, FileAgentCandidateExecutionClaimStore, FileConversationJournal, INTELLIGENCE_WIRE_VERSION, InMemoryAgentCandidateExecutionClaimStore, InMemoryConversationJournal, InMemoryRuntimeSessionStore, JudgeError, NotFoundError, OfficialOptimizerUnavailableError, PlannerError, RESEARCH_SUPERVISOR_SYSTEM_PROMPT, ROLLOUT_POLICY_EXTENSION, RetainedRunAdmissionError, RetainedRunDispatchBindingError, RuntimeRunStateError, SqlConversationJournal, ValidationError, agentCandidateProfileAsAgentProfile, agenticGenerator, applyExactAgentProfileDiff, applyRolloutPolicyToProfile, applyRunRecordDefaults, assertCandidateProfileBinding, auditLoopRunner, buildAgentCandidateBundle, buildForwardHeaders, buildKnowledgeImprovementExperimentBundles, buildLoopOtelSpans, buildLoopSpanNodes, buildRuntimeEventOtelSpans, candidateExecutionClaim, candidateKnowledgeExecutionPaths, captureAgentCandidateWorkspace, captureAgentCandidateWorkspaceFiles, cleanModelId, commandVerifier, composeRuntimeHooks, computeBackoff, createAgentCandidateWorkspacePort, createAgentKnowledgeReadinessCheck, createConversationBackend, createIterableBackend, createKnowledgeImprovementActivationExecutor, createOpenInferenceFileExporter, createOtelExporter, createProfileExecutionBackend, createProtectedAgentCandidateModelPort, createRuntimeEventCollector, createRuntimeStreamEventCollector, createSandboxPromptBackend, createSupervisedKnowledgeUpdater, d1ToSqlAdapter, decideKnowledgeReadiness, defaultBuildPrompt, defaultIsRetryable, defineConversation, defineRuntimeHooks, disposePreparedAgentCandidateExecution, exactProcessProviderAsCandidateExecutor, executePreparedAgentCandidate, exportEvalRuns, findingLines, formatSupervisedKnowledgeTask, freezeGenericAgentCandidateProfile, generateSpanId, getModels, improve, isDelegatedLoopMode, isDepthExceeded, knowledgeReadinessDeliverable, loopEventToOtelSpan, makePerAttemptSignal, mcpBuildPrompt, mcpServeVerifier, mcpToolsForRuntimeMcp, mcpToolsForRuntimeMcpSubset, normalizeRolloutPolicy, notifyRuntimeDecisionPoint, notifyRuntimeHookEvent, officialGepa, officialSkillOpt, omitUndefinedObjectFields, optimizerMethod, padSpanId, padTraceId, parseExactAgentProfile, parseExactAgentProfileDiff, parseExactCandidateProfile, parseLoopRunnerArgv, parseRolloutPolicy, persistCandidateOutputArtifact, prepareAgentCandidateExecution, rawTraceDistiller, readDepth, readinessServerSentEvent, recoverExpiredAgentCandidateExecution, reflectiveGenerator, researchLoopRunner, resolveChatModel, resolveRouterBaseUrl, runAgentTask, runAgentTaskStream, runConversation, runConversationStream, runDelegatedLoop, runKnowledgeImprovementJob, runLoopRunnerCli, runPersonaConversation, runPersonaDispatch, runProtectedAgentCandidateModelGrant, runSupervisedKnowledgeUpdate, runtimeStreamServerSentEvent, sanitizeAgentRuntimeEvent, sanitizeKnowledgeReadinessReport, sanitizeRuntimeStreamEvent, sealAgentCandidateBundle, serializeRolloutPolicy, sleep, slugifySpeaker, startRuntimeRun, strategyAuthorMethod, structuralRolloutPolicyFromProfile, toOtelAttributes, toolBuildPrompt, turnId, validateChatModelId, verifyAgentCandidateBundle, worktreeLoopRunner };
|
|
1329
|
+
export { AGENT_CANDIDATE_EXECUTION_SUPPORT, AgentEvalError, BackendTransportError, CANDIDATE_KNOWLEDGE_RETRIEVAL_CONFIG_ENV, CANDIDATE_KNOWLEDGE_ROOT_ENV, CANDIDATE_TRACE_ENV, CANDIDATE_TRACE_TAGS, CircuitBreakerState, CircuitOpenError, ConfigError, DEFAULT_MAX_DEPTH, DEFAULT_ROUTER_BASE_URL, DELEGATED_LOOP_MODES, DeadlineExceededError, FORWARD_HEADERS, FileAgentCandidateExecutionClaimStore, FileConversationJournal, INTELLIGENCE_WIRE_VERSION, InMemoryAgentCandidateExecutionClaimStore, InMemoryConversationJournal, InMemoryRuntimeSessionStore, JudgeError, NotFoundError, OfficialOptimizerUnavailableError, PROMPT_INSTRUCTION_COMPONENT_PREFIX, PlannerError, RESEARCH_SUPERVISOR_SYSTEM_PROMPT, ROLLOUT_POLICY_EXTENSION, RetainedInteractiveAdmissionError, RetainedInteractiveBindingError, RetainedRunAdmissionError, RetainedRunDispatchBindingError, RuntimeRunStateError, SqlConversationJournal, ValidationError, agentCandidateProfileAsAgentProfile, agenticGenerator, applyExactAgentProfileDiff, applyRolloutPolicyToProfile, applyRunRecordDefaults, assertCandidateProfileBinding, auditLoopRunner, buildAgentCandidateBundle, buildForwardHeaders, buildKnowledgeImprovementExperimentBundles, buildLoopOtelSpans, buildLoopSpanNodes, buildRuntimeEventOtelSpans, candidateExecutionClaim, candidateKnowledgeExecutionPaths, captureAgentCandidateWorkspace, captureAgentCandidateWorkspaceFiles, cleanModelId, commandVerifier, composeRuntimeHooks, computeBackoff, createAgentCandidateWorkspacePort, createAgentKnowledgeReadinessCheck, createConversationBackend, createIterableBackend, createKnowledgeImprovementActivationExecutor, createOpenInferenceFileExporter, createOtelExporter, createProfileExecutionBackend, createProfileImprovementHarness, createProtectedAgentCandidateModelPort, createRuntimeEventCollector, createRuntimeStreamEventCollector, createSandboxPromptBackend, createSupervisedKnowledgeUpdater, d1ToSqlAdapter, decideKnowledgeReadiness, defaultBuildPrompt, defaultIsRetryable, defineConversation, defineRuntimeHooks, disposePreparedAgentCandidateExecution, exactProcessProviderAsCandidateExecutor, executePreparedAgentCandidate, exportEvalRuns, findingLines, formatSupervisedKnowledgeTask, freezeGenericAgentCandidateProfile, generateSpanId, getModels, improve, isDelegatedLoopMode, isDepthExceeded, knowledgeReadinessDeliverable, loopEventToOtelSpan, makePerAttemptSignal, mcpBuildPrompt, mcpServeVerifier, mcpToolsForRuntimeMcp, mcpToolsForRuntimeMcpSubset, normalizeRolloutPolicy, notifyRuntimeDecisionPoint, notifyRuntimeHookEvent, officialGepa, officialSkillOpt, omitUndefinedObjectFields, optimizerMethod, padSpanId, padTraceId, parseExactAgentProfile, parseExactAgentProfileDiff, parseExactCandidateProfile, parseLoopRunnerArgv, parseRolloutPolicy, persistCandidateOutputArtifact, prepareAgentCandidateExecution, promptInstructionsProfileComponents, rawTraceDistiller, readDepth, readinessServerSentEvent, recoverExpiredAgentCandidateExecution, reflectiveGenerator, researchLoopRunner, resolveChatModel, resolveRouterBaseUrl, runAgentTask, runAgentTaskStream, runConversation, runConversationStream, runDelegatedLoop, runKnowledgeImprovementJob, runLoopRunnerCli, runPersonaConversation, runPersonaDispatch, runProtectedAgentCandidateModelGrant, runSupervisedKnowledgeUpdate, runtimeStreamServerSentEvent, sanitizeAgentRuntimeEvent, sanitizeKnowledgeReadinessReport, sanitizeRuntimeStreamEvent, sealAgentCandidateBundle, serializeRolloutPolicy, sleep, slugifySpeaker, startRuntimeRun, strategyAuthorMethod, structuralRolloutPolicyFromProfile, toOtelAttributes, toolBuildPrompt, turnId, validateChatModelId, verifyAgentCandidateBundle, worktreeLoopRunner };
|
|
1239
1330
|
|
|
1240
1331
|
//# sourceMappingURL=index.js.map
|