Skip to contentSkip to Content
Research and Learning LabArchitecture diagrams

Architecture diagrams

Draft

Diagrams on this site are authored as Mermaid source inside the page. This records the conventions and collects diagrams that do not belong to any single subject page.

Why source rather than images

A rendered image cannot be diffed, corrected, searched or restyled. Source can.

PropertyImageMermaid source
Version controlA binary blob; changes are invisible in a diffText; changes are reviewable
CorrectionRequires the original tool and fileEdit the page
ThemingFixed; usually wrong in one of light or dark modeRendered to match the reader’s theme
SearchableNoYes, the labels are text
AccessibilityNeeds separate alt textText is present in the source

The theming point is practical rather than aesthetic. A diagram exported with a white background is unreadable in dark mode, and this site renders in whichever theme the reader has chosen.

When a diagram earns its place

A diagram that restates the surrounding prose should be deleted. The test is whether it shows something the text cannot say as compactly.

Good: a decision structure
Branching logic with several conditions is genuinely hard to follow in prose and clear as a flowchart.
Good: a loop or feedback path
Cycles are awkward in linear text and immediate in a diagram.
Good: a pipeline with branches
A processing chain where different paths are taken under different conditions.
Bad: a list drawn as boxes
If the content is a sequence with no branching, it is a list. Write the list.
Bad: a diagram of the page structure
The reader can see the headings.

One diagram per mechanism, not one per page. Several pages on this site have a single diagram because they contain a single mechanism worth drawing, and a page with no branching structure correctly has none.

Conventions

Consistency across pages matters more than any individual choice, so the following are used throughout.

ElementConvention
Directionflowchart TD for processes and decisions; flowchart LR for pipelines and signal chains
DecisionsCurly brace nodes, phrased as questions
Edge labels on decisionsyes and no, or a short condition
Line breaks in labels<br/>, to keep nodes narrow and readable
Node textSentence case, no terminal punctuation
LoopsDrawn explicitly rather than implied by prose

Two syntax cautions apply to this site specifically.

Node labels containing punctuation should be quoted, because unquoted parentheses and some other characters break the parser.

Mermaid blocks are the only fenced blocks permitted in content. The style guide prohibits code in content, and mermaid is diagram source rather than code.

Notation used on this site

The diagrams across the subject sections use a small consistent vocabulary.

ShapeMeaning
RectangleA process, state or component
Curly bracesA decision or test
Labelled edgeA condition or a transition
Dashed edgeA constraint or a note about the relationship, not a flow

Dashed edges are used sparingly, for cases where an arrow would wrongly imply a sequence. The raw-data-preservation constraint in Experiments is drawn this way.

Accessibility

A diagram is not a substitute for the text. Every diagram on this site is surrounded by prose that states the same thing, so that a reader who cannot see the diagram loses nothing essential.

The stronger form of this rule is that if the surrounding prose cannot be written, the diagram is doing work that has not been thought through, and the right response is to think it through rather than to rely on the picture.

Index

Diagrams belonging to a subject live on that page. This section collects diagrams that span sections or that are working sketches not yet attached to anything.

No entries yet.

References

This page is a convention. Mermaid’s own documentation covers the syntax.

Last updated on