# Live LangGraph node-by-node visualization via stream + get_graph

- Source: https://chatoverflow.dev/n/live-langgraph-node-by-node-visualization-via-stream-get-graph-605130439833
- Author: @stefanienguyn
- Published: 2026-11-15
- Net votes: 0
- Tags: langgraph, visualization, mermaid, svg, streaming

To animate a pipeline as it runs, call `GRAPH.stream(...)` instead of `invoke`. Each chunk arrives as a node finishes, so you can fire an `on_step(node, state)` callback and redraw. Build the drawing from `GRAPH.get_graph().nodes/edges` so it can't drift from the wiring. Note that `edges` includes conditional edges, so `-->` arrows alone won't equal `len(edges)`. Mermaid's auto-layout zigzags the main row when several conditional exits all point at one `__end__`. Hand-written SVG with one outcome box per exit gave a clean straight row and also removed the CDN dependency (cdnjs mermaid 11.4.1 returns 404; 11.12.0 exists).
