Skip to main content
Glama

set_selection

Set a selection by rectangle, ellipse, polygon, layer, color tolerance, all, or none, and choose replace/add/subtract/intersect to constrain later edits to that area.

Instructions

Select: kind=rect or ellipse (x, y, width, height), polygon (points [[x,y],...]), layer (the opaque pixels of layer), color (every pixel within tolerance 0-255 of color, or of the colour at x,y; contiguous=true = magic wand from x,y), all, or none. mode: replace, add, subtract, intersect. Later draw/brush/filter/fill operations are limited to it.

Input Schema

NameRequiredDescriptionDefault
xNo
yNo
kindNorect
modeNoreplace
colorNo
layerNo
widthNo
heightNo
pointsNo
toleranceNo
contiguousNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.0

TDQS

A4/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 substantial work: it explains that the resulting selection constrains later draw/brush/filter/fill operations, and clarifies tolerance/contiguous semantics ('magic wand from x,y') and how mode interacts with an existing selection. It omits error behavior and what happens when kind maps to 'none' or when required coordinates are missing.

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?

Two dense sentences, front-loaded with the resource and its variants; the parenthetical enumerations keep related semantics adjacent and there is essentially no filler. The compression into slash-separated lists is slightly harder to scan than a short bulleted breakdown would be.

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

Completeness4/5

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

For an 11-parameter, default-everything mutation tool with no annotations and no output schema, the description covers all parameter meanings and the key downstream effect on painting operations. It falls short only on failure modes and on the default selection behavior (e.g., empty call), which an agent might need.

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

Parameters5/5

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

Schema description coverage is 0% across 11 parameters, so the description must compensate, and it does: it defines kind values, the x/y/width/height box, the points [[x,y],...] structure, layer meaning ('opaque pixels'), color plus tolerance 0-255 and the x,y-sampled color case, contiguous, and mode. This is meaning well beyond the bare schema titles.

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?

The description opens with a specific verb ('Select') and then enumerates every selection shape it supports (rect, ellipse, polygon, layer, color, all, none), so an agent knows exactly what the tool produces. It does not, however, distinguish itself from the sibling modify_selection, which an agent could easily confuse with it.

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 rather than stated: the 'mode' enumeration (replace, add, subtract, intersect) tells the agent how to combine with an existing selection, and the final sentence implies you call this before draw/brush/filter/fill. There is no explicit when-to-use or when-not-to-use versus modify_selection or fill_selection.

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