ai-cut
v0.1.2
Published
CLI background remover that cuts image backgrounds into transparent PNG/WebP files.
Maintainers
Readme
ai-cut
CLI background remover. Run it with npx ai-cut and get transparent cutouts from local images.
ai-cut uses @imgly/background-removal-node, which runs an ONNX model locally. First run downloads model assets and takes longer; later runs use cache.
Usage
npx ai-cut portrait.jpg
npx ai-cut product.jpg --output product-cut.png
npx ai-cut photos/*.jpg --out-dir cutouts --model smallDefault output is <name>-cut.png beside the source image.
Options
Usage:
ai-cut <image> [options]
ai-cut <image...> --out-dir <dir> [options]
Options:
-o, --output <file> Output path for one image
-d, --out-dir <dir> Output directory for one or many images
-m, --model <name> Model: small or medium (default: medium)
-f, --format <format> Output: png or webp (default: png)
-q, --quality <number> Output quality from 0 to 1 (default: 0.8)
-t, --type <type> foreground, background, or mask (default: foreground)
--force Overwrite existing output files
--quiet Only print errors
--debug Print model debug output
-v, --version Print version
-h, --help Show helpDevelopment
npm install
npm test
npm run pack:checkLicense
AGPL-3.0-or-later. Core background removal dependency is AGPL-licensed.
