Skip to main content
Glama

set_all_locos_lights

Turns all locomotive lights on or off in one call, operating on every locomotive currently acquired. Use for bulk lighting control without naming each loco.

Instructions

Turn ON/OFF EVERY light-related function of EVERY currently-acquired locomotive at once.

Args: state: True to turn every light-related function on for every locomotive, False to turn them all off.

Call for "turn on/off all the lights of all the locos"/"allume/ éteins toutes les lumières de toutes les locos" — locomotives in bulk, no single one named. Never loop set_loco_lights/set_function yourself — this loops server-side in one call, over every locomotive this session has acquired.

Same scope limitation as emergency_stop_all: only reaches locomotives THIS session has acquired a throttle for. A locomotive driven only from a JMRI panel or another session is untouched. Nothing acquired yet returns {"locomotives": []}, not an error.

For ONE named locomotive use set_loco_lights. For layout/scenery lighting (JMRI Light objects, no locomotive involved), use set_layout_lights instead — never this tool.

Returns {"locomotives": []} — attempted independently, one failure doesn't block the others.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
stateYes
Behavior5/5

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

Despite no annotations, the description fully discloses behavior: loops server-side, independent attempts per locomotive, one failure doesn't block others, returns list of results. Also explains scope: only affects locomotives acquired this session and that nothing acquired returns an empty array, not an error.

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?

Description is well-structured with a clear main sentence followed by Args, usage notes, and return info. Slightly redundant mentioning the looping behavior twice, but overall efficient and front-loaded.

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?

Given a single boolean parameter and no output schema, the description covers all needed context: input meaning, behavioral scope, return format, error handling, and alternatives. It is fully self-contained and leaves no gaps.

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 only parameter 'state' is fully explained in the Args section: 'True to turn every light-related function on for every locomotive, False to turn them all off.' Although context signals indicate 0% schema description coverage, the actual description provides complete semantics.

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 uses specific verb and resource: 'Turn ON/OFF EVERY light-related function of EVERY currently-acquired locomotive at once.' It clearly distinguishes itself from siblings by naming alternatives: set_loco_lights for one locomotive and set_layout_lights for layout/scenery lighting.

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?

Provides explicit when-to-use criteria: 'Call for "turn on/off all the lights of all the locos"... Never loop set_loco_lights/set_function yourself.' It also states when not to use: 'For ONE named locomotive use set_loco_lights' and 'For layout/scenery lighting... use set_layout_lights.' Includes scope limitation referencing emergency_stop_all.

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