**DEPRECATED** — Use `creating-coloring-books` instead. This skill uses an outdated workflow (Pixabay sourcing, local potrace). The replacement skill uses Google Images → screenshot → fal.ai Qwen + Recraft. Do not use this skill for new coloring book work.
6-phase pipeline that transforms curated source illustrations into print-ready coloring book pages. We do NOT generate art from scratch — we find great existing illustrations and convert them.
Phase 1: Research → find 20+ candidate illustrations
Phase 2: Vectorize → raster → SVG via fal.ai
Phase 3: Line Art → extract clean outlines
Phase 4: Cleanup → pure black/white, print-ready
Phase 5: QA → independent agent inspection
Phase 6: Upload → gallery for human review
── PAUSE ── → Carrie approves / rejects
Goal: Find 20+ illustrations that would make excellent coloring pages.
Model requirement: Use a strong visual model (Gemini 3 Pro or GLM-4-6v) for image evaluation — the agent must SEE the candidates to score them.
Search broadly across free/open illustration sources. Be creative:
Future: Source list may be locked to proven reliable sites after iteration.
Rate each image 1-10 on these axes:
| Axis | Weight | What to look for |
|---|---|---|
| Coloring compatibility | 3x | Clear outlines, distinct regions, no tiny details that disappear at print |
| Stylistic flair | 2x | Interesting composition, dynamic poses, visual appeal |
| Subject clarity | 2x | Single clear subject or well-separated scene elements |
| Line clarity | 2x | Clean edges, vector-like quality, minimal texture/noise |
| Print readiness | 1x | Will it look good at 8.5x11? Landscape or portrait? |
CandidateScore = (compat * 3 + flair * 2 + clarity * 2 + lines * 2 + print * 1) / 10
Threshold: Accept candidates scoring ≥ 6.0. Target 20+ candidates so ~10 survive through QA.
Save to {bundle_dir}/research/:
candidates.json — array of {url, source, license, scores, total_score, notes}thumbnails/ — downloaded preview of each candidateresearch-report.md — summary with top picks and rationaleGoal: Convert accepted raster candidates to clean SVG.
| Endpoint | Best for | Notes |
|---|---|---|
fal-ai/recraft/vectorize | Illustrations with solid colors | Recraft's vectorizer, good color separation |
fal-ai/star-vector | Complex illustrations | AI vectorization preserving visual detail |
fal-ai/image2svg | Clean graphics, logos | Precise control over detail levels |
{bundle_dir}/vectorized/{filename}.meta.json with: source_url, endpoint_used, parameters, timestamprecraft/vectorizestar-vectorimage2svgGoal: Extract clean black outlines from vectorized illustrations.
Endpoint: fal-ai/image-preprocessors/lineart
This extracts line art from any image — feed it the vectorized SVG rendered as PNG, or the original raster if vectorization wasn't needed.
If fal.ai lineart doesn't produce clean enough output, fall back to local processing with Python/Pillow:
# Edge detection + threshold approach
from PIL import Image, ImageFilter
img = Image.open(path).convert('L')
edges = img.filter(ImageFilter.FIND_EDGES)
bw = edges.point(lambda x: 0 if x > threshold else 255)
{bundle_dir}/lineart/Goal: Production-ready coloring pages. Should look amazing/perfect.
| Metric | Pass Criteria |
|---|---|
| Black pixel ratio | 2% – 15% of total pixels |
| Gray pixels | Exactly 0 |
| Min connected component | No isolated dots < 5px |
| Stroke continuity | No broken lines (gaps < 3px) |
| Margin clearance | ≥ 50px clear border on all sides |
Save to {bundle_dir}/cleaned/
Goal: Every page independently inspected by a visual model agent.
Critical: The QA agent must be a SEPARATE agent/session from the one that produced the art. Fresh eyes, no confirmation bias.
Each criterion scored 1-5. Page passes if:
{bundle_dir}/qa/qa-report.json — per-page scores and notes{bundle_dir}/qa/qa-summary.md — human-readable summary{bundle_dir}/qa/rejected/ with rejection reasonGoal: Upload passing pages to Piwigo for Carrie's review.
https://media.delo.shpwg.images.addSimple via ws.phpUser-Agent: Dumply/1.0 and Referer: https://media.delo.sh/pwg.session.login (creds from env: PIWIGO_USER, PIWIGO_PASSWORD)~/workspace-dumpling/bin/piwigo-uploadsessions_send that bundle is ready for Carrie reviewEach bundle lives under ~/workspace-dumpling/assets/{bundle-name}/:
{bundle-name}/
├── research/
│ ├── candidates.json
│ ├── thumbnails/
│ └── research-report.md
├── vectorized/
│ ├── {page}.svg
│ └── {page}.meta.json
├── lineart/
│ └── {page}.png
├── cleaned/
│ ├── {page}.png
│ └── {page}.meta.json
├── qa/
│ ├── qa-report.json
│ ├── qa-summary.md
│ └── rejected/
└── bundle-manifest.json
{
"name": "K-pop Demon Hunters",
"theme": "K-pop fantasy coloring",
"page_count": 10,
"target_format": "8.5x11 PDF bundle",
"created": "2026-02-21T15:00:00-05:00",
"status": "pending_review",
"phases_completed": ["research", "vectorize", "lineart", "cleanup", "qa", "upload"],
"gallery_url": "https://media.delo.sh/index.php?/category/1",
"plane_ticket": "DIGI-1"
}
Every bundle MUST have a Plane ticket in the DIGI project (workspace: lasertoast). Create the ticket before starting Phase 1. Update status as phases complete.
| Phase | Recommended Agent/Model | Why |
|---|---|---|
| Research | Sub-agent with Gemini 3 Pro or GLM-4-6v | Needs strong vision for image scoring |
| Vectorize | Dumply (self) | API calls to fal.ai, straightforward |
| Line Art | Dumply (self) | fal.ai API + optional local Pillow |
| Cleanup | Dumply (self) | Local Python image processing |
| QA | Spawn independent sub-agent | Fresh eyes, no confirmation bias |
| Upload | Dumply (self) | Piwigo API via helper script |