@tangle-network/agent-runtime 0.93.2 → 0.94.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (80) hide show
  1. package/README.md +4 -3
  2. package/dist/agent.d.ts +1 -1
  3. package/dist/agent.js +5 -6
  4. package/dist/agent.js.map +1 -1
  5. package/dist/{agentic-generator-B8oeE2Yv.d.ts → agentic-generator-D9ZmAuiL.d.ts} +1 -1
  6. package/dist/analyst-loop.d.ts +1 -1
  7. package/dist/candidate-execution/index.d.ts +10 -3
  8. package/dist/candidate-execution/index.js +9 -3
  9. package/dist/{chunk-6K5CI33W.js → chunk-D336OZHK.js} +1232 -19
  10. package/dist/chunk-D336OZHK.js.map +1 -0
  11. package/dist/{chunk-TU73X3I6.js → chunk-HPCJBBLS.js} +2 -2
  12. package/dist/chunk-ISTDY47H.js +849 -0
  13. package/dist/chunk-ISTDY47H.js.map +1 -0
  14. package/dist/{chunk-RTVVH2KL.js → chunk-JEP2WM24.js} +2 -2
  15. package/dist/{chunk-Z7K5BPKZ.js → chunk-K7OPNHU4.js} +2 -2
  16. package/dist/{chunk-OX3QRJOA.js → chunk-KHLE3C5G.js} +281 -251
  17. package/dist/chunk-KHLE3C5G.js.map +1 -0
  18. package/dist/{chunk-XDSWWUKE.js → chunk-MZH4HORF.js} +6 -29
  19. package/dist/chunk-MZH4HORF.js.map +1 -0
  20. package/dist/chunk-PJNGPWTA.js +634 -0
  21. package/dist/chunk-PJNGPWTA.js.map +1 -0
  22. package/dist/{chunk-X5KJKS33.js → chunk-RTSZNYXM.js} +3 -3
  23. package/dist/{chunk-WGR6QJ5H.js → chunk-SJHFJOCY.js} +8 -161
  24. package/dist/chunk-SJHFJOCY.js.map +1 -0
  25. package/dist/{chunk-2BQMAZAB.js → chunk-URMJTSXB.js} +1378 -28
  26. package/dist/chunk-URMJTSXB.js.map +1 -0
  27. package/dist/{chunk-3D2RHC4K.js → chunk-WIPGQ4GT.js} +1 -1
  28. package/dist/{chunk-3D2RHC4K.js.map → chunk-WIPGQ4GT.js.map} +1 -1
  29. package/dist/{chunk-R5GWDTM3.js → chunk-ZEYAT33L.js} +2 -2
  30. package/dist/{completion-gate-BLaiN0-X.d.ts → completion-gate-BAj3dXeW.d.ts} +14 -2
  31. package/dist/{coordination-DxJ83oZA.d.ts → coordination-B3ZuApR_.d.ts} +7 -5
  32. package/dist/environment-provider.d.ts +2 -2
  33. package/dist/{improve-DDhQaaJT.d.ts → improve-r8SvIxYv.d.ts} +13 -16
  34. package/dist/index.d.ts +39 -110
  35. package/dist/index.js +92 -36
  36. package/dist/index.js.map +1 -1
  37. package/dist/intelligence.d.ts +24 -7
  38. package/dist/intelligence.js +114 -20
  39. package/dist/intelligence.js.map +1 -1
  40. package/dist/knowledge.d.ts +7 -7
  41. package/dist/knowledge.js +5 -5
  42. package/dist/lifecycle.d.ts +3 -3
  43. package/dist/lifecycle.js +2 -2
  44. package/dist/{local-harness-dcD5WTTr.d.ts → local-harness-B7bNuNJw.d.ts} +49 -1
  45. package/dist/{loop-runner-bin-kKUNGLyV.d.ts → loop-runner-bin-D4bMIxmB.d.ts} +2 -2
  46. package/dist/loop-runner-bin.d.ts +6 -6
  47. package/dist/loop-runner-bin.js +6 -7
  48. package/dist/loops.d.ts +457 -18
  49. package/dist/loops.js +39 -41
  50. package/dist/mcp/bin.js +5 -5
  51. package/dist/mcp/index.d.ts +10 -10
  52. package/dist/mcp/index.js +9 -8
  53. package/dist/{mcp-serve-verifier-Bg4C3p5S.d.ts → mcp-serve-verifier-BuXjaZDE.d.ts} +1 -1
  54. package/dist/{openai-tools-E3woykz9.d.ts → openai-tools-D0ZSRCC6.d.ts} +1 -1
  55. package/dist/{prepare-DiVGKcwS.d.ts → prepare-BKxAiUcH.d.ts} +1 -1
  56. package/dist/profiles.d.ts +1 -1
  57. package/dist/{sanitize-C9go6tXj.d.ts → sanitize-C2jicjNf.d.ts} +1 -1
  58. package/dist/{supervise-T2pazU3G.d.ts → supervise-DTNcLDl2.d.ts} +4 -4
  59. package/dist/{types-DAdIm4AC.d.ts → types-Bb-CqxJH.d.ts} +5 -2
  60. package/dist/{types-B00NtbCs.d.ts → types-DWA64rbJ.d.ts} +1 -1
  61. package/dist/{worktree-fanout-BUb2Ag02.d.ts → worktree-fanout-IMKqdV_E.d.ts} +244 -244
  62. package/package.json +4 -4
  63. package/skills/build-with-agent-runtime/SKILL.md +1 -1
  64. package/dist/chunk-2BQMAZAB.js.map +0 -1
  65. package/dist/chunk-6K5CI33W.js.map +0 -1
  66. package/dist/chunk-FDJ7AHXG.js +0 -1229
  67. package/dist/chunk-FDJ7AHXG.js.map +0 -1
  68. package/dist/chunk-J2K6WIG6.js +0 -2172
  69. package/dist/chunk-J2K6WIG6.js.map +0 -1
  70. package/dist/chunk-OX3QRJOA.js.map +0 -1
  71. package/dist/chunk-PX6SXX3M.js +0 -146
  72. package/dist/chunk-PX6SXX3M.js.map +0 -1
  73. package/dist/chunk-WGR6QJ5H.js.map +0 -1
  74. package/dist/chunk-XDSWWUKE.js.map +0 -1
  75. package/dist/structural-rollout-DHGDbhvR.d.ts +0 -446
  76. /package/dist/{chunk-TU73X3I6.js.map → chunk-HPCJBBLS.js.map} +0 -0
  77. /package/dist/{chunk-RTVVH2KL.js.map → chunk-JEP2WM24.js.map} +0 -0
  78. /package/dist/{chunk-Z7K5BPKZ.js.map → chunk-K7OPNHU4.js.map} +0 -0
  79. /package/dist/{chunk-X5KJKS33.js.map → chunk-RTSZNYXM.js.map} +0 -0
  80. /package/dist/{chunk-R5GWDTM3.js.map → chunk-ZEYAT33L.js.map} +0 -0
