/** * Dependency edges discovered during authoring are reconciled into the * manifest, not raised as findings. * * A finding is a problem someone must resolve. A discovered edge is not a * problem — if a spec consumes another workstream's output then the edge * exists, and the manifest is simply out of date. Correcting it is * transcription, and routing transcription through a human gate is what made * every validation run stall on "WS-07 depends on WS-03, go fix the * manifest". * * Exactly two outcomes still belong to a human, and neither is about an edge: * * - **A cycle.** Two workstreams that depend on each other are not badly * recorded, they are badly decomposed — they are one workstream, or the * split is in the wrong place. No manifest edit fixes that. * - **An unmet requirement.** Work the program needs and no workstream * provides is missing scope, which is a planning decision. * * Everything else merges and is logged. */ export interface DeclaredEdges { workstreamId: string; dependencies: string[]; needs: string[]; unmet: string[]; } export interface DependencyEdge { workstreamId: string; dependsOn: string; } export interface UnmetRequirement { workstreamId: string; requirement: string; } export interface ReconcileInput { workstreams: Array<{ id: string; dependencies: string[]; }>; declarations: DeclaredEdges[]; } export interface ReconcileResult { /** Merged dependency lists, keyed by workstream id. */ dependencies: Map; /** Edges that were missing from the manifest and have now been merged. */ added: DependencyEdge[]; /** Declared edges naming a workstream the manifest does not contain. */ unknown: DependencyEdge[]; /** Cycles in the merged graph; empty when the merge stays acyclic. */ cycles: string[][]; /** Workstreams that asked to be re-authored with a dependency's spec. */ needs: Array<{ workstreamId: string; dependsOn: string[]; }>; unmet: UnmetRequirement[]; } export declare function reconcileDependencies(input: ReconcileInput): ReconcileResult; /** * Persist merged dependency lists to the manifest, preserving every other * field and the file's key order. Only workstreams present in `dependencies` * are touched. */ export declare function writeMergedDependencies(manifestPath: string, dependencies: Map): Promise; /** Human-readable edge list for progress output and failure reasons. */ export declare function describeEdges(edges: DependencyEdge[]): string; //# sourceMappingURL=reconcile-dependencies.d.ts.map