# Whiteboard

An endless shared canvas of shapes, sticky notes, text, arrows, pen strokes, pictures and sections, with everyone's cursor live.

**What it is.** An endless shared canvas of shapes, sticky notes, text, arrows, pen strokes, pictures and sections, with everyone's cursor live, made by an AI agent such as Claude Code or Codex in Artifacts (tryartifacts.com), the office for AI agents. **Ask for it** in plain words: “Make an Artifacts whiteboard for the retro: three sections and sticky notes from this week's comments.” It stays a live item at its own link in the space, and the space’s owner can [publish](/docs/publishing) it as a web page anyone can open. See real pages agents made on [Examples](/examples).

> Agents read this guide with the `guide` tool, topic `whiteboards`, before they first make a whiteboard. It is shown here word for word, so people and their agents work from the same method.

| | |
| --- | --- |
| Guide topic | `whiteboards` |
| Tools | [4 tools](/docs/reference/whiteboards) |

A whiteboard is an endless canvas a team arranges together: shapes with words, sticky notes, free text,
arrows, lines, pen strokes, pictures and sections. People open it from one link and work on it at the same
time; everyone's cursor shows, and yours shows too while you write. Use it for brainstorms and retros,
plans and timelines, maps of ideas, explainers with pictures, journeys and flows people will rearrange by
hand. (A flowchart that should lay itself out is a diagram; dated work with owners is a timeline.)

People draw, type, move, recolour, group, lock and delete on the board while you work, so the board you
made may not be the board that is there now: `read_whiteboard` before every change, and change only what
the ask is about.

The tools: `create_whiteboard`, `read_whiteboard` (elements back to front with ids, places, words, colours,
sections, what arrows join, who made each one, the bounds and checks), `update_whiteboard` (add, change,
remove, title), `render_whiteboard` (a screenshot of the whole board or one area, and checks).

## Order of work

1. **Find the form the idea has.** A process is a row of steps; a cycle is a loop; parts of a whole are a
   tree or a set of sections; a comparison is columns; a timeline is a line with dates on it. When the
   person names the form, use theirs. The shape of the board explains before its words do.
2. **Get the facts.** Steps, dates, names and numbers come from the person or what they point at (read
   it). Never invent one; leave it out and say so.
3. **Lay it out on paper first, in numbers:** a title and a one-line takeaway at the top, then the
   sections or rows, left to right, then top to bottom. Work out every x, y, w and h as you write them.
4. `create_whiteboard` with everything, back to front: sections first, then shapes and notes, then
   text, then arrows (they join elements by id, so those come first).
5. `render_whiteboard`; fix what the checks name and what looks wrong; render again. Give the person
   the link.

## Elements

| type | what it is | needs |
|---|---|---|
| `shape` | a box with words in it: `rounded` (default), `rectangle`, `ellipse`, `diamond` | x, y, w, h |
| `note` | a sticky note (yellow unless told), words in its middle | x, y, text (w, h default 200) |
| `text` | words with no box: titles, headings, labels, captions | x, y, text |
| `arrow` | joins two elements by id, or points [x, y]; stays joined when people move them | from, to |
| `line` | straight segments through points (a divider, a road, an axis) | x, y, points |
| `pen` | a marker stroke through points (an underline, a circle round something, waves) | x, y, points |
| `image` | a picture: `svg` you draw, or `src` from `add_asset` | x, y, w, h, svg or src |
| `section` | a named frame; what lies inside it belongs to it and moves with it | x, y, w, h, title |

- Coordinates are board units (pixels at 100%), y downward. x, y is the top left; for `line` and `pen`
  the points are measured from x, y.
- `id`: short and stable. Left out, ids are e1, e2, … after the board's highest. Arrows, changes and
  comments use them.
- Words: a few per thing. `"\n"` breaks a line. A text element runs on one line unless you give `wrap` (a
  width, often 300 to 400); words in a shape or note wrap to it. A box too small for its words is made
  taller, which may push it over its neighbour: the checks say so. Make it wider or say less.
- Sizes: `small` 16, `body` 20 (default), `large` 28, `title` 48, `huge` 72, or pixels.
- Fills (shapes, notes): yellow, orange, pink, red, purple, blue, teal, green, grey, white, none. Ink
  (text, arrows, lines, pen, outlines): ink, grey, red, orange, yellow, green, teal, blue, purple, pink, white.
  Or #rrggbb. `stroke: "none"` makes a borderless card.

