vectorize
Skill21 starsChanged 7 days agoMITView on GitHub
Use when the user wants to trace a raster image (PNG/JPEG) into an SVG vector — useful for logos, line art, diagrams, and stylized illustrations. Wraps `vtracer` (Rust-backed, via Python wheel in the plugin venv). Companion to `svg-to-raster` (other direction).
1 other project uses a version of this.
Adopted by
Most recently taken up by
- MohamedAbdallah-14/prompt-to-assettheir own version, first seen May 6, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- MohamedAbdallah-14/prompt-to-asset★ 18same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository28 other files it gives its agents.
- ai-graphicsSkill
- auto-deskewSkill
- auto-toneSkill
- auto-white-balanceSkill
- batch-set-copyrightSkill
- check-model-pricingSkill
- convert-to-avifSkill
- fast-resizeSkill
- fast-thumbnailSkill
- from-jxlSkill
- images-to-pdfSkill
- install-depsSkill
- new-projectSkill
- new-workflowSkill
- open-workspaceSkill
- optimize-jpegSkill
- optimize-pngSkill
- pdf-extract-embedded-imagesSkill
- pdf-to-imagesSkill
- read-metadataSkill
- scrub-metadataSkill
- set-metadataSkill
- svg-to-rasterSkill
- to-jxlSkill
- transcode-jpeg-to-jxl-losslessSkill
- upscale-imageSkill
- web-readySkill
- workspace-setupSkill
The file
We split this skill into the rules it gives an agent
4 rules. About 0 are common, 1 is distinctive, and 3 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 17
Do not use this skill when:
- Very specific: line 37
Verify vtracer is importable:
- Very specific: line 43
If missing → point at install-deps.
- Very specific: line 85
If vtracer's quality isn't enough for a specific case, fall back to Inkscape's bitmap trace or potrace (B/W only).
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Vectorize
Convert raster images to SVG via vtracer. vtracer is a colour-clustering tracer — much better than potrace for full-colour images, comparable for B/W line art. Installed as a Python wheel in the plugin venv (bundled Rust binary, no cargo needed at install time).
When to use
- Recover an editable vector logo from a raster (PNG/JPEG).
- Convert a flat illustration / icon / diagram into SVG for crisp scaling.
- Stylize a photo into a flat-colour vector (large
--filter-speckle+ low--color-precision). - Pre-step before
svg-to-rasterif you want to upscale a small raster losslessly.
Do not use this skill when:
- Source is a complex photograph and you want photo-realism — vector tracing always loses gradients/texture; use
upscale-imagefor raster upscaling instead. - You need OCR'd text inside the SVG — vtracer traces strokes, not text. Use a separate OCR step.
- Input is already SVG — no-op.
Inputs
- Input — image file or directory. Required.
- Output dir — default:
<input-dir>/svg/. Never overwrites originals. - Mode —
color(default, multi-colour with clustering) orbinary(B/W line art, faster, smaller output). - Color precision —
1..8, default6. Lower = fewer colours = smaller / more abstract SVG. - Layer difference —
0..255, default16. Larger = fewer layers, simpler output. - Filter speckle — pixels, default
4. Discards regions smaller than N pixels — raise to denoise. - Path simplification —
corner threshold(default60deg),length threshold(default4.0),splice threshold(default45deg). Most users won't tune these; expose only if asked. - Recursive —
--recursivefor directory descent.
Procedure
- Resolve venv:
VENV_DIR="${CLAUDE_USER_DATA:-${XDG_DATA_HOME:-$HOME/.local/share}/claude-plugins}/image-production/venv". Verify
vtraceris importable:"$VENV_DIR/bin/python" -c "import vtracer" 2>&1If missing → point at
install-deps.- Enumerate inputs (
*.png,*.jpg,*.jpeg,*.bmp,*.tiff). Skip already-SVG with note. For each file, call vtracer via Python:
"$VENV_DIR/bin/python" -c " import vtracer, sys vtracer.convert_image_to_svg_py( sys.argv[1], # input sys.argv[2], # output colormode='<color|binary>', color_precision=<int>, layer_difference=<int>, filter_speckle=<int>, corner_threshold=<int>, length_threshold=<float>, splice_threshold=<int>, path_precision=8, ) " "<input>" "<output.svg>"- Track size deltas and a quick "vector quality" sniff: file size ratio (SVG / PNG), and visually-noticeable degradation flags (very large filter_speckle on a detailed source = likely loss).
Output
- SVG files at
<output-dir>/. - Summary:
- Files processed / failed.
- Per-file: input pixels × → SVG path count (heuristic:
grep -c '<path' <file>), file size delta. - Tuning suggestions if path count is suspiciously high (likely too noisy — raise
filter_speckle) or low (likely over-simplified — droplayer_difference).
Notes
- vtracer is MIT — free to bundle and use.
- For B/W technical drawings / scanned line art,
binarymode is dramatically faster and produces cleaner output thancolor. - Common preset suggestions:
- Logo / icon (clean source):
color, color_precision=6, filter_speckle=4, layer_difference=16. Defaults are tuned for this. - Photo → flat illustration:
color, color_precision=3, filter_speckle=20, layer_difference=32. Aggressive simplification, painterly look. - Line drawing / scan:
binary, filter_speckle=10. Smallest output.
- Logo / icon (clean source):
- If vtracer's quality isn't enough for a specific case, fall back to Inkscape's bitmap trace or
potrace(B/W only). vtracer is the right default for everything else. - vtracer ships a CLI binary too (
vtracer-cli) — the Python wheel is preferred here so the venv is self-contained.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

