IDs and numbers¶
How a person reads an ID, a number or a unit: tail numbers, units, ratios and money.
Tail-number IDs¶
- Give every object a person can point at a tail number: product prefix, optional type, short code; uppercase, hyphenated.
HGR-7Q2Ksandbox,FDK-EXP-0142experiment,TWR-APR-0391approval,TWR-RCPT-88A1receipt. - Set IDs in
af-id(DM Mono 500). Never lowercase, wrap or truncate an ID; truncate the description beside it. The fleet board may show the code alone (7Q2K) because the pool header carries the prefix. - Lead with the ID: "HGR-0PZ4 failed at test", not "Test failed for sandbox HGR-0PZ4".
- Derive the code from the real ID: a hash written in Crockford base32 (
0-9,A-ZwithoutI L O U), four characters. When two objects on the same page share a code, lengthen both until they differ. Keep the real ID on hover (title), on copy, and in URLs and the API. - Kind segments: the product's main object has none (
HGR-7Q2Kis a sandbox). Others use a short word:JOB,SESsession,APRapproval,SNAPsnapshot,REQrequest,RUN,BLDbuild,TOKtoken,EXPexperiment,RCPTreceipt. Things people name (environments, credentials, named sessions) keep their names. - Where a machine reads the text (commands, commit trailers, logs), keep the real ID. Where a person reads it (Slack, PR comments), lead with the tail number and give the real ID beside it.
Numbers and units¶
- Use tabular figures wherever numbers stack (
datastyle,af-num,af-mono). Right-align numeric columns. - Put a space between number and unit:
14.0 s,41 min,2 vCPU,48.6k tokens. No space before%or after a currency sign:61%,$1.18. - Elapsed clocks as
00:41:07. Span durations in seconds with one decimal. Relative time axes run-60 mintonow. - Money: two decimals in tables (
$0.42), whole units in headlines ($142). Group thousands:2,481. - Ratios in words:
22 of 24 slots,38 of 41. Never38/41. - Show zero as a number (
0,$0.00). Use an em dash only for "not applicable".
Part of the brand book. See also Status, Data and Products.