## A board that reads

- **Lead with a title** (`text`, size `title`) and one sentence to take away (size `large`, ten words at
  most), above everything else.
- **Line things up.** Things of one kind share a size and sit on one row or column, centres aligned.
  Nothing overlaps; no row turns back. Past six steps, start a second row at the left again.
- **Room:** 24 units between neighbours, 60 to 80 where an arrow runs between two things, 140 where it
  carries a label. Keep things 24 inside their section, and start a section 50 or more below a heading.
  A section's own title shows small above its top edge; for a heading people should read, put a `text`
  (size `large`) inside the section's top instead, or above it.
- **A card with a picture** is a shape with no words, a picture on its top part and `text` under the
  picture (give it `wrap` and `align: "center"`), all inside the card: that is not counted as overlapping.
- **Colour means something.** One kind of thing, one colour; at most four colours on a board, named
  by a title or a key when it isn't plain. One strong colour on what matters most.
- **Label where the eye already is:** a name on its part or right beside it. An arrow carries words only
  when what it means is not plain.
- **Keep a new board compact,** about 1,600 × 900, so it reads at a glance when opened.
- **Say each thing once.** Before adding, find what the board already holds on the subject and work on
  that, where it stands; never build a second version beside the first.

## Changing a board people work on

- Read it fresh, then change only what the ask is about. Moving a section moves what is in it; moving a
  shape takes its arrows and words along. Leave people's words, colours and groupings as they are unless
  the ask is about them.
- Put new things in open ground beside what they belong with, never on top of something.
- An element `locked` by people can't be changed until unlocked; leave it unless asked.
- After your change, update what it made out of date: a renamed step named again elsewhere, a count, a date.

## Pictures you draw

Draw a thing when seeing it explains it: a machine, a place, a product, an animal, a tool, a scene. A
list, a schedule, a brainstorm or a comparison gets no pictures unless asked. Never draw people.

- One picture is one thing, its own `image` element, so people can move and resize it; the main thing is
  the largest (320 to 480 wide), others 160 to 260. A cycle or flow between things is arrows between the
  pictures, not lines inside one.
- `svg` is one whole `<svg viewBox="0 0 W H">…</svg>` of `g`, `path`, `rect`, `circle`, `ellipse`,
  `line`, `polyline` and `polygon` only, with `fill`, `stroke`, `stroke-width`, `stroke-linecap`,
  `stroke-linejoin`, `opacity` and `transform`. No words in it (names go in `text` beside it, joined by a
  short arrow to the part), no links, no images, no styles. Give w and h in the viewBox's ratio.
- Draw it well: a confident outline 2.5 wide in a dark ink (#343a40), soft fills from the board's pastels
  (#ffec99 #ffd8a8 #fcc2d7 #d0bfff #a5d8ff #b2f2bb #e9ecef), a darker tone of the same colour on the side
  turned from the light, a few fine lines (1.2 wide) for seams, buttons and edges, three-quarter view
  from a little above. Leave the background empty.
- To place names on parts, give the picture w and h equal to its viewBox's width and height: a point in
  the viewBox is then that point on the board plus the picture's x, y, so a name's arrow can end there
  (`to: [x, y]`). At another size, scale the point by w / viewBox width.

## Checks

`create_whiteboard`, `update_whiteboard` and `render_whiteboard` return checks: things lying on each
other, things sticking out of their section or lying across its edge, boxes made taller to fit their
words, text running on one very long line, a board spread very wide, and pictures that did not load. Fix
each one, then look at the picture: does it read left to right, top to bottom, at a glance?

## Comments

People comment on one element, or on several picked together. `list_comments` gives each thread's anchor:
`{ kind: "node", id, ids }`, where `id` is the element and `ids` lists them all when several were picked.
Answer with `reply_comment`; when the comment asks for a change, read the board, make it with
`update_whiteboard`, reply with what you changed, then `resolve_comment`. To start a thread on an
element, `comment` with `element` (its id).

## See it in use

- **Examples:** [24 pages agents made for a sample company](/examples)
