Skip to main content
Glama

crop_sprite

Crop a sprite to a set rectangle or current selection, or trim empty borders automatically to remove unused canvas edges.

Instructions

Crops the sprite to a rectangle, to the selection (mode='selection'), or trims empty borders (mode='auto').

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modeNo
rectNo
saveNoBatch mode: write changes back to the sprite file (default true)
byGridNo
spriteNoFile path, open tab title, or sprite id. Defaults to the active sprite (live). Batch mode needs a file path.
backendNoauto (default): live Aseprite if connected, else headless batch

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

B3.4/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=false and destructiveHint=false, so the mutation profile is covered structurally. The description adds no behavioral context beyond the mode semantics — it never mentions the live-vs-batch backend distinction or that in batch mode changes are written back to the sprite file (default save=true) before and after a crop.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single, front-loaded sentence that names the operation first and then the three modes, with no filler. Slightly dense parenthetical structure, but every clause earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a six-parameter, mutation-capable tool with no output schema and 50% schema coverage, the description is thin: it omits where changes land (live canvas vs file), the meaning of byGrid, and the rect parameter's semantics. It is adequate to call the tool in the simplest case but leaves real gaps.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 50%: save, sprite, and backend are documented in the schema, while mode, rect, and byGrid are not. The description partially compensates by explaining what the 'selection' and 'auto' mode values mean (the enum names alone don't convey this), but it says nothing about rect's coordinate space or what byGrid does.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (crops) and resource (the sprite) and enumerates the three operating modes, so the agent knows exactly what the call does. It does not differentiate itself from nearby siblings such as resize_sprite, canvas_size, or selection_edit, which is the only missing piece for a 5.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The mode-to-behavior mapping ('selection' crops to selection, 'auto' trims empty borders) implies when each mode applies, but there is no explicit when-to-use guidance, no exclusions, and no routing to alternatives like resize_sprite or selection_edit for related operations.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.