Command Palette

Search for a command to run...

Bento diagrams: drawn by an agent, checked by a script

15 Oct 2026 · 2 min read

A bentō (弁当) is a Japanese lunch box with a compartment for each thing. Nothing touches anything else, and the layout of the compartments tells you what the meal is before you taste it. I wanted the same from the diagrams coding agents draw, so the skill took the name.

Agents describe a system well in words. Ask one for a picture and nobody checks the result: labels spill out of their boxes, arrows cut through cards, the dark theme is an afterthought. The agent can't see what it drew, so it can't fix it. bento-diagrams gives it a way to look.

Five stage columns from a task's resource request through candidates, estimate and plan to launch; a failed launch is blocked and loops back into the candidate filter.

How SkyPilot's optimizer picks where a task runs, drawn by an agent from the source code.

How it works

Compartments, then cards. Grey compartments hold the parts of a system, cards say what each part is, thin arrows say what moves. An outline says how a path ends: green when it succeeds, red when it stops. Decisions and retries are yellow. The look is Apple's system UI, with Instrument Sans and the system colours.

The question picks the layout. Who does what is a swimlane, where things run is boxes inside boxes, what a thing can become is a state machine, when is a roadmap. Each of the fifteen layouts has its grid written down, so two agents asked the same question draw the same picture.

One file for both themes. Every colour is stored as a light and dark pair inside a single .drawio file. The picture follows whatever shows it, and a person can still open it in draw.io and move a box.

A script looks at the picture. render.mjs exports each page through draw.io and lays the text out in a real browser with the real fonts. It fails on overlaps, lines through words, crossings without a bridge, and near misses of a few pixels, and names the fix for each. It exits with 1 until every page is clean, so the agent draws, checks and fixes on its own.

The last step is most of the skill. A rule written in a prompt gets skipped when nothing checks it. An exit code doesn't get skipped.

Try it

Any agent, with Node.js:

npx skills add exdsgift/shuji-skills --skill bento-diagrams

In Claude Code, the shuji plugin brings every shuji skill at once and runs this one as /shuji:bento-diagrams:

claude plugin install shuji --marketplace exdsgift/shuji-skills

Then ask for a diagram in plain words. The check needs Node 18, the draw.io desktop app, and Chrome or Edge.

References