/** * Deps wiring for the CLI: the configuration objects are real; the roles * are not implemented yet and are stubbed with proxies that throw a * NotImplementedError naming the exact method that was reached. This * makes the walking skeleton honest: a run wires everything, validates * its inputs, and fails at the FIRST role call with a precise pointer to * the next thing to implement. */ import { type Escalation } from "./escalation.js"; import { type RunHistory } from "./run-history.js"; import { type LoadedProjectConfig, type ProjectSettings } from "./project-config.js"; import { type ImplementFeatureDeps } from "./shared.js"; import type { LoadedTemplate } from "./template-descriptor.js"; import { NotImplementedError } from "./types.js"; export { NotImplementedError }; /** * A role whose data fields (discriminants, job names) are real but whose * every method throws NotImplementedError. */ export declare function stubRole(name: string, fields?: Record): T; /** * A run that stops and flags is waiting for a person, so the report has * to reach one. The console always gets it; a project that configured * escalation.webhookUrl gets it delivered too, for the long unattended * runs where nobody is watching the terminal. */ export declare function escalationTo(settings?: ProjectSettings, runHistory?: RunHistory): Escalation; /** * Best-effort delivery. The run has ALREADY stopped by the time this is * called and the console already carries the full situation, so every * failure here is reported and swallowed: a bad webhook URL must never * become the thing that hides why the run stopped. */ export declare function postEscalation(webhookUrl: string, situation: string, projectName?: string): Promise; /** * Real configuration, stubbed roles. Replace stubs as roles get built. * Three layers configure the run, later layers overriding earlier ones: * built-ins ← the TEMPLATE's descriptor (farketari/template.json under * the --example path) ← the PROJECT's farketari.ts. CLI flags override * all three per run (resolved in cli.ts before this is called). */ export declare function buildDeps(template?: LoadedTemplate, project?: LoadedProjectConfig): ImplementFeatureDeps; /** * Real configuration AND real roles: buildDeps with every stub replaced * by its Claude-backed (or deterministic) implementation. The CLI's * implement command runs on this; buildDeps stays stubbed for library * users and tests that supply their own roles. * * `examplePath` is required here (not just at implementFeature) because * roles resolve INTERNAL work orders (context.orderFor) for hybrid * executors — a local acceptance run judging its own failure — and a * work order without the example path could cite nothing. */ export declare function buildLiveDeps(repoRoot: string, examplePath: string, template?: LoadedTemplate, project?: LoadedProjectConfig): ImplementFeatureDeps;