Skip to main content
Glama

Get viewer selection

get_selection
Read-only

What the human selected in the viewer, fixed as a set: a write with this set hits exactly these elements, even if the selection changes meanwhile. Also picked points without an element. Chosen openings, grids (a grid group with every member), structural items (IfcStructuralItem), spatial nodes without node address (IfcBridge, IfcSpatialZone ...) and an IfcAlignment or IfcReferent join the set too; no element - a writer that does not take its class rejects it with its way, set_properties writes it as by guid. Beside the set, never a target: refs (what each click hit: kind element|point|edge|face, guid, point; at a point, edge or face also grip: which part of the definition that place is, match one|choice|withheld|none, as the call that moves it - fill names the field to add; grip null with grip_reason stale when the model moved on; source measured mesh with snap: vertex|edge_midpoint|grid|circle_center|circle_quadrant|edge_perpendicular|face_perpendicular|edge|face|free, strongest first; edge, face and free are a mere click spot), measure (the distance the human measured: refs [from, to], from, to, length_m, delta_m per axis, source with the weaker snap of both ends; null without one), section (the cut the human sees, null without one: planes [{normal, d}], what stays is normal . p <= d for every plane - a box has six; axis_parallel false means render_view and draw_section cannot show it). All in project m. rows lists the first 20; the whole set reads in pages with find_elements filter.set (next). Read-only.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "get_selection"
  }
}

Input Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.6/5.0
Behavior4/5

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

Annotations only give readOnlyHint=true and idempotentHint=false; the description goes well beyond them, disclosing that rows are capped at 20 with paging, that refs can be null, that grip may be null with grip_reason 'stale' when the model moved on, that measure/section may be null, that axis_parallel=false blocks render_view and draw_section, and that values are in project metres. With no output schema, this return-shape disclosure carries real weight, though it is delivered as an undifferentiated wall rather than structured sections.

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

Conciseness2/5

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

The content is front-loaded, but it is one enormous run-on sentence chain stitched with semicolons, parentheticals and nested asides ('refs (what each click hit: kind element|point|edge|face, guid, point; at a point, edge or face also grip: ...)'). Important operational facts like the 20-row cap and the metres unit are buried mid-stream, making the definition hard to parse on first read.

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 a zero-argument, read-only tool with no output schema, the description covers the return payload unusually thoroughly: set membership rules, non-element targets, refs/grip/snap semantics, measure, section planes, units and paging. Gaps are minor - it does not say what an empty selection returns or whether the snapshot is taken at call time - but nothing critical for calling it correctly 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?

The tool takes zero parameters, so there is nothing for the description to disambiguate and the baseline of 4 applies. The description does confirm that no filter arguments exist and that paging is done through find_elements instead, which is a small useful addition.

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?

It states a concrete resource and scope: 'What the human selected in the viewer, fixed as a set', and clarifies the set is a snapshot so a write against it hits exactly those elements. That distinguishes it from get_element (one element) and find_elements (model query), though it never names those siblings as alternatives, so the differentiation is inferable rather than explicit.

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: it says the set 'reads in pages with find_elements filter.set (next)', which is a useful hand-off, but there is no explicit 'use this when the human picked something in the viewer; use cast_ray instead when you need to probe geometry'. The agent must infer the when-to-use from the surrounding text.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources