Flowchart
Flowchart
A flowchart shows a process as steps connected by arrows. kymo reads the
Mermaid flowchart / graph
syntax — a diagram you already have in Mermaid works unchanged.
This page works like a quickstart: as you scroll, the pane on the right shows the source and the rendered result for the section you're reading. Copy grabs the source; ▶ Open in editor loads it into editor.kymo.studio (pick mermaid in the diagram-type dropdown when starting from scratch).
The example on the right is a complete approval flow: a start/end terminal, a decision with two labelled exits, and a merge back to a single end node — seven lines of text.
flowchart TD
Start((Start)) --> Submit[Submit request]
Submit --> Review{Approved?}
Review -->|yes| Provision[Provision]
Review -->|no| Reject[Reject]
Provision --> Done((Done))
Reject --> Done
Direction
The header names the diagram type (flowchart and graph are synonyms) and an
optional direction:
Node shapes
A node is an identifier plus an optional label wrapped in shape delimiters.
Without delimiters (A --> B), the node renders as a rectangle labelled with
its own id.
Labels may be double-quoted to include characters that would otherwise close
the shape: A["a label with (parens)"].
Mermaid's trapezoid (
[/ /],[\ \]) and double-circle (((( )))) shapes are not supported yet — the parser reports a syntax error.
flowchart LR
A[Rect] --> B(Rounded)
B ==> C([Stadium])
C -.-> D[(Database)]
D --- E((Circle))
E --> F{Decision}
F -->|ok| G{{Hexagon}}
G --> H[[Subroutine]]
Links between nodes
A link is two nodes joined by an edge operator. kymo distinguishes solid vs dashed and arrow vs plain line:
Label an edge with pipes right after the operator, as the example shows:
B -->|yes| C.
Links chain on a single line; each operator connects the two nodes around it:
The
&fan-out shorthand (A & B --> C) and Mermaid's inline label form (A -- text --> B) are not supported — use one link per line and the|text|label form instead.
flowchart TD
A[Submit] --> B{Approved?}
B -->|yes| C[Provision]
B -->|no| D[Reject]
C -.-> E[Audit log]
D --- E
Subgraphs
subgraph … end groups nodes into a labelled container. The id and the title
are both optional (subgraph Title, subgraph id [Title], or a bare
subgraph), titles may be quoted, and subgraphs nest.
A direction statement inside a subgraph is accepted but ignored — the whole
diagram flows in the header direction.
flowchart TB
Start --> A
subgraph G [Worker Pool]
A[Fetch] --> B[Transform]
B --> C[Write]
end
C --> End[Done]
Comments
Lines starting with %% are comments:
Rendering from the command line
The same sources render locally with the kymo CLI — identical syntax, no
browser. Save as a .mmd (or .mermaid) file; the CLI ships in all three
distributions (PyPI,
npm,
crates.io):
The flowchart pipeline is format-neutral — kymo also imports
D2 and Graphviz DOT sources
(kymo flow.d2 flow.svg, kymo flow.dot flow.svg), and exports to other
diagram-as-code formats:
The Python CLI additionally offers --animate (animated SVG), --excalidraw,
and --figma targets — see the Getting Started guide.
Differences from Mermaid
kymo implements the structural core of the flowchart grammar. Styling and
interactivity directives are not supported and are reported as syntax
errors: style, classDef, class, click, and linkStyle. Keep sources to
nodes, links, subgraphs, and comments.
Also note that the inline edge-label form (A -- text --> B) is currently
mis-read as a chain through a node named text — always label edges with the
|text| form.
See also
- Sequence Diagram — the second Mermaid diagram type kymo imports.
- Flowchart Notation (ISO 5807) — background reference on classic flowchart symbols and conventions.
- Best Practices — layout and readability guidance.