@diagrammo/dgmo 0.8.1 → 0.8.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.cjs +189 -194
- package/dist/index.cjs +450 -596
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +7 -6
- package/dist/index.d.ts +7 -6
- package/dist/index.js +450 -596
- package/dist/index.js.map +1 -1
- package/docs/language-reference.md +821 -1060
- package/package.json +1 -1
- package/src/c4/parser.ts +19 -13
- package/src/chart.ts +69 -47
- package/src/class/parser.ts +46 -19
- package/src/class/renderer.ts +2 -2
- package/src/cli.ts +11 -16
- package/src/completion.ts +29 -25
- package/src/d3.ts +173 -174
- package/src/dgmo-router.ts +1 -1
- package/src/echarts.ts +42 -22
- package/src/er/parser.ts +9 -17
- package/src/gantt/parser.ts +108 -40
- package/src/graph/flowchart-parser.ts +7 -55
- package/src/graph/state-parser.ts +7 -10
- package/src/infra/parser.ts +6 -126
- package/src/infra/types.ts +0 -1
- package/src/initiative-status/parser.ts +7 -13
- package/src/kanban/parser.ts +4 -7
- package/src/org/parser.ts +5 -8
- package/src/org/resolver.ts +3 -3
- package/src/render.ts +1 -2
- package/src/sequence/parser.ts +22 -45
- package/src/sitemap/parser.ts +10 -17
- package/src/utils/parsing.ts +9 -43
- package/src/utils/tag-groups.ts +4 -41
- package/src/infra/serialize.ts +0 -67
|
@@ -31,1491 +31,1252 @@ Syntax changes introduced in the consistency cleanup. Old forms now produce erro
|
|
|
31
31
|
|
|
32
32
|
---
|
|
33
33
|
|
|
34
|
-
##
|
|
34
|
+
## Table of Contents
|
|
35
|
+
|
|
36
|
+
1. [Universal Constructs](#1-universal-constructs)
|
|
37
|
+
2. [Sequence Diagrams](#2-sequence-diagrams)
|
|
38
|
+
3. [Infrastructure Diagrams](#3-infrastructure-diagrams)
|
|
39
|
+
4. [Flowchart Diagrams](#4-flowchart-diagrams)
|
|
40
|
+
5. [State Diagrams](#5-state-diagrams)
|
|
41
|
+
6. [Org Charts](#6-org-charts)
|
|
42
|
+
7. [C4 Architecture Diagrams](#7-c4-architecture-diagrams)
|
|
43
|
+
8. [Entity-Relationship Diagrams](#8-entity-relationship-diagrams)
|
|
44
|
+
9. [Class Diagrams](#9-class-diagrams)
|
|
45
|
+
10. [Kanban Boards](#10-kanban-boards)
|
|
46
|
+
11. [Initiative-Status Diagrams](#11-initiative-status-diagrams)
|
|
47
|
+
12. [Sitemap Diagrams](#12-sitemap-diagrams)
|
|
48
|
+
13. [Gantt Charts](#13-gantt-charts)
|
|
49
|
+
14. [Timeline Diagrams](#14-timeline-diagrams)
|
|
50
|
+
15. [Data Charts](#15-data-charts)
|
|
51
|
+
16. [Visualizations](#16-visualizations)
|
|
52
|
+
17. [Colon Usage Summary](#17-colon-usage-summary)
|
|
35
53
|
|
|
36
|
-
|
|
54
|
+
---
|
|
37
55
|
|
|
38
|
-
|
|
56
|
+
## 1. Universal Constructs
|
|
39
57
|
|
|
40
|
-
|
|
41
|
-
bar Revenue by Region
|
|
42
|
-
```
|
|
58
|
+
These patterns are shared across all or most diagram types.
|
|
43
59
|
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
### Directives
|
|
60
|
+
### 1.1 Chart Type Declaration (First Line)
|
|
47
61
|
|
|
48
62
|
```
|
|
49
|
-
|
|
50
|
-
theme dark
|
|
51
|
-
xlabel Category
|
|
52
|
-
ylabel Count
|
|
63
|
+
<chart-type> [Title]
|
|
53
64
|
```
|
|
54
65
|
|
|
55
|
-
|
|
66
|
+
- Space-separated, NO colon
|
|
67
|
+
- Title is optional
|
|
68
|
+
- Examples: `bar Treasure Hauls`, `sequence Auth Flow`, `gantt Product Launch`
|
|
56
69
|
|
|
57
|
-
### Comments
|
|
70
|
+
### 1.2 Comments
|
|
58
71
|
|
|
59
72
|
```
|
|
60
|
-
//
|
|
73
|
+
// comment text
|
|
61
74
|
```
|
|
62
75
|
|
|
63
|
-
|
|
76
|
+
- Full-line only (no inline comments after code)
|
|
77
|
+
- `#` is NOT a comment character
|
|
64
78
|
|
|
65
|
-
|
|
79
|
+
### 1.3 Tag Declarations
|
|
66
80
|
|
|
67
81
|
```
|
|
68
|
-
|
|
69
|
-
|
|
82
|
+
tag GroupName [alias X]
|
|
83
|
+
Value1(color)
|
|
84
|
+
Value2(color) [default]
|
|
70
85
|
```
|
|
71
86
|
|
|
72
|
-
|
|
87
|
+
- `tag` keyword, NO colon
|
|
88
|
+
- Alias: 1-4 lowercase letters
|
|
89
|
+
- Inline values also supported: `tag Priority p Low(green), High(red)`
|
|
90
|
+
- First entry is default unless another is marked `default`
|
|
91
|
+
- Must appear before diagram content
|
|
73
92
|
|
|
74
|
-
|
|
93
|
+
**Diagram types that support tags**: sequence, infra, org, c4, er, kanban, gantt, initiative-status, sitemap, timeline
|
|
75
94
|
|
|
76
|
-
|
|
95
|
+
### 1.4 Pipe Metadata
|
|
77
96
|
|
|
78
|
-
|
|
97
|
+
```
|
|
98
|
+
EntityName | key: value, key2: value2
|
|
99
|
+
```
|
|
79
100
|
|
|
80
|
-
|
|
101
|
+
- Colons ARE required within pipe segments (`key: value`)
|
|
102
|
+
- Items separated by commas
|
|
103
|
+
- Tag aliases resolve: `| c: Caching` resolves to `concern: Caching` (if `tag Concern alias c` is defined)
|
|
104
|
+
- One pipe per line only
|
|
81
105
|
|
|
82
|
-
###
|
|
106
|
+
### 1.5 Color Suffixes
|
|
83
107
|
|
|
84
|
-
|
|
108
|
+
```
|
|
109
|
+
Label(colorName)
|
|
110
|
+
```
|
|
85
111
|
|
|
86
|
-
|
|
112
|
+
- Named palette colors only (no hex codes)
|
|
113
|
+
- Appears at end of labels, node names, tag values, series names
|
|
114
|
+
- Color is stripped from display text
|
|
87
115
|
|
|
88
|
-
|
|
116
|
+
### 1.6 Indentation
|
|
89
117
|
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
series Rum, Spices, Silk, Gold
|
|
118
|
+
- Spaces or tabs (1 tab = 4 spaces)
|
|
119
|
+
- Determines hierarchy and block scope
|
|
93
120
|
|
|
94
|
-
|
|
95
|
-
series
|
|
96
|
-
Rum
|
|
97
|
-
Spices
|
|
98
|
-
Silk
|
|
99
|
-
Gold
|
|
100
|
-
```
|
|
101
|
-
|
|
102
|
-
Multi-line blocks support blank lines and `//` comments within the block. Trailing commas on values are stripped for convenience.
|
|
121
|
+
### 1.7 Groups / Containers
|
|
103
122
|
|
|
104
123
|
```
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
// gold last
|
|
109
|
-
Gold (yellow)
|
|
124
|
+
[Group Name]
|
|
125
|
+
[Group Name](color)
|
|
126
|
+
[Group Name] | key: value
|
|
110
127
|
```
|
|
111
128
|
|
|
112
|
-
|
|
129
|
+
- Bracket-enclosed name
|
|
130
|
+
- Optional color suffix
|
|
131
|
+
- Optional pipe metadata (outside brackets)
|
|
132
|
+
- Indented content below belongs to the group
|
|
133
|
+
|
|
134
|
+
### 1.8 Boolean Options
|
|
113
135
|
|
|
114
136
|
```
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
February
|
|
118
|
-
March
|
|
137
|
+
option-name // on
|
|
138
|
+
no-option-name // off
|
|
119
139
|
```
|
|
120
140
|
|
|
141
|
+
- Bare keyword = on; `no-` prefix = off
|
|
142
|
+
- Must appear before diagram content
|
|
143
|
+
|
|
121
144
|
---
|
|
122
145
|
|
|
123
|
-
##
|
|
146
|
+
## 2. Sequence Diagrams
|
|
124
147
|
|
|
125
|
-
###
|
|
148
|
+
### 2.1 Participants
|
|
126
149
|
|
|
127
|
-
|
|
150
|
+
```
|
|
151
|
+
Name is a <type> [aka Alias] [position N]
|
|
152
|
+
Name | key: value
|
|
153
|
+
```
|
|
128
154
|
|
|
129
|
-
|
|
155
|
+
Types: `service`, `database`, `actor`, `queue`, `cache`, `gateway`, `external`, `networking`, `frontend`
|
|
130
156
|
|
|
131
|
-
**
|
|
157
|
+
**Inference rules** — the parser infers the type (and shape) from the participant name. Only use `is a` when the name does not match or you want to override:
|
|
132
158
|
|
|
133
|
-
|
|
159
|
+
| Inferred Type | Shape | Name Patterns (examples) |
|
|
160
|
+
|--------------|-------|--------------------------|
|
|
161
|
+
| actor | Stick figure | `User`, `Customer`, `Client`, `Admin`, `Agent`, `Person`, `Buyer`, `Seller`, `Guest`, `Visitor`, `Operator`, Alice, Bob, Charlie, `*User`, `*Actor`, `*Analyst`, `*Staff` |
|
|
162
|
+
| service | Rounded rectangle | `*Service`, `*Svc`, `*API`, Lambda, `*Function`, `*Fn`, `*Job`, Cron, Auth, SSO, OAuth, Stripe, Twilio, S3, Vercel, Docker, K8s, Vault, KMS, IAM, LLM, GPT, Claude, `*Pipeline`, `*Engine`, and many `-er`/`-or` suffixes (Scheduler, Handler, Processor, Worker, etc.) |
|
|
163
|
+
| database | Cylinder (vertical) | `*DB`, `Database`, `*Store`, `Storage`, `*Repo`, `SQL`, Postgres, MySQL, Mongo, Dynamo, Aurora, Spanner, Supabase, Firebase, BigQuery, Redshift, Snowflake, Cassandra, Neo4j, ClickHouse, Elastic, OpenSearch, Pinecone, Weaviate, `*Table` |
|
|
164
|
+
| cache | Dashed cylinder | `*Cache`, Redis, Memcache, KeyDB, Dragonfly, Hazelcast, Valkey |
|
|
165
|
+
| queue | Horizontal cylinder (pipe) | `*Queue`, `*MQ`, SQS, Kafka, RabbitMQ, `EventBus`, `*Bus`, `Topic`, `*Stream`, SNS, PubSub, NATS, Pulsar, Kinesis, EventBridge, Celery, Sidekiq, `*Channel`, `*Broker` |
|
|
166
|
+
| networking | Hexagon | `*Router`, `*Balancer`, `Gateway`, `Proxy`, `LB`, `CDN`, `Firewall`, `WAF`, `DNS`, `Ingress`, Nginx, Traefik, Envoy, Istio, Kong, Akamai, Cloudflare, `*Mesh` |
|
|
167
|
+
| frontend | Monitor (screen + stand) | `*App`, `Application`, `Mobile`, iOS, Android, `Web`, `Browser`, `Frontend`, `*UI`, `Dashboard`, `*CLI`, `Terminal`, React, Vue, Angular, Svelte, NextJS, Electron, Tauri, `*Widget`, `Portal`, `*Console`, SPA, PWA |
|
|
168
|
+
| gateway | Rectangle (same as default) | matched via `is a gateway` only |
|
|
169
|
+
| external | Dashed rectangle | `External`, `*Ext`, `ThirdParty`, `*3P`, `Vendor`, `Webhook`, `Upstream`, `Downstream`, `Callback`, AWS, GCP, Azure |
|
|
170
|
+
| default | Rectangle | Everything else (no `is a` needed) |
|
|
134
171
|
|
|
172
|
+
**Inference handles it (skip `is a`):**
|
|
173
|
+
```
|
|
174
|
+
AuthService // service (matches *Service)
|
|
175
|
+
PostgresDB // database (matches *DB)
|
|
176
|
+
Redis // cache (exact match)
|
|
177
|
+
User // actor (exact match)
|
|
178
|
+
Kafka // queue (exact match)
|
|
179
|
+
API Gateway // networking (matches Gateway)
|
|
180
|
+
WebApp // frontend (matches *App)
|
|
181
|
+
Stripe // service (exact match)
|
|
135
182
|
```
|
|
136
|
-
bar Revenue by Region
|
|
137
|
-
series Revenue
|
|
138
183
|
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
184
|
+
**Inference would miss (use `is a`):**
|
|
185
|
+
```
|
|
186
|
+
Payments is a service // "Payments" matches no rule
|
|
187
|
+
Vault is a database // "Vault" infers as service, but you want database
|
|
188
|
+
Notifications is a queue // "Notifications" matches no rule
|
|
189
|
+
Analytics is a frontend // "Analytics" matches no rule
|
|
143
190
|
```
|
|
144
191
|
|
|
145
|
-
|
|
192
|
+
### 2.2 Participant Groups
|
|
146
193
|
|
|
147
|
-
|
|
194
|
+
```
|
|
195
|
+
[Group Name]
|
|
196
|
+
Participant1
|
|
197
|
+
Participant2
|
|
198
|
+
```
|
|
148
199
|
|
|
149
|
-
|
|
200
|
+
- Pipe metadata goes outside brackets: `[Backend] | t: Eng`
|
|
201
|
+
- Invalid: `[Backend | t: Eng]` (pipe inside brackets)
|
|
150
202
|
|
|
151
|
-
|
|
203
|
+
### 2.3 Messages (Arrows)
|
|
152
204
|
|
|
153
|
-
|
|
205
|
+
| Type | Syntax | Example |
|
|
206
|
+
|------|--------|---------|
|
|
207
|
+
| Sync (labeled) | `A -label-> B` | `Client -login-> API` |
|
|
208
|
+
| Sync (bare) | `A -> B` | `Client -> API` |
|
|
209
|
+
| Async (labeled) | `A ~label~> B` | `API ~notify~> Queue` |
|
|
210
|
+
| Async (bare) | `A ~> B` | `API ~> Queue` |
|
|
154
211
|
|
|
155
|
-
|
|
212
|
+
- Whitespace around arrows is optional: `A-label->B` works
|
|
213
|
+
- Labels can contain spaces, hyphens, special chars
|
|
214
|
+
- Labels cannot contain arrow chars (`->`, `~>`)
|
|
215
|
+
- Pipe metadata: `A -msg-> B | c: Caching`
|
|
156
216
|
|
|
157
|
-
|
|
158
|
-
line Quarterly Performance
|
|
159
|
-
series Sales(red), Costs(blue)
|
|
217
|
+
### 2.4 Section Dividers
|
|
160
218
|
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
Q4 130, 58
|
|
219
|
+
```
|
|
220
|
+
== Label ==
|
|
221
|
+
== Label
|
|
165
222
|
```
|
|
166
223
|
|
|
167
|
-
|
|
224
|
+
Trailing `==` is optional.
|
|
168
225
|
|
|
169
|
-
|
|
226
|
+
### 2.5 Notes
|
|
170
227
|
|
|
171
228
|
```
|
|
172
|
-
|
|
173
|
-
|
|
229
|
+
note Text
|
|
230
|
+
note right Text
|
|
231
|
+
note left of ParticipantID Text
|
|
232
|
+
```
|
|
174
233
|
|
|
175
|
-
|
|
176
|
-
era '89 -> '93 Bush (red)
|
|
177
|
-
era '93 -> '01 Clinton (blue)
|
|
234
|
+
**Multi-line notes** use an indented body below the `note` heading:
|
|
178
235
|
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
236
|
+
```
|
|
237
|
+
note right of API
|
|
238
|
+
- First bullet point
|
|
239
|
+
- Second bullet point
|
|
240
|
+
**Bold text** and *italic text*
|
|
241
|
+
`inline code`
|
|
242
|
+
[link text](https://example.com)
|
|
243
|
+
https://example.com
|
|
184
244
|
```
|
|
185
245
|
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
-
|
|
189
|
-
-
|
|
190
|
-
- Band label is hidden if the era spans fewer than 3 category slots
|
|
191
|
-
- Works on `line`, `multi-line`, and `area` charts
|
|
192
|
-
- Era boundary labels are always pinned visible on the x-axis even when auto-skip is active
|
|
246
|
+
Content formatting:
|
|
247
|
+
- `- ` prefix on indented lines = bullet points
|
|
248
|
+
- Inline markdown: `**bold**`, `*italic*`, `` `code` ``
|
|
249
|
+
- Links: `[text](url)` and bare URLs (auto-truncated in display)
|
|
193
250
|
|
|
194
|
-
###
|
|
251
|
+
### 2.6 Structural Blocks
|
|
195
252
|
|
|
196
|
-
|
|
253
|
+
```
|
|
254
|
+
if condition
|
|
255
|
+
messages...
|
|
256
|
+
else if condition
|
|
257
|
+
messages...
|
|
258
|
+
else
|
|
259
|
+
messages...
|
|
197
260
|
|
|
198
|
-
|
|
261
|
+
loop condition
|
|
262
|
+
messages...
|
|
199
263
|
|
|
200
|
-
|
|
264
|
+
parallel label
|
|
265
|
+
messages...
|
|
266
|
+
```
|
|
201
267
|
|
|
202
|
-
|
|
268
|
+
- `parallel` requires a label
|
|
269
|
+
- Blocks nest via indentation
|
|
203
270
|
|
|
204
|
-
###
|
|
271
|
+
### 2.7 Sequence Options
|
|
205
272
|
|
|
206
|
-
|
|
273
|
+
- `activations` / `no-activations`
|
|
274
|
+
- `collapse-notes` / `no-collapse-notes`
|
|
275
|
+
- `active-tag GroupName`
|
|
207
276
|
|
|
208
|
-
|
|
277
|
+
---
|
|
209
278
|
|
|
210
|
-
|
|
279
|
+
## 3. Infrastructure Diagrams
|
|
211
280
|
|
|
212
|
-
|
|
281
|
+
### 3.1 Declaration
|
|
213
282
|
|
|
214
283
|
```
|
|
215
|
-
|
|
216
|
-
labels percent
|
|
217
|
-
|
|
218
|
-
Company A 40
|
|
219
|
-
Company B 35
|
|
220
|
-
Company C 25
|
|
284
|
+
infra [Title]
|
|
221
285
|
```
|
|
222
286
|
|
|
223
|
-
###
|
|
224
|
-
|
|
225
|
-
**Syntax:** `doughnut [Title]`
|
|
226
|
-
|
|
227
|
-
**Options:** same as `pie`
|
|
228
|
-
|
|
229
|
-
**Data format:** same as `pie`
|
|
287
|
+
### 3.2 Nodes
|
|
230
288
|
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
289
|
+
```
|
|
290
|
+
NodeName
|
|
291
|
+
NodeName | key: value
|
|
292
|
+
```
|
|
234
293
|
|
|
235
|
-
|
|
294
|
+
Nodes are plain names. Capabilities come from properties (see 3.3), not type declarations.
|
|
236
295
|
|
|
237
|
-
|
|
296
|
+
### 3.3 Node Properties (Indented, Space-Separated, NO Colon)
|
|
238
297
|
|
|
239
|
-
|
|
298
|
+
```
|
|
299
|
+
NodeName
|
|
300
|
+
latency-ms 50
|
|
301
|
+
max-rps 8000
|
|
302
|
+
uptime 99.99%
|
|
303
|
+
cache-hit 75%
|
|
304
|
+
description My API gateway
|
|
305
|
+
firewall-block 10%
|
|
306
|
+
instances 3
|
|
307
|
+
```
|
|
240
308
|
|
|
241
|
-
|
|
309
|
+
Properties use a known schema with space-separated values:
|
|
242
310
|
|
|
243
|
-
|
|
311
|
+
| Property | Capability | Effect |
|
|
312
|
+
|----------|-----------|--------|
|
|
313
|
+
| `cache-hit` | Cache | % requests served from cache, reduces downstream RPS |
|
|
314
|
+
| `firewall-block` | Firewall/WAF | % requests blocked, reduces downstream RPS |
|
|
315
|
+
| `ratelimit-rps` | Rate limiter | Max RPS passed through |
|
|
316
|
+
| `latency-ms` | Latency | Adds to path latency |
|
|
317
|
+
| `uptime` | Availability | Multiplied along path for SLO |
|
|
318
|
+
| `instances` | Horizontal scaling | Multiplies capacity |
|
|
319
|
+
| `max-rps` | Capacity ceiling | Max RPS node handles |
|
|
320
|
+
| `cb-error-threshold` | Circuit breaker | Error rate trip threshold |
|
|
321
|
+
| `cb-latency-threshold-ms` | Circuit breaker | Latency trip threshold |
|
|
322
|
+
| `concurrency` | Concurrency limit | Max concurrent requests |
|
|
323
|
+
| `duration-ms` | Processing time | Time spent processing |
|
|
324
|
+
| `cold-start-ms` | Serverless | Cold start penalty |
|
|
325
|
+
| `buffer` | Queue | Buffer size |
|
|
326
|
+
| `drain-rate` | Queue | Consumption rate |
|
|
327
|
+
| `retention-hours` | Queue | Message retention |
|
|
328
|
+
| `partitions` | Queue | Partition count |
|
|
329
|
+
| `description` | Display | Description text |
|
|
244
330
|
|
|
245
|
-
|
|
331
|
+
### 3.4 Connections
|
|
246
332
|
|
|
247
|
-
|
|
333
|
+
| Type | Syntax |
|
|
334
|
+
|------|--------|
|
|
335
|
+
| Sync (bare) | `-> Target` |
|
|
336
|
+
| Sync (labeled) | `-/api-> Target` |
|
|
337
|
+
| Async (bare) | `~> Target` |
|
|
338
|
+
| Async (labeled) | `~event~> Target` |
|
|
248
339
|
|
|
249
|
-
|
|
340
|
+
- Connection metadata: `| split: 50%, fanout: 3` (colons in pipe metadata)
|
|
341
|
+
- Indented under source node
|
|
250
342
|
|
|
251
|
-
|
|
343
|
+
### 3.5 Groups
|
|
252
344
|
|
|
253
345
|
```
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
Backend 70
|
|
258
|
-
DevOps 60
|
|
259
|
-
Design 90
|
|
260
|
-
Testing 75
|
|
346
|
+
[Group Name]
|
|
347
|
+
[Group Name](color)
|
|
348
|
+
[Group Name] | key: value
|
|
261
349
|
```
|
|
262
350
|
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
**Syntax:** `bar-stacked [Title]`
|
|
351
|
+
Bracket syntax only. Optional color and pipe metadata.
|
|
266
352
|
|
|
267
|
-
|
|
353
|
+
### 3.6 Infra Options (Space-Separated, NO Colon)
|
|
268
354
|
|
|
269
|
-
|
|
355
|
+
- `direction-tb` (boolean; default is LR)
|
|
356
|
+
- `default-latency-ms N`
|
|
357
|
+
- `default-rps N`
|
|
358
|
+
- `default-uptime DECIMAL`
|
|
359
|
+
- `slo-availability DECIMAL`
|
|
360
|
+
- `slo-p90-latency-ms N`
|
|
361
|
+
- `animate` / `no-animate`
|
|
270
362
|
|
|
271
|
-
|
|
363
|
+
### 3.7 Edge Nodes
|
|
272
364
|
|
|
273
365
|
```
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
Q1 100, 50, 30
|
|
278
|
-
Q2 110, 55, 35
|
|
279
|
-
Q3 105, 60, 40
|
|
366
|
+
edge
|
|
367
|
+
internet
|
|
280
368
|
```
|
|
281
369
|
|
|
282
|
-
|
|
370
|
+
Special top-level entry points. `internet` only accepts `rps` property.
|
|
283
371
|
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
**Options:** `labels` (`on`/`off`), `xlabel`, `ylabel`, `sizelabel`
|
|
372
|
+
---
|
|
287
373
|
|
|
288
|
-
|
|
374
|
+
## 4. Flowchart Diagrams
|
|
289
375
|
|
|
290
|
-
|
|
376
|
+
### 4.1 Declaration
|
|
291
377
|
|
|
292
378
|
```
|
|
293
|
-
|
|
294
|
-
labels on
|
|
295
|
-
xlabel Experience (years)
|
|
296
|
-
ylabel Output
|
|
297
|
-
|
|
298
|
-
Alice 3, 85
|
|
299
|
-
Bob 7, 92
|
|
300
|
-
Carol 2, 70
|
|
379
|
+
flowchart [Title]
|
|
301
380
|
```
|
|
302
381
|
|
|
303
|
-
|
|
382
|
+
### 4.2 Node Shapes
|
|
304
383
|
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
384
|
+
| Shape | Syntax | Example |
|
|
385
|
+
|-------|--------|---------|
|
|
386
|
+
| Terminal | `(Label)` | `(Start)` |
|
|
387
|
+
| Process | `[Label]` | `[Do Task]` |
|
|
388
|
+
| Decision | `<Label>` | `<Check?>` |
|
|
389
|
+
| I/O | `/Label/` | `/Read Input/` |
|
|
390
|
+
| Subroutine | `[[Label]]` | `[[Validate]]` |
|
|
391
|
+
| Document | `[Label~]` | `[Report~]` |
|
|
310
392
|
|
|
311
|
-
|
|
312
|
-
Acme Cloud 12, 8.5
|
|
313
|
-
DataSync 5.2, 3.1
|
|
393
|
+
- Color suffix: `(Start(green))`
|
|
314
394
|
|
|
315
|
-
|
|
316
|
-
PayFlow 45, 32
|
|
317
|
-
LendTech 18, 12.5
|
|
318
|
-
```
|
|
395
|
+
### 4.3 Arrows
|
|
319
396
|
|
|
320
|
-
|
|
397
|
+
| Type | Syntax |
|
|
398
|
+
|------|--------|
|
|
399
|
+
| Unlabeled | `->` |
|
|
400
|
+
| Labeled | `-label->` |
|
|
401
|
+
| Colored | `-(color)->` |
|
|
402
|
+
| Labeled + colored | `-label(color)->` |
|
|
321
403
|
|
|
322
|
-
|
|
404
|
+
- Color inference: `yes/success/ok/true` infers green; `no/fail/error/false` infers red
|
|
323
405
|
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
**Data format:** `Row Label v1, v2, v3` — comma-separated values matching the `columns` list
|
|
327
|
-
|
|
328
|
-
**Example:**
|
|
406
|
+
### 4.4 Groups
|
|
329
407
|
|
|
330
408
|
```
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
Team A 5, 4, 5, 3, 4, 5
|
|
335
|
-
Team B 2, 3, 2, 4, 3, 2
|
|
336
|
-
Team C 3, 2, 1, 2, 3, 4
|
|
409
|
+
[GroupName]
|
|
410
|
+
[Child nodes...]
|
|
337
411
|
```
|
|
338
412
|
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
**Syntax:** `sankey [Title]`
|
|
342
|
-
|
|
343
|
-
**Options:** (none)
|
|
413
|
+
Bracket syntax only.
|
|
344
414
|
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
**Arrow syntax:**
|
|
415
|
+
### 4.5 Inline Chains
|
|
348
416
|
|
|
349
417
|
```
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
Source A -> Processing 300
|
|
353
|
-
Source B -> Processing 200
|
|
354
|
-
Processing -> Output X 350
|
|
355
|
-
Processing -> Output Y 150
|
|
418
|
+
(Start) -> [Step 1] -> [Step 2] -> (End)
|
|
356
419
|
```
|
|
357
420
|
|
|
358
|
-
|
|
421
|
+
### 4.6 Options
|
|
359
422
|
|
|
360
|
-
|
|
361
|
-
|
|
423
|
+
- `direction-tb` (boolean; default is LR)
|
|
424
|
+
- `orientation-vertical` (boolean; default is horizontal)
|
|
362
425
|
|
|
363
|
-
|
|
364
|
-
Processing 300
|
|
365
|
-
Source B
|
|
366
|
-
Processing 200
|
|
367
|
-
Processing
|
|
368
|
-
Output X 350
|
|
369
|
-
Output Y 150
|
|
370
|
-
```
|
|
426
|
+
---
|
|
371
427
|
|
|
372
|
-
|
|
428
|
+
## 5. State Diagrams
|
|
373
429
|
|
|
374
|
-
|
|
430
|
+
### 5.1 Declaration
|
|
375
431
|
|
|
376
432
|
```
|
|
377
|
-
|
|
378
|
-
Costs (red) 600
|
|
379
|
-
Profit (blue) 400
|
|
380
|
-
|
|
381
|
-
// or with arrows
|
|
382
|
-
Revenue (green) -> Costs (red) 600
|
|
433
|
+
state [Title]
|
|
383
434
|
```
|
|
384
435
|
|
|
385
|
-
|
|
436
|
+
### 5.2 States
|
|
386
437
|
|
|
387
438
|
```
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
// or with arrows
|
|
392
|
-
Revenue -> Costs 600 (orange)
|
|
439
|
+
StateName
|
|
440
|
+
StateName(color)
|
|
441
|
+
[*] // initial/final pseudostate
|
|
393
442
|
```
|
|
394
443
|
|
|
395
|
-
###
|
|
396
|
-
|
|
397
|
-
**Syntax:** `chord [Title]`
|
|
398
|
-
|
|
399
|
-
**Options:** (none)
|
|
444
|
+
### 5.3 Transitions
|
|
400
445
|
|
|
401
|
-
|
|
446
|
+
| Type | Syntax |
|
|
447
|
+
|------|--------|
|
|
448
|
+
| Unlabeled | `Idle -> Active` |
|
|
449
|
+
| Labeled | `Idle -submit-> Processing` |
|
|
450
|
+
| Colored | `Idle -(blue)-> Active` |
|
|
402
451
|
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
**Example:**
|
|
452
|
+
### 5.4 Groups
|
|
406
453
|
|
|
407
454
|
```
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
Engineering -> Design 85
|
|
411
|
-
Engineering -> Product 72
|
|
412
|
-
Design -> Marketing 45
|
|
413
|
-
Product -> Sales 42
|
|
455
|
+
[Group Name]
|
|
456
|
+
[Group Name](color)
|
|
414
457
|
```
|
|
415
458
|
|
|
416
|
-
###
|
|
459
|
+
### 5.5 Options
|
|
417
460
|
|
|
418
|
-
|
|
461
|
+
- `direction-tb` (boolean; default is LR)
|
|
419
462
|
|
|
420
|
-
|
|
463
|
+
---
|
|
421
464
|
|
|
422
|
-
|
|
465
|
+
## 6. Org Charts
|
|
423
466
|
|
|
424
|
-
|
|
467
|
+
### 6.1 Declaration
|
|
425
468
|
|
|
426
469
|
```
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
Visitors 1000
|
|
430
|
-
Signups 500
|
|
431
|
-
Trials 200
|
|
432
|
-
Customers 100
|
|
470
|
+
org [Title]
|
|
433
471
|
```
|
|
434
472
|
|
|
435
|
-
###
|
|
436
|
-
|
|
437
|
-
**Syntax:** `function [Title]`
|
|
438
|
-
|
|
439
|
-
**Options:** `x` (required, `start to end`), `xlabel`, `ylabel`
|
|
440
|
-
|
|
441
|
-
**Data format:** `Name (color) expression` — math expressions using `x`
|
|
442
|
-
|
|
443
|
-
**Example:**
|
|
473
|
+
### 6.2 Nodes (Indentation = Hierarchy)
|
|
444
474
|
|
|
445
475
|
```
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
f(x) (blue) sin(x)
|
|
452
|
-
g(x) (red) x^2 / 10
|
|
453
|
-
h(x) (green) cos(x) * 2
|
|
476
|
+
CEO
|
|
477
|
+
CTO
|
|
478
|
+
Engineer1
|
|
479
|
+
Engineer2
|
|
480
|
+
CFO
|
|
454
481
|
```
|
|
455
482
|
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
### slope
|
|
459
|
-
|
|
460
|
-
**Syntax:** `slope [Title]`
|
|
461
|
-
|
|
462
|
-
**Options:** `orientation` (`horizontal`/`vertical`)
|
|
463
|
-
|
|
464
|
-
**Data format:** First data line defines period labels. Subsequent lines: `Item (color) v1, v2, ...`
|
|
483
|
+
- Color suffix: `Alice(blue)`
|
|
484
|
+
- Pipe metadata: `Alice | role: CEO, t: Exec`
|
|
465
485
|
|
|
466
|
-
|
|
486
|
+
### 6.3 Metadata (Indented, Colon REQUIRED)
|
|
467
487
|
|
|
468
488
|
```
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
Python (blue) 3, 1, 1
|
|
473
|
-
JavaScript (yellow) 1, 2, 2
|
|
474
|
-
TypeScript (cyan) 7, 4, 3
|
|
475
|
-
Rust (orange) 18, 12, 5
|
|
489
|
+
Alice
|
|
490
|
+
role: Senior Engineer
|
|
491
|
+
location: NYC
|
|
476
492
|
```
|
|
477
493
|
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
**Syntax:** `wordcloud [Title]`
|
|
481
|
-
|
|
482
|
-
**Options:** `rotate` (`none`/`mixed`/`angled`), `max` (word limit), `size` (`min, max` font range)
|
|
494
|
+
This is key-value metadata assignment, consistent with pipe metadata syntax.
|
|
483
495
|
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
**Example:**
|
|
496
|
+
### 6.4 Containers
|
|
487
497
|
|
|
488
498
|
```
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
kubernetes 95
|
|
492
|
-
docker 80
|
|
493
|
-
terraform 65
|
|
494
|
-
ansible 50
|
|
499
|
+
[Team Name]
|
|
500
|
+
members...
|
|
495
501
|
```
|
|
496
502
|
|
|
497
|
-
###
|
|
503
|
+
### 6.5 Options
|
|
498
504
|
|
|
499
|
-
|
|
505
|
+
- `direction-tb` (boolean; default is LR)
|
|
506
|
+
- `sub-node-label Text`
|
|
507
|
+
- `show-sub-node-count`
|
|
508
|
+
- `hide`
|
|
500
509
|
|
|
501
|
-
|
|
510
|
+
---
|
|
502
511
|
|
|
503
|
-
|
|
512
|
+
## 7. C4 Architecture Diagrams
|
|
504
513
|
|
|
505
|
-
|
|
514
|
+
### 7.1 Declaration
|
|
506
515
|
|
|
507
516
|
```
|
|
508
|
-
|
|
509
|
-
order: group
|
|
510
|
-
|
|
511
|
-
[Frontend]
|
|
512
|
-
WebApp -> API Gateway 5
|
|
513
|
-
MobileApp -> API Gateway 3
|
|
514
|
-
|
|
515
|
-
[Core Services]
|
|
516
|
-
API Gateway -> AuthService 4
|
|
517
|
-
API Gateway -> UserService 5
|
|
517
|
+
c4 [Title]
|
|
518
518
|
```
|
|
519
519
|
|
|
520
|
-
###
|
|
521
|
-
|
|
522
|
-
**Syntax:** `venn [Title]`
|
|
523
|
-
|
|
524
|
-
**Options:** `values` (`on`/`off`)
|
|
525
|
-
|
|
526
|
-
**Data format:** Sets: `id(color) alias shortname`. Overlaps: `id1 + id2 Label`.
|
|
527
|
-
|
|
528
|
-
**Example:**
|
|
520
|
+
### 7.2 Elements
|
|
529
521
|
|
|
530
522
|
```
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
Frontend(blue) alias fe
|
|
534
|
-
Backend(green) alias be
|
|
535
|
-
DevOps(orange) alias de
|
|
536
|
-
|
|
537
|
-
fe + be Web Systems
|
|
538
|
-
be + de Platform Ops
|
|
539
|
-
fe + de Dev Tools
|
|
540
|
-
fe + be + de Full Stack
|
|
523
|
+
Name is a <type>
|
|
524
|
+
Name is a container is a database // shape override
|
|
541
525
|
```
|
|
542
526
|
|
|
543
|
-
|
|
527
|
+
Types: `person`, `system`, `container`, `component`
|
|
528
|
+
Shape overrides: `database`, `cache`, `queue`, `cloud`, `external`
|
|
544
529
|
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
**Options:** `x-axis` (`low label, high label`), `y-axis` (`low label, high label`)
|
|
548
|
-
|
|
549
|
-
**Data format:** Quadrant labels: `top-right Label`, `top-left Label`, etc. Data points: `Label (color) x, y` where x,y are 0-1.
|
|
550
|
-
|
|
551
|
-
**Example:**
|
|
530
|
+
### 7.3 Element Metadata (Indented, Colon REQUIRED)
|
|
552
531
|
|
|
553
532
|
```
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
top-right Quick Wins(green)
|
|
559
|
-
top-left Big Bets(yellow)
|
|
560
|
-
bottom-left Skip(red)
|
|
561
|
-
bottom-right Reconsider(gray)
|
|
562
|
-
|
|
563
|
-
Task A 0.9, 0.8
|
|
564
|
-
Task B 0.2, 0.3
|
|
565
|
-
Task C 0.7, 0.4
|
|
533
|
+
Web App is a container
|
|
534
|
+
description: SPA built with React
|
|
535
|
+
tech: React
|
|
566
536
|
```
|
|
567
537
|
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
**Syntax:** `timeline [Title]`
|
|
571
|
-
|
|
572
|
-
**Options:** `scale` (`on`/`off`), `sort` (`time`/`group`/`tag`/`tag:GroupName`), `swimlanes` (`on`/`off`)
|
|
538
|
+
Indented metadata uses colon-separated `key: value`, consistent with org charts and pipe metadata.
|
|
573
539
|
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
**Example:**
|
|
540
|
+
### 7.4 Pipe Metadata (Colons in pipes)
|
|
577
541
|
|
|
578
542
|
```
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
tag Team
|
|
582
|
-
Team A(blue)
|
|
583
|
-
Team B(green)
|
|
584
|
-
|
|
585
|
-
era 2023->2024 Phase 1
|
|
586
|
-
marker 2023-06 Launch(orange)
|
|
587
|
-
|
|
588
|
-
2023-01->2023-06 Planning | Team: Team A
|
|
589
|
-
2023-06->2024-01 Development | Team: Team A
|
|
590
|
-
2024-02 Release | Team: Team A
|
|
591
|
-
|
|
592
|
-
2023-03->2023-09 Research | Team: Team B
|
|
593
|
-
2023-09->2024-03? Implementation | Team: Team B
|
|
543
|
+
Web App is a container | description: SPA, tech: React
|
|
594
544
|
```
|
|
595
545
|
|
|
596
|
-
|
|
546
|
+
### 7.5 Relationships
|
|
597
547
|
|
|
598
|
-
|
|
548
|
+
| Type | Syntax |
|
|
549
|
+
|------|--------|
|
|
550
|
+
| Sync labeled | `-Makes API calls-> API` |
|
|
551
|
+
| Sync with tech | `-Uses [HTTPS]-> API` |
|
|
552
|
+
| Async labeled | `~Sends emails~> Email` |
|
|
599
553
|
|
|
600
|
-
|
|
554
|
+
### 7.6 Sections
|
|
601
555
|
|
|
602
556
|
```
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
2024-01->2024-06 Build API | Team: Engineering
|
|
611
|
-
2024-03->2024-05 UX Review | Team: Design
|
|
557
|
+
containers
|
|
558
|
+
...
|
|
559
|
+
components
|
|
560
|
+
...
|
|
561
|
+
deployment
|
|
562
|
+
container Web App // reference existing container
|
|
612
563
|
```
|
|
613
564
|
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
---
|
|
617
|
-
|
|
618
|
-
## Diagram Types
|
|
565
|
+
### 7.7 Options
|
|
619
566
|
|
|
620
|
-
|
|
567
|
+
- `direction-tb` (boolean; default is LR)
|
|
621
568
|
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
**Options:** `activations` (`on`/`off`), `collapse-notes` (`yes`/`no`), `active-tag GroupName`
|
|
569
|
+
---
|
|
625
570
|
|
|
626
|
-
|
|
571
|
+
## 8. Entity-Relationship Diagrams
|
|
627
572
|
|
|
628
|
-
|
|
573
|
+
### 8.1 Declaration
|
|
629
574
|
|
|
630
575
|
```
|
|
631
|
-
|
|
632
|
-
API -findUser-> DB
|
|
633
|
-
DB -user-> API
|
|
634
|
-
API -token-> User
|
|
576
|
+
er [Title]
|
|
635
577
|
```
|
|
636
578
|
|
|
637
|
-
|
|
579
|
+
### 8.2 Tables
|
|
638
580
|
|
|
639
581
|
```
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
User is an actor
|
|
644
|
-
API is a service
|
|
645
|
-
DB is a database
|
|
646
|
-
NotifyQueue is a queue aka Notifications
|
|
647
|
-
|
|
648
|
-
User -Login request-> API
|
|
649
|
-
API -Find user by email-> DB
|
|
650
|
-
DB -user record-> API
|
|
651
|
-
note on DB
|
|
652
|
-
Indexed lookup on email column
|
|
653
|
-
|
|
654
|
-
if credentials valid
|
|
655
|
-
API -Create session-> DB
|
|
656
|
-
DB -session token-> API
|
|
657
|
-
API ~session.created~> NotifyQueue
|
|
658
|
-
API -200 OK + token-> User
|
|
659
|
-
else
|
|
660
|
-
API -401 Unauthorized-> User
|
|
661
|
-
|
|
662
|
-
== Logout ==
|
|
663
|
-
|
|
664
|
-
User -Logout-> API
|
|
665
|
-
API -Delete session-> DB
|
|
666
|
-
API -200 OK-> User
|
|
582
|
+
users
|
|
583
|
+
users(blue)
|
|
584
|
+
users | domain: Core
|
|
667
585
|
```
|
|
668
586
|
|
|
669
|
-
|
|
670
|
-
-
|
|
671
|
-
- `Name aka Display Label` — alias for display
|
|
672
|
-
- `Name at position 2` — manual left-to-right ordering (0-based; negative from right)
|
|
673
|
-
|
|
674
|
-
**Messages**:
|
|
675
|
-
- Sync call: `A -label-> B` or `A -> B` (unlabeled) — always left-to-right
|
|
676
|
-
- Async call: `A ~label~> B` or `A ~> B` (unlabeled)
|
|
677
|
-
|
|
678
|
-
**Blocks** (indentation-scoped):
|
|
679
|
-
- `if condition` ... `else` ... (no explicit `end` needed — indentation closes blocks)
|
|
680
|
-
- `loop label` ...
|
|
681
|
-
- `parallel label` ...
|
|
682
|
-
|
|
683
|
-
**Notes**:
|
|
684
|
-
- `note text` — standalone
|
|
685
|
-
- `note on Participant` followed by indented text — anchored
|
|
686
|
-
- Multi-line: indent continuation lines under `note`
|
|
687
|
-
|
|
688
|
-
**Sections**: `== Section Title ==`
|
|
689
|
-
|
|
690
|
-
**Groups**: `[Group Name]` or `[Group Name | key: value]` — visual grouping box around participants
|
|
587
|
+
- Pipe metadata on declaration line only
|
|
588
|
+
- Indented lines are columns or relationships
|
|
691
589
|
|
|
692
|
-
|
|
590
|
+
### 8.3 Columns (Indented, Space-Separated, NO Colon)
|
|
693
591
|
|
|
694
592
|
```
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
593
|
+
users
|
|
594
|
+
id int pk
|
|
595
|
+
name varchar
|
|
596
|
+
email string unique
|
|
597
|
+
created_at timestamp nullable
|
|
699
598
|
```
|
|
700
599
|
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
- `default` on an entry applies it to untagged elements when the group is active
|
|
600
|
+
Format: `name [type] [constraints...]`
|
|
601
|
+
Constraints: `pk`, `fk`, `unique`, `nullable`
|
|
704
602
|
|
|
705
|
-
|
|
603
|
+
### 8.4 Relationships (Indented Under Source Table)
|
|
706
604
|
|
|
707
605
|
```
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
OrderAPI
|
|
712
|
-
DB
|
|
606
|
+
ships
|
|
607
|
+
1-aboard-* crew_members
|
|
608
|
+
?-frequents-1 ports
|
|
713
609
|
```
|
|
714
610
|
|
|
715
|
-
|
|
716
|
-
- Multiple tags: `| key1: val1, key2: val2`
|
|
717
|
-
- Aliases work: `| c: Caching` (if `alias c` was declared)
|
|
718
|
-
|
|
719
|
-
**Tag resolution priority** (when a tag group is active):
|
|
720
|
-
1. Explicit metadata on the participant
|
|
721
|
-
2. Group propagation (participant inherits from its group)
|
|
722
|
-
3. Receiver inheritance (all incoming tagged messages agree on same value)
|
|
723
|
-
4. `default` entry value
|
|
724
|
-
5. Neutral (no color)
|
|
725
|
-
|
|
726
|
-
**Legend** — rendered automatically above participants when tag groups exist. The active group expands to show colored entry dots. Click a group pill to activate it (in the desktop app).
|
|
611
|
+
Cardinality symbols: `1` (one), `*` (many), `?` (optional)
|
|
727
612
|
|
|
728
|
-
###
|
|
613
|
+
### 8.5 Options
|
|
729
614
|
|
|
730
|
-
|
|
615
|
+
- `notation chen` / `notation crow`
|
|
731
616
|
|
|
732
|
-
|
|
617
|
+
---
|
|
733
618
|
|
|
734
|
-
|
|
619
|
+
## 9. Class Diagrams
|
|
735
620
|
|
|
736
|
-
|
|
621
|
+
### 9.1 Declaration
|
|
737
622
|
|
|
738
623
|
```
|
|
739
|
-
|
|
624
|
+
class [Title]
|
|
740
625
|
```
|
|
741
626
|
|
|
742
|
-
|
|
627
|
+
### 9.2 Classes
|
|
743
628
|
|
|
744
629
|
```
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
630
|
+
Ship
|
|
631
|
+
abstract Vessel
|
|
632
|
+
interface Serializable
|
|
633
|
+
Ship extends Vessel
|
|
634
|
+
Galleon implements Serializable
|
|
635
|
+
ShipType enum
|
|
751
636
|
```
|
|
752
637
|
|
|
753
|
-
|
|
754
|
-
- `(Terminal)` — oval
|
|
755
|
-
- `[Process]` — rectangle
|
|
756
|
-
- `<Decision?>` — diamond
|
|
757
|
-
- `/Input Output/` — parallelogram
|
|
758
|
-
- `[[Subroutine]]` — double-bordered rectangle
|
|
759
|
-
- `[Document~]` — document (wavy bottom)
|
|
760
|
-
|
|
761
|
-
**Arrows**: `-label-> Target`, `-(color)-> Target`, `-label(color)-> Target`
|
|
762
|
-
|
|
763
|
-
**Inferred arrow colors** — when a label matches a well-known keyword, the arrow color is set automatically:
|
|
764
|
-
|
|
765
|
-
| Label | Inferred Color |
|
|
766
|
-
|---|---|
|
|
767
|
-
| yes, success, ok, true | green |
|
|
768
|
-
| no, fail, error, false | red |
|
|
769
|
-
| maybe, warning | orange |
|
|
770
|
-
|
|
771
|
-
Colors on nodes: `[Process(blue)]`
|
|
772
|
-
|
|
773
|
-
### state
|
|
774
|
-
|
|
775
|
-
**Syntax:** `state [Title]`
|
|
776
|
-
|
|
777
|
-
**Options:** `direction` (`TB` or `LR`), `color` (`off` for monochrome)
|
|
778
|
-
|
|
779
|
-
**Data format:** States connected by transitions
|
|
780
|
-
|
|
781
|
-
Minimal example:
|
|
638
|
+
### 9.3 Members (Indented, Colon for Types)
|
|
782
639
|
|
|
640
|
+
**Fields:**
|
|
783
641
|
```
|
|
784
|
-
|
|
642
|
+
+ name: string
|
|
643
|
+
- speed: number
|
|
644
|
+
# protectedField: int
|
|
785
645
|
```
|
|
786
646
|
|
|
787
|
-
|
|
788
|
-
|
|
647
|
+
**Methods:**
|
|
789
648
|
```
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
[Processing(blue)]
|
|
794
|
-
Validating -valid-> Approved
|
|
795
|
-
Validating -invalid-> Rejected(red)
|
|
796
|
-
|
|
797
|
-
[*] -> Pending -submit-> Validating
|
|
798
|
-
Approved -ship-> Shipped -> [*]
|
|
799
|
-
Rejected -> [*]
|
|
800
|
-
Shipped -return-> Pending
|
|
649
|
+
+ sail(): void
|
|
650
|
+
- calculate(x: number): boolean
|
|
651
|
+
+ getName() {static}: string
|
|
801
652
|
```
|
|
802
653
|
|
|
803
|
-
|
|
654
|
+
Visibility: `+` public, `-` private, `#` protected
|
|
804
655
|
|
|
805
|
-
**
|
|
656
|
+
**Enum values:**
|
|
657
|
+
```
|
|
658
|
+
ShipType enum
|
|
659
|
+
Galleon
|
|
660
|
+
Sloop
|
|
661
|
+
```
|
|
806
662
|
|
|
807
|
-
|
|
663
|
+
### 9.4 Relationships (Indented Under Source Class)
|
|
808
664
|
|
|
809
|
-
|
|
665
|
+
| Relationship | Arrow |
|
|
666
|
+
|-------------|-------|
|
|
667
|
+
| Inheritance | `--|>` |
|
|
668
|
+
| Implementation | `..\|>` |
|
|
669
|
+
| Composition | `*--` |
|
|
670
|
+
| Aggregation | `o--` |
|
|
671
|
+
| Dependency | `..>` |
|
|
672
|
+
| Association | `->` |
|
|
810
673
|
|
|
811
|
-
|
|
674
|
+
Relationships are indented under the source class:
|
|
812
675
|
|
|
813
676
|
```
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
677
|
+
Ship
|
|
678
|
+
--|> Vessel
|
|
679
|
+
*-- Cannon
|
|
817
680
|
```
|
|
818
681
|
|
|
819
|
-
|
|
682
|
+
Optional label: `--|> Vessel : extends` (colon optional before label)
|
|
820
683
|
|
|
821
|
-
|
|
684
|
+
`extends` and `implements` on class declarations still work as part of the declaration syntax.
|
|
822
685
|
|
|
823
|
-
|
|
686
|
+
### 9.5 Options
|
|
824
687
|
|
|
825
|
-
|
|
688
|
+
- `no-auto-color` (boolean; auto-coloring is on by default)
|
|
826
689
|
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
**Options:** (none beyond `palette`, `theme`)
|
|
690
|
+
---
|
|
830
691
|
|
|
831
|
-
|
|
692
|
+
## 10. Kanban Boards
|
|
832
693
|
|
|
833
|
-
|
|
694
|
+
### 10.1 Declaration
|
|
834
695
|
|
|
835
696
|
```
|
|
836
|
-
|
|
837
|
-
+ name: string
|
|
838
|
-
+ speak(): void
|
|
839
|
-
|
|
840
|
-
Dog extends Animal
|
|
841
|
-
+ breed: string
|
|
842
|
-
|
|
843
|
-
Cat extends Animal
|
|
844
|
-
+ indoor: boolean
|
|
697
|
+
kanban [Title]
|
|
845
698
|
```
|
|
846
699
|
|
|
847
|
-
|
|
700
|
+
### 10.2 Columns
|
|
848
701
|
|
|
849
702
|
```
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
Printable [interface]
|
|
853
|
-
+ print(): void
|
|
854
|
-
|
|
855
|
-
Shape implements Printable [abstract]
|
|
856
|
-
# x: number
|
|
857
|
-
# y: number
|
|
858
|
-
+ area(): number
|
|
859
|
-
count: number {static}
|
|
860
|
-
|
|
861
|
-
Circle extends Shape
|
|
862
|
-
- radius: number
|
|
863
|
-
+ area(): number
|
|
864
|
-
|
|
865
|
-
Rectangle extends Shape
|
|
866
|
-
- width: number
|
|
867
|
-
- height: number
|
|
868
|
-
|
|
869
|
-
Shape *-- Circle : contains
|
|
703
|
+
[Column Name]
|
|
704
|
+
[Column Name](color) | wip: 3
|
|
870
705
|
```
|
|
871
706
|
|
|
872
|
-
|
|
707
|
+
### 10.3 Cards (Indented Under Columns)
|
|
873
708
|
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
- Inheritance: `A --|> B`
|
|
880
|
-
- Implementation: `A ..|> B`
|
|
881
|
-
- Composition: `A *-- B`
|
|
882
|
-
- Aggregation: `A o-- B`
|
|
883
|
-
- Dependency: `A ..> B`
|
|
884
|
-
- Association: `A -> B`
|
|
885
|
-
- Optional label: `A *-- B : description`
|
|
709
|
+
```
|
|
710
|
+
[To Do]
|
|
711
|
+
Card title | priority: High, c: Owner
|
|
712
|
+
Detail text (indented deeper)
|
|
713
|
+
```
|
|
886
714
|
|
|
887
|
-
###
|
|
715
|
+
### 10.4 Options
|
|
888
716
|
|
|
889
|
-
|
|
717
|
+
- `no-auto-color` (boolean; auto-coloring is on by default)
|
|
718
|
+
- `hide`
|
|
890
719
|
|
|
891
|
-
|
|
720
|
+
---
|
|
892
721
|
|
|
893
|
-
|
|
722
|
+
## 11. Initiative-Status Diagrams
|
|
894
723
|
|
|
895
|
-
|
|
724
|
+
### 11.1 Declaration
|
|
896
725
|
|
|
897
726
|
```
|
|
898
|
-
|
|
899
|
-
id: int [pk]
|
|
900
|
-
name: varchar
|
|
901
|
-
1-* posts
|
|
902
|
-
|
|
903
|
-
posts
|
|
904
|
-
id: int [pk]
|
|
905
|
-
user_id: int [fk]
|
|
727
|
+
initiative-status [Title]
|
|
906
728
|
```
|
|
907
729
|
|
|
908
|
-
|
|
730
|
+
### 11.2 Nodes
|
|
909
731
|
|
|
910
732
|
```
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
users
|
|
914
|
-
id: int [pk]
|
|
915
|
-
email: varchar [unique]
|
|
916
|
-
name: varchar
|
|
917
|
-
1-writes-* posts
|
|
918
|
-
?-moderates-* categories
|
|
919
|
-
|
|
920
|
-
posts
|
|
921
|
-
id: int [pk]
|
|
922
|
-
title: varchar
|
|
923
|
-
body: text
|
|
924
|
-
author_id: int [fk]
|
|
925
|
-
category_id: int [fk, nullable]
|
|
926
|
-
|
|
927
|
-
categories
|
|
928
|
-
id: int [pk]
|
|
929
|
-
name: varchar [unique]
|
|
930
|
-
1-* posts
|
|
733
|
+
NodeLabel | status, key: value
|
|
734
|
+
NodeLabel | done, t: Team1
|
|
931
735
|
```
|
|
932
736
|
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
**Relationships** — indented under the source table (preferred):
|
|
936
|
-
- `1-* target` — one-to-many
|
|
937
|
-
- `1-1 target` — one-to-one
|
|
938
|
-
- `?-1 target` — zero-or-one to one
|
|
939
|
-
- `?-* target` — zero-or-more
|
|
940
|
-
- Labeled: `1-writes-* target` (label between dashes)
|
|
941
|
-
|
|
942
|
-
Columns and relationships can be mixed under the same table. The parser distinguishes them by the leading cardinality character (`1`, `*`, `?`).
|
|
943
|
-
|
|
944
|
-
**Flat relationships** — at indent 0 (also supported):
|
|
945
|
-
- `table1 1--* table2` — one-to-many
|
|
946
|
-
- `table1 1--* table2 : label` — with label
|
|
737
|
+
Status values and equivalences:
|
|
947
738
|
|
|
948
|
-
|
|
739
|
+
| User writes | Canonical | Display |
|
|
740
|
+
|------------|-----------|---------|
|
|
741
|
+
| `done` | `done` | Done |
|
|
742
|
+
| `doing` | `doing` | In Progress |
|
|
743
|
+
| `wip` | `doing` | In Progress |
|
|
744
|
+
| `blocked` | `blocked` | Blocked |
|
|
745
|
+
| `paused` | `blocked` | Blocked |
|
|
746
|
+
| `waiting` | `blocked` | Blocked |
|
|
747
|
+
| `todo` | `todo` | To Do |
|
|
748
|
+
| `na` | `na` | N/A |
|
|
749
|
+
| (omitted) | `na` | N/A |
|
|
949
750
|
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
**Options:** (none beyond `palette`, `theme`)
|
|
953
|
-
|
|
954
|
-
**Data format:** Element declarations with `Name is a type`, relationships with arrows
|
|
955
|
-
|
|
956
|
-
Minimal example:
|
|
751
|
+
### 11.3 Edges
|
|
957
752
|
|
|
958
753
|
```
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
MyApp is a system | description: The main application
|
|
963
|
-
-Uses-> User
|
|
754
|
+
Source -> Target
|
|
755
|
+
Source -label-> Target
|
|
756
|
+
Source -> Target | status
|
|
964
757
|
```
|
|
965
758
|
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
759
|
+
Indented shorthand (source from preceding node):
|
|
760
|
+
```
|
|
761
|
+
Captain | t: Bridge
|
|
762
|
+
-issueOrders-> CrewApp | na
|
|
970
763
|
```
|
|
971
|
-
c4 Banking System
|
|
972
764
|
|
|
973
|
-
|
|
974
|
-
Internal(blue) default
|
|
975
|
-
External(gray)
|
|
765
|
+
### 11.4 Groups
|
|
976
766
|
|
|
977
|
-
|
|
767
|
+
```
|
|
768
|
+
[Group Name]
|
|
769
|
+
indented nodes...
|
|
770
|
+
```
|
|
978
771
|
|
|
979
|
-
|
|
980
|
-
-Delivers content-> Customer | tech: HTTPS
|
|
981
|
-
-Sends emails-> Email | tech: SMTP
|
|
772
|
+
### 11.5 Options
|
|
982
773
|
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
-API calls-> API | tech: JSON/HTTPS
|
|
774
|
+
- `active-tag GroupName`
|
|
775
|
+
- `hide phase:Planning, phase:Review` (colon syntax for tag:value)
|
|
986
776
|
|
|
987
|
-
|
|
988
|
-
-Reads/writes-> Database | tech: SQL
|
|
777
|
+
---
|
|
989
778
|
|
|
990
|
-
|
|
779
|
+
## 12. Sitemap Diagrams
|
|
991
780
|
|
|
992
|
-
|
|
993
|
-
~Sends emails~> Customer
|
|
781
|
+
### 12.1 Declaration
|
|
994
782
|
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
container Web App
|
|
998
|
-
Railway
|
|
999
|
-
container API
|
|
1000
|
-
Neon is a database
|
|
1001
|
-
container Database
|
|
783
|
+
```
|
|
784
|
+
sitemap [Title]
|
|
1002
785
|
```
|
|
1003
786
|
|
|
1004
|
-
|
|
1005
|
-
- `Name is a person` — human actor
|
|
1006
|
-
- `Name is a system` — software system
|
|
1007
|
-
- `Name is a container` — application/service within a system
|
|
1008
|
-
- `Name is a component` — component within a container
|
|
1009
|
-
- `Name is a external` — external system
|
|
1010
|
-
- `Name is a database` — database element
|
|
787
|
+
### 12.2 Pages (Indentation = Hierarchy)
|
|
1011
788
|
|
|
1012
|
-
|
|
789
|
+
```
|
|
790
|
+
Home
|
|
791
|
+
About
|
|
792
|
+
Pricing | Auth: Public
|
|
793
|
+
Enterprise
|
|
794
|
+
Blog
|
|
795
|
+
```
|
|
1013
796
|
|
|
1014
|
-
|
|
797
|
+
### 12.3 Arrows
|
|
1015
798
|
|
|
1016
|
-
|
|
799
|
+
```
|
|
800
|
+
Home
|
|
801
|
+
-pricing-> Pricing
|
|
802
|
+
-login-> Login
|
|
803
|
+
```
|
|
1017
804
|
|
|
1018
|
-
|
|
1019
|
-
- Sync: `-> Target` or `-label-> Target`
|
|
1020
|
-
- Async: `~> Target` or `~label~> Target`
|
|
1021
|
-
- With technology metadata: `-label-> Target | tech: HTTPS`
|
|
805
|
+
### 12.4 Containers
|
|
1022
806
|
|
|
1023
|
-
|
|
807
|
+
```
|
|
808
|
+
[Marketing]
|
|
809
|
+
Pricing | Auth: Public
|
|
810
|
+
```
|
|
1024
811
|
|
|
1025
|
-
###
|
|
812
|
+
### 12.5 Options
|
|
1026
813
|
|
|
1027
|
-
|
|
814
|
+
- `direction-tb` (boolean; default is LR)
|
|
1028
815
|
|
|
1029
|
-
|
|
816
|
+
---
|
|
1030
817
|
|
|
1031
|
-
|
|
818
|
+
## 13. Gantt Charts
|
|
1032
819
|
|
|
1033
|
-
|
|
820
|
+
### 13.1 Declaration
|
|
1034
821
|
|
|
1035
822
|
```
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
CEO
|
|
1039
|
-
VP Engineering
|
|
1040
|
-
Team Lead
|
|
1041
|
-
VP Marketing
|
|
823
|
+
gantt [Title]
|
|
1042
824
|
```
|
|
1043
825
|
|
|
1044
|
-
|
|
826
|
+
### 13.2 Options (Space-Separated, NO Colon)
|
|
1045
827
|
|
|
1046
828
|
```
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
Manager(blue)
|
|
1054
|
-
IC(green) default
|
|
1055
|
-
|
|
1056
|
-
CTO | lv: Director
|
|
1057
|
-
VP Engineering | lv: Director
|
|
1058
|
-
[Platform]
|
|
1059
|
-
Lead | lv: Manager
|
|
1060
|
-
Dev 1
|
|
1061
|
-
Dev 2
|
|
1062
|
-
[Product]
|
|
1063
|
-
Lead | lv: Manager
|
|
1064
|
-
Dev 3
|
|
829
|
+
start 2026-03-15
|
|
830
|
+
today-marker
|
|
831
|
+
today-marker 2026-03-27
|
|
832
|
+
critical-path
|
|
833
|
+
no-dependencies
|
|
834
|
+
sort tag:Team
|
|
1065
835
|
```
|
|
1066
836
|
|
|
1067
|
-
|
|
837
|
+
### 13.3 Holidays
|
|
1068
838
|
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
839
|
+
```
|
|
840
|
+
holiday
|
|
841
|
+
2024-02-19 Presidents Day
|
|
842
|
+
2024-05-27 -> 2024-05-29 Memorial Weekend
|
|
843
|
+
```
|
|
1072
844
|
|
|
1073
|
-
###
|
|
845
|
+
### 13.4 Workweek
|
|
1074
846
|
|
|
1075
|
-
|
|
847
|
+
```
|
|
848
|
+
workweek mon-fri
|
|
849
|
+
workweek sun-thu
|
|
850
|
+
```
|
|
1076
851
|
|
|
1077
|
-
|
|
852
|
+
Top-level directive (not nested under `holiday`).
|
|
1078
853
|
|
|
1079
|
-
|
|
854
|
+
### 13.5 Eras
|
|
1080
855
|
|
|
1081
|
-
|
|
856
|
+
**Flat form:**
|
|
857
|
+
```
|
|
858
|
+
era 2026-04-06 -> 2026-04-10 Conference (purple)
|
|
859
|
+
```
|
|
1082
860
|
|
|
861
|
+
**Block form:**
|
|
862
|
+
```
|
|
863
|
+
era
|
|
864
|
+
2026-04-06 -> 2026-04-10 Conference (purple)
|
|
865
|
+
2026-06-01 -> 2026-06-05 Sprint Review (blue)
|
|
1083
866
|
```
|
|
1084
|
-
kanban
|
|
1085
867
|
|
|
1086
|
-
|
|
1087
|
-
Task 1
|
|
1088
|
-
Task 2
|
|
868
|
+
### 13.6 Markers
|
|
1089
869
|
|
|
1090
|
-
|
|
1091
|
-
|
|
870
|
+
**Flat form:**
|
|
871
|
+
```
|
|
872
|
+
marker 2026-03-27 Board Review
|
|
1092
873
|
```
|
|
1093
874
|
|
|
1094
|
-
|
|
1095
|
-
|
|
875
|
+
**Block form:**
|
|
876
|
+
```
|
|
877
|
+
marker
|
|
878
|
+
2026-03-27 Board Review
|
|
879
|
+
2026-06-15 Release (green)
|
|
1096
880
|
```
|
|
1097
|
-
kanban Sprint Board
|
|
1098
881
|
|
|
1099
|
-
|
|
1100
|
-
Critical(red)
|
|
1101
|
-
High(orange)
|
|
1102
|
-
Low(green) default
|
|
882
|
+
### 13.7 Groups (Swimlanes)
|
|
1103
883
|
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
884
|
+
```
|
|
885
|
+
[Backend] | t: Engineering
|
|
886
|
+
```
|
|
1107
887
|
|
|
1108
|
-
|
|
1109
|
-
Research API options | priority: High, o: Alice
|
|
888
|
+
Bracket syntax only.
|
|
1110
889
|
|
|
1111
|
-
|
|
1112
|
-
Build auth module | priority: Critical, o: Bob
|
|
1113
|
-
Integrate OAuth2
|
|
1114
|
-
Add session management
|
|
890
|
+
### 13.8 Tasks
|
|
1115
891
|
|
|
1116
|
-
|
|
1117
|
-
|
|
892
|
+
```
|
|
893
|
+
20bd Database Schema | p: Foundation, 100%
|
|
894
|
+
10bd API Integration | t: Engineering
|
|
895
|
+
0d Launch Day
|
|
896
|
+
2026-03-15 -> 30d Setup
|
|
1118
897
|
```
|
|
1119
898
|
|
|
1120
|
-
|
|
899
|
+
Duration units: `min`, `h`, `d`, `bd` (business days), `w`, `m`, `q`, `y`
|
|
900
|
+
Uncertain: `10bd?` (trailing `?`)
|
|
901
|
+
Progress: `| 80%` in pipe metadata
|
|
1121
902
|
|
|
1122
|
-
|
|
903
|
+
### 13.9 Dependencies (Indented Under Tasks)
|
|
1123
904
|
|
|
1124
|
-
|
|
905
|
+
```
|
|
906
|
+
10bd API Integration
|
|
907
|
+
-> E2E Testing
|
|
908
|
+
-> Launch Day | offset: 10bd
|
|
909
|
+
```
|
|
1125
910
|
|
|
1126
|
-
###
|
|
911
|
+
### 13.10 Parallel Block
|
|
1127
912
|
|
|
1128
|
-
|
|
913
|
+
```
|
|
914
|
+
parallel
|
|
915
|
+
[Backend]
|
|
916
|
+
20bd Schema
|
|
917
|
+
[Frontend]
|
|
918
|
+
10bd Wireframes
|
|
919
|
+
```
|
|
1129
920
|
|
|
1130
|
-
|
|
921
|
+
---
|
|
1131
922
|
|
|
1132
|
-
|
|
923
|
+
## 14. Timeline Diagrams
|
|
1133
924
|
|
|
1134
|
-
|
|
925
|
+
### 14.1 Declaration
|
|
1135
926
|
|
|
1136
927
|
```
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
Auth | done
|
|
1140
|
-
-> UserService | doing
|
|
1141
|
-
-> NotifyService | todo
|
|
1142
|
-
UserService | doing
|
|
1143
|
-
NotifyService | todo
|
|
928
|
+
timeline [Title]
|
|
1144
929
|
```
|
|
1145
930
|
|
|
1146
|
-
|
|
931
|
+
### 14.2 Events
|
|
1147
932
|
|
|
933
|
+
**Point event:**
|
|
1148
934
|
```
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
Auth | done
|
|
1152
|
-
-depends-> UserService | doing
|
|
1153
|
-
-feeds-> Dashboard | todo
|
|
1154
|
-
Dashboard | todo
|
|
1155
|
-
UserService | doing
|
|
1156
|
-
-calls-> DBLayer | done
|
|
1157
|
-
DBLayer | done
|
|
1158
|
-
|
|
1159
|
-
[External]
|
|
1160
|
-
PaymentGW | na
|
|
1161
|
-
EmailProvider | na
|
|
935
|
+
1718-05 Blockades Charleston | p: Blackbeard
|
|
1162
936
|
```
|
|
1163
937
|
|
|
1164
|
-
**
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
**Relationships**: `-label-> Target | status` or indented children.
|
|
1169
|
-
|
|
1170
|
-
**Groups**: `[Group Name]` for visual grouping. `[Group Name] | key: value` — pipe metadata cascades to contained nodes.
|
|
1171
|
-
|
|
1172
|
-
### sitemap
|
|
938
|
+
**Range event:**
|
|
939
|
+
```
|
|
940
|
+
1716 -> 1717 Sails under Hornigold | p: Blackbeard
|
|
941
|
+
```
|
|
1173
942
|
|
|
1174
|
-
**
|
|
943
|
+
**Duration event:**
|
|
944
|
+
```
|
|
945
|
+
2026-03-20 -> 30d Sprint 1
|
|
946
|
+
```
|
|
1175
947
|
|
|
1176
|
-
**
|
|
948
|
+
**Uncertain ending:**
|
|
949
|
+
```
|
|
950
|
+
1718 -> 1719? Rackham builds crew
|
|
951
|
+
```
|
|
1177
952
|
|
|
1178
|
-
|
|
953
|
+
Date formats: `YYYY`, `YYYY-MM`, `YYYY-MM-DD`, `YYYY-MM-DD HH:MM`
|
|
954
|
+
Duration units: `min`, `h`, `d`, `w`, `m`, `y`
|
|
1179
955
|
|
|
1180
|
-
|
|
956
|
+
### 14.3 Eras
|
|
1181
957
|
|
|
958
|
+
**Flat form:**
|
|
1182
959
|
```
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
Home
|
|
1186
|
-
-about-> About
|
|
1187
|
-
-blog-> Blog
|
|
1188
|
-
|
|
1189
|
-
[Content]
|
|
1190
|
-
About
|
|
1191
|
-
Blog
|
|
1192
|
-
-read-> Post
|
|
1193
|
-
Post
|
|
960
|
+
era 1716 -> 1718 Nassau Republic
|
|
1194
961
|
```
|
|
1195
962
|
|
|
1196
|
-
|
|
1197
|
-
|
|
963
|
+
**Block form:**
|
|
964
|
+
```
|
|
965
|
+
era
|
|
966
|
+
1716 -> 1718 Nassau Republic
|
|
967
|
+
1718 -> 1720 Woodes Rogers Era (orange)
|
|
1198
968
|
```
|
|
1199
|
-
sitemap SaaS Platform
|
|
1200
|
-
direction TB
|
|
1201
|
-
|
|
1202
|
-
tag Auth
|
|
1203
|
-
Public(green)
|
|
1204
|
-
Required(blue)
|
|
1205
|
-
Admin(red)
|
|
1206
969
|
|
|
1207
|
-
|
|
1208
|
-
Landing(purple)
|
|
1209
|
-
Form(orange)
|
|
1210
|
-
Content(cyan)
|
|
970
|
+
### 14.4 Markers
|
|
1211
971
|
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
-login-> Login
|
|
1217
|
-
-docs-> Docs
|
|
972
|
+
**Flat form:**
|
|
973
|
+
```
|
|
974
|
+
marker 1718-07 Woodes Rogers arrives (orange)
|
|
975
|
+
```
|
|
1218
976
|
|
|
1219
|
-
|
|
1220
|
-
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
|
|
977
|
+
**Block form:**
|
|
978
|
+
```
|
|
979
|
+
marker
|
|
980
|
+
1718-07 Woodes Rogers arrives (orange)
|
|
981
|
+
1720-01 End of Golden Age (red)
|
|
982
|
+
```
|
|
1224
983
|
|
|
1225
|
-
|
|
1226
|
-
Auth: Public
|
|
1227
|
-
Type: Content
|
|
984
|
+
### 14.5 Groups
|
|
1228
985
|
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
-success-> Dashboard
|
|
1234
|
-
-forgot-> Reset Password
|
|
986
|
+
```
|
|
987
|
+
[Royal Navy]
|
|
988
|
+
1718-07 Woodes Rogers arrives
|
|
989
|
+
```
|
|
1235
990
|
|
|
1236
|
-
|
|
1237
|
-
Auth: Public
|
|
1238
|
-
Type: Form
|
|
1239
|
-
-success-> Dashboard
|
|
991
|
+
---
|
|
1240
992
|
|
|
1241
|
-
|
|
1242
|
-
Auth: Public
|
|
1243
|
-
Type: Form
|
|
1244
|
-
-submitted-> Login
|
|
993
|
+
## 15. Data Charts
|
|
1245
994
|
|
|
1246
|
-
|
|
1247
|
-
Dashboard
|
|
1248
|
-
Auth: Required
|
|
1249
|
-
Type: Landing
|
|
1250
|
-
-projects-> Projects
|
|
1251
|
-
-settings-> Settings
|
|
995
|
+
### 15.1 Simple Charts (bar, line, pie, doughnut, area, polar-area, radar, bar-stacked)
|
|
1252
996
|
|
|
1253
|
-
|
|
1254
|
-
Auth: Required
|
|
1255
|
-
Type: Content
|
|
997
|
+
**Declaration:** `bar [Title]`, `line [Title]`, etc.
|
|
1256
998
|
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
999
|
+
**Series:**
|
|
1000
|
+
```
|
|
1001
|
+
series Name1 Name2
|
|
1002
|
+
series
|
|
1003
|
+
Name1
|
|
1004
|
+
Name2(color)
|
|
1261
1005
|
```
|
|
1262
1006
|
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
**Groups**: `[Group Name]` wraps indented children in a container.
|
|
1266
|
-
|
|
1267
|
-
**Arrows**: `-label-> Target`, `-(color)-> Target`, `-label(color)-> Target` — cross-link between any pages. Arrow colors are inferred from well-known labels (see flowchart section).
|
|
1007
|
+
Commas between series names are optional.
|
|
1268
1008
|
|
|
1269
|
-
**
|
|
1009
|
+
**Data rows (space-separated, NO colon):**
|
|
1010
|
+
```
|
|
1011
|
+
Label 100
|
|
1012
|
+
Label 100 200 300
|
|
1013
|
+
Label(color) 100
|
|
1014
|
+
```
|
|
1270
1015
|
|
|
1271
|
-
|
|
1016
|
+
Commas between values are optional. Thousands commas are supported (`3,984,078.65` is a valid number).
|
|
1272
1017
|
|
|
1273
|
-
**
|
|
1018
|
+
**Options (space-separated, NO colon):**
|
|
1019
|
+
```
|
|
1020
|
+
title My Chart
|
|
1021
|
+
xlabel X Label
|
|
1022
|
+
ylabel Y Label
|
|
1023
|
+
orientation-horizontal
|
|
1024
|
+
stacked
|
|
1025
|
+
```
|
|
1274
1026
|
|
|
1275
|
-
|
|
1027
|
+
- `orientation-horizontal` (boolean; default is vertical bars)
|
|
1028
|
+
- `stacked` (boolean; default is off)
|
|
1029
|
+
- Legend is always shown (no option needed)
|
|
1276
1030
|
|
|
1277
|
-
**
|
|
1031
|
+
**Labels** default to showing all parts (name + value + percent for pie-family). Disable parts individually:
|
|
1032
|
+
- `no-label-name` — hide name
|
|
1033
|
+
- `no-label-value` — hide value
|
|
1034
|
+
- `no-label-percent` — hide percent
|
|
1278
1035
|
|
|
1279
|
-
|
|
1036
|
+
**Eras (line/area only):**
|
|
1037
|
+
```
|
|
1038
|
+
era Day 1 -> Day 3 Rough Seas (red)
|
|
1039
|
+
```
|
|
1280
1040
|
|
|
1281
|
-
|
|
1041
|
+
### 15.2 Scatter / Bubble Charts
|
|
1282
1042
|
|
|
1283
|
-
**
|
|
1043
|
+
**Data rows (space-separated, NO colon):**
|
|
1044
|
+
```
|
|
1045
|
+
Name x y
|
|
1046
|
+
Name x y size
|
|
1047
|
+
```
|
|
1284
1048
|
|
|
1285
|
-
|
|
1049
|
+
Commas between values are optional. Thousands commas supported.
|
|
1286
1050
|
|
|
1287
|
-
|
|
1051
|
+
**Categories:**
|
|
1052
|
+
```
|
|
1053
|
+
[Caribbean](red)
|
|
1054
|
+
Blackbeard 90 8500
|
|
1055
|
+
```
|
|
1288
1056
|
|
|
1057
|
+
**Options:**
|
|
1058
|
+
```
|
|
1059
|
+
xlabel Weight
|
|
1060
|
+
ylabel Height
|
|
1061
|
+
sizelabel Crew
|
|
1062
|
+
no-labels
|
|
1289
1063
|
```
|
|
1290
|
-
infra
|
|
1291
1064
|
|
|
1292
|
-
|
|
1293
|
-
rps: 1000
|
|
1294
|
-
-> CDN
|
|
1065
|
+
Labels are on by default. Use `no-labels` to hide point names.
|
|
1295
1066
|
|
|
1296
|
-
|
|
1297
|
-
cache-hit: 80%
|
|
1298
|
-
-> API
|
|
1067
|
+
### 15.3 Heatmap
|
|
1299
1068
|
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
latency-ms: 30
|
|
1069
|
+
**Columns:**
|
|
1070
|
+
```
|
|
1071
|
+
columns Jan Feb Mar
|
|
1304
1072
|
```
|
|
1305
1073
|
|
|
1306
|
-
|
|
1074
|
+
Commas between column names are optional.
|
|
1307
1075
|
|
|
1076
|
+
**Data rows (space-separated, NO colon):**
|
|
1077
|
+
```
|
|
1078
|
+
RowLabel 5 4 3
|
|
1308
1079
|
```
|
|
1309
|
-
infra Production Traffic Flow
|
|
1310
|
-
direction LR
|
|
1311
1080
|
|
|
1312
|
-
|
|
1313
|
-
Backend(blue)
|
|
1314
|
-
Platform(teal)
|
|
1081
|
+
Commas between values are optional. Thousands commas supported.
|
|
1315
1082
|
|
|
1316
|
-
|
|
1317
|
-
rps: 10000
|
|
1318
|
-
-> CloudFront
|
|
1083
|
+
### 15.4 Function Charts (Colon REQUIRED)
|
|
1319
1084
|
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1085
|
+
```
|
|
1086
|
+
function Trajectories
|
|
1087
|
+
xlabel Distance
|
|
1088
|
+
ylabel Height
|
|
1089
|
+
x 0 to 250
|
|
1323
1090
|
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1091
|
+
15 degrees(blue): -0.001*x^2 + 0.27*x
|
|
1092
|
+
45 degrees(red): -0.003*x^2 + 0.75*x
|
|
1093
|
+
```
|
|
1327
1094
|
|
|
1328
|
-
|
|
1329
|
-
-/api-> [API Pods] | split: 60%
|
|
1330
|
-
-/purchase-> [Commerce Pods] | split: 30%
|
|
1331
|
-
-/static-> StaticServer | split: 10%
|
|
1095
|
+
The colon between name and expression is **required** — both sides can contain spaces, so colon is the unambiguous delimiter.
|
|
1332
1096
|
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
instances: 3
|
|
1336
|
-
max-rps: 500
|
|
1337
|
-
latency-ms: 45
|
|
1338
|
-
cb-error-threshold: 50%
|
|
1097
|
+
**Options:**
|
|
1098
|
+
- `shade` (boolean; off by default, shades area below curves when enabled)
|
|
1339
1099
|
|
|
1340
|
-
|
|
1341
|
-
PurchaseMS
|
|
1342
|
-
instances: 1-8
|
|
1343
|
-
max-rps: 300
|
|
1344
|
-
latency-ms: 120
|
|
1100
|
+
### 15.5 Sankey Charts
|
|
1345
1101
|
|
|
1346
|
-
|
|
1347
|
-
|
|
1102
|
+
**Tree structure (indented, space-separated):**
|
|
1103
|
+
```
|
|
1104
|
+
Sugar Plantations(green)
|
|
1105
|
+
Tortuga Distillery(orange) 3000
|
|
1106
|
+
Nassau Distillery 2500
|
|
1348
1107
|
```
|
|
1349
1108
|
|
|
1350
|
-
**
|
|
1109
|
+
**Explicit links:**
|
|
1110
|
+
```
|
|
1111
|
+
Source -> Target 3500
|
|
1112
|
+
Source -- Target 2000
|
|
1113
|
+
```
|
|
1351
1114
|
|
|
1352
|
-
|
|
1353
|
-
- `cache-hit: N%` — percentage of traffic served from cache (reduces downstream flow)
|
|
1354
|
-
- `firewall-block: N%` — percentage of traffic blocked (reduces downstream flow)
|
|
1355
|
-
- `ratelimit-rps: N` — maximum rps allowed through (excess dropped)
|
|
1356
|
-
- `max-rps: N` — maximum rps capacity per instance
|
|
1357
|
-
- `instances: N` or `instances: N-M` — fixed or auto-scaling instance count
|
|
1358
|
-
- `latency-ms: N` — per-request latency in milliseconds
|
|
1359
|
-
- `cb-error-threshold: N%` — circuit breaker opens when overload exceeds this ratio
|
|
1360
|
-
- `cb-latency-threshold-ms: N` — circuit breaker opens when cumulative latency exceeds this
|
|
1115
|
+
`->` = directed, `--` = undirected. Thousands commas supported in values.
|
|
1361
1116
|
|
|
1362
|
-
|
|
1363
|
-
- `database`, `cache`, `queue`, `service`, `gateway`, `storage`, `function`, `network`
|
|
1364
|
-
- Example: `Redis is a cache`, `SQS is a queue`
|
|
1117
|
+
### 15.6 Chord Charts
|
|
1365
1118
|
|
|
1366
|
-
|
|
1367
|
-
|
|
1368
|
-
|
|
1369
|
-
|
|
1370
|
-
- Fan-out multiplier: `-> Target | fanout: 5` or `-> Target | split: 50%, fanout: 5`
|
|
1119
|
+
```
|
|
1120
|
+
Blackbeard -- Bonnet 150 // undirected
|
|
1121
|
+
Roberts -> Rackham 20 // directed
|
|
1122
|
+
```
|
|
1371
1123
|
|
|
1372
|
-
|
|
1124
|
+
Thousands commas supported in values.
|
|
1373
1125
|
|
|
1374
|
-
|
|
1126
|
+
### 15.7 Funnel Charts
|
|
1375
1127
|
|
|
1376
|
-
**
|
|
1128
|
+
**Data rows (space-separated, NO colon):**
|
|
1129
|
+
```
|
|
1130
|
+
Visits 1200
|
|
1131
|
+
Signups 800
|
|
1132
|
+
Purchases 200
|
|
1133
|
+
```
|
|
1377
1134
|
|
|
1378
|
-
|
|
1135
|
+
Thousands commas supported.
|
|
1379
1136
|
|
|
1380
|
-
|
|
1137
|
+
---
|
|
1381
1138
|
|
|
1382
|
-
|
|
1139
|
+
## 16. Visualizations
|
|
1383
1140
|
|
|
1384
|
-
|
|
1141
|
+
### 16.1 Slope Charts (Colon REQUIRED for data)
|
|
1385
1142
|
|
|
1386
|
-
|
|
1143
|
+
```
|
|
1144
|
+
slope Fleet Strength
|
|
1387
1145
|
|
|
1388
|
-
|
|
1146
|
+
1715 1725
|
|
1389
1147
|
|
|
1390
|
-
|
|
1148
|
+
Blackbeard: 40 4
|
|
1149
|
+
Roberts: 12 52
|
|
1150
|
+
```
|
|
1391
1151
|
|
|
1392
|
-
|
|
1152
|
+
- Period labels on their own line, commas optional
|
|
1153
|
+
- Data rows: `Label: value1 value2` — colon required, commas between values optional
|
|
1154
|
+
- Thousands commas supported in values
|
|
1393
1155
|
|
|
1394
|
-
|
|
1156
|
+
### 16.2 Wordcloud
|
|
1395
1157
|
|
|
1396
1158
|
```
|
|
1397
|
-
|
|
1159
|
+
wordcloud Pirate Skills
|
|
1160
|
+
rotate none
|
|
1161
|
+
max 50
|
|
1162
|
+
size 14 80
|
|
1398
1163
|
|
|
1399
|
-
|
|
1400
|
-
|
|
1401
|
-
20bd Implementation
|
|
1402
|
-
-> Testing
|
|
1403
|
-
5bd Testing
|
|
1164
|
+
swordsmanship 95
|
|
1165
|
+
navigation 88
|
|
1404
1166
|
```
|
|
1405
1167
|
|
|
1406
|
-
|
|
1168
|
+
- Data: space-separated only (`word value`)
|
|
1169
|
+
- Options: `rotate none|mixed|angled`, `max N`, `size min max`
|
|
1407
1170
|
|
|
1408
|
-
|
|
1171
|
+
### 16.3 Arc Diagrams (Colon Before Weight)
|
|
1409
1172
|
|
|
1410
1173
|
```
|
|
1411
|
-
|
|
1412
|
-
start 2024-01-01
|
|
1413
|
-
today-marker on
|
|
1174
|
+
arc Pirate Alliances
|
|
1414
1175
|
|
|
1415
|
-
|
|
1416
|
-
|
|
1417
|
-
|
|
1176
|
+
[Caribbean](red)
|
|
1177
|
+
Blackbeard -> Bonnet: 8
|
|
1178
|
+
Blackbeard -> Vane: 5
|
|
1418
1179
|
|
|
1419
|
-
|
|
1420
|
-
2024-01-15: MLK Day
|
|
1421
|
-
2024-02-19: Presidents Day
|
|
1422
|
-
|
|
1423
|
-
era 2024-01 -> 2024-03 Phase 1(blue)
|
|
1424
|
-
marker 2024-02-15 Sprint Review(orange)
|
|
1425
|
-
|
|
1426
|
-
[Design]
|
|
1427
|
-
5bd UX Research | t: Frontend
|
|
1428
|
-
10bd Wireframes | t: Frontend
|
|
1429
|
-
-informs-> API Design
|
|
1430
|
-
|
|
1431
|
-
[Engineering]
|
|
1432
|
-
15bd API Design | t: Backend
|
|
1433
|
-
-> Frontend Build | offset: 2bd
|
|
1434
|
-
20bd Frontend Build | t: Frontend
|
|
1435
|
-
10bd Integration Testing
|
|
1180
|
+
order group
|
|
1436
1181
|
```
|
|
1437
1182
|
|
|
1438
|
-
|
|
1439
|
-
|
|
1440
|
-
**Tasks**: `<duration> <name>` — duration units: `bd` (business days), `d` (days), `w` (weeks), `m` (months), `q` (quarters), `y` (years), `h` (hours), `min` (minutes).
|
|
1183
|
+
- Link: `Source -> Target: weight` — colon before optional weight
|
|
1184
|
+
- Options: `order appearance|name|group|degree`
|
|
1441
1185
|
|
|
1442
|
-
|
|
1186
|
+
### 16.4 Venn Diagrams
|
|
1443
1187
|
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
**Dependencies**: `-label-> Target` or `-> Target` — indented under the source task. The target task starts after the source completes.
|
|
1447
|
-
|
|
1448
|
-
**Dependency offsets**: `-> Target | offset: 2bd` — positive offset adds a gap; `-> Target | offset: -3d` — negative offset creates overlap (lead time).
|
|
1449
|
-
|
|
1450
|
-
**Labeled dependency arrows**: `-label-> Target` — the label text appears on the rendered arrow.
|
|
1451
|
-
|
|
1452
|
-
**Groups**: `[Group Name]` wraps indented tasks in a collapsible section.
|
|
1453
|
-
|
|
1454
|
-
**Group metadata cascading**: `[Group Name] | key: value` — pipe metadata cascades to all tasks in the group.
|
|
1455
|
-
|
|
1456
|
-
**Eras**: `era YYYY-MM -> YYYY-MM Label(color)` — background shading bands.
|
|
1457
|
-
|
|
1458
|
-
**Markers**: `marker YYYY-MM-DD Label(color)` — vertical milestone lines.
|
|
1459
|
-
|
|
1460
|
-
**Holidays**: `holidays` block with `YYYY-MM-DD: Name` entries or `YYYY-MM-DD -> YYYY-MM-DD: Name` ranges. Holiday dates skip business-day counting.
|
|
1461
|
-
|
|
1462
|
-
**Tag groups**: Same syntax as other diagrams — `tag Name alias x` with colored entries.
|
|
1188
|
+
```
|
|
1189
|
+
venn Skill Overlap
|
|
1463
1190
|
|
|
1464
|
-
|
|
1191
|
+
Swordsmanship(red) alias sw
|
|
1192
|
+
Navigation(blue) alias nav
|
|
1193
|
+
Leadership(green) alias lead
|
|
1465
1194
|
|
|
1466
|
-
|
|
1195
|
+
sw + nav Sea Raiders
|
|
1196
|
+
sw + nav + lead Legendary Pirates
|
|
1197
|
+
```
|
|
1467
1198
|
|
|
1468
|
-
|
|
1199
|
+
- Set declaration: `Name(color) alias X`
|
|
1200
|
+
- Intersections: `Set1 + Set2 Label` — label follows the last set reference (no colon)
|
|
1469
1201
|
|
|
1470
|
-
|
|
1471
|
-
tag Priority
|
|
1472
|
-
Critical(red)
|
|
1473
|
-
High(orange)
|
|
1474
|
-
Medium(yellow)
|
|
1475
|
-
Low(green) default
|
|
1202
|
+
### 16.5 Quadrant Diagrams (Colon REQUIRED)
|
|
1476
1203
|
|
|
1477
|
-
tag Team alias t
|
|
1478
|
-
Frontend(blue)
|
|
1479
|
-
Backend(green)
|
|
1480
1204
|
```
|
|
1205
|
+
quadrant Crew Assessment
|
|
1206
|
+
x-axis: Low Skill, High Skill
|
|
1207
|
+
y-axis: Low Loyalty, High Loyalty
|
|
1481
1208
|
|
|
1482
|
-
-
|
|
1483
|
-
-
|
|
1484
|
-
-
|
|
1485
|
-
-
|
|
1486
|
-
|
|
1487
|
-
Assign to elements via pipe metadata: `Element Name | priority: High, t: Frontend`
|
|
1209
|
+
top-right: Promote (green)
|
|
1210
|
+
top-left: Train (yellow)
|
|
1211
|
+
bottom-left: Maroon (red)
|
|
1212
|
+
bottom-right: Watch Closely (purple)
|
|
1488
1213
|
|
|
1489
|
-
|
|
1214
|
+
Quartermaster: 0.9 0.95
|
|
1215
|
+
Navigator: 0.85 0.8
|
|
1216
|
+
```
|
|
1490
1217
|
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
- `# comment` — wrong. Use `// comment`
|
|
1496
|
-
- `chart: bar` + `title: Revenue` — wrong. Use `bar Revenue` (single first line)
|
|
1497
|
-
- `Label: value` in ECharts data — wrong. Use `Label value` (no colon)
|
|
1498
|
-
- `async A -> B: msg` — wrong. Use `A ~msg~> B`
|
|
1499
|
-
- `parallel else` — not supported. Use separate `parallel` blocks
|
|
1500
|
-
- Hex colors `#ff0000` — wrong. Use named colors only: `red`, `green`, `blue`, etc.
|
|
1501
|
-
- `->` inside labeled arrows `A -routes to /api-> B` — ambiguous. Rephrase the label
|
|
1502
|
-
- Missing chart type for ambiguous content — when auto-detection picks the wrong type, add an explicit chart type keyword
|
|
1503
|
-
- `end` keyword in sequence blocks — not needed. Indentation closes blocks
|
|
1504
|
-
- `== Column ==` in kanban — removed. Use `[Column]`
|
|
1505
|
-
- `person Name` in C4 — removed. Use `Name is a person`
|
|
1506
|
-
- `A <-> B` bidirectional arrows — removed. Use two separate lines
|
|
1507
|
-
- `-> Target x5` fan-out — removed. Use `-> Target | fanout: 5`
|
|
1508
|
-
- `lag: 5d` / `lead: 3d` in gantt — removed. Use `offset: 5d` / `offset: -3d`
|
|
1509
|
-
- `Name(color)` in sequence participants — removed. Use `tag` groups for coloring
|
|
1218
|
+
- Axis labels: `x-axis: Low, High` — colon required
|
|
1219
|
+
- Position labels: `top-right: Label` — colon required
|
|
1220
|
+
- Data points: `Label: x y` — colon required, commas between values optional
|
|
1221
|
+
- Thousands commas supported in values
|
|
1510
1222
|
|
|
1511
1223
|
---
|
|
1512
1224
|
|
|
1513
|
-
##
|
|
1514
|
-
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
|
|
1520
|
-
|
|
1521
|
-
|
|
1225
|
+
## 17. Colon Usage Summary
|
|
1226
|
+
|
|
1227
|
+
### Constructs Where Colons Are REQUIRED
|
|
1228
|
+
|
|
1229
|
+
| Construct | Diagram Type | Example |
|
|
1230
|
+
|-----------|-------------|---------|
|
|
1231
|
+
| Pipe metadata | all | `\| key: value, key2: value2` |
|
|
1232
|
+
| Org metadata (indented) | org | `role: Manager` |
|
|
1233
|
+
| C4 metadata (indented) | c4 | `description: SPA built with React` |
|
|
1234
|
+
| Class field types | class | `+ name: string` |
|
|
1235
|
+
| Class method returns | class | `+ sail(): void` |
|
|
1236
|
+
| Function expressions | function | `f(x): x^2 + 1` |
|
|
1237
|
+
| Slope data rows | slope | `Blackbeard: 40 4` |
|
|
1238
|
+
| Quadrant axes | quadrant | `x-axis: Low, High` |
|
|
1239
|
+
| Quadrant positions | quadrant | `top-right: Promote` |
|
|
1240
|
+
| Quadrant data points | quadrant | `Quartermaster: 0.9 0.8` |
|
|
1241
|
+
| Arc link weight | arc | `Source -> Target: 8` |
|
|
1242
|
+
| Hide tag values | initiative-status | `hide phase:Planning` |
|
|
1243
|
+
|
|
1244
|
+
### Colons OPTIONAL
|
|
1245
|
+
|
|
1246
|
+
| Construct | Diagram Type | Example |
|
|
1247
|
+
|-----------|-------------|---------|
|
|
1248
|
+
| Class relationship label | class | `--|> Vessel : extends` or `--|> Vessel extends` |
|
|
1249
|
+
|
|
1250
|
+
### Colons NOT USED
|
|
1251
|
+
|
|
1252
|
+
| Construct | Diagram Type | Example |
|
|
1253
|
+
|-----------|-------------|---------|
|
|
1254
|
+
| Chart type declaration | all | `bar Title` |
|
|
1255
|
+
| Tag declarations | all | `tag Name alias x` |
|
|
1256
|
+
| Boolean options | all | `activations`, `no-activations` |
|
|
1257
|
+
| Key-value options | all | `start 2026-03-15`, `active-tag Team` |
|
|
1258
|
+
| Series declarations | data charts | `series A B C` |
|
|
1259
|
+
| Data rows | bar/line/pie/etc | `Label 100` |
|
|
1260
|
+
| Infra node properties | infra | `latency-ms 50` |
|
|
1261
|
+
| ER columns | er | `id int pk` |
|
|
1262
|
+
| Sequence messages | sequence | `A -msg-> B` |
|
|
1263
|
+
| Groups/containers | all | `[Group Name]` |
|
|
1264
|
+
| Section dividers | sequence | `== Phase ==` |
|
|
1265
|
+
| Comments | all | `// comment` |
|
|
1266
|
+
| Wordcloud data | wordcloud | `swordsmanship 95` |
|
|
1267
|
+
| Venn intersections | venn | `sw + nav Sea Raiders` |
|
|
1268
|
+
|
|
1269
|
+
### The Rule
|
|
1270
|
+
|
|
1271
|
+
**Colons appear in two contexts:**
|
|
1272
|
+
1. **Value assignment** — `key: value` in pipe metadata, indented tag/metadata assignment (org, c4), and hide directives
|
|
1273
|
+
2. **Type/expression separation** — where labels can contain spaces and a delimiter is needed (function expressions, slope data, quadrant data, arc weights, class members)
|
|
1274
|
+
|
|
1275
|
+
**Exception**: Known-schema properties (infra node properties, ER columns) remain space-separated even though they are indented. The colon rule applies to open-ended metadata, not fixed property schemas.
|
|
1276
|
+
|
|
1277
|
+
**Colons never appear in:**
|
|
1278
|
+
- Directives and options (space-separated)
|
|
1279
|
+
- Tag declarations
|
|
1280
|
+
- Chart type declarations
|
|
1281
|
+
- Data rows for simple charts (space or comma delimited)
|
|
1282
|
+
- Structural syntax (groups, sections, arrows, comments)
|