# Bar Sketch: Stat & chart element for AI agents

> A bar chart sketched into the note: the pen draws the axes, each bar's outline draws up and fills with highlighter, its value is handwritten on top and its label rises underneath.

Canonical page: https://agentframes.ai/elements/jotter/bar-sketch/
Markdown: https://agentframes.ai/elements/jotter/bar-sketch.md

## Overview

- Name: Bar Sketch (`barSketch`), an element: one HyperFrames block per size
- Part of: the [Jotter](https://agentframes.ai/packs/jotter.md) pack (22 of 50). Available only through the All-access subscription.
- Category: Stat & chart
- Purpose: A bar chart sketched into the note: the pen draws the axes, each bar's outline draws up and fills with highlighter, its value is handwritten on top and its label rises underneath.
- Pack: [Jotter](https://agentframes.ai/packs/jotter.md), included in All-access (from $14/month billed annually ($168/year), or $19 monthly)
- Subscribe: POST https://agentframes.ai/api/checkout/subscribe with interval=month or interval=year (optional currency=USD|GBP|EUR|AUD|CAD; 303 redirect to Stripe checkout; a human pays there). Then download any pack with the subscriber key: https://agentframes.ai/account.md
- Aspects: 16:9 (native), 9:16 (native), 4:5 (native), 1:1 (native)
- Canvases: works on Daylight (white note, dusk wallpaper) (`daylight`), Dark mode (graphite note, night wallpaper) (`dark`), Tinted (cream note, sunrise wallpaper) (`tinted`); avoid none
- Typical duration: 10s
- Speaker-safe: no
- Preview video (watermarked): https://agentframes.ai/media/jotter/bar-sketch.mp4
- Poster: https://agentframes.ai/media/jotter/bar-sketch.jpg
- Licence: [AgentFrames Licence](https://agentframes.ai/licence.md)

## Paste this into Claude Code

```text
Use the AgentFrames Jotter pack. Add a `barSketch` beat to plan.json on a `daylight` canvas with slots `title`, `tags`, `items`, `prefix`, `unit`, `highlight`, `note` and `cues` from my script. Then run validate → build → qa and show me qa/contact.jpg.
```

## Variables

| Variable | Type | Label | Description | Default |
|---|---|---|---|---|
| `title` | string | title | the note title (types on first); up to 2 lines. Markup: **bold**, ==yellow==, ++green++, ~~struck~~, __pen underline__. {"type":"string","minLength":1,"maxLength":44} | Hours on deep work |
| `tags` | string | tags | #tags under the title (the first is the accent tag), e.g. ["step 3 of 5", "productivity"]. JSON string. {"type":"array","items":{"type":"string","minLength":1,"maxLength":16},"minItems":0,"maxItems":3} | [] |
| `items` | string | items | JSON string. {"type":"array","items":{"type":"object","properties":{"label":{"type":"string","minLength":1,"maxLength":12},"value":{"type":"number","minimum":0,"maximum":100000}},"required":["label","value"]},"minItems":2,"maxItems":6} | [{"label":"Wk 1","value":4},{"label":"Wk 2","value":6},{"label":"Wk 3","value":9},{"label":"Wk 4","value":11}] |
| `prefix` | string | prefix | {"type":"string","minLength":0,"maxLength":2} |  |
| `unit` | string | unit | {"type":"string","minLength":0,"maxLength":5} | h |
| `highlight` | number | highlight | index of the bar to make yellow (-1 = the tallest). {"type":"integer","minimum":-1,"maximum":5} | -1 |
| `note` | string | note | a handwritten pen note (Gochi Hand); "\|" breaks a line. {"type":"string","minLength":0,"maxLength":28} | after starting reviews |
| `cues` | string | cues | start time (s, from the scene start) of each item, in order; empty = typed one after another. JSON string. {"type":"array","items":{"type":"number","minimum":0,"maximum":45},"maxItems":8} | [] |

## What your agent can change

**Bar Sketch**. Native 1920×1080, 10s at 30fps.

A bar chart sketched into the note: the pen draws the axes, each bar's outline draws up and fills with highlighter, its value is handwritten on top and its label rises underneath.

**Motion.** Axes draw (0.5 s); each bar: outline draws, the fill grows up behind it, value inks in; the tallest (or chosen) bar is yellow.
**Why it moves.** magnitude: drawn by hand so the comparison builds one bar at a time.

### Mount

Copy every manifest file into your project (plus `af-jotter-runtime`). Mount with a unique host id, `data-composition-id="af-jotter-bar-sketch-16x9"`,
`data-composition-src="compositions/af-jotter-bar-sketch-16x9.html"`, `data-duration` and `data-variable-values`.
Use the variant whose size matches your project (16x9, 9x16, 4x5, 1x1): each is laid out natively, never scaled.

### Content slots

Nested slots are JSON strings. Every slot is checked against `constraints.json` and measured against the note before anything
draws; the block stops with a message naming the slot and the fix (it never truncates or shrinks text).

- `title`: the note title (types on first); up to 2 lines. Markup: **bold**, ==yellow==, ++green++, ~~struck~~, __pen underline__. {"type":"string","minLength":1,"maxLength":44}
- `tags`: #tags under the title (the first is the accent tag), e.g. ["step 3 of 5", "productivity"]. {"type":"array","items":{"type":"string","minLength":1,"maxLength":16},"minItems":0,"maxItems":3}
- `items` (required): {"type":"array","items":{"type":"object","properties":{"label":{"type":"string","minLength":1,"maxLength":12},"value":{"type":"number","minimum":0,"maximum":100000}},"required":["label","value"]},"minItems":2,"maxItems":6}
- `prefix`: {"type":"string","minLength":0,"maxLength":2}
- `unit`: {"type":"string","minLength":0,"maxLength":5}
- `highlight`: index of the bar to make yellow (-1 = the tallest). {"type":"integer","minimum":-1,"maximum":5}
- `note`: a handwritten pen note (Gochi Hand); "|" breaks a line. {"type":"string","minLength":0,"maxLength":28}
- `cues`: start time (s, from the scene start) of each item, in order; empty = typed one after another. {"type":"array","items":{"type":"number","minimum":0,"maximum":45},"maxItems":8}

- Bars scale from zero; values are handwritten as given.

Style: `colourway` (daylight, dark, tinted), `accent` (optional hex for ticks, tags and the pen), `app` (menu-bar name), `series` (16:9 folder), `stamp` (the date line), `clock`, `intro` (none or open), `exit` (clear or cut), `duration` (seconds).

### Syncing to the narration

Typing runs at a readable pace and speeds up (up to 2.2×) if a scene would otherwise land late. Lists take `cues` (where
offered): the second, from the scene start, at which each item should start typing, taken from your transcript. Raise
`duration` (and the mount's `data-duration`) to fit long narration: everything lands by 60% of the scene, which leaves the rest as a
readable hold while the caret blinks.

### Timing

10s by default. The note starts empty and its content types on from about 0.3 s; reveals land by 60%; with `exit: clear` the content lifts away over the last 0.45 s, leaving the empty note for the next scene.

### Example

```json
{
  "title": "Hours on deep work",
  "tags": "[]",
  "items": "[{\"label\":\"Wk 1\",\"value\":4},{\"label\":\"Wk 2\",\"value\":6},{\"label\":\"Wk 3\",\"value\":9},{\"label\":\"Wk 4\",\"value\":11}]",
  "prefix": "",
  "unit": "h",
  "highlight": -1,
  "note": "after starting reviews",
  "cues": "[]"
}
```

## FAQ

### What can my AI agent change in Bar Sketch?

Your agent fills the `title`, `tags`, `items`, `prefix`, `unit`, `highlight`, `note` and `cues` slots through the block's data-variable-values (or the starter project's variables). Motion, timing, palette, fonts and the internal layout are protected, so the result keeps the Jotter look.

### Which aspect ratios does Bar Sketch support?

Bar Sketch is designed natively for 16:9, 9:16, 4:5 and 1:1. A typical beat lasts 10s.

### How do I get Bar Sketch?

Bar Sketch is included in the Jotter pack, which is part of the AgentFrames All-access subscription along with 49 other templates in this pack and every other pack on the store. You get the full source, the editing contracts and the agent instructions.

## More in Jotter

- [Big Number](https://agentframes.ai/elements/jotter/big-number.md): One figure, huge: the number counts up, the pen rings it, a handwritten note sits beside it, and the label and an optional source type underneath.
- [Line Sketch](https://agentframes.ai/elements/jotter/line-sketch.md): A trend sketched in the note: pen axes, labels along the bottom, then the pen draws the line through every point and the last value is dotted and handwritten.
- [Pie Sketch](https://agentframes.ai/elements/jotter/pie-sketch.md): Shares of a whole drawn by hand: the pen draws the circle, each slice line, the slice fills with highlighter colour, its % is handwritten inside, and a legend types beside (16:9, 1:1) or below (9:16, 4:5).
- [Tally Ratio](https://agentframes.ai/elements/jotter/tally-ratio.md): "7 in 10" as a pictogram: the ratio types big, then a row of little person icons appears one by one, the hits filled in accent and the rest outlined, and a label explains it.

## Community

Coming soon.
