← 返回
未分类

image-compress

Compress images (JPEG, PNG, WebP) using Python Pillow. Supports quality adjustment, format conversion, batch processing, and resizing.
Compress images (JPEG, PNG, WebP) using Python Pillow. Supports quality adjustment, format conversion, batch processing, and resizing.
user_13f0f8f8
未分类 community v1.0.0 1 版本 100000 Key: 无需
★ 0
Stars
📥 75
下载
💾 0
安装
1
版本
#latest

概述

Image Compression Skill

Compress images to reduce file size while maintaining quality.

Usage

/image-compress <path> [options]

Arguments

ArgumentDescription
-----------------------
Image file, directory, or glob pattern (e.g. .jpg, ./images//.png)
--quality, -qOutput quality 1-100 (default: 85). Lower = smaller file
--format, -fOutput format: jpeg, png, webp (default: same as input)
--output, -oOutput directory (default: overwrite for single file, ./compressed for batch)
--max-width, -wMax width in pixels, maintains aspect ratio
--max-height, -eMax height in pixels, maintains aspect ratio
--lossless, -lUse lossless compression (PNG/WebP only)

Examples

/image-compress photo.jpg -q 80
/image-compress photo.jpg -f webp -q 90
/image-compress ./images/*.jpg -q 75 -o ./compressed
/image-compress photo.jpg -w 1920 -q 80
/image-compress image.png --lossless
/image-compress ./photos --quality 85 --format webp --output ./webp_output

How it works

  1. Write the compress.py script to a temp location and run it
  2. Script uses Python Pillow to process images
  3. Results are displayed as a summary table

The script is located at: ~/.claude/skills/image-compress/compress.py

Notes

  • Requires Python with Pillow (python -m pip install Pillow)
  • 注意:此系统上 python3 是 Windows Store 存根,使用 python 命令
  • JPEG output automatically converts RGBA to RGB
  • EXIF metadata is preserved unless explicitly stripped
  • For batch jobs, directory structure under the input path is preserved in the output

版本历史

共 1 个版本

  • v1.0.0 Initial release 当前
    2026-05-17 16:54 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

design-media

UI/UX Pro Max

xobi667
提供 UI/UX 设计智能与实现指导,帮助打造精美界面。适用于 UI 设计、UX 流程、信息架构、视觉风格、设计系统/标记、组件规格、文案/微文案、无障碍及前端 UI(HTML/CSS/JS、React、Next.js、Vue、Svelte
★ 216 📥 46,518
design-media

Nano Banana Pro

steipete
使用 Nano Banana Pro (Gemini 3 Pro Image) 生成或编辑图像。支持文生图、图生图及 1K/2K/4K 分辨率,适用于图像创建、修改及编辑请求,使用 --input-image 指定输入图像。
★ 424 📥 116,167
design-media

Openai Whisper

steipete
使用 Whisper CLI 进行本地语音转文字(无需 API 密钥)
★ 329 📥 92,863