package/dist/loops.d.ts CHANGED
@@ -2,30 +2,28 @@ import { ChatClient, RunRecord, HarnessType, AgentProfile, AnalystFinding, Analy
2
2
  export { AnalystFinding, DefaultVerdict, computeFindingId, makeFinding } from '@tangle-network/agent-eval';
3
3
  import { SandboxEvent, SandboxInstance, CreateSandboxOptions, PromptOptions, TaskOptions } from '@tangle-network/sandbox';
4
4
  export { AgentProfile, CreateSandboxOptions, SandboxEvent, SandboxInstance } from '@tangle-network/sandbox';
5
- import { a as ResultBlobStore, g as SpawnJournal, N as NodeId, j as SpawnEvent, E as ExecutorFactory, A as Agent, B as Budget, d as Settled, S as Scope, b as SupervisedResult, e as Spend, U as UsageEvent, h as ExecutorRegistry, k as Supervisor } from './types-DAdIm4AC.js';
6
- export { f as AgentSpec, c as Executor, l as ExecutorContext, m as ExecutorResult, R as Runtime, n as SupervisorOpts, T as TreeView, W as WidenGate } from './types-DAdIm4AC.js';
7
- import { M as MakeWorkerAgent, A as AnalystRegistry, o as CoordinationTools, n as CoordinationEvent, as as QuestionPolicy, E as ExecutorConfig } from './coordination-DxJ83oZA.js';
8
- export { bh as BusEvent, bi as BusRecord, bj as BusStats, bk as EventBus, bl as ProviderSeam, bm as PublishOptions, bn as cliWorktreeExecutor, bo as createEventBus, bp as createExecutor, bq as createExecutorRegistry } from './coordination-DxJ83oZA.js';
9
- import { R as RuntimeHooks, I as Iteration, S as SandboxClient, D as Driver, e as AgentRunSpec, d as OutputAdapter, V as Validator, E as ExecCtx, Y as LoopWinner, Z as LoopLineageOptions, _ as LoopResult, L as LoopTokenUsage, b as RuntimeStreamEvent, $ as MountRecorder, l as AgentExecutionBackend, c as AgentTaskStatus, B as BackendErrorDetail } from './types-B00NtbCs.js';
10
- export { a0 as LoopDecisionPayload, a1 as LoopEndedPayload, a2 as LoopIterationDispatchPayload, a3 as LoopIterationEndedPayload, a4 as LoopIterationStartedPayload, a5 as LoopPlanDescription, a6 as LoopPlanPayload, f as LoopSandboxPlacement, a7 as LoopStartedPayload, a8 as LoopTeardownFailedPayload, h as LoopTraceEmitter, g as LoopTraceEvent, a9 as MountManifestEntry, aa as RunProvenance, a as SelectionReceipt, ab as ValidationCtx } from './types-B00NtbCs.js';
5
+ import { a as ResultBlobStore, f as SpawnJournal, N as NodeId, j as SpawnEvent, E as ExecutorFactory, A as Agent, B as Budget, S as Scope, h as Settled, b as SupervisedResult, i as Spend, U as UsageEvent, e as ExecutorRegistry, k as Supervisor } from './types-Bb-CqxJH.js';
6
+ export { d as AgentSpec, c as Executor, l as ExecutorContext, m as ExecutorResult, R as Runtime, n as SupervisorOpts, T as TreeView, W as WidenGate } from './types-Bb-CqxJH.js';
7
+ import { M as MakeWorkerAgent, A as AnalystRegistry, o as CoordinationTools, n as CoordinationEvent, as as QuestionPolicy, E as ExecutorConfig } from './coordination-B3ZuApR_.js';
8
+ export { bh as BusEvent, bi as BusRecord, bj as BusStats, bk as EventBus, bl as ProviderSeam, bm as PublishOptions, bn as cliWorktreeExecutor, bo as createEventBus, bp as createExecutor, bq as createExecutorRegistry } from './coordination-B3ZuApR_.js';
9
+ import { R as RuntimeHooks, I as Iteration, S as SandboxClient, D as Driver, d as AgentRunSpec, c as OutputAdapter, V as Validator, E as ExecCtx, X as LoopWinner, Y as LoopLineageOptions, Z as LoopResult, L as LoopTokenUsage, a as RuntimeStreamEvent, _ as MountRecorder, k as AgentExecutionBackend, b as AgentTaskStatus, B as BackendErrorDetail, $ as SelectionReceipt } from './types-DWA64rbJ.js';
10
+ export { a0 as LoopDecisionPayload, a1 as LoopEndedPayload, a2 as LoopIterationDispatchPayload, a3 as LoopIterationEndedPayload, a4 as LoopIterationStartedPayload, a5 as LoopPlanDescription, a6 as LoopPlanPayload, e as LoopSandboxPlacement, a7 as LoopStartedPayload, a8 as LoopTeardownFailedPayload, g as LoopTraceEmitter, f as LoopTraceEvent, a9 as MountManifestEntry, aa as RunProvenance, ab as ValidationCtx } from './types-DWA64rbJ.js';
11
11
  import { RunProfileMatrixResult, Scenario, ProfileDispatchFn, JudgeConfig, RunProfileMatrixOptions, DispatchFn } from '@tangle-network/agent-eval/campaign';
12
12
  export { AgentEnvironmentProviderRef, AgentEnvironmentProviderRegistry, ProviderAsSandboxClientOptions, ProviderExecutorOptions, SandboxClientProviderOptions, createAgentEnvironmentProviderRegistry, providerAsExecutor, providerAsSandboxClient, resolveAgentEnvironmentProvider, sandboxClientAsProvider } from './environment-provider.js';
13
- import { c as CorpusRecord, C as Corpus, S as ScopeAnalyzeInput, d as AssertTraceDerivedFindings, O as Outcome, e as SteerContext, f as ScopeAnalyst, F as FanoutOptions, g as CombinatorShape, h as ScopeWidenGate, L as LoopUntilSpec, P as PanelSpec, i as PipelineStage, W as WinnerStrategy, j as FanoutWinnerSelector, V as VerifySpec, k as WidenSpec, l as CorpusFilter, R as RenderCorpusToInstructionsOptions, D as DefinePersonaInput, m as Persona, n as RunPersonifiedOptions, o as ShapeRegistry, p as LoopShape, E as EqualKArm, q as EqualKOnCostOptions, r as EqualKVerdict, T as TrajectoryReportOptions, s as TrajectoryReport } from './worktree-fanout-BUb2Ag02.js';
14
- export { A as AuthoredHarness, t as DefinePersona, u as EqualKOnCost, v as Fanout, w as FanoutSynthesis, x as FlatWidenGate, y as LoopUntil, z as LoopUntilState, B as Panel, G as PanelJudge, H as PanelVerdict, I as PatchDeliverableOptions, J as PersonaContext, K as PersonaExecutors, M as Pipeline, N as RenderCorpusToInstructions, Q as RunPersonified, U as ShapeBudget, X as ShapeContext, Y as TrajectoryNode, Z as TrajectoryReportFn, _ as Verify, $ as Widen, a0 as WidenDecision, a1 as WidenLineage, a2 as WorktreeCliExecutorOptions, a as WorktreeFanoutOptions, b as WorktreePatchArtifact, a3 as createWorktreeCliExecutor, a4 as patchDelivered, a5 as worktreeFanout } from './worktree-fanout-BUb2Ag02.js';
15
- import { A as AgenticSurface, a as AgenticTask, b as AgenticOptions, c as Strategy, d as ArtifactHandle, e as SurfaceScore, f as AgenticTool } from './structural-rollout-DHGDbhvR.js';
16
- export { g as AgenticRunResult, C as CheckExecChannel, h as CheckOutcome, i as CheckRunContext, j as CheckRunner, k as CheckSource, l as CheckSourceCtx, m as CorpusReadbackOptions, R as RepairStop, n as RunAgenticOptions, o as ShotPersona, p as ShotSpec, q as StrategyCtx, r as StrategyResult, s as StructuralRolloutConfig, S as StructuralRolloutPolicy, t as StructuralRolloutResult, V as VisibleCheck, u as adaptiveRefine, v as breadthStrategy, w as canDisplace, x as compareCheckOutcomes, y as composeCheckSources, z as defaultExtractCandidate, B as defaultStructuralRolloutPolicy, D as defineStrategy, E as depthStrategy, F as filterAuthoredAsserts, G as modelAuthoredChecks, H as officialChecksFromMeta, I as refine, J as resolveEntrySymbol, K as runAgentic, L as sample, M as sampleThenRefine, N as sandboxCheckRunner, O as selectBestIndex, P as structuralRollout, Q as visibleCheckScore } from './structural-rollout-DHGDbhvR.js';
13
+ import { C as CorpusRecord, c as Corpus, O as Outcome, S as ScopeAnalyzeInput, d as AssertTraceDerivedFindings, e as SteerContext, f as ScopeAnalyst, F as FanoutOptions, g as CombinatorShape, h as ScopeWidenGate, L as LoopUntilSpec, P as PanelSpec, i as PipelineStage, W as WinnerStrategy, j as FanoutWinnerSelector, V as VerifySpec, k as WidenSpec, l as CorpusFilter, R as RenderCorpusToInstructionsOptions, D as DefinePersonaInput, m as Persona, n as RunPersonifiedOptions, o as ShapeRegistry, p as LoopShape, E as EqualKArm, q as EqualKOnCostOptions, r as EqualKVerdict, T as TrajectoryReportOptions, s as TrajectoryReport } from './worktree-fanout-IMKqdV_E.js';
14
+ export { A as AuthoredHarness, t as DefinePersona, u as EqualKOnCost, v as Fanout, w as FanoutSynthesis, x as FlatWidenGate, y as LoopUntil, z as LoopUntilState, B as Panel, G as PanelJudge, H as PanelVerdict, I as PatchDeliverableOptions, J as PersonaContext, K as PersonaExecutors, M as Pipeline, N as RenderCorpusToInstructions, Q as RunPersonified, U as ShapeBudget, X as ShapeContext, Y as TrajectoryNode, Z as TrajectoryReportFn, _ as Verify, $ as Widen, a0 as WidenDecision, a1 as WidenLineage, a2 as WorktreeCliExecutorOptions, a as WorktreeFanoutOptions, b as WorktreePatchArtifact, a3 as createWorktreeCliExecutor, a4 as patchDelivered, a5 as worktreeFanout } from './worktree-fanout-IMKqdV_E.js';
17
15
  import { b as AnalystRegistryLike } from './types-BC3bZpH0.js';
18
16
  import { AgentProfile as AgentProfile$1 } from '@tangle-network/agent-interface';
19
- import { R as RouterConfig, T as ToolLoopChat, a as ToolLoopCompactionOptions } from './sanitize-C9go6tXj.js';
20
- export { j as RouterChatResult, k as RouterChatToolsResult, l as RouterToolCall, m as RouterToolLoopResult, n as ToolLoopCompaction, b as ToolSpec, r as routerBrain, o as routerChatWithTools, p as routerChatWithUsage, q as routerToolLoop } from './sanitize-C9go6tXj.js';
21
- import { D as DeliverableSpec } from './completion-gate-BLaiN0-X.js';
22
- export { g as WorktreeCommandResult, h as gateOnDeliverable } from './completion-gate-BLaiN0-X.js';
23
- import { S as SupervisorProfile } from './supervise-T2pazU3G.js';
24
- export { D as DriveHarness, a as SuperviseOptions, b as SupervisorAgentDeps, s as supervise, c as supervisorAgent, w as workerFromBackend } from './supervise-T2pazU3G.js';
17
+ import { R as RouterConfig, T as ToolLoopChat, a as ToolLoopCompactionOptions } from './sanitize-C2jicjNf.js';
18
+ export { j as RouterChatResult, k as RouterChatToolsResult, l as RouterToolCall, m as RouterToolLoopResult, n as ToolLoopCompaction, b as ToolSpec, r as routerBrain, o as routerChatWithTools, p as routerChatWithUsage, q as routerToolLoop } from './sanitize-C2jicjNf.js';
19
+ import { D as DeliverableSpec } from './completion-gate-BAj3dXeW.js';
20
+ export { g as WorktreeCommandResult, h as gateOnDeliverable } from './completion-gate-BAj3dXeW.js';
21
+ import { S as SupervisorProfile } from './supervise-DTNcLDl2.js';
22
+ export { D as DriveHarness, a as SuperviseOptions, b as SupervisorAgentDeps, s as supervise, c as supervisorAgent, w as workerFromBackend } from './supervise-DTNcLDl2.js';
25
23
  import { stuckLoopView, toolWasteView } from '@tangle-network/agent-eval/pipelines';
26
24
  export { AgentEnvironment, AgentEnvironmentCapabilities, AgentEnvironmentEvent, AgentEnvironmentProvider, AgentEnvironmentQuery, AgentEnvironmentStatus, AgentEnvironmentSummary, AgentProfileRef, AgentSession, AgentSessionRef, AgentSessionStatus, AgentTurnInput, AgentTurnResult, CheckpointRef, CheckpointRequest, CreateAgentEnvironmentInput, ExecRequest, ExecResult, ForkRequest, PlacementInfo, ResourceRequest, WorkspaceRequest } from '@tangle-network/agent-interface/environment-provider';
27
25
  import './substrate-DO2GHNg2.js';
28
- import './local-harness-dcD5WTTr.js';
26
+ import './local-harness-B7bNuNJw.js';
29
27
  import 'node:child_process';
30
28
 
31
29
  /**
@@ -1062,6 +1060,248 @@ declare function loopCampaignDispatch<Task, Output, Decision, TScenario extends
1062
1060
  */
1063
1061
  declare function loopDispatch<Task, Output, Decision, TScenario extends Scenario, TArtifact>(opts: LoopDispatchOptions<Task, Output, Decision, TScenario, TArtifact>): ProfileDispatchFn<TScenario, TArtifact>;
1064
1062
 
1063
+ /**
1064
+ * The general agentic primitive — sequential (depth) and parallel (breadth) over a shared,
1065
+ * checkable artifact, driven through the keystone Supervisor as one recursive `Agent.act`.
1066
+ *
1067
+ * The domain lives behind ONE seam — `AgenticSurface` (open an artifact, list tools, call a tool,
1068
+ * score the artifact, close it). EnterpriseOps implements it (seed a gym DB, MCP tools, SQL
1069
+ * verifier); Commit0/AppWorld/terminal-bench implement it the same way (a repo workspace, shell
1070
+ * tools, the test suite). The drivers below are domain-blind: they run over any surface.
1071
+ *
1072
+ * Two shapes, the agent's POMDP rollout as the unit:
1073
+ * - DEPTH one persistent artifact carried across shots. Each shot the agent works the tool loop;
1074
+ * between shots a trace-analyst (selector≠judge: reads the trajectory, never the score)
1075
+ * steers the resumed session toward what's unfinished. shot n stands on shot n-1's
1076
+ * artifact state + history. This is continuation — long-horizon, same artifact.
1077
+ * - BREADTH K independent artifacts, each a fresh rollout, the deployable verifier picks the best.
1078
+ *
1079
+ * Both are an `Agent` whose `act` spawns leaf shots through `scope.spawn` and reacts via
1080
+ * `scope.next()` — so the conserved budget pool meters them (equal-k by construction), the journal
1081
+ * records the tree, and the same primitive nests. `runAgentic` runs the chosen driver through
1082
+ * `createSupervisor().run`. The leaf (one shot over a handle) is resolved per-spawn from a
1083
+ * surface-closed registry — the open `Executor` seam, not bespoke per-benchmark glue.
1084
+ */
1085
+
1086
+ interface AgenticTask {
1087
+ readonly id: string;
1088
+ readonly systemPrompt: string;
1089
+ readonly userPrompt: string;
1090
+ /** Opaque domain payload the surface reads (EOPS: servers/verifiers/tools). Drivers never read it. */
1091
+ readonly meta?: Record<string, unknown>;
1092
+ }
1093
+ interface ArtifactHandle {
1094
+ readonly id: string;
1095
+ readonly surface: string;
1096
+ /** Opaque per-artifact context the surface stashes (EOPS: the seeded gym server + db id). */
1097
+ readonly ctx?: unknown;
1098
+ }
1099
+ interface AgenticTool {
1100
+ readonly type: 'function';
1101
+ readonly function: {
1102
+ name: string;
1103
+ description?: string;
1104
+ parameters: Record<string, unknown>;
1105
+ };
1106
+ }
1107
+ interface SurfaceScore {
1108
+ passes: number;
1109
+ total: number;
1110
+ /** Checks excluded as malformed (data defect, not the agent). `total === 0` ⇒ unscoreable. */
1111
+ errored: number;
1112
+ }
1113
+ /** A stateful, checkable environment an agent operates over with tools. Open behind one interface. */
1114
+ interface AgenticSurface {
1115
+ readonly name: string;
1116
+ open(task: AgenticTask): Promise<ArtifactHandle>;
1117
+ tools(task: AgenticTask, handle: ArtifactHandle): Promise<AgenticTool[]>;
1118
+ call(handle: ArtifactHandle, name: string, args: Record<string, unknown>): Promise<string>;
1119
+ score(task: AgenticTask, handle: ArtifactHandle): Promise<SurfaceScore>;
1120
+ close(handle: ArtifactHandle): Promise<void>;
1121
+ }
1122
+ interface AgenticOptions {
1123
+ routerBaseUrl: string;
1124
+ routerKey: string;
1125
+ model: string;
1126
+ /** Optional completion transport (see `RouterConfig.complete`): when set, BOTH legs of an
1127
+ * offline run use it instead of `fetch`-ing the router — the worker's tool loop (threaded into
1128
+ * its `routerToolLoop` cfg) AND the analyst's critic (its `ChatClient` is bound to this same
1129
+ * transport). One injected responder serves both, as a localhost mock endpoint would. Absent ⇒
1130
+ * the live router fetch path (the default). */
1131
+ complete?: (body: Record<string, unknown>) => Promise<unknown>;
1132
+ temperature?: number;
1133
+ /** Completion cap per worker turn — REQUIRED for thinking models (they burn unbounded
1134
+ * budgets on reasoning and return empty content without it). Omitted ⇒ provider default. */
1135
+ maxTokens?: number;
1136
+ /** Turns the agent may take within ONE shot before the driver intervenes. */
1137
+ innerTurns?: number;
1138
+ /** The depth STEERER's analyst instruction (observe()'s system prompt). The knob a
1139
+ * prompt optimizer (GEPA) tunes — the analyst IS the steerer. Omitted ⇒ the default. */
1140
+ analystInstruction?: string;
1141
+ /** The critic's model — lets the analyst be a stronger (or cheaper) model than the
1142
+ * worker. Omitted ⇒ the worker's `model`. */
1143
+ analystModel?: string;
1144
+ /** Across-run learning: when set, the analyst's observe() pass appends trace-derived
1145
+ * facts here (the flywheel write side). Read-back is opt-in via `corpusReadback`
1146
+ * because unconditional priming can pollute context on some domains. */
1147
+ corpus?: Corpus;
1148
+ /** Tags written onto learned facts (and used by the caller's priming query). */
1149
+ corpusTags?: string[];
1150
+ /** In-context learning: when set, query `corpus` before each depth shot and inject
1151
+ * the top trace-derived facts as guidance for the active run. No corpus means no read-back. */
1152
+ corpusReadback?: CorpusReadbackOptions;
1153
+ }
1154
+ interface CorpusReadbackOptions {
1155
+ /** Minimum confidence for a fact to be injected. Default 0.7. */
1156
+ minConfidence?: number;
1157
+ /** Extra tags a fact must carry, in addition to `corpusTags`. */
1158
+ tags?: ReadonlyArray<string>;
1159
+ /** Max facts injected per shot. Default 3. */
1160
+ maxFacts?: number;
1161
+ /** Default false: only facts tagged `audience:agent` are injected into the worker. */
1162
+ includeOperatorFacts?: boolean;
1163
+ }
1164
+ type Msg$1 = Record<string, unknown>;
1165
+ interface ShotResult {
1166
+ messages: Msg$1[];
1167
+ score: number;
1168
+ passes: number;
1169
+ total: number;
1170
+ completions: number;
1171
+ toolErrors: number;
1172
+ }
1173
+ interface AgenticRunResult {
1174
+ /** The strategy name (built-in 'depth'/'breadth' or a custom strategy's name). */
1175
+ mode: string;
1176
+ score: number;
1177
+ resolved: boolean;
1178
+ completions: number;
1179
+ /** DEPTH: score after each shot — the progress-over-rounds curve. BREADTH: best-so-far per rollout. */
1180
+ progression: number[];
1181
+ shots: number;
1182
+ /** The cost vector, stamped by `runAgentic` from the Supervisor's conserved pool: real
1183
+ * router tokens, priced usd (0 when the model is unpriced — never fabricated), wall ms. */
1184
+ usd: number;
1185
+ ms: number;
1186
+ tokens: {
1187
+ input: number;
1188
+ output: number;
1189
+ };
1190
+ }
1191
+ /** DEPTH: one persistent artifact, carried across analyst-steered shots. */
1192
+ declare function depthStrategy(surface: AgenticSurface, task: AgenticTask, opts: AgenticOptions, cfg: {
1193
+ maxShots: number;
1194
+ }): Agent<unknown, Outcome<unknown>>;
1195
+ /** BREADTH: K independent rollouts (each own artifact), verifier picks the best. */
1196
+ declare function breadthStrategy(_surface: AgenticSurface, task: AgenticTask, opts: AgenticOptions, cfg: {
1197
+ width: number;
1198
+ }): Agent<unknown, Outcome<unknown>>;
1199
+ /**
1200
+ * A Strategy is HOW you spend the compute budget to beat the Environment's check — it
1201
+ * builds the driver `Agent` the Supervisor runs. This is the OPEN extension point: a dev
1202
+ * authors their own by implementing `driver()` to return an Agent whose `act()` spawns
1203
+ * shots/analysts via `scope.spawn` / `scope.next` / `scope.send`. The two built-ins are
1204
+ * the reference implementations to copy:
1205
+ * sample — K INDEPENDENT attempts, keep the best-verifying (best-of-N / resample).
1206
+ * refine — attempt → observe() reads the trace → steer the next → repeat (iterate).
1207
+ * (A multi-agent "team" is just a Strategy whose driver spawns several different agents.)
1208
+ */
1209
+ interface Strategy {
1210
+ readonly name: string;
1211
+ driver(surface: AgenticSurface, task: AgenticTask, opts: AgenticOptions, budget: number): Agent<unknown, Outcome<unknown>>;
1212
+ }
1213
+ /** Built-in `Strategy`: K independent attempts, keep the best-verifying (best-of-N / resample). */
1214
+ declare const sample: Strategy;
1215
+ /** Built-in `Strategy`: attempt → `observe()` reads the trace → steer the next attempt → repeat (deepen one lineage). */
1216
+ declare const refine: Strategy;
1217
+ /** A role for one shot — multi-agent loops (researcher + engineer, a panel of k
1218
+ * researchers) give each shot its own system prompt and optionally its own model. */
1219
+ interface ShotPersona {
1220
+ /** Replaces the task's systemPrompt for a FRESH shot; on a carried conversation it is
1221
+ * injected as a hand-off message (the transcript's earlier roles stay intact). */
1222
+ systemPrompt?: string;
1223
+ /** Per-shot model override (e.g. a stronger model for the engineer shot). */
1224
+ model?: string;
1225
+ }
1226
+ interface ShotSpec {
1227
+ /** present ⇒ continue this artifact (depth); absent ⇒ the shot opens a fresh one (sample/restart). */
1228
+ handle?: ArtifactHandle;
1229
+ messages?: Msg$1[];
1230
+ steer?: string;
1231
+ persona?: ShotPersona;
1232
+ /** Restrict THIS shot to a subset of the domain's tools (by name) — focus a shot on
1233
+ * the relevant capabilities. Restriction-only; unknown names throw. Omitted ⇒ all. */
1234
+ tools?: string[];
1235
+ }
1236
+ interface StrategyResult {
1237
+ score: number;
1238
+ resolved: boolean;
1239
+ completions: number;
1240
+ progression: number[];
1241
+ shots: number;
1242
+ }
1243
+ /** Artifact lifecycle a strategy may manage itself — open/close ONLY. Raw `call`/`score`
1244
+ * are withheld: scores reach the body solely through `shot()`'s ShotResult (the
1245
+ * harness-verified channel), so a body cannot peek the check or fabricate around it. */
1246
+ interface StrategyArtifacts {
1247
+ readonly name: string;
1248
+ open(task: AgenticTask): Promise<ArtifactHandle>;
1249
+ close(handle: ArtifactHandle): Promise<void>;
1250
+ }
1251
+ /** What a strategy body composes with: the artifact lifecycle, the budget, and the two steps. */
1252
+ interface StrategyCtx {
1253
+ /** Open/close artifacts the body manages itself (e.g. one persistent handle for depth). */
1254
+ readonly surface: StrategyArtifacts;
1255
+ readonly task: AgenticTask;
1256
+ readonly opts: AgenticOptions;
1257
+ readonly budget: number;
1258
+ readonly scope: Scope<Outcome<unknown>>;
1259
+ /** Run ONE worker shot; its harness-scored result, or null if it went down. */
1260
+ shot(spec?: ShotSpec): Promise<ShotResult | null>;
1261
+ /** The firewalled critic reads the trajectory → a steer string, or null on COMPLETE/down. */
1262
+ critique(messages: Msg$1[]): Promise<string | null>;
1263
+ /** The RAW analyst channel: the firewalled critic answers `instruction` over the
1264
+ * trajectory verbatim — no findings extraction, so verdict-shaped formats
1265
+ * (CONTINUE/STOP decisions, calibrated predictions) survive. Same firewall:
1266
+ * trajectory in, never scores. Null when the analyst went down. */
1267
+ consult(messages: Msg$1[], instruction: string): Promise<string | null>;
1268
+ /** The tools THIS artifact's task actually offers (names + descriptions only — never
1269
+ * the implementations). Tool sets vary per task on heterogeneous domains; a strategy
1270
+ * that restricts shots MUST select from this list, never from hardcoded names. */
1271
+ listTools(handle: ArtifactHandle): Promise<Array<{
1272
+ name: string;
1273
+ description?: string;
1274
+ }>>;
1275
+ }
1276
+ /** Author a Strategy from the composable steps — the open, compact way. */
1277
+ declare function defineStrategy(name: string, run: (ctx: StrategyCtx) => Promise<StrategyResult>): Strategy;
1278
+ /** A NEW strategy, authored from the steps (~20 lines): refine, but when a steered shot
1279
+ * fails to improve the score it ABANDONS that line and restarts fresh (branch-when-stuck)
1280
+ * — the widen/MCTS idea the depth-stuck failure motivated. Scored keep-best (the best
1281
+ * checkpoint across all lines), the deployable metric. This is the "experts build BETTER
1282
+ * optimizations" path: a new technique, compact, with zero Supervisor ceremony. */
1283
+ declare const adaptiveRefine: Strategy;
1284
+ /** The explore-then-exploit MIX: spend ⌈budget/2⌉ on independent samples (kept open),
1285
+ * then refine the best-verifying line with the remaining budget. Sample's basin escape +
1286
+ * refine's accumulation — the third built-in, authored from the public steps. */
1287
+ declare const sampleThenRefine: Strategy;
1288
+ interface RunAgenticOptions extends AgenticOptions {
1289
+ surface: AgenticSurface;
1290
+ task: AgenticTask;
1291
+ /** Lifecycle observability — every spawn/settle (shots, analysts) streams here live.
1292
+ * The seam online watchdogs/route-auditors subscribe to. */
1293
+ hooks?: RuntimeHooks;
1294
+ /** A Strategy (the open way) — author/pass your own. Overrides `mode` when present. */
1295
+ strategy?: Strategy;
1296
+ /** Built-in shorthand: 'depth'→refine, 'breadth'→sample. Default 'depth'. */
1297
+ mode?: 'depth' | 'breadth';
1298
+ /** budget: refine→max shots; sample→rollout width. */
1299
+ budget: number;
1300
+ rootBudget?: Budget;
1301
+ }
1302
+ /** Run a Strategy through the keystone Supervisor — `Agent.act` over a conserved-budget Scope. */
1303
+ declare function runAgentic(opts: RunAgenticOptions): Promise<AgenticRunResult>;
1304
+
1065
1305
  /**
1066
1306
  * runBenchmark — the packaged optimization suite. Define a domain by implementing an
1067
1307
  * `Environment` (open / tools / call / score / close); get the optimization strategies
@@ -2842,6 +3082,205 @@ declare function streamAgentTurn(backend: AgentTurnBackend, prompt: string, opts
2842
3082
  */
2843
3083
  declare function collectAgentTurn(stream: AsyncIterable<RuntimeStreamEvent>): Promise<CollectedAgentTurn>;
2844
3084
 
3085
+ /**
3086
+ * structuralRollout — the measured structural lever as a fourth member of the
3087
+ * sample/refine/sampleThenRefine strategy family: k independent samples, selection by
3088
+ * TASK-VISIBLE checks only, then a guarded self-repair loop steered by the checks'
3089
+ * failure output. Design: docs/design/structural-rollout-integration.md; measured basis
3090
+ * (bench/src/hev-structural.mts, bench/src/mbpp-structural.mts): +8.5..+21.3pp hidden-test
3091
+ * lift across Llama-3-8B/Qwen2.5-7B × HumanEval/MBPP, null only at saturation.
3092
+ *
3093
+ * Honesty invariants carried over from the proven rigs:
3094
+ * - Visible checks are generated from task-visible information only, BEFORE any
3095
+ * candidate exists, and FROZEN for every sample and repair round of the task.
3096
+ * - OFFICIAL checks (shown in the task itself) rank lexicographically above
3097
+ * model-AUTHORED guesses. This ordering is measured, not stylistic: authored guesses
3098
+ * run 17–70% wrong depending on model × spec richness, and unweighted they flipped
3099
+ * selection NEGATIVE on MBPP (6 noisy guesses outvoting the one reliable check).
3100
+ * - A candidate that crashed before the checks could run ranks below one that ran and
3101
+ * failed everything.
3102
+ * - Repair sees ONLY the checks' failure output, and never displaces a candidate that
3103
+ * passes more official checks with one that passes fewer (wrong visible examples
3104
+ * poison repair at saturation — the glm /47,/116 regressions).
3105
+ *
3106
+ * Placement rule: this is an INFERENCE-TIME capability (it wraps the model call via the
3107
+ * strategy seam). It does not belong in improve()/selfImprove (training-time); improve()
3108
+ * may later tune `StructuralRolloutPolicy` as an optimizable surface.
3109
+ */
3110
+
3111
+ type Msg = Record<string, unknown>;
3112
+ /** The rollout's compute recipe — promoted from the proven rigs' env vars (K/REPAIRS/
3113
+ * TESTGEN/DIVERSE/TEMPERATURE). Defaults are the measured sweet spot: repair value
3114
+ * concentrates at low k (~+12pp at k=1, +1–3pp at k=5), so `k=5, repairRounds=2` is the
3115
+ * full recipe and `k=1, repairRounds=2` the low-compute preset. */
3116
+ interface StructuralRolloutPolicy {
3117
+ /** Independent samples per task (selection breadth). */
3118
+ k: number;
3119
+ /** Repair shots after selection, each steered by the checks' failure output. */
3120
+ repairRounds: number;
3121
+ /** Model-authored visible checks requested per task; 0 disables authoring. */
3122
+ testgen: number;
3123
+ /** Per-slot strategy-lens prefixes on the k samples (attacks the all-k-fail bucket).
3124
+ * Measured as a paired null (+0.6pp) — kept as an optional knob, off by default. */
3125
+ diverse?: boolean;
3126
+ /** Sampling temperature for every shot of this strategy; omitted ⇒ the worker default. */
3127
+ temperature?: number;
3128
+ }
3129
+ /** The measured default recipe: 5 samples, 2 guarded repair rounds, 6 authored checks. */
3130
+ declare const defaultStructuralRolloutPolicy: StructuralRolloutPolicy;
3131
+ /** One task-visible executable check (e.g. a single-line Python assert). */
3132
+ interface VisibleCheck {
3133
+ code: string;
3134
+ /** 'official' = shown in the task itself (docstring example, shown assert);
3135
+ * 'authored' = the model's own guess. Official outranks authored in selection. */
3136
+ kind: 'official' | 'authored';
3137
+ }
3138
+ /** What a CheckSource composes with. `consult` is the strategy family's raw analyst
3139
+ * channel (metered by the conserved pool, offline-injectable via `opts.complete`) —
3140
+ * check authoring goes through it rather than a bespoke model client. */
3141
+ interface CheckSourceCtx {
3142
+ /** Authored-check budget for this task (`policy.testgen`). */
3143
+ count: number;
3144
+ /** The symbol authored checks must reference; undefined ⇒ authoring is skipped
3145
+ * (no guesses beats guesses pinned to nothing). */
3146
+ entrySymbol?: string;
3147
+ /** One metered LLM call: instruction in, reply text out, null when the channel went
3148
+ * down. The task's visible prompt is included by the channel itself. */
3149
+ consult(instruction: string): Promise<string | null>;
3150
+ }
3151
+ /** Produces the task's visible checks. MUST derive them from agent-visible information
3152
+ * only, before any candidate exists — the strategy freezes the returned set for every
3153
+ * sample and repair round of the task. */
3154
+ interface CheckSource {
3155
+ generate(task: AgenticTask, ctx: CheckSourceCtx): Promise<VisibleCheck[]>;
3156
+ }
3157
+ /** The proven authored-assert filter (lifted from the rigs' generateTests): keep only
3158
+ * single-line, paren-balanced asserts that reference the entry symbol — malformed lines
3159
+ * are dropped here rather than poisoning every candidate's score identically. */
3160
+ declare function filterAuthoredAsserts(reply: string, entrySymbol: string, count: number): string[];
3161
+ /** Default authored-check source: one metered LLM call per task, before sampling,
3162
+ * filtered through `filterAuthoredAsserts`. Returns [] (no signal, never a fabricated
3163
+ * check) when the budget is 0, no entry symbol resolves, or the channel went down. */
3164
+ declare function modelAuthoredChecks(overrides?: {
3165
+ count?: number;
3166
+ }): CheckSource;
3167
+ /** Official checks the surface stashed on the task (e.g. MBPP's shown assert). Reads
3168
+ * `task.meta[key]` as a string array; anything else means no official checks. */
3169
+ declare function officialChecksFromMeta(key?: string): CheckSource;
3170
+ /** Concatenate check sources (official first by convention — ordering does not affect
3171
+ * scoring, which reads each check's `kind`). */
3172
+ declare function composeCheckSources(...sources: CheckSource[]): CheckSource;
3173
+ /** The symbol authored checks are pinned to: `task.meta.entryPoint` when the surface
3174
+ * provides it, else the LAST `def name(` in the visible prompt (a code-completion stub
3175
+ * lists helpers first, the entry stub last). Undefined ⇒ authoring is skipped. */
3176
+ declare function resolveEntrySymbol(task: AgenticTask): string | undefined;
3177
+ /** How one candidate fared against the frozen visible checks, split by check kind. */
3178
+ interface CheckOutcome {
3179
+ passedOfficial: number;
3180
+ totalOfficial: number;
3181
+ passedAuthored: number;
3182
+ totalAuthored: number;
3183
+ /** The checks' failure report — the ONLY feedback the repair loop may see. */
3184
+ failureOutput: string;
3185
+ /** True when the candidate crashed before any check could run — ranks below a
3186
+ * candidate that ran and failed everything. */
3187
+ crashed?: boolean;
3188
+ }
3189
+ /** Minimal exec channel the default runner needs. `SandboxInstance` (and therefore
3190
+ * `ValidationCtx.box`) satisfies it structurally. */
3191
+ interface CheckExecChannel {
3192
+ exec(command: string, options?: {
3193
+ timeoutMs?: number;
3194
+ }): Promise<{
3195
+ exitCode: number;
3196
+ stdout: string;
3197
+ stderr: string;
3198
+ }>;
3199
+ }
3200
+ interface CheckRunContext {
3201
+ task: AgenticTask;
3202
+ /** Live exec channel for this run (`ValidationCtx.box` / a sandbox instance). */
3203
+ box?: CheckExecChannel;
3204
+ signal?: AbortSignal;
3205
+ }
3206
+ /** Executes the frozen checks against one candidate. Implementations MUST fail loud
3207
+ * (throw) when they cannot execute — a silent zero poisons selection. */
3208
+ interface CheckRunner {
3209
+ run(candidate: string, checks: VisibleCheck[], ctx: CheckRunContext): Promise<CheckOutcome>;
3210
+ }
3211
+ /** Default CheckRunner backend: pipes the check program into `python3` over the sandbox
3212
+ * exec channel (`ctx.box`, or one bound at construction). Never shells out to docker
3213
+ * itself — the jail is the sandbox's concern. No channel ⇒ throws; it must never
3214
+ * silently score 0. Empty check sets short-circuit to a no-signal outcome (nothing to
3215
+ * execute, so no channel is required). */
3216
+ declare function sandboxCheckRunner(options?: {
3217
+ box?: CheckExecChannel;
3218
+ python?: string;
3219
+ timeoutMs?: number;
3220
+ }): CheckRunner;
3221
+ /** The selection order: crash < ran; then official pass-fraction; authored guesses only
3222
+ * break ties. Returns > 0 when `a` outranks `b`. Strictly lexicographic — on MBPP,
3223
+ * letting 6 noisy guesses outvote the one official check flipped selection negative. */
3224
+ declare function compareCheckOutcomes(a: CheckOutcome, b: CheckOutcome): number;
3225
+ /** Display scalar for receipts/reports (the rigs' `visibleScore` shape): crash = -1,
3226
+ * else official fraction + 0.001 × authored fraction. Selection itself uses the exact
3227
+ * lexicographic comparator, never this scalar. */
3228
+ declare function visibleCheckScore(o: CheckOutcome): number;
3229
+ /** Argmax by `compareCheckOutcomes`, FIRST index wins ties (deterministic; with zero
3230
+ * visible coverage every candidate ties at no-signal and index 0 is the blind pick). */
3231
+ declare function selectBestIndex(outcomes: ReadonlyArray<CheckOutcome>): number;
3232
+ /** The repair keep-best guard: a challenger displaces the incumbent only when it is
3233
+ * strictly better in the selection order AND passes at least as many official checks.
3234
+ * The raw-count clause is deliberate belt-and-braces over the comparator (a custom
3235
+ * runner can report shifted totals): repair must NEVER replace a candidate that passes
3236
+ * more official checks with one that passes fewer. */
3237
+ declare function canDisplace(challenger: CheckOutcome, incumbent: CheckOutcome): boolean;
3238
+ /** The candidate a shot produced, read from its conversation: the LAST `submit_answer`
3239
+ * tool-call argument (verifier environments submit the artifact explicitly), else the
3240
+ * latest assistant reply's fenced code block — preferring a block containing a `def`,
3241
+ * because repair replies echo the failure report in a bare fence BEFORE the fixed code
3242
+ * (the rigs' extractRepairCode lesson) — else the latest non-empty assistant text. */
3243
+ declare function defaultExtractCandidate(messages: ReadonlyArray<Msg>): string;
3244
+ type RepairStop = 'already-passing' | 'no-signal' | 'repaired-pass' | 'rounds-exhausted' | 'no-candidates';
3245
+ /** The body's deliverable — a `StrategyResult` plus selection provenance. The extra
3246
+ * fields ride through `defineStrategy`'s deliverable spread onto `AgenticRunResult`
3247
+ * (score/resolved stay harness-verified, exactly as for every authored strategy). */
3248
+ interface StructuralRolloutResult extends StrategyResult {
3249
+ /** One receipt per scored candidate (k samples, then repairs), `SelectionReceipt`
3250
+ * shaped like the kernel's (`types.ts`), selector 'driver'. */
3251
+ selection: SelectionReceipt[];
3252
+ repairStop: RepairStop;
3253
+ officialChecks: number;
3254
+ authoredChecks: number;
3255
+ }
3256
+ interface StructuralRolloutConfig {
3257
+ /** Knobs; missing fields take the measured defaults (k=5, repairRounds=2, testgen=6). */
3258
+ policy?: Partial<StructuralRolloutPolicy>;
3259
+ /** Where the visible checks come from. Default: official checks from
3260
+ * `task.meta.visibleChecks` composed with `modelAuthoredChecks()`. */
3261
+ checkSource?: CheckSource;
3262
+ /** How candidates are measured. Default `sandboxCheckRunner()` — it needs an exec
3263
+ * channel (bind one to the runner, or pass `box` here) and fails loud without one. */
3264
+ checkRunner?: CheckRunner;
3265
+ /** Exec channel threaded into every check run of this strategy (a sandbox instance /
3266
+ * `ValidationCtx.box`). The strategy seam itself carries no sandbox, so the caller
3267
+ * who owns one supplies it here or binds it into the runner. */
3268
+ box?: CheckExecChannel;
3269
+ /** Candidate extraction from a shot's conversation. Default `defaultExtractCandidate`. */
3270
+ extractCandidate?: (messages: ReadonlyArray<Msg>) => string;
3271
+ }
3272
+ /**
3273
+ * Build the structuralRollout `Strategy`: k shots → score each by the frozen visible
3274
+ * checks (official above authored, crash lowest) → argmax with first-index tie-break →
3275
+ * up to `repairRounds` repair shots steered by the failure output, keep-best under the
3276
+ * official-check guard. Authored via `defineStrategy`, so the deliverable score stays
3277
+ * harness-verified and every shot is metered by the conserved pool.
3278
+ *
3279
+ * Budget note: `runAgentic`'s `budget` sizes the pool — pass at least
3280
+ * `k + repairRounds + 1` so the samples, repairs, and the check-author consult all admit.
3281
+ */
3282
+ declare function structuralRollout(config?: StructuralRolloutConfig): Strategy;
3283
+
2845
3284
  /**
2846
3285
  *
2847
3286
  * The supervisor's intelligence is AUTHORING the agents it spawns — not pressing buttons.
@@ -3754,4 +4193,4 @@ declare function runInWorkspace<T>(ws: Workspace, body: (cwd: string) => Promise
3754
4193
  commitOnInvalid?: boolean;
3755
4194
  }): Promise<WorkspaceRun<T>>;
3756
4195
 
3757
- export { Agent, AgentRunSpec, type AgentTurnBackend, type AgentTurnUsage, AgenticOptions, AgenticSurface, AgenticTask, AgenticTool, AnalystRegistry, type AnytimeReport, type AnytimeStrategySummary, type AnytimeTaskCurve, type ApplyContinuation, ArtifactHandle, AssertTraceDerivedFindings, type AuditIntentInput, type AuditIntentOptions, type AuthorStrategyOptions, type AuthoredProfile, type AuthoredStrategy, type BenchmarkCell, type BenchmarkConfig, type BenchmarkLift, type BenchmarkReport, type BenchmarkStrategySummary, type BenchmarkTaskRow, Budget, type BudgetPool, type BudgetReadout, type ChampionPick, type ChampionPolicy, type CheckpointCapableBox, type CollectedAgentTurn, CombinatorShape, type CompletionAnalyst, type CompletionEvidence, type CompletionPolicy, type CompletionVerdict, CoordinationEvent, type CoordinationMcpHandle, Corpus, CorpusFilter, CorpusRecord, type CreateScopeAnalystOptions, type CriuCapableClient, DefinePersonaInput, type DefinedLeaderboard, type DelegateOptions, type Deliverable, DeliverableSpec, Driver, type DriverAgentOptions, type DumbDriverOptions, type Environment, EqualKArm, EqualKOnCostOptions, EqualKVerdict, type EvolutionArchiveNode, type EvolutionAuthor, type EvolutionBandInfo, type EvolutionCandidate, type EvolutionGeneration, type EvolutionReport, ExecCtx, ExecutorConfig, ExecutorFactory, ExecutorRegistry, FanoutOptions, FanoutWinnerSelector, FileCorpus, type ForkCapableBox, type GitWorkspaceOptions, type HarvestCorpusOptions, type HarvestFailure, type HarvestReport, InMemoryCorpus, InMemoryResultBlobStore, type InMemoryRunContext, type InMemoryRunContextOptions, InMemorySpawnJournal, type InProcessOnPrompt, type InProcessPromptCtx, type InProcessSandboxClientOptions, type Inbox, type InboxMessage, type IntentAudit, type Interval, Iteration, type Leaderboard, type LeaderboardBenchScore, type LeaderboardBenchTask, type LeaderboardBenchmarkAdapter, type LeaderboardFlagSpec, type LeaderboardIterationInfo, type LeaderboardOptions, type LeaderboardRow, type LeaderboardRunContext, type LeaderboardScenario, type LeaderboardScore, type LeaderboardSpec, type LoopCampaignDispatchOptions, type LoopDispatchOptions, LoopLineageOptions, type LoopOptionsForDispatch, LoopResult, LoopShape, LoopTokenUsage, LoopUntilSpec, LoopWinner, MakeWorkerAgent, type McpEndpoint, type McpEnvironmentOptions, MountRecorder, type NaiveDriverOptions, type Observation, type ObserveInput, type ObserveOptions, type OpenSandboxRunBeforeStartContext, type OpenSandboxRunOptions, type OpenSandboxRunPromptOptions, Outcome, OutputAdapter, type PairwiseOptions, type PairwiseVerdict, PanelSpec, Persona, PipelineStage, type ProfileRichness, type ProfileRichnessThresholds, type PromotionGateOptions, type PromotionVerdict, type RegistryAnalyzeProjection, RenderCorpusToInstructionsOptions, type ReservationTicket, type ResolveSandboxClientOptions, ResultBlobStore, RouterConfig, RunPersonifiedOptions, type SandboxCapabilities, SandboxClient, type SandboxLineage, type SandboxLineageHandle, type SandboxRun, SandboxRunAbortError, type SandboxToolPartState, Scope, ScopeAnalyst, ScopeAnalyzeInput, ScopeWidenGate, type SessionCapableBox, type SessionTraceBox, Settled, ShapeRegistry, type Shell, Spend, SteerContext, type SteeringDecision, Strategy, type StrategyEvolutionConfig, type StreamAgentTurnOptions, type SuperviseSurfaceOptions, type SuperviseSurfaceResult, SupervisedResult, Supervisor, SupervisorProfile, SurfaceScore, type SurfaceWorkerConfig, type SurfaceWorkerOut, ToolLoopChat, ToolLoopCompactionOptions, type TraceSource, type TrajectoryAnalysis, TrajectoryReport, TrajectoryReportOptions, type TurnResult, UsageEvent, type UsageSink, Validator, type VerifierEnvironmentOptions, VerifySpec, type WatchTraceOptions, type WaterfallCollector, type WaterfallReport, type WaterfallSpan, WidenSpec, WinnerStrategy, type Workspace, type WorkspaceCommit, type WorkspaceRun, acquireSandbox, analyzeTrace, anytimeReport, asAuthoredProfile, assertModelAllowed, assertStrategyContract, assertTraceDerivedFindings, assessAuthoredProfile, auditIntent, authorStrategy, authoredWorker, buildSteerContext, builtinShapes, collectAgentTurn, completionAuthorizes, contentAddress, createBudgetPool, createInMemoryRunContext, createInbox, createMcpEnvironment, createPushTraceSource, createSandboxLineage, createSandboxToolPartState, createScope, createScopeAnalyst, createShapeRegistry, createSupervisor, createVerifierEnvironment, createWaterfallCollector, decodeToolPart, defaultAnalystInstruction, defaultAuditorInstruction, defaultDelegateBudget, defaultProfileRichnessThresholds, defaultSelectWinner, defaultToolDetectors, defineLeaderboard, definePersona, delegate, deterministicCompletion, discriminatingMeans, driverAgent, dumbDriver, equalKOnCost, extractLlmCallEvent, failuresAnalyst, fanout, finalizeBestDelivered, flatWidenGate, gitWorkspace, harvestCorpus, inProcessSandboxClient, inlineSandboxClient, jjWorkspace, leaderboard, localShell, loopCampaignDispatch, loopDispatch, loopUntil, mapSandboxEvent, mapSandboxToolEvent, naiveDriver, observe, openSandboxRun, pairwiseSignificance, panel, pickChampion, pipeline, printBenchmarkReport, probeSandboxCapabilities, profileRichnessFinding, promotionGate, registerShape, registryScopeAnalyst, renderAnytimeTable, renderCorpusToInstructions, renderLeaderboardHtml, renderLeaderboardMarkdown, renderLeaderboardSvg, renderPairwiseMarkdown, renderReport, reportLoopUsage, resolveSandboxClient, runBenchmark, runInWorkspace, runLoop, runPersonified, runStrategyEvolution, sandboxSessionTraceSource, selectChampion, selectValidWinner, sentinelCompletion, serveCoordinationMcp, settledToIteration, spendFromUsageEvents, stopSentinel, strategyAuthorContract, streamAgentTurn, sumSandboxUsage, superviseSurface, supervisorInstructions, trajectoryReport, verify, watchTrace, widen };
4196
+ export { Agent, AgentRunSpec, type AgentTurnBackend, type AgentTurnUsage, type AgenticOptions, type AgenticRunResult, type AgenticSurface, type AgenticTask, type AgenticTool, AnalystRegistry, type AnytimeReport, type AnytimeStrategySummary, type AnytimeTaskCurve, type ApplyContinuation, type ArtifactHandle, AssertTraceDerivedFindings, type AuditIntentInput, type AuditIntentOptions, type AuthorStrategyOptions, type AuthoredProfile, type AuthoredStrategy, type BenchmarkCell, type BenchmarkConfig, type BenchmarkLift, type BenchmarkReport, type BenchmarkStrategySummary, type BenchmarkTaskRow, Budget, type BudgetPool, type BudgetReadout, type ChampionPick, type ChampionPolicy, type CheckExecChannel, type CheckOutcome, type CheckRunContext, type CheckRunner, type CheckSource, type CheckSourceCtx, type CheckpointCapableBox, type CollectedAgentTurn, CombinatorShape, type CompletionAnalyst, type CompletionEvidence, type CompletionPolicy, type CompletionVerdict, CoordinationEvent, type CoordinationMcpHandle, Corpus, CorpusFilter, type CorpusReadbackOptions, CorpusRecord, type CreateScopeAnalystOptions, type CriuCapableClient, DefinePersonaInput, type DefinedLeaderboard, type DelegateOptions, type Deliverable, DeliverableSpec, Driver, type DriverAgentOptions, type DumbDriverOptions, type Environment, EqualKArm, EqualKOnCostOptions, EqualKVerdict, type EvolutionArchiveNode, type EvolutionAuthor, type EvolutionBandInfo, type EvolutionCandidate, type EvolutionGeneration, type EvolutionReport, ExecCtx, ExecutorConfig, ExecutorFactory, ExecutorRegistry, FanoutOptions, FanoutWinnerSelector, FileCorpus, type ForkCapableBox, type GitWorkspaceOptions, type HarvestCorpusOptions, type HarvestFailure, type HarvestReport, InMemoryCorpus, InMemoryResultBlobStore, type InMemoryRunContext, type InMemoryRunContextOptions, InMemorySpawnJournal, type InProcessOnPrompt, type InProcessPromptCtx, type InProcessSandboxClientOptions, type Inbox, type InboxMessage, type IntentAudit, type Interval, Iteration, type Leaderboard, type LeaderboardBenchScore, type LeaderboardBenchTask, type LeaderboardBenchmarkAdapter, type LeaderboardFlagSpec, type LeaderboardIterationInfo, type LeaderboardOptions, type LeaderboardRow, type LeaderboardRunContext, type LeaderboardScenario, type LeaderboardScore, type LeaderboardSpec, type LoopCampaignDispatchOptions, type LoopDispatchOptions, LoopLineageOptions, type LoopOptionsForDispatch, LoopResult, LoopShape, LoopTokenUsage, LoopUntilSpec, LoopWinner, MakeWorkerAgent, type McpEndpoint, type McpEnvironmentOptions, MountRecorder, type NaiveDriverOptions, type Observation, type ObserveInput, type ObserveOptions, type OpenSandboxRunBeforeStartContext, type OpenSandboxRunOptions, type OpenSandboxRunPromptOptions, Outcome, OutputAdapter, type PairwiseOptions, type PairwiseVerdict, PanelSpec, Persona, PipelineStage, type ProfileRichness, type ProfileRichnessThresholds, type PromotionGateOptions, type PromotionVerdict, type RegistryAnalyzeProjection, RenderCorpusToInstructionsOptions, type RepairStop, type ReservationTicket, type ResolveSandboxClientOptions, ResultBlobStore, RouterConfig, type RunAgenticOptions, RunPersonifiedOptions, type SandboxCapabilities, SandboxClient, type SandboxLineage, type SandboxLineageHandle, type SandboxRun, SandboxRunAbortError, type SandboxToolPartState, Scope, ScopeAnalyst, ScopeAnalyzeInput, ScopeWidenGate, SelectionReceipt, type SessionCapableBox, type SessionTraceBox, Settled, ShapeRegistry, type Shell, type ShotPersona, type ShotSpec, Spend, SteerContext, type SteeringDecision, type Strategy, type StrategyCtx, type StrategyEvolutionConfig, type StrategyResult, type StreamAgentTurnOptions, type StructuralRolloutConfig, type StructuralRolloutPolicy, type StructuralRolloutResult, type SuperviseSurfaceOptions, type SuperviseSurfaceResult, SupervisedResult, Supervisor, SupervisorProfile, type SurfaceScore, type SurfaceWorkerConfig, type SurfaceWorkerOut, ToolLoopChat, ToolLoopCompactionOptions, type TraceSource, type TrajectoryAnalysis, TrajectoryReport, TrajectoryReportOptions, type TurnResult, UsageEvent, type UsageSink, Validator, type VerifierEnvironmentOptions, VerifySpec, type VisibleCheck, type WatchTraceOptions, type WaterfallCollector, type WaterfallReport, type WaterfallSpan, WidenSpec, WinnerStrategy, type Workspace, type WorkspaceCommit, type WorkspaceRun, acquireSandbox, adaptiveRefine, analyzeTrace, anytimeReport, asAuthoredProfile, assertModelAllowed, assertStrategyContract, assertTraceDerivedFindings, assessAuthoredProfile, auditIntent, authorStrategy, authoredWorker, breadthStrategy, buildSteerContext, builtinShapes, canDisplace, collectAgentTurn, compareCheckOutcomes, completionAuthorizes, composeCheckSources, contentAddress, createBudgetPool, createInMemoryRunContext, createInbox, createMcpEnvironment, createPushTraceSource, createSandboxLineage, createSandboxToolPartState, createScope, createScopeAnalyst, createShapeRegistry, createSupervisor, createVerifierEnvironment, createWaterfallCollector, decodeToolPart, defaultAnalystInstruction, defaultAuditorInstruction, defaultDelegateBudget, defaultExtractCandidate, defaultProfileRichnessThresholds, defaultSelectWinner, defaultStructuralRolloutPolicy, defaultToolDetectors, defineLeaderboard, definePersona, defineStrategy, delegate, depthStrategy, deterministicCompletion, discriminatingMeans, driverAgent, dumbDriver, equalKOnCost, extractLlmCallEvent, failuresAnalyst, fanout, filterAuthoredAsserts, finalizeBestDelivered, flatWidenGate, gitWorkspace, harvestCorpus, inProcessSandboxClient, inlineSandboxClient, jjWorkspace, leaderboard, localShell, loopCampaignDispatch, loopDispatch, loopUntil, mapSandboxEvent, mapSandboxToolEvent, modelAuthoredChecks, naiveDriver, observe, officialChecksFromMeta, openSandboxRun, pairwiseSignificance, panel, pickChampion, pipeline, printBenchmarkReport, probeSandboxCapabilities, profileRichnessFinding, promotionGate, refine, registerShape, registryScopeAnalyst, renderAnytimeTable, renderCorpusToInstructions, renderLeaderboardHtml, renderLeaderboardMarkdown, renderLeaderboardSvg, renderPairwiseMarkdown, renderReport, reportLoopUsage, resolveEntrySymbol, resolveSandboxClient, runAgentic, runBenchmark, runInWorkspace, runLoop, runPersonified, runStrategyEvolution, sample, sampleThenRefine, sandboxCheckRunner, sandboxSessionTraceSource, selectBestIndex, selectChampion, selectValidWinner, sentinelCompletion, serveCoordinationMcp, settledToIteration, spendFromUsageEvents, stopSentinel, strategyAuthorContract, streamAgentTurn, structuralRollout, sumSandboxUsage, superviseSurface, supervisorInstructions, trajectoryReport, verify, visibleCheckScore, watchTrace, widen };