Skip to main content
Glama

Find regions (Segment Anything)

find_regions
Read-onlyIdempotent

Detects distinct image objects automatically and returns numbered boxes plus an outlined preview, helping you pick correct regions to pass to segmentation when manual boxes are hard.

Instructions

Find the distinct objects in an image automatically, with no boxes needed: returns them numbered, with each one's exact box, and a picture with the numbered outlines drawn on it. Nothing is saved.

Use it before segment_objects when an image has many similar objects (glands, cells, crypts, vessels) or when boxes are hard to place: look at the picture, choose the numbers that are the objects asked for, and pass their boxes unchanged to segment_objects (with model "medsam" for medical images). A region inside another is a part of it (e.g. a gland's lumen inside the gland): choose the one that matches the whole object. Objects not found as a region still need a box of your own. Takes about a minute (a few after a quiet spell, while the model loads); very small objects can be missed.

Input Schema

NameRequiredDescriptionDefault
image_idYesId of an image in Image Label: the imageId (a UUID string) returned by list_images or an upload.
max_sizeNoLongest side of the returned picture, in pixels.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.9.0

TDQS

A4.8/5.0
Behavior5/5

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

Beyond the readOnly/idempotent/non-destructive annotations, it says nothing is persisted, describes the return payload (numbered regions, boxes, overlay picture), gives latency expectations (~1 minute, longer after idle while the model loads), and discloses a failure mode (very small objects can be missed). These are exactly the cost and reliability facts an agent needs before committing.

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?

Front-loaded with purpose and output, then workflow, then caveats; every sentence carries operational content. It is a bit dense with parenthetical asides, but none are redundant filler.

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

Completeness5/5

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

There is no output schema, so the description carries the return-value burden and does so fully, including the downstream handoff to segment_objects. For a read-only two-parameter tool with annotations covering safety, nothing material is missing.

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

Parameters4/5

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

Schema coverage is 100%, so image_id and max_size are already documented, and the description correctly does not restate them. It does add meaning by explaining that the returned picture is the artifact whose numbers you select and whose boxes you pass unchanged to segment_objects, which clarifies the intended use of the output rather than the inputs.

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: find the distinct objects in an image automatically, with no boxes needed. It also describes the output precisely (numbered regions, exact boxes, overlay picture) and distinguishes itself from the sibling segment_objects by naming it and by requiring pre-existing boxes.

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

Usage Guidelines5/5

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

Explicit when-to-use: before segment_objects when an image has many similar objects (glands, cells, crypts, vessels) or when boxes are hard to place, and when not to rely on it (objects not found still need a box of your own). It also resolves the ambiguous nested-region case with a rule (choose the region matching the whole object) and recommends model "medsam" for medical images.

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