Skip to main content
Glama

set_turnout

Set a model railroad turnout to thrown or closed by name, then report the actual observed state and whether it was confirmed.

Instructions

Set a turnout CLOSED or THROWN, and report the state actually observed.

Args: name: Turnout name (JMRI system name like "IT100", or its user-friendly label like "Layout Turnout A") or an unambiguous fragment of the label. Case-insensitive. thrown: True to THROW the turnout, False to CLOSE it. JMRI/ PanelPro's own terminology — not "open"/"closed" track, which would be ambiguous about which direction is which.

This writes to JMRI (and moves a physical turnout motor on real hardware). The reported state is re-read after the command; if the observed state doesn't match the request, "confirmed" will be false and that should be reported honestly rather than assumed as success — some turnouts have feedback sensors that can fail to settle to the commanded position.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYes
thrownYes
Behavior5/5

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

With no annotations provided, the description fully carries the burden of behavioral disclosure. It states that the tool writes to JMRI, moves physical hardware, re-reads state after command, and warns about possible feedback sensor issues where 'confirmed' may be false. It also clarifies JMRI terminology for the boolean parameter, preventing ambiguity.

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?

The description is concise and well-structured with a clear header and 'Args:' section. Every sentence adds value—no fluff. It is appropriately sized for the tool's complexity.

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?

Given the tool's moderate complexity (write with feedback), the description covers the command, parameters, and behavioral consequences. It mentions the 'confirmed' field but does not explicitly outline the return structure; however, since no output schema is provided, this is acceptable. A slightly more explicit statement about the output format would make it fully complete.

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?

The input schema provides only names and types. The description adds significant meaning: 'name' can be system name or user label (case-insensitive), and 'thrown' is explained with JMRI terminology ('THROW' vs 'CLOSE') and disambiguation from track terminology. This fully compensates for the schema's lack of descriptions.

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?

The description clearly states the action: 'Set a turnout CLOSED or THROWN, and report the state actually observed.' It specifies the resource (turnout) and the two possible states. This distinguishes it from siblings like get_turnout (read-only) and set_all_turnouts (sets all turnouts).

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

Usage Guidelines4/5

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

The description explains when to use this tool (to set a turnout to a specific state) and provides important context about feedback sensors and the 'confirmed' field. However, it does not explicitly contrast with alternatives (e.g., when to use get_turnout instead) or state when not to use. Still, the context is clear and useful.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/HO44-PROJECT/MrJ-JMRI-MCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server