Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Visualization

The visualize module generates Mermaid diagrams and HTML exports for pipeline state.

PipelineGraph

flowchart TB
    subgraph Input
        W["Workflow.toml"]
        S["Pipeline State"]
    end
    
    subgraph Process
        G["PipelineGraph"]
        M["to_mermaid()"]
        H["to_html()"]
    end
    
    subgraph Output
        MD["Mermaid SVG"]
        HT["HTML + Mermaid.js"]
    end
    
    W --> G
    S --> G
    G --> M --> MD
    G --> H --> HT
#![allow(unused)]
fn main() {
pub struct PipelineGraph {
    pub nodes: HashMap<String, NodeVisualState>,
    pub edges: Vec<EdgeVisual>,
    pub current_state: String,
    pub accumulated_confidence: f32,
}
}

NodeVisualState

Visual states for pipeline nodes:

  • Idle: Waiting, not entered
  • Active: Currently executing
  • Success: Completed successfully
  • Warning: Recoverable issue
  • Error: Unrecoverable issue
  • Review: Awaiting human review

Mermaid Generation

#![allow(unused)]
fn main() {
let mermaid = graph.to_mermaid();
// Generates stateDiagram-v2
}

HTML Export

#![allow(unused)]
fn main() {
let html = to_html(&graph);
// Returns complete HTML with Mermaid.js
}

LayoutSolver

Kasuari-backed constraint solver for node positioning:

#![allow(unused)]
fn main() {
pub struct LayoutSolver;
pub fn generate_layout(&self, graph: &PipelineGraph) -> HashMap<String, (f32, f32)>;
}