npx skills add ...
npx skills add picsart/gen-ai-skills --skill dev-screenshot-beautifier
Polish raw screenshots into LP-ready heroes.
npx skills add picsart/gen-ai-skills --skill dev-screenshot-beautifier
A polish pipeline that takes a raw UI screenshot (localhost capture, production screen grab, mobile viewport) and turns it into a blog-ready, changelog-ready, doc-ready hero: device-framed, drop-shadowed, on a gradient backdrop, dark-mode matched.
Not for: generating UI that doesn't exist (use Figma or a mockup tool), or replacing real content with fake text (prefer annotation/blurring).
Before processing, ask (one message, 5 questions):
Skip if the user hands over a detailed brief.
Estimate the background swap cost.
Option A — Background swap only (UI stays pixel-exact, just drop on a new surface). Use this when the screenshot itself is final.
Option B — Full edit (add device frame + shadow + reflection in one pass). Use when you want the model to re-composite.
Option C — Background only, composite locally (maximum UI fidelity, optional). Use only when local compositing tools are available; otherwise use Option A or B. Generate a backdrop, then overlay the raw PNG with sharp, browser canvas/CSS, or ffmpeg if already installed.
Dark-mode paired variant.
Verify. Open side by side with the raw. UI text must still be readable. No melted edges on the bezel. No duplicated chrome.
Batch-beautify all screenshots for a release:
Run with gen-ai batch run screenshots.json -c 3 -o ./out/beautified.
| Sub-task | Model | Why |
|---|---|---|
| Background swap only, preserve UI pixel-exact | picsart-change-bg | Cleanest edge extraction on UI shapes |
| Background removal (transparent PNG out) | picsart-remove-bg | Fast, reliable, preserves anti-aliasing |
| Device frame + shadow + reflection (full recomposite) | flux-kontext-pro | Best edit model, follows -i reference |
| Standalone backdrop for local compositing | flux-2-pro | Richest textures + lighting |
| Quick draft while choosing direction | gemini-3.1-flash-image | Lowest credits |
| Upscale final export to print | topaz-upscale-image | 2-4× with UI-safe edges |
Verify with gen-ai models --mode image.
brand.md with hex values; pass ` so backdrops don't drift between posts.-i — shadows, tilt, and bezel stay identical, only lighting changes.--save-to-drive for sensitive screenshots (pre-launch UI, customer data). Keep local or use --no-save-to-drive.| Pitfall | Fix |
|---|---|
| UI text is rewritten / garbled after edit | Use Option A (bg swap) or Option C (local composite) — not Option B |
| Device bezel looks melted at corners | Drop Flux Kontext Pro; use remove-bg + local PNG composite with a real bezel asset |
| Perspective is wrong (tilted + fish-eye) | Prompt explicitly "flat, frontal, no perspective distortion" — or composite locally |
| Dark variant shifts UI colors | Pass the light variant as -i, prompt "keep UI content identical, re-light background only" |
| Screenshot contains leaked customer data | Blur/redact in the raw PNG BEFORE running gen-ai |
| Anti-aliasing fringe after bg removal | Use picsart-remove-bg with PNG input; avoid JPEG sources |
| Gradient backdrop clashes with UI accent color | Pull the UI's accent into the prompt palette; match rather than contrast |
Run gen-ai whoami to confirm authentication, then re-run the failed command with --debug.
| Task | Credits | Time |
|---|---|---|
| Background swap (picsart-change-bg) | 1-2 | ~4-8s |
| Background removal (picsart-remove-bg) | 1 | ~3-5s |
| Full edit with device frame (flux-kontext-pro) | 3-6 | ~10-18s |
| Standalone backdrop (flux-2-pro) | 3-5 | ~10-15s |
| Paired dark-mode variant | +3-6 | +10-18s |
| Upscale to 4K (topaz-upscale-image) | 2-4 | ~15-30s |
| Typical blog hero (light + dark, framed) | ~10-15 | ~30-45s |
gen-ai-use.md — full CLI reference, remove-bg, change-bg, enhance flagsgen-ai-batch.md — batching multiple screenshots, gen-ai batch resume <output-dir> for partial runsgen-ai-workflows.md — Workflow 1 (blog-to-visuals) for the full post asset setdev-og-image-service — turn the beautified hero into a per-URL OG carddev-app-assets — App Store screenshot framing at scale`