Skip to main content
Glama

image_optimize

Destructive

Shrink images for web delivery by setting quality and stripping metadata to cut file size, with optional overwrite and metadata retention.

Instructions

Shrink an image for web delivery. Metadata is stripped unless strip_metadata=false.

Input Schema

NameRequiredDescriptionDefault
qualityNo
overwriteNo
input_pathYes
output_pathYes
strip_metadataNo

Output Schema

NameRequiredDescriptionDefault
widthYes
formatYes
heightYes
output_pathYes
output_bytesYes
original_bytesYes
savings_percentYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.0

TDQS

B3.3/5.0
Behavior3/5

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

Annotations already declare destructiveHint=true and readOnlyHint=false, so the safety profile is covered. The description adds a genuinely useful behavioral fact — metadata is stripped by default — but says nothing about what happens when the output file already exists or when overwrite=false, which matters for a destructive tool.

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

Conciseness5/5

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

Two short sentences with zero filler; the core action is front-loaded and the surprising default (metadata stripping) follows immediately.

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?

An output schema exists, so return values needn't be explained, and annotations cover the safety profile. However, for a 5-parameter destructive mutation with 0% schema coverage, the description is too thin — most parameters and the overwrite/existing-file behavior are unaddressed.

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

Parameters2/5

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

Schema description coverage is 0% across 5 parameters, so the description must carry the load. It explains only strip_metadata (including its default); quality, overwrite, input_path, and output_path are left entirely undocumented, and overwrite's interaction with destructiveHint is unmentioned.

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 ('Shrink') and resource ('an image') with a clear end goal ('for web delivery'), which distinguishes it from siblings like image_resize or image_convert. It doesn't explicitly name those siblings, so it stops short of 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 phrase 'for web delivery' implies the use case, but there is no explicit when-to-use versus image_resize/image_convert/image_thumbnail guidance and no prerequisites. Usage must be inferred from the sibling list.

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