Sequence diagrams
Not boxes and links, so it has seven rules of its own: participants in one row an even step apart, one message to a row, words off every lifeline. Its page goes through the messages one at a time.
Declared with sequenceDiagram. Of 42 features Mermaid documents for a sequence diagram, 40 drawn as written, 2 drawn less something. See all 42 drawn both ways, or draw one yourself.

What is read
A block that starts sequenceDiagram is read, placed and checked by rules of its own (S1 to S7, with D1 and D2).
| Written | Read as |
|---|---|
participant B as Buyer, actor B, or a name first met in a message | Who is in it, left to right in the order named. An actor is a figure with its name under it; @{ "type": … } is a drawing of its own for boundary, control, entity, database (the data kind), collections and queue. Each is drawn again at the foot of its lifeline, unless mirrorActors: false is in the front matter or a directive |
A->B, A-->B, A->>B, A-->>B, A<<->>B, A-xB, A-)B | A message: solid or dotted, with nothing, an arrowhead, an arrowhead at both ends, a cross or an open arrow |
A-|\B, A-|/B, A-\\B, A-//B, dotted with --, reversed as A/|-B, A\|-B, A//-B, A\\-B | A message with half an arrowhead, or one stroke of an open one, above or below its line as written. A reversed one is drawn, and read, back to the participant named first |
A->>()B, A()->>B, A()->>()B | A message that meets the middle of a lifeline, in a dot at that end |
A->>A: words | A message to itself: a loop to the right |
A->>+B, B-->>-A, activate B, deactivate B | A bar on a participant at work; a second on the same one sits beside the first |
Note right of A: …, Note left of A: …, Note over A: …, Note over A,B: … | A note, on a row of its own |
loop, alt / else, opt, par / and, critical / option, break … end | A frame round its rows, named, one inside another |
rect rgb(…) … end | A highlight behind its rows, in the design's own colour nearest the one written (any CSS colour), thinly; with no colour, or a grey, in the design's tint |
box Aqua Buying … end | A group of participants, framed, its title inside the frame above them and wrapped to it, in the design's own colour nearest the one written, as a highlight is |
create participant J, destroy J | A participant that starts at the message that makes it, and ends in a cross |
autonumber, autonumber 10 5 | Each message numbered, from a start and by a step |
title: …, accTitle, accDescr, front matter, %% comments, <br/>, #9829; | As in a flowchart |
link A: … @ url, links A: {…} | Read past: a page of Merlive opens no links |
A line that is none of these is named in a note, line with its number, and nothing is drawn from it. There are no %% lines of Merlive's own for a sequence: its page goes through the messages in order without being told.
Feature by feature
Every feature Mermaid’s own pages set out for a sequence diagram, each with a sample of it in the corpus. A sample is drawn when every box, link and word it has is read and every rule passes. Drawn, less something is the same with one thing known to be missing, named beside it.
Written from skills/merlive/reference.md in the repository, so the two cannot disagree.