Diagram chart reference

Diagram examples

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

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

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

PathTypeRequiredMeaning
nodesarrayyesOne to 80 uniquely identified diagram nodes.
nodes[].idstringyesTrimmed identifier of at most 80 Unicode code points; control characters and the auto: prefix are reserved.
nodes[].kindstringyesSemantic 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[].shapeobjectyesNode outline or icon-only shape.
nodes[].shape.kind (nodes[].shape branch 1)stringyesSelect the rectangle node shape. One of 'rectangle'.
nodes[].shape.kind (nodes[].shape branch 2)stringyesSelect the roundedRect node shape. One of 'roundedRect'.
nodes[].shape.radius (nodes[].shape branch 2)numberCorner radius in layout pixels; omission uses the theme-scaled radius.
nodes[].shape.kind (nodes[].shape branch 3)stringyesSelect the circle node shape. One of 'circle'.
nodes[].shape.kind (nodes[].shape branch 4)stringyesSelect the pill node shape. One of 'pill'.
nodes[].shape.kind (nodes[].shape branch 5)stringyesSelect the chevron node shape. One of 'chevron'.
nodes[].shape.tip (nodes[].shape branch 5)numberChevron tip depth as a fraction of width; defaults to 0.16 and is capped by shape height.
nodes[].shape.kind (nodes[].shape branch 6)stringyesSelect the text node shape. One of 'text'.
nodes[].shape.kind (nodes[].shape branch 7)stringyesSelect the store node shape. One of 'store'.
nodes[].shape.kind (nodes[].shape branch 8)stringyesSelect the icon node shape. One of 'icon'.
nodes[].shape.name (nodes[].shape branch 8)stringyesName from the built-in icon catalog.
nodes[].shape.kind (nodes[].shape branch 9)stringyesSelect the roof node shape. One of 'roof'.
nodes[].shape.apex (nodes[].shape branch 9)numberHorizontal roof apex as a fraction of width; defaults to 0.5.
nodes[].shape.eaveInset (nodes[].shape branch 9)numberInset of each roof eave as a fraction of width; defaults to 0.
nodes[].labelstringyesPrimary visible node label, at most 200 Unicode code points.
nodes[].secondaryLabelstringSecondary line inside the node, at most 400 Unicode code points.
nodes[].captionstringSupporting caption placed near the node, at most 400 Unicode code points.
nodes[].iconstringOptional built-in icon displayed with the node label.
nodes[].badgeobjectBorder badge; long text uses a pill clear of the node label.
nodes[].badge.textstringyesBadge text, at most 200 Unicode code points.
nodes[].badge.rolestringVisual emphasis or semantic tone for this element. One of 'primary', 'accent', 'secondary', 'muted', 'good', 'bad', 'warn', 'category'.
nodes[].badge.paletteKeystringStable categorical color key; required only when role is category.
nodes[].rolestringVisual emphasis or semantic tone for this element. One of 'primary', 'accent', 'secondary', 'muted', 'good', 'bad', 'warn', 'category'.
nodes[].paletteKeystringStable categorical color key; required only when role is category.
nodes[].minSizeobjectMinimum node dimensions, also bounded below by measured content.
nodes[].minSize.widthnumberyesNode width in layout pixels.
nodes[].minSize.heightnumberyesNode height in layout pixels.
nodes[].sizeobjectRequested node dimensions; measured content and minSize remain lower bounds.
nodes[].size.widthnumberyesNode width in layout pixels.
nodes[].size.heightnumberyesNode height in layout pixels.
nodes[].positionobjectAuthored node position in normalized plot coordinates.
nodes[].position.xnumberyesHorizontal position as a fraction of the diagram plot width.
nodes[].position.ynumberyesVertical position as a fraction of the diagram plot height.
nodes[].portsarrayUp to 16 named connection ports, unique within this node.
nodes[].ports[].idstringyesTrimmed identifier of at most 80 Unicode code points; control characters and the auto: prefix are reserved.
nodes[].ports[].atobjectyesAuthored connection location on the node boundary.
nodes[].ports[].at.side (nodes[].ports[].at branch 1)stringyesSide of the node bounding rectangle used by this port. One of 'top', 'right', 'bottom', 'left'.
nodes[].ports[].at.offset (nodes[].ports[].at branch 1)numberFraction along the side from left to right or top to bottom; defaults to 0.5.
nodes[].ports[].at.perimeter (nodes[].ports[].at branch 2)numberyesFraction along the node bounding perimeter; 1 wraps to 0.
nodes[].ports[].intentstringAllowed edge direction: incoming, outgoing or both. One of 'in', 'out', 'bidi'.
nodes[].ports[].capacityintegerMaximum number of edge endpoints assigned to this port.
nodes[].groupIdstringId of an existing group containing this node.
nodes[].laneIdstringId of an existing lane containing this node. Architecture with flow 'lanes' requires it except on policy-strip nodes, which must omit it.
nodes[].orderintegerOrdering 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[].trackstringArchitecture only: named cross-axis track. Nodes in one track line up across zones or lanes.
nodes[].spanstringArchitecture only: a wide band across its lane, or a full-height rail in its zone. One of 'full'.
nodes[].repeatintegerArchitecture only: draws 2 to 5 stacked copies, for repeated workers.
nodes[].protectedbooleanArchitecture only: a lock and a double border. This is an authored claim.
edgesarrayUp to 160 uniquely identified links between distinct existing nodes.
edges[].idstringyesTrimmed identifier of at most 80 Unicode code points; control characters and the auto: prefix are reserved.
edges[].sourceobjectyesEdge origin: a node with an optional named output port, or a zone in variant architecture.
edges[].source.nodeId (edges[].source branch 1)stringyesId of the existing node at this edge endpoint.
edges[].source.portId (edges[].source branch 1)stringNamed port on the endpoint node; omission allows automatic port selection.
edges[].source.groupId (edges[].source branch 2)stringyesId of the existing zone whose frame this edge ends on.
edges[].targetobjectyesEdge destination: a node with an optional named input port, or a zone in variant architecture.
edges[].target.nodeId (edges[].target branch 1)stringyesId of the existing node at this edge endpoint.
edges[].target.portId (edges[].target branch 1)stringNamed port on the endpoint node; omission allows automatic port selection.
edges[].target.groupId (edges[].target branch 2)stringyesId of the existing zone whose frame this edge ends on.
edges[].routingstringRequested 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[].arrowStartbooleanWhether to draw an arrowhead at the source endpoint.
edges[].arrowEndbooleanWhether to draw an arrowhead at the target endpoint.
edges[].dashstringEdge stroke pattern. One of 'solid', 'dashed', 'dotted'.
edges[].weightstringTheme-scaled edge stroke weight. One of 'hairline', 'normal', 'strong'.
edges[].rolestringVisual emphasis or semantic tone for this element. One of 'primary', 'accent', 'secondary', 'muted', 'good', 'bad', 'warn', 'category'.
edges[].paletteKeystringStable categorical color key; required only when role is category.
edges[].labelstringOptional visible label, at most 200 Unicode code points.
edges[].waypointsarrayUp to 12 authored route waypoints in normalized plot coordinates.
edges[].waypoints[].xnumberyesHorizontal position as a fraction of the diagram plot width.
edges[].waypoints[].ynumberyesVertical position as a fraction of the diagram plot height.
edges[].flowstringArchitecture only: a return edge does not set the node order and may close a loop. Default forward. One of 'forward', 'return'.
groupsarrayUp to 32 named visual groups referenced by node.groupId.
groups[].idstringyesTrimmed identifier of at most 80 Unicode code points; control characters and the auto: prefix are reserved.
groups[].titlestringyesVisible group title, at most 200 Unicode code points.
groups[].paddingnumberSpace in layout pixels around the group members.
groups[].orderintegerAuthored ordering key used by the selected diagram variant.
groups[].rolestringVisual emphasis or semantic tone for this element. One of 'primary', 'accent', 'secondary', 'muted', 'good', 'bad', 'warn', 'category'.
groups[].paletteKeystringStable categorical color key; required only when role is category.
groups[].kindstringArchitecture only: a policy group is a strip across the exhibit, and its nodes take no edges. Default zone. One of 'zone', 'policy'.
groups[].parentIdstringArchitecture only: the zone this zone sits in, up to three levels.
groups[].protectedbooleanArchitecture only: a lock and a double frame. This is an authored claim.
lanesarrayUp to 32 named partitions referenced by node.laneId.
lanes[].idstringyesTrimmed identifier of at most 80 Unicode code points; control characters and the auto: prefix are reserved.
lanes[].labelstringOptional visible label, at most 200 Unicode code points.
lanes[].orientationstringyesLane direction in the diagram. customer-journey and roadmap, the variants that read lanes, refuse horizontal. One of 'horizontal', 'vertical'.
lanes[].orderintegerAuthored ordering key used by the selected diagram variant.
lanes[].rolestringVisual emphasis or semantic tone for this element. One of 'primary', 'accent', 'secondary', 'muted', 'good', 'bad', 'warn', 'category'.
lanes[].paletteKeystringStable categorical color key; required only when role is category.
keyarrayUp 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)stringyesThe node role whose fill this entry names. One of 'primary', 'accent', 'secondary', 'muted', 'good', 'bad', 'warn', 'category'.
key[].paletteKey (key[] branch 1)stringStable categorical color key; required only when role is category.
key[].label (key[] branch 1)stringyesWhat the fill means, at most 80 Unicode code points.
key[].line (key[] branch 2)stringyesThe edge style this entry names, drawn as the edges draw it. One of 'solid', 'dashed', 'dotted'.
key[].label (key[] branch 2)stringyesWhat the line style means, at most 80 Unicode code points.
channelsarrayArchitecture only: up to 16 shared labels, each for edges that cross one gutter.
channels[].idstringyesTrimmed identifier of at most 80 Unicode code points; control characters and the auto: prefix are reserved.
channels[].edgeIdsarrayyesIds of the edges this label names; they must cross one common gutter.
channels[].labelstringyesThe shared label, at most 80 Unicode code points.
calloutsarrayArchitecture only: up to 16 numbered discs, numbered in this order.
callouts[].idstringyesTrimmed identifier of at most 80 Unicode code points; control characters and the auto: prefix are reserved.
callouts[].targetobjectyesThe 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)stringyesId of the node this callout marks.
callouts[].target.edgeId (callouts[].target branch 2)stringyesId of the edge this callout marks.
callouts[].target.groupId (callouts[].target branch 3)stringyesId of the zone this callout marks.
callouts[].titlestringShort name in the key row, at most 80 Unicode code points.
callouts[].textstringExplanation in the key row, at most 200 Unicode code points.
insetobjectArchitecture only: a detail panel after a rule, beside the exhibit from 800 px and under it below that.
inset.titlestringyesPanel title, at most 80 Unicode code points.
inset.kpisarrayUp to 4 large numbers.
inset.kpis[].valuestringyesThe large number as text, at most 16 Unicode code points.
inset.kpis[].labelstringyesWhat the number means, at most 60 Unicode code points.
inset.rowsarrayUp to 12 short rows.
inset.rows[].labelstringyesRow name, at most 60 Unicode code points.
inset.rows[].valuestringyesRow value as text, at most 24 Unicode code points.
inset.headingfalsefalse draws no panel title, with its height and gap gone. The title stays the accessible name. One of false.
inset.columnOverridesobjectSettings of the rows' two columns: label, value.
inset.columnOverrides.*.widthnumberTrack width in px. It beats the width the type would pick.
inset.columnOverrides.*.alignstringAlignment 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

