/** * DryRunSimulator — Simulate a task DAG execution with zero side effects. * * Walks a TaskDAG using topological layers, produces per-node estimated * costs, permission requirements, and a synthetic TeamResult — without * touching adapters, the blackboard, or spending any budget. * * @module DryRunSimulator */ import type { DAGCostPrediction, CostModel, CostDAGNode } from './cost-governor'; /** Per-node simulation result */ export interface SimulatedNode { taskId: string; agent: string; action: string; estimatedTokens: number; confidence: number; dependencies: string[]; layer: number; } /** Full dry-run report */ export interface DryRunReport { /** Whether the plan could execute within budget constraints */ feasible: boolean; /** Human-readable summary */ summary: string; /** Per-node simulation */ nodes: SimulatedNode[]; /** Topological layers — tasks within a layer run in parallel */ layers: string[][]; /** Cost prediction from CostGovernor */ costPrediction: DAGCostPrediction; /** Total estimated wall-clock layers (sequential depth) */ parallelDepth: number; /** Maximum parallel width (largest layer size) */ maxParallelWidth: number; } /** Minimal DAG node with dependencies for topological ordering */ export interface DryRunNode extends CostDAGNode { dependencies: string[]; } /** Minimal budget interface (same as CostBudget) */ export interface DryRunBudget { remaining(): number; getCeiling(): number; getAgentSpent(agentId: string): number; getPerAgentCeiling(): number | undefined; } /** * Simulate a DAG execution plan without side effects. * * @example * ```ts * const sim = new DryRunSimulator(budget); * const report = sim.simulate(dag.nodes.map(n => ({ * id: n.id, agent: n.agent, action: n.action, * params: n.params, dependencies: n.dependencies, * }))); * console.log(report.summary); * ``` */ export declare class DryRunSimulator { private governor; constructor(budget: DryRunBudget, model?: CostModel); /** Replace the underlying cost model */ setCostModel(model: CostModel): void; /** * Simulate execution of a DAG. Returns a full report with cost predictions, * layer structure, and feasibility assessment. */ simulate(nodes: DryRunNode[]): DryRunReport; } //# sourceMappingURL=dry-run.d.ts.map