crop-images

crop-images is a command for Claude Code from danielrosehill/Claude-Image-Production-Plugin. It costs 0 tokens per session (1,544 once invoked), scanned A, original, MIT.

A command for cutting images to exact dimensions, a chosen shape ratio, coordinates, or the visible subject. An aspect ratio is the relationship between an image’s width and height, such as 16:9 or 1:1.

In plain words
What is it for?
Use it to prepare images for websites, social media, thumbnails, print sizes, or any layout requiring a specific shape or size.
Why use it?
It removes the repetitive work of opening and cropping images one by one. It can also apply the same kind of crop to many images.

Command for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the image-production plugin — 29 skills, 19 commands shipped together

Good fit Use it to prepare images for websites, social media, thumbnails, print sizes, or any layout requiring a specific shape or size.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/danielrosehill/claude-image-production-plugin/crop-images
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/danielrosehill/Claude-Image-Production-Plugin

Made for: Claude Code.

Or install image-production, the plugin that ships this one along with the rest of its 29 skills, 19 commands.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for crop-images

README.md
[![agentmods](https://agentmods.dev/badge/commands/danielrosehill/claude-image-production-plugin/crop-images/github.svg)](https://agentmods.dev/commands/danielrosehill/claude-image-production-plugin/crop-images)
Your own site
<a href="https://agentmods.dev/commands/danielrosehill/claude-image-production-plugin/crop-images"><img src="https://agentmods.dev/badge/commands/danielrosehill/claude-image-production-plugin/crop-images/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for crop-images

Your own site · 80×15
<a href="https://agentmods.dev/commands/danielrosehill/claude-image-production-plugin/crop-images"><img src="https://agentmods.dev/badge/commands/danielrosehill/claude-image-production-plugin/crop-images.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,544 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00000 $0.01544
Opus 5 $0.00000 $0.00772
Sonnet 5 $0.00000 $0.00309
Haiku 4.5 $0.00000 $0.00154

Measured 10d ago against content hash 268a08bf202b, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

crop-images scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

commands/crop-images.md · 227 lines

How it starts

The opening of the file, as written. The whole thing — 227 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Crop Images

You are a photo editing assistant specialized in cropping images to specific dimensions, aspect ratios, or custom areas.

Your Task

Help the user crop images precisely:

  1. Ask the user for:

    • Input image(s)
    • Crop method (dimensions, aspect ratio, coordinates, smart crop)
    • Target size or ratio
    • Alignment (center, top, bottom, left, right)
    • Output path
  2. Use ImageMagick or FFmpeg:

    • Crop to exact dimensions
    • Crop to aspect ratio
    • Crop based on coordinates
    • Smart crop based on content
    • Batch processing
  3. Execute and verify results

ImageMagick Crop Commands

Crop to Specific Dimensions

Crop 800x600 from top-left:

convert input.jpg -crop 800x600+0+0 output.jpg

Crop 800x600 from center:

convert input.jpg -gravity center -crop 800x600+0+0 output.jpg

Crop from specific coordinates (x,y):

convert input.jpg -crop 800x600+100+50 output.jpg

Crop to Aspect Ratio (Center)

Crop to 16:9 ratio:

convert input.jpg -gravity center -crop 16:9 output.jpg

Crop to 1:1 (square):

convert input.jpg -gravity center -crop 1:1 output.jpg

Crop to 4:3 ratio:

convert input.jpg -gravity center -crop 4:3 output.jpg

Gravity Options for Alignment

Crop from top:

convert input.jpg -gravity north -crop 1920x800+0+0 output.jpg

Crop from bottom:

convert input.jpg -gravity south -crop 1920x800+0+0 output.jpg

Crop from left:

convert input.jpg -gravity west -crop 800x1080+0+0 output.jpg

Crop from right:

convert input.jpg -gravity east -crop 800x1080+0+0 output.jpg

Smart Crop (Content-Aware)

Auto-crop whitespace/borders:

convert input.jpg -trim +repage output.jpg

Crop to largest centered square:

convert input.jpg -gravity center -crop 1:1 +repage output.jpg

Social Media Crops

Instagram square (1080x1080):

convert input.jpg -gravity center -crop 1080x1080+0+0 +repage output.jpg

Read the full file on GitHub · 227 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 10d ago First seen · 227 lines · 0 tokens per session scan A 268a08bf202b

Subscribe to this mod's changes

crop-images is a command published in the GitHub repository danielrosehill/Claude-Image-Production-Plugin (16 stars, last pushed 23d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,544 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.