pillow-technical-diagrams

pillow-technical-diagrams is a skill for Claude Code, Codex from cxcscmu/SkillLearnBench. It costs 30 tokens per session (791 once invoked), scanned A, original, MIT.

A guide to creating technical posters and diagrams with Pillow, a Python library for drawing and editing images. It covers shapes, lines, colours, text, fonts, and layered layouts.

In plain words
What is it for?
Use it to generate technical diagrams, posters, labelled shapes, flow illustrations, and other composed bitmap images with Python.
Why use it?
It helps developers create diagrams as image files directly from Python code instead of drawing each one by hand. The examples provide starting points for structured posters and technical illustrations.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to generate technical diagrams, posters, labelled shapes, flow illustrations, and other composed bitmap images with Python.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/cxcscmu/skilllearnbench/pillow-technical-diagrams
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add cxcscmu/SkillLearnBench --skill pillow-technical-diagrams
Clone the repo
git clone --depth 1 https://github.com/cxcscmu/SkillLearnBench

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for pillow-technical-diagrams

README.md
[![agentmods](https://agentmods.dev/badge/skills/cxcscmu/skilllearnbench/pillow-technical-diagrams/github.svg)](https://agentmods.dev/skills/cxcscmu/skilllearnbench/pillow-technical-diagrams)
Your own site
<a href="https://agentmods.dev/skills/cxcscmu/skilllearnbench/pillow-technical-diagrams"><img src="https://agentmods.dev/badge/skills/cxcscmu/skilllearnbench/pillow-technical-diagrams/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for pillow-technical-diagrams

Your own site · 80×15
<a href="https://agentmods.dev/skills/cxcscmu/skilllearnbench/pillow-technical-diagrams"><img src="https://agentmods.dev/badge/skills/cxcscmu/skilllearnbench/pillow-technical-diagrams.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 30 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 791 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00030 $0.00791
Opus 5 $0.00015 $0.00396
Sonnet 5 $0.00006 $0.00158
Haiku 4.5 $0.00003 $0.00079

Measured 5d ago against content hash a012f7020daa, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

pillow-technical-diagrams scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/b1-one-shot-claude-sonnet-4-6/anthropic-poster-design/pillow-technical-diagrams/SKILL.md · 91 lines

How it starts

The opening of the file, as written. The whole thing — 91 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Pillow Technical Diagrams

Installation

pip install Pillow numpy --break-system-packages

Core Setup

from PIL import Image, ImageDraw, ImageFont
import numpy as np

# Create canvas
W, H = 2400, 3200  # portrait poster
img = Image.new("RGB", (W, H), color="#F5F0E8")
draw = ImageDraw.Draw(img)

Drawing Shapes

# Rectangle with rounded corners (Pillow 9+)
draw.rounded_rectangle([x0,y0,x1,y1], radius=12, fill="#hex", outline="#hex", width=2)

# Ellipse / circle
draw.ellipse([x0,y0,x1,y1], fill="#hex", outline="#hex", width=1)

# Polygon
draw.polygon([(x1,y1),(x2,y2),(x3,y3)], fill="#hex", outline="#hex")

# Line with width
draw.line([(x0,y0),(x1,y1)], fill="#hex", width=2)

Text Rendering

# Load system font (fallback chain)
import os

def load_font(size, bold=False):
    candidates = [
        "/usr/share/fonts/truetype/dejavu/DejaVuSans-Bold.ttf" if bold else "/usr/share/fonts/truetype/dejavu/DejaVuSans.ttf",
        "/usr/share/fonts/truetype/liberation/LiberationSans-Bold.ttf" if bold else "/usr/share/fonts/truetype/liberation/LiberationSans-Regular.ttf",
        "/usr/share/fonts/truetype/freefont/FreeSansBold.ttf" if bold else "/usr/share/fonts/truetype/freefont/FreeSans.ttf",
    ]
    for path in candidates:
        if os.path.exists(path):
            return ImageFont.truetype(path, size)
    return ImageFont.load_default()

font_title = load_font(120, bold=True)
draw.text((x, y), "NOVA", fill="#1A1A1A", font=font_title)

Centered / Anchored Text

# Anchor options: "lt" (left-top), "mm" (middle-middle), "rt" (right-top)
draw.text((cx, cy), "label", fill="#hex", font=font, anchor="mm")

# Get bounding box for manual centering
bbox = draw.textbbox((0,0), "text", font=font)
tw = bbox[2] - bbox[0]
th = bbox[3] - bbox[1]
draw.text((cx - tw//2, cy - th//2), "text", fill="#hex", font=font)

Saving

img.save("/root/output.png", dpi=(300, 300))

Alpha / Compositing

layer = Image.new("RGBA", (W, H), (0,0,0,0))
d = ImageDraw.Draw(layer)
d.rectangle([...], fill=(200,200,200,120))  # semi-transparent
img_rgba = img.convert("RGBA")
img_rgba = Image.alpha_composite(img_rgba, layer)
img = img_rgba.convert("RGB")

Read the full file on GitHub · 91 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 91 lines · 30 tokens per session scan A a012f7020daa

Subscribe to this mod's changes

pillow-technical-diagrams is a skill published in the GitHub repository cxcscmu/SkillLearnBench (83 stars, last pushed 2mo ago), licensed MIT. It adds 30 tokens to every session and 791 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

rdkit

Cheminformatics toolkit for fine-grained molecular control. SMILES/SDF parsing, descriptors (MW, LogP, TPSA), fingerprints, substructure search, 2D/3D generation, similarity, reactions. For standard workflows with simpler interface, use datamol (wrapper around RDKit). Use rdkit for advanced control, custom…

benchflow-ai/skillsbench · 80 tokens

pcap-analysis

Guidance for analyzing network packet captures (PCAP files) and computing network statistics using Python, with tested utility functions.

benchflow-ai/skillsbench · 28 tokens

memory-optimization

Optimize Python code for reduced memory usage and improved memory efficiency. Use when asked to reduce memory footprint, fix memory leaks, optimize data structures for memory, handle large datasets efficiently, or diagnose memory issues. Covers object sizing, generator patterns, efficient data structures, and memory…

benchflow-ai/skillsbench · 60 tokens

python-parallelization

Transform sequential Python code into parallel/concurrent implementations. Use when asked to parallelize Python code, improve code performance through concurrency, convert loops to parallel execution, or identify parallelization opportunities. Handles CPU-bound (multiprocessing), I/O-bound (asyncio, threading), and…

benchflow-ai/skillsbench · 68 tokens

trl

Reference for the TRL (Transformer Reinforcement Learning) library codebase. Use proactively before reading or editing any file under trl/ so you have the intended contracts and invariants in mind, not just what the current code says. Covers trainer hierarchy (SFT, DPO, GRPO, KTO), shared utility functions…

benchflow-ai/skillsbench · 100 tokens

parallel-processing

Parallel processing with joblib for grid search and batch computations. Use when speeding up computationally intensive tasks across multiple CPU cores.

benchflow-ai/skillsbench · 28 tokens