import type { BoberConfig } from "../../config/schema.js"; import type { WorkflowArgs, ResumeCursor } from "./types.js"; import type { PlanSpec } from "../../contracts/spec.js"; import type { SprintContract } from "../../contracts/sprint-contract.js"; /** Prior on-disk state for a resumed run. The CALLER loads it (keeps build() pure). */ export interface PreloadedState { /** Prior plan spec — reused instead of re-planning on resume. */ spec?: PlanSpec; /** Prior sprint contracts — the interpreter skips the already-completed ones. */ contracts?: SprintContract[]; } /** * Marshals config + user prompt + resume cursor into a fully JSON-serializable * WorkflowArgs payload. * * Pure function — no fs / Date.now / Math.random inside build(). * Throws typed errors at build time before any agent is dispatched: * - MissingKnobError — a required knob is undefined * - AgentCapError — worst-case agent count exceeds 16/1000 caps * - NonSerializableArgError — args cannot round-trip through JSON */ export declare class ArgsPayloadBuilder { /** * @param userPrompt Plain-text user request passed verbatim to the workflow. * @param config Validated BoberConfig (all defaults already applied). * @param resumeCursor Pre-built cursor from ResumeCursorReconstructor. * @param principles Raw principles text (caller reads from disk; keep build pure). * @param preloaded Prior spec + contracts for a resumed run. The caller loads * these from disk (e.g. via loadSpec / listContracts) so build() stays pure. * The interpreter reuses the spec instead of re-planning and skips the * already-completed contracts named by `resumeCursor.completedSprintNumbers`. */ build(userPrompt: string, config: BoberConfig, resumeCursor: ResumeCursor, principles?: string, preloaded?: PreloadedState): WorkflowArgs; } //# sourceMappingURL=args-builder.d.ts.map