@petercjl/semantic-image-slicer
v0.1.1
Published
Local-first semantic slicing for long ecommerce images, with previewable cut plans for Codex and SealSeek.
Maintainers
Readme
@petercjl/semantic-image-slicer
Local-first semantic slicing for long ecommerce and document images. It analyzes horizontal whitespace and content density, produces a reviewable cut plan, renders a cut-line preview, and exports numbered slices without uploading the source image.
Quick start
npx @petercjl/semantic-image-slicer doctor
npx @petercjl/semantic-image-slicer analyze long-image.jpg -o plan.json
npx @petercjl/semantic-image-slicer preview plan.json -o preview.jpg
npx @petercjl/semantic-image-slicer cut plan.json -o slicesOr run the complete workflow into a new directory:
npx @petercjl/semantic-image-slicer run long-image.jpg -o resultThe default semantic mode uses variable-height slices. Use --ratio 9:16 for a screen target, or --max-height 3000 for a platform limit.
Safety and privacy
All image processing is local. Output paths are never overwritten: existing plan and preview files, or non-empty output directories, produce a structured OUTPUT_EXISTS error.
Agent Skill
The canonical portable Skill ships inside this npm package. Inspect or install its managed links with:
longslice skill source
longslice skill status --agent all
longslice skill install --agent codex
longslice skill install --agent sealseek
longslice skill update --agent sealseekCodex and SealSeek share the same CLI implementation and canonical Skill source. The CLI resolves Agent targets with cross-platform path APIs, supports CODEX_SKILLS_DIR and SEALSEEK_SKILLS_DIR overrides, and accepts --target <path> when the host exposes a different managed Skill directory.
Installation uses --mode auto by default: it creates a managed link when supported and falls back to a managed copy when linking is unavailable. Managed copies include package version and content-hash metadata so skill status and skill update can verify them without maintaining an independent business-logic copy.