PathTypeValuesDefaultMeaning
variantstring'hierarchy', 'issue-tree', 'linear-process', 'customer-journey', 'circular-process', 'strategy-house', 'roadmap', 'architecture'Required structural layout variant for the diagram.
flowstring'columns', 'serpentine', 'lanes'Layout flow: columns or serpentine for customer-journey, columns or lanes for architecture.
heightFillstring'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.
highlightstring | arrayArchitecture 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

IDKindUse case
org-structureexampleA three-level operating model keeps decision ownership visible
profit-issue-treeexampleA four-column issue tree decomposes the profit question
transformation-processexampleFive equal chevrons show the transformation sequence
onboarding-journeyexampleFive phase lanes organize eight onboarding pain points
operating-cycleexampleFour icon nodes form a complete clockwise operating cycle
strategy-houseexampleThe strategy house renders one roof, three beams, six pillars, and three base bands
growth-roadmapexampleThree phase lanes carry nine milestones on a monotone trajectory
deep-hierarchytortureDeep hierarchy torture case
single-nodetortureSingle-node diagram torture case
single-issuetortureSingle-node issue-tree torture case
longest-labelstortureLong labels exercise wrapping without shrinking type
sparse-journeytortureSparse journey preserves explicit empty phases
single-step-circletortureSingle-step circular-process degenerate case
two-step-circletortureTwo-step circular-process degenerate case
authored-routingtortureAuthored positions, ports, waypoints, and edge styles
onboarding-journey-serpentinetortureOnboarding phases wrap into a two-row reading path
org-structure-theme-ringtortureSquare nodes on the panel with a hairline ring, only the accent node filled
torture-long-labelstortureTorture: long names at a generous size read whole, never cut
onboarding-journey-at-risktortureOnboarding journey with an at-risk phase and critical and at-risk pain points named in a key
onboarding-fix-plan-samplertorturePhase lanes, pain points and badges in every role, each color named once in the key
portfolio-health-samplertortureSeven workstreams framed by health under three programs, every edge style named in a key
division-groupstortureTwo sibling division groups whose heads take their tree edge from above
long-secondary-readingtortureLong secondary text remains available in the reading
four-child-start-arrowtortureA start arrow clears a neighboring group frame
stacked-leaf-captionstortureEvery stacked leaf keeps its caption
long-border-badgestortureLong badge phrases keep clear of node labels
protected-requestexampleA request stays protected on its way to private processing and back
marketing-pipelineexampleRejected records return to the source for repair
journey-attributionexampleMulti-touch attribution from customer journey to budget
nested-serviceexampleA service nested three levels deep, with one protected runtime
agent-approvalexampleAn agent reaches its tools through an approval gate
pipeline-healthexampleA data pipeline with its service levels beside it
long-namestortureLong names keep every word at every width
twenty-node-platformtortureTwenty nodes and thirty edges across four zones
inset-no-headingexampleAn inset without its title, with authored column widths and alignment

Not for

Quantities to compare; node size and edges encode no values.