Skip to main content
Glama

render_raster_layer_png

Convert attached raster layers or GeoTIFFs into PNG previews, auto-stretching single-band rasters and using the first three bands for multiband images.

Instructions

Decode an attached raster layer (or a GeoTIFF on disk) into a PNG preview. Single-band rasters are auto-stretched to grayscale; multi-band rasters use the first three bands. Returns base64 PNG bytes; pass output_path to also write to disk.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idNo
pathNo
max_widthNo
max_heightNo
output_pathNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.8/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does reasonably well: it discloses band handling (single-band auto-stretched to grayscale, multi-band uses first three), the return type (base64 PNG bytes), and the side effect of output_path writing to disk. It stops short of stating permission requirements or that one of id/path must be supplied.

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?

Three tight sentences with the core purpose front-loaded, band behavior next, and output/return semantics last. No filler or redundancy.

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 five-parameter tool with no annotations and no output schema, the description covers the return format and rendering behavior but leaves the sizing parameters and the id-versus-path input requirement unstated. Adequate but with clear gaps given the complexity.

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% for five parameters. The description covers output_path and hints at id/path via 'attached raster layer (or a GeoTIFF on disk)', but max_width and max_height are never explained, and it does not clarify that id and path are mutually exclusive inputs. It compensates only partially for the coverage gap.

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

Purpose5/5

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

States a specific verb and resource (decode a raster layer into a PNG preview) and scopes the accepted inputs (attached layer or on-disk GeoTIFF). This clearly separates it from list_raster_layers, attach_raster_layer, and the generic render_preview_svg/render_preview siblings.

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?

Usage is implied (produce a preview image from a raster), but there is no explicit when-to-use or when-not-to-use statement and no mention of alternatives such as get_raster_layer or render_preview_svg. The agent must infer routing from the purpose sentence alone.

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

Deploy Server

Other Tools