import type { ModelGraph } from "../loader/model-graph.js"; /** * Renders a Flow (e.g. C1) as a mermaid `flowchart`, per Decision record * 004 技术点 5 (Phase 1, C1 only — proposal 001 §12 success-criteria * scope, not all 9 Flows). Structure: * * - Nodes: the Flow itself, every Loop in `traverses`/`guarded_by`, and * every node referenced by a crossing Junction's `between` (covers * Loops that aren't in `traverses`/`guarded_by` at all, e.g. a * junction linking two loops outside this flow's primary chain). * `between` accepts a FlowId as well as a LoopId (Proposal 016 T4 — a * Loop↔Flow or Flow↔Flow handoff is expressible), so an endpoint's * title is resolved against BOTH tables; a loop-only lookup left every * flow endpoint rendered as a bare, untitled `C10["C10: C10"]` box. * - Edges: `traverses` rendered as the plain forward sequence; each * `guarded_by` Loop as a dashed "guards" edge into the Flow node * (flow-level watchdog coverage, not tied to one step); each crossing * Junction as its OWN dashed edge, drawn literally from * `junction.between[0]` to `junction.between[1]` and labeled with the * junction id + risk_class. * * The junction edges are deliberately NOT inferred by walking * `traverses` as a forward chain and matching adjacent pairs — real flow * data has junctions that aren't forward-adjacent traversal steps at all * (a projection junction can be a backward edge from the last traverses * step to an earlier one; a watchdog junction can link a `guarded_by` * loop to a traverses step, not two traverses steps). Inferring from * adjacency would silently drop both — 2 of the 5 risk classes * (projection, watchdog). Drawing every * junction from its own literal `between` pair, unconditionally, can't * drop any of them. */ export declare function renderFlowMermaid(graph: ModelGraph, flowId: string): string; //# sourceMappingURL=flow-mermaid.d.ts.map