CommunityImagegithub.com

refkit

Prep a reference photo for drawing or painting by hand - notan, 5-value study, grayscale, grid, limited palette with paint-mixing recipes, printable A4 sheet. Use when the user wants to draw or paint from a photo, asks for values, a grid or paint mixes, or types /refkit.

What is refkit?

refkit is a Claude Code agent skill that prep a reference photo for drawing or painting by hand - notan, 5-value study, grayscale, grid, limited palette with paint-mixing recipes, printable A4 sheet. Use when the user wants to draw or paint from a photo, asks for values, a grid or paint mixes, or types /refkit.

Works with✓Claude Code~Codex CLI~Cursor
npx skills add https://github.com/thibaud360/refkit/tree/HEAD/skills/refkit

Installed? Explore more Image skills: steipete/songsee, affaan-m/frontend-design, mattpocock/improve-codebase-architecture · View all 6 →

Ask in your favorite AI

Open a new chat with this agent skill pre-loaded.

Documentation

What does refkit do?

Reference-prep for people who draw or paint by hand. Claude does not draw for the user: it prepares the reference so the user can. Runs scripts/refkit.py (Python 3, Pillow, NumPy, OpenCV, scikit-image, scikit-learn). No image model.

What it writes (in refkit_out/)

FileContent
*_notan.png2-value and 3-value notan, with the share of each value
*_values5.png5-value study with a value scale legend
*_gray.pnggrayscale (perceptual lightness, levels stretched)
*_grid.pngphoto with a drawing grid, columns A, B, C and rows 1, 2, 3
*_palette.png3-10 colours (k-means) with a paint recipe for each
*_sheet.png, *_sheet.pdfeverything on one A4 landscape sheet to print and pin at the easel

Steps

  1. Find the user's photo (their own photo or drawing). Make sure the dependencies exist: pip install pillow numpy opencv-python-headless scikit-image scikit-learn (add --break-system-packages if pip asks).
  2. Ask, only if not already said: the canvas size in cm, and the medium (oil, acrylic or gouache = oil/gouache; watercolour = watercolor). Do not interrogate; defaults are fine.
  3. Run: python scripts/refkit.py PHOTO -o refkit_out [options]
  4. Look at the sheet and at least the grid and palette before sending. If a recipe looks odd, say that mixes are estimates.
  5. Send the sheet (PNG and PDF) first, then the single images if asked. Offer one tweak: more or fewer grid squares, another palette size, another medium.

Options, and what the user says

  • --canvas 40x50 (cm, or A4..A1). The photo is cropped to this ratio for every output, centre crop. Use when the user names a canvas or paper size.
  • --grid N squares along the long side (default 8). "More detail" means a bigger N.
  • --grid-cm 5 square size in cm; needs --canvas. Use for "a grid every 5 cm".
  • --palette N colours, 3 to 10 (default 6). "Limited palette" is 4 to 6.
  • --paints oil|watercolor|gouache. Watercolour has no white: lightening is done with water and the paper stays bare for whites.
  • --values 2,3,5 which studies to make (default all).
  • --width PX working size (default 1600), --dpi sheet resolution (default 200), --strip also writes a before/after strip.

Example: python scripts/refkit.py photo.jpg --canvas 30x40 --grid-cm 5 --palette 7 --paints oil

How to talk about it

Frame it as help for the user's own drawing: the notan shows the big shapes, the values show where light and dark sit, the grid is for transferring the drawing, the recipes are a starting point. Never call it AI art. The mixes come from a Kubelka-Munk model of ten common tube paints (Titanium White, Ivory Black, Cadmium Yellow Light, Yellow Ochre, Cadmium Red, Alizarin Crimson, Ultramarine Blue, Phthalo Blue, Burnt Umber, Burnt Sienna). Brands differ, so tell the user to test on a scrap. Parts are by volume.

If the script is missing

git clone --depth 1 https://github.com/thibaud360/refkit /tmp/refkit and use /tmp/refkit/skills/refkit/scripts/refkit.py.

Related Skills