← 返回
未分类 Key

Pixmind Image Compress

Cloud-powered image compression and resize — compress JPG/PNG/WebP/HEIC to WebP/AVIF, resize images, batch process folders. No local dependencies, uses Tence...
云端图片压缩与调整大小 — 将 JPG/PNG/WebP/HEIC 压缩为 WebP/AVIF,支持尺寸调整和批量文件夹处理,无需本地依赖,使用腾讯云
fuyunzhishang
未分类 clawhub v1.0.1 1 版本 100000 Key: 需要
★ 0
Stars
📥 281
下载
💾 0
安装
1
版本
#latest

概述

Pixmind Image Compress

Cloud-powered image compression and resize. Compress JPG, PNG, WebP, HEIC photos to WebP, AVIF or smaller JPG — save 60-90% file size with zero local dependencies.

Powered by Pixmind + Tencent Cloud COS imageMogr2.

Why this skill?

  • Zero install — No sharp, ImageMagick, or native modules. Runs on any platform with just an API key.
  • Cloud-processed — Handles HEIC, AVIF, TPG formats that local tools struggle with.
  • Scene presets — One command for web, WeChat, email, or archival use.
  • Batch ready — Compress entire folders recursively.
  • Safe by default — Never overwrites originals, auto-numbered output.

When to use

Use this skill when the user mentions:

  1. Compress — "图片太大"、"压缩一下"、"缩小文件"、"reduce image size"、"compress photo"、"file too large"
  2. Format conversion — "转成 JPG"、"PNG 转 WebP"、"HEIC 转 JPG"、"convert to webp"、"change format"
  3. Resize — "缩小到 1920px"、"调整尺寸"、"resize image"、"reduce dimensions"、"scale down"
  4. Batch — "批量压缩"、"处理这个文件夹"、"compress all images"、"batch resize"
  5. Scene optimization — "用于邮件附件"、"上传网站"、"微信发送"、"optimize for web"、"shrink for email"
  6. Typical triggers:
    • "帮我压缩这张图片,文件太大了发不了微信"
    • "Screenshot.png is 10MB, make it smaller"
    • "Convert all PNGs in this folder to WebP"
    • "Resize these photos to max 1920px width"

Do NOT trigger for:

  • Image generation (use pixmind-image skill)
  • Image editing (crop, rotate, watermark, filters)
  • Image analysis (OCR, content recognition, EXIF reading)

Prerequisites

  1. Register at pixmind.io200 bonus points on signup (free trial)
  2. Create an API key at pixmind.io/api-keys
  3. Set env PIXMIND_API_KEY with your key

Quick Start

# Compress a single image (local file)
node {baseDir}/compress.js --file ~/Desktop/photo.png --preset web

# Compress from URL
node {baseDir}/compress.js --url https://example.com/image.jpg --quality 80 --format webp

# Resize to max 1920px width
node {baseDir}/compress.js --file photo.jpg --width 1920

# Batch compress a folder
node {baseDir}/compress.js --dir ~/Pictures/ --preset web --recursive

Presets

Quick scene-based compression — no need to remember quality numbers:

PresetQualityFormatUse CaseSavings
--------------------------------------------
web75WebPWebsite, blog, CMS upload60-70%
wechat65JPGWeChat, social media sharing70-80%
email55JPGEmail attachments, fast transfer80-90%
quality95originalHigh-quality archiving, print30-40%
thumbnail60WebPThumbnails, previews, avatars80-90%

API Details

Endpoint: POST https://aihub-admin.aimix.pro/open/cos/image/compress

Auth: Header X-API-Key: {API_KEY} and X-App-Key: {APP_KEY}

Request Body (JSON)

ParameterRequiredTypeDescription
----------------------------------------
imageUrlOne ofstringImage URL (COS or external link)
imageBase64One ofstringBase64 image data (supports data:image/xxx;base64, prefix)
formatNostringOutput format: webp, jpg, png, avif, heif, tpg
qualityNonumberCompression quality 1-100 (default: 75)
widthNonumberTarget width in pixels (maintains aspect ratio)
heightNonumberTarget height in pixels (maintains aspect ratio)
modeNostringResponse type: url (default) or base64

Response Format

{
  "code": 1000,
  "message": "success",
  "data": {
    "originalUrl": "https://bucket.cos.region.myqcloud.com/image.jpg",
    "compressedUrl": "https://bucket.cos.region.myqcloud.com/image.jpg?imageMogr2/format/webp/quality/75",
    "originalSize": 1024000,
    "compressedSize": 256000,
    "format": "webp",
    "quality": 75,
    "width": 800,
    "height": 600
  }
}

Supported Formats

Input: JPG, JPEG, PNG, WebP, GIF, BMP, HEIC, HEIF

Output: webp, jpg, png, avif, heif, tpg

CLI Options

OptionShortTypeDefaultDescription
-------------------------------------------
--url-ustringImage URL to compress
--file-fstringLocal image file path
--dir-dstringDirectory for batch processing
--formatstringoriginalOutput: webp, jpg, png, avif, heif, tpg
--quality-qnumber75Quality 1-100
--width-wnumberTarget width (maintain ratio)
--heightnumberTarget height (maintain ratio)
--preset-pstringweb, wechat, email, quality, thumbnail
--output-ostringautoOutput directory
--recursive-rbooleanfalseProcess subdirectories
--modestringurlResponse: url or base64

Output Rules

  • Compressed files saved to ~/Downloads/compressed-images/{date}/ by default
  • Original files are never modified or overwritten
  • Duplicate filenames auto-numbered: photo_001.jpg, photo_002.jpg
  • Batch mode preserves original directory structure

Guidelines

  1. For local files, the script auto-reads and converts to Base64 for upload
  2. Default to quality 75 — good balance of quality and size
  3. Match presets to use cases: web for sites, wechat for sharing, email for attachments
  4. When resizing, specify only one dimension to maintain aspect ratio
  5. For batch processing, show progress and total savings summary
  6. After compression, always show before/after size and savings percentage
  7. Prefer webp for web — best compression with good quality
  8. For photos: recommend jpg or webp; for screenshots/diagrams: png or webp
  9. HEIC (iPhone) photos are natively supported — no extra dependencies needed

版本历史

共 1 个版本

  • v1.0.1 当前
    2026-05-08 02:59 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

ai-intelligence

Self-Improving + Proactive Agent

ivangdavila
自我反思+自我批评+自我学习+自组织记忆。智能体评估自身工作、发现错误并持续改进。
★ 1,355 📥 318,015
ai-intelligence

ontology

oswalpalash
类型化知识图谱,用于结构化智能体记忆与可组合技能。支持创建/查询实体(人员、项目、任务、事件、文档)及关联...
★ 711 📥 243,702
security-compliance

Skill Vetter

spclaudehome
AI智能体技能安全预审工具。安装ClawdHub、GitHub等来源技能前,检查风险信号、权限范围及可疑模式。
★ 1,214 📥 266,401