Skip to content

About

Claude agent skill that turns a photo, sketch or idea into a buildable brick model: checked in software, with an instruction book, 3D viewer and parts lists. Build it by hand in the browser at snapwright.eastham.ai.

Topics

Resources

Contributing

Stars

4 stars

Watchers

0 watching

Forks

Repository files navigation

Snapwright

Turn a photo, a doodle or a wild idea into a brick model you can actually build.
Real parts. Checked in software. With the instruction book, a 3D viewer and a shopping list.

tests license npx skills add geastham/snapwright a Claude skill

A brick lighthouse building itself, part by part


Hi! What is this?

Snapwright is an agent skill for Claude (and other coding agents). Ask for a brick version of your dog, your house, a rocket you modelled, a sunset photo, and it:

  1. designs it on a stud-and-plate grid, looking at your picture and scoring its own likeness,
  2. packs it into real parts: bricks, plates, tiles, slopes, corner slopes, round bricks and sideways-built faces, only in colours those parts are actually made in,
  3. checks it like a grumpy engineer: one piece, nothing floating, nothing held on by a single stud, and it won't tip over,
  4. and hands you everything you need to build it.
Instruction book cover Instruction book step page
A printable instruction book: bags, numbered steps, a callout of the new parts with colour names, and a progress bar Steps you can follow: every part lands on something already built; tricky ones get an x-ray outline

The 3D build viewer

An interactive 3D viewer (one HTML file, works offline): build playback, step by step,
exploded panels, record to video, and the honest list of what the software checked.

What you get

Every build drops these into an out/ folder:

file what it is
<name>-instructions.pdf the instruction book, ready to print
<name>-viewer.html the 3D viewer: one file, opens in any browser, offline too
<name>-bricklink.xml the order list: upload it to BrickLink and buy everything in a few clicks (how)
<name>-parts.csv a readable parts list with a BrickLink link for every part
<name>-rebrickable.csv the parts list for Rebrickable (what do I already own?)
<name>.ldr the model for Studio, LeoCAD or Mecabricks
build.mp4 on request: a build video of the model assembling itself, ready to post

Gallery

Every one of these passes the checks. Click a picture to open its 3D viewer, or browse the creations library to download each one's instruction book, BrickLink parts list and 3D viewer for free.

Lakeside Sail Tower Harbour Lighthouse Signal Robot
Lakeside Sail Tower
3,115 parts · 43 cm
a lakefront diorama, from two photos
Harbour Lighthouse
1,808 parts · 33 cm
slopes and rounds on the tapers
Signal Robot
492 parts · 25 cm
face and chest built sideways
Little Rocket Stone Keep Memorial Church
Little Rocket
485 parts · 24 cm
straight from an STL file
Stone Keep
5,210 parts · 45 cm
hollow walls with bracing
Memorial Church
3,443 parts · 28 cm
a mosaic gable built from plate edges

Make your own creation

Bring an idea and a few pictures; the skill walks you through the rest, checking in with you at each step:

  1. Three quick questions: what is it, how big, who's building.
  2. References: it checks your pictures, suggests brick colours, and gives you copy-paste prompts to generate any views it still needs.
  3. A short brief: size, colours, and the features that make it yours.
  4. Block-out and likeness: it designs the model and scores how closely it matches your picture, and you steer.
  5. Build and check: real parts, checked in software, every repair listed.
  6. Everything you need: book, viewer, parts lists and video.
Checking the references Scoring the likeness The built model
checks the references scores the likeness builds it for real

See the whole walkthrough → (recorded on Biscuit the dog)

Getting the bricks

Upload <name>-bricklink.xml on BrickLink (Want → Upload), then click Buy All: it finds the shops that have everything. Every part is listed only in colours it's actually made in. There's also a Rebrickable list, and a link per part in the parts CSV and the viewer. Step by step →

Build it with your hands

No bricks yet? Handbuild plays any Snapwright model in the browser: hold your hands up to the webcam, pinch a part from the tray and click it into place, step by step from the same instruction book. Ask Claude to "open it in Handbuild" after a build and it gives you a link, or open the site and drop in your out/model.json.

Install (30 seconds)

Claude Code, Cursor, Codex and other agents (via the open skills CLI):

npx skills add geastham/snapwright

Claude.ai / the Claude apps: download snapwright.zip from the latest release, turn on Code execution and file creation (Settings → Capabilities), then upload the zip under Skills (how).

It needs Python with numpy, scipy, pillow and reportlab (the Claude sandbox has them). No GPU, no network (except refreshing the parts catalog), about 300 KB. Then just ask: "I'd like to make a brick version of … — walk me through it."

Things to ask it

Here's a photo of our dog Biscuit. Turn him into a brick sculpture about 20 cm tall, with instructions I can print.

Design a small brick lighthouse my 7-year-old can build, under 400 pieces.

Make a 48 x 48 mosaic of this sunset and give me a BrickLink wanted list.

I 3D-modelled a rocket (rocket.stl, Z-up). Make it a brick model, white with red fins.

The base of my model keeps tipping over. Fix it and regenerate the book.

It builds original things, your own things, generic things, real places and public-domain works, and politely offers an original design instead of copying someone else's character.

How it works

flowchart LR
  A["photo / sketch / idea / 3D file"] --> B["design.py<br><i>a tiny voxel language</i>"]
  B --> C["preview + likeness score"]
  C -->|tweak| B
  C --> D["pack into real parts<br><i>seeds + repair loop</i>"]
  D --> E["check<br><i>connections, balance, weak joints</i>"]
  E --> F["plan steps + bags"]
  F --> G["book · viewer · LDraw · parts lists · video"]
Loading
  • The packer lays bricks in courses with staggered joints, anchors overhangs, and smooths tapers and curves with slopes, corner slopes, inverted slopes and round parts.
  • The repair loop fixes what didn't join up, least invasive first: re-pack, then studs instead of tiles, then one recoloured cell, and only as a last resort trims an overhang.
  • Nothing is hidden. Every automatic change is counted and printed in the log, the book and the viewer.
  • Parts that exist. The catalog knows which colours each part has actually been made in (from Rebrickable's set inventories), and the packer sticks to those.
  • Deterministic. Same design, same seed, same model. model.json regenerates everything.

It's checked in software: nobody has built your model until you build it. If something doesn't click, tell us and we'll teach the packer.

For tinkerers

make setup        # numpy, scipy, pillow, reportlab (+ pytest)
make test         # ~150 tests in ~20 s
make example      # builds the lighthouse into examples/lighthouse/out/
python skills/snapwright/scripts/sw.py preview my_design.py --out out/preview
python skills/snapwright/scripts/sw.py compare my_design.py --ref photo.jpg
python skills/snapwright/scripts/sw.py build   my_design.py --out out --audience family
python skills/snapwright/scripts/sw.py video   out/model.json --out out/build.mp4

The skill lives in skills/snapwright/. There are also examples/, creations/ (our own builds), evals/ (how we test the skill with and without it, see docs/evals.md) and tools/. The roadmap is in SPEC.md, and CONTRIBUTING.md explains how to help.

Credits

Made by Open Conjecture and The Augmented Mind. MIT licensed.

Snapwright is unofficial and independent: not affiliated with, sponsored or endorsed by any brick manufacturer or marketplace (see NOTICE.md). The 3D viewer uses three.js (MIT).

About

Claude agent skill that turns a photo, sketch or idea into a buildable brick model: checked in software, with an instruction book, 3D viewer and parts lists. Build it by hand in the browser at snapwright.eastham.ai.

Topics

Resources

Contributing

Stars

4 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages