Diagram chart reference
Contents: Use cases, Design, Chart IDs, Minimal spec, Data, Options, Annotations, Sizing, Fixtures, Not for.
Deterministic node-edge diagrams with eight consulting presets, obstacle-aware routing, and structural descriptions. Type diagram.
Use cases
- Process or organization flow
- Driver tree or value chain
- Organization chart
- System architecture and data flow
- Trust boundaries and protected zones
Design
Message: How parts connect: a structure, a process, or a system and its data flows.
Use when: The links between the parts are the message, such as an organization, a driver tree, a process or a system architecture with variant: architecture.
Not when: The message is a number or a change (a chart); the items only rank (bar or table); dated work over time (gantt or the roadmap variant).
design-diagram-variant
Pick the variant that matches the links: architecture for systems, data flow and trust boundaries; linear-process for steps; hierarchy for reporting lines. This rule needs the author's judgment; render does not check it.
design-diagram-title
Write the finding in the title, such as "Only the protected runtime reads the keys", not the name of the system. This rule needs the author's judgment; render does not check it.
design-diagram-one-focus
Mark one node or path with options.highlight, so the reader sees the message first and the structure second. This rule needs the author's judgment; render does not check it.
design-diagram-size
Keep an exhibit to about 20 nodes; split a larger system into one overview and detail exhibits. This rule needs the author's judgment; render does not check it.
design-diagram-return
Set flow: return on a feedback edge, so it stays out of the node order and on the outer corridors. This rule needs the author's judgment; render does not check it.
design-diagram-protected
Set protected only where the claim is true: the lock states that the zone is protected, and the engine cannot check it. This rule needs the author's judgment; render does not check it.
Chart IDs
diagram.hierarchy: fixtureorg-structurediagram.issue-tree: fixtureprofit-issue-treediagram.linear-process: fixturetransformation-processdiagram.customer-journey: fixtureonboarding-journeydiagram.circular-process: fixtureoperating-cyclediagram.strategy-house: fixturestrategy-housediagram.roadmap: fixturegrowth-roadmapdiagram.architecture: fixtureprotected-request
Minimal spec
{
"type": "diagram",
"data": {
"nodes": [
{ "id": "draft", "kind": "step", "shape": { "kind": "rectangle" }, "label": "Draft" },
{ "id": "review", "kind": "step", "shape": { "kind": "rectangle" }, "label": "Review" }
],
"edges": [
{
"id": "next",
"source": { "nodeId": "draft" },
"target": { "nodeId": "review" },
"arrowEnd": true
}
]
},
"options": { "variant": "linear-process", "title": "Review follows drafting", "source": "Illustrative data" }
}Data
| Path | Type | Required | Meaning |
|---|---|---|---|
| nodes | array | yes | One to 80 uniquely identified diagram nodes. |
| nodes[].id | string | yes | Trimmed identifier of at most 80 Unicode code points; control characters and the auto: prefix are reserved. |
| nodes[].kind | string | yes | Semantic node kind. Each variant reads: hierarchy 'entity'; issue-tree 'issue' or 'driver'; linear-process and circular-process 'step'; customer-journey 'painPoint'; roadmap 'milestone'. Another kind is refused with invalid-diagram-kind. strategy-house and architecture do not check the kind. One of 'entity', 'issue', 'driver', 'step', 'painPoint', 'vision', 'objective', 'initiative', 'enabler', 'foundation', 'milestone', 'callout'. |
| nodes[].shape | object | yes | Node outline or icon-only shape. |
| nodes[].shape.kind (nodes[].shape branch 1) | string | yes | Select the rectangle node shape. One of 'rectangle'. |
| nodes[].shape.kind (nodes[].shape branch 2) | string | yes | Select the roundedRect node shape. One of 'roundedRect'. |
| nodes[].shape.radius (nodes[].shape branch 2) | number | Corner radius in layout pixels; omission uses the theme-scaled radius. | |
| nodes[].shape.kind (nodes[].shape branch 3) | string | yes | Select the circle node shape. One of 'circle'. |
| nodes[].shape.kind (nodes[].shape branch 4) | string | yes | Select the pill node shape. One of 'pill'. |
| nodes[].shape.kind (nodes[].shape branch 5) | string | yes | Select the chevron node shape. One of 'chevron'. |
| nodes[].shape.tip (nodes[].shape branch 5) | number | Chevron tip depth as a fraction of width; defaults to 0.16 and is capped by shape height. | |
| nodes[].shape.kind (nodes[].shape branch 6) | string | yes | Select the text node shape. One of 'text'. |
| nodes[].shape.kind (nodes[].shape branch 7) | string | yes | Select the store node shape. One of 'store'. |
| nodes[].shape.kind (nodes[].shape branch 8) | string | yes | Select the icon node shape. One of 'icon'. |
| nodes[].shape.name (nodes[].shape branch 8) | string | yes | Name from the built-in icon catalog. |
| nodes[].shape.kind (nodes[].shape branch 9) | string | yes | Select the roof node shape. One of 'roof'. |
| nodes[].shape.apex (nodes[].shape branch 9) | number | Horizontal roof apex as a fraction of width; defaults to 0.5. | |
| nodes[].shape.eaveInset (nodes[].shape branch 9) | number | Inset of each roof eave as a fraction of width; defaults to 0. | |
| nodes[].label | string | yes | Primary visible node label, at most 200 Unicode code points. |
| nodes[].secondaryLabel | string | Secondary line inside the node, at most 400 Unicode code points. | |
| nodes[].caption | string | Supporting caption placed near the node, at most 400 Unicode code points. | |
| nodes[].icon | string | Optional built-in icon displayed with the node label. | |
| nodes[].badge | object | Border badge; long text uses a pill clear of the node label. | |
| nodes[].badge.text | string | yes | Badge text, at most 200 Unicode code points. |
| nodes[].badge.role | string | Visual emphasis or semantic tone for this element. One of 'primary', 'accent', 'secondary', 'muted', 'good', 'bad', 'warn', 'category'. | |
| nodes[].badge.paletteKey | string | Stable categorical color key; required only when role is category. | |
| nodes[].role | string | Visual emphasis or semantic tone for this element. One of 'primary', 'accent', 'secondary', 'muted', 'good', 'bad', 'warn', 'category'. | |
| nodes[].paletteKey | string | Stable categorical color key; required only when role is category. | |
| nodes[].minSize | object | Minimum node dimensions, also bounded below by measured content. | |
| nodes[].minSize.width | number | yes | Node width in layout pixels. |
| nodes[].minSize.height | number | yes | Node height in layout pixels. |
| nodes[].size | object | Requested node dimensions; measured content and minSize remain lower bounds. | |
| nodes[].size.width | number | yes | Node width in layout pixels. |
| nodes[].size.height | number | yes | Node height in layout pixels. |
| nodes[].position | object | Authored node position in normalized plot coordinates. | |
| nodes[].position.x | number | yes | Horizontal position as a fraction of the diagram plot width. |
| nodes[].position.y | number | yes | Vertical position as a fraction of the diagram plot height. |
| nodes[].ports | array | Up to 16 named connection ports, unique within this node. | |
| nodes[].ports[].id | string | yes | Trimmed identifier of at most 80 Unicode code points; control characters and the auto: prefix are reserved. |
| nodes[].ports[].at | object | yes | Authored connection location on the node boundary. |
| nodes[].ports[].at.side (nodes[].ports[].at branch 1) | string | yes | Side of the node bounding rectangle used by this port. One of 'top', 'right', 'bottom', 'left'. |
| nodes[].ports[].at.offset (nodes[].ports[].at branch 1) | number | Fraction along the side from left to right or top to bottom; defaults to 0.5. | |
| nodes[].ports[].at.perimeter (nodes[].ports[].at branch 2) | number | yes | Fraction along the node bounding perimeter; 1 wraps to 0. |
| nodes[].ports[].intent | string | Allowed edge direction: incoming, outgoing or both. One of 'in', 'out', 'bidi'. | |
| nodes[].ports[].capacity | integer | Maximum number of edge endpoints assigned to this port. | |
| nodes[].groupId | string | Id of an existing group containing this node. | |
| nodes[].laneId | string | Id of an existing lane containing this node. Architecture with flow 'lanes' requires it except on policy-strip nodes, which must omit it. | |
| nodes[].order | integer | Ordering key: nodes sort by order, a node without one by its 0-based position in nodes, ties by id. Automatic step numbers follow this order. | |
| nodes[].track | string | Architecture only: named cross-axis track. Nodes in one track line up across zones or lanes. | |
| nodes[].span | string | Architecture only: a wide band across its lane, or a full-height rail in its zone. One of 'full'. | |
| nodes[].repeat | integer | Architecture only: draws 2 to 5 stacked copies, for repeated workers. | |
| nodes[].protected | boolean | Architecture only: a lock and a double border. This is an authored claim. | |
| edges | array | Up to 160 uniquely identified links between distinct existing nodes. | |
| edges[].id | string | yes | Trimmed identifier of at most 80 Unicode code points; control characters and the auto: prefix are reserved. |
| edges[].source | object | yes | Edge origin: a node with an optional named output port, or a zone in variant architecture. |
| edges[].source.nodeId (edges[].source branch 1) | string | yes | Id of the existing node at this edge endpoint. |
| edges[].source.portId (edges[].source branch 1) | string | Named port on the endpoint node; omission allows automatic port selection. | |
| edges[].source.groupId (edges[].source branch 2) | string | yes | Id of the existing zone whose frame this edge ends on. |
| edges[].target | object | yes | Edge destination: a node with an optional named input port, or a zone in variant architecture. |
| edges[].target.nodeId (edges[].target branch 1) | string | yes | Id of the existing node at this edge endpoint. |
| edges[].target.portId (edges[].target branch 1) | string | Named port on the endpoint node; omission allows automatic port selection. | |
| edges[].target.groupId (edges[].target branch 2) | string | yes | Id of the existing zone whose frame this edge ends on. |
| edges[].routing | string | Requested edge path style. curved draws only in circular-process; other variants draw it orthogonal with diagram-route-degraded. One of 'straight', 'elbow', 'orthogonal', 'curved'. | |
| edges[].arrowStart | boolean | Whether to draw an arrowhead at the source endpoint. | |
| edges[].arrowEnd | boolean | Whether to draw an arrowhead at the target endpoint. | |
| edges[].dash | string | Edge stroke pattern. One of 'solid', 'dashed', 'dotted'. | |
| edges[].weight | string | Theme-scaled edge stroke weight. One of 'hairline', 'normal', 'strong'. | |
| edges[].role | string | Visual emphasis or semantic tone for this element. One of 'primary', 'accent', 'secondary', 'muted', 'good', 'bad', 'warn', 'category'. | |
| edges[].paletteKey | string | Stable categorical color key; required only when role is category. | |
| edges[].label | string | Optional visible label, at most 200 Unicode code points. | |
| edges[].waypoints | array | Up to 12 authored route waypoints in normalized plot coordinates. | |
| edges[].waypoints[].x | number | yes | Horizontal position as a fraction of the diagram plot width. |
| edges[].waypoints[].y | number | yes | Vertical position as a fraction of the diagram plot height. |
| edges[].flow | string | Architecture only: a return edge does not set the node order and may close a loop. Default forward. One of 'forward', 'return'. | |
| groups | array | Up to 32 named visual groups referenced by node.groupId. | |
| groups[].id | string | yes | Trimmed identifier of at most 80 Unicode code points; control characters and the auto: prefix are reserved. |
| groups[].title | string | yes | Visible group title, at most 200 Unicode code points. |
| groups[].padding | number | Space in layout pixels around the group members. | |
| groups[].order | integer | Authored ordering key used by the selected diagram variant. | |
| groups[].role | string | Visual emphasis or semantic tone for this element. One of 'primary', 'accent', 'secondary', 'muted', 'good', 'bad', 'warn', 'category'. | |
| groups[].paletteKey | string | Stable categorical color key; required only when role is category. | |
| groups[].kind | string | Architecture only: a policy group is a strip across the exhibit, and its nodes take no edges. Default zone. One of 'zone', 'policy'. | |
| groups[].parentId | string | Architecture only: the zone this zone sits in, up to three levels. | |
| groups[].protected | boolean | Architecture only: a lock and a double frame. This is an authored claim. | |
| lanes | array | Up to 32 named partitions referenced by node.laneId. | |
| lanes[].id | string | yes | Trimmed identifier of at most 80 Unicode code points; control characters and the auto: prefix are reserved. |
| lanes[].label | string | Optional visible label, at most 200 Unicode code points. | |
| lanes[].orientation | string | yes | Lane direction in the diagram. customer-journey and roadmap, the variants that read lanes, refuse horizontal. One of 'horizontal', 'vertical'. |
| lanes[].order | integer | Authored ordering key used by the selected diagram variant. | |
| lanes[].role | string | Visual emphasis or semantic tone for this element. One of 'primary', 'accent', 'secondary', 'muted', 'good', 'bad', 'warn', 'category'. | |
| lanes[].paletteKey | string | Stable categorical color key; required only when role is category. | |
| key | array | Up to 8 entries naming what a node fill or an edge line style means, drawn as the diagram key above the plot; a good, bad or warn node fill needs one, and so does a dashed or dotted edge. | |
| key[].role (key[] branch 1) | string | yes | The node role whose fill this entry names. One of 'primary', 'accent', 'secondary', 'muted', 'good', 'bad', 'warn', 'category'. |
| key[].paletteKey (key[] branch 1) | string | Stable categorical color key; required only when role is category. | |
| key[].label (key[] branch 1) | string | yes | What the fill means, at most 80 Unicode code points. |
| key[].line (key[] branch 2) | string | yes | The edge style this entry names, drawn as the edges draw it. One of 'solid', 'dashed', 'dotted'. |
| key[].label (key[] branch 2) | string | yes | What the line style means, at most 80 Unicode code points. |
| channels | array | Architecture only: up to 16 shared labels, each for edges that cross one gutter. | |
| channels[].id | string | yes | Trimmed identifier of at most 80 Unicode code points; control characters and the auto: prefix are reserved. |
| channels[].edgeIds | array | yes | Ids of the edges this label names; they must cross one common gutter. |
| channels[].label | string | yes | The shared label, at most 80 Unicode code points. |
| callouts | array | Architecture only: up to 16 numbered discs, numbered in this order. | |
| callouts[].id | string | yes | Trimmed identifier of at most 80 Unicode code points; control characters and the auto: prefix are reserved. |
| callouts[].target | object | yes | The node, edge or zone that carries the number. Each target takes one callout. In flow 'lanes', a zone must contain a node. |
| callouts[].target.nodeId (callouts[].target branch 1) | string | yes | Id of the node this callout marks. |
| callouts[].target.edgeId (callouts[].target branch 2) | string | yes | Id of the edge this callout marks. |
| callouts[].target.groupId (callouts[].target branch 3) | string | yes | Id of the zone this callout marks. |
| callouts[].title | string | Short name in the key row, at most 80 Unicode code points. | |
| callouts[].text | string | Explanation in the key row, at most 200 Unicode code points. | |
| inset | object | Architecture only: a detail panel after a rule, beside the exhibit from 800 px and under it below that. | |
| inset.title | string | yes | Panel title, at most 80 Unicode code points. |
| inset.kpis | array | Up to 4 large numbers. | |
| inset.kpis[].value | string | yes | The large number as text, at most 16 Unicode code points. |
| inset.kpis[].label | string | yes | What the number means, at most 60 Unicode code points. |
| inset.rows | array | Up to 12 short rows. | |
| inset.rows[].label | string | yes | Row name, at most 60 Unicode code points. |
| inset.rows[].value | string | yes | Row value as text, at most 24 Unicode code points. |
| inset.heading | false | false draws no panel title, with its height and gap gone. The title stays the accessible name. One of false. | |
| inset.columnOverrides | object | Settings of the rows' two columns: label, value. | |
| inset.columnOverrides.*.width | number | Track width in px. It beats the width the type would pick. | |
| inset.columnOverrides.*.align | string | Alignment of the column: its cell text and, unless headAlign is set, its head. Bars keep starting at the panel origin. One of 'left', 'right', 'center'. |
Options
| Path | Type | Values | Default | Meaning |
|---|---|---|---|---|
| variant | string | 'hierarchy', 'issue-tree', 'linear-process', 'customer-journey', 'circular-process', 'strategy-house', 'roadmap', 'architecture' | Required structural layout variant for the diagram. | |
| flow | string | 'columns', 'serpentine', 'lanes' | Layout flow: columns or serpentine for customer-journey, columns or lanes for architecture. | |
| heightFill | string | 'rows', 'none' | 'rows' | Spare canvas height, read by hierarchy (org chart) and customer-journey. 'rows' (default): a canvas with a set height grows the gaps between the levels up to 2.6 times. 'none': natural gaps, the block centered. |
| highlight | string | array | Architecture only: the node and edge ids that carry the message. They take the accent, and everything else recedes. |
Plus the shared options. This type does not accept belowMinimum, unit, unitShown, strings, format, detailFields, smallValues, labelDensity, labels, labelPosition, labelPlacements, labelOffsets, legend, valueAxis, scaleGroup, story, focus, hatchStrength, rounding, annotations. This type ignores animate, debug, rowLabels, categoryAxis, categoryLabels, secondaryAxis, sort, topN, bandFraction, valueAxis.show, valueAxis.gridlines with an option-ignored warning.
Annotations
This type takes no annotations.
Sizing
Floor 280 × 160 px; fit content.
Below the floor a render is refused with size-below-floor and the pixels it needs. measure returns the natural and comfortable size for a given spec; see Sizing in the manual.
Fixtures
| ID | Kind | Use case |
|---|---|---|
| org-structure | example | A three-level operating model keeps decision ownership visible |
| profit-issue-tree | example | A four-column issue tree decomposes the profit question |
| transformation-process | example | Five equal chevrons show the transformation sequence |
| onboarding-journey | example | Five phase lanes organize eight onboarding pain points |
| operating-cycle | example | Four icon nodes form a complete clockwise operating cycle |
| strategy-house | example | The strategy house renders one roof, three beams, six pillars, and three base bands |
| growth-roadmap | example | Three phase lanes carry nine milestones on a monotone trajectory |
| deep-hierarchy | torture | Deep hierarchy torture case |
| single-node | torture | Single-node diagram torture case |
| single-issue | torture | Single-node issue-tree torture case |
| longest-labels | torture | Long labels exercise wrapping without shrinking type |
| sparse-journey | torture | Sparse journey preserves explicit empty phases |
| single-step-circle | torture | Single-step circular-process degenerate case |
| two-step-circle | torture | Two-step circular-process degenerate case |
| authored-routing | torture | Authored positions, ports, waypoints, and edge styles |
| onboarding-journey-serpentine | torture | Onboarding phases wrap into a two-row reading path |
| org-structure-theme-ring | torture | Square nodes on the panel with a hairline ring, only the accent node filled |
| torture-long-labels | torture | Torture: long names at a generous size read whole, never cut |
| onboarding-journey-at-risk | torture | Onboarding journey with an at-risk phase and critical and at-risk pain points named in a key |
| onboarding-fix-plan-sampler | torture | Phase lanes, pain points and badges in every role, each color named once in the key |
| portfolio-health-sampler | torture | Seven workstreams framed by health under three programs, every edge style named in a key |
| division-groups | torture | Two sibling division groups whose heads take their tree edge from above |
| long-secondary-reading | torture | Long secondary text remains available in the reading |
| four-child-start-arrow | torture | A start arrow clears a neighboring group frame |
| stacked-leaf-captions | torture | Every stacked leaf keeps its caption |
| long-border-badges | torture | Long badge phrases keep clear of node labels |
| protected-request | example | A request stays protected on its way to private processing and back |
| marketing-pipeline | example | Rejected records return to the source for repair |
| journey-attribution | example | Multi-touch attribution from customer journey to budget |
| nested-service | example | A service nested three levels deep, with one protected runtime |
| agent-approval | example | An agent reaches its tools through an approval gate |
| pipeline-health | example | A data pipeline with its service levels beside it |
| long-names | torture | Long names keep every word at every width |
| twenty-node-platform | torture | Twenty nodes and thirty edges across four zones |
| inset-no-heading | example | An inset without its title, with authored column widths and alignment |
Not for
Quantities to compare; node size and edges encode no values.