Skip to main content
Glama

sch_set_units

Sets the unit system for the active schematic, letting you switch between imperial and metric units for consistent measurement display and editing.

Instructions

Set the unit system for the active schematic.

Calls ISch_Document.SetState_Unit with a TUnit enum value. The current unit is readable via obj_get_document_info (unit_system field).

Args: unit: one of "mil" , imperial, mils (0.001 in) "inch" , imperial, inches "dxp" , DXP default "auto_imperial" , auto-scaled imperial display "mm" , metric, millimetres "cm" , metric, centimetres "m" , metric, metres "auto_metric" , auto-scaled metric display

Returns: Dictionary confirming the change, with the resulting unit_system ("imperial" or "metric").

Input Schema

NameRequiredDescriptionDefault
unitYes

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.6.1

TDQS

A4.2/5.0
Behavior3/5

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

No annotations are provided, so the description carries the full behavioral burden. It usefully discloses that this calls `ISch_Document.SetState_Unit` and that the response confirms the resulting `unit_system`, but it does not clarify whether the change is purely display-level, whether it persists, or what happens if no schematic is active.

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?

The purpose is front-loaded in the first sentence, and the enum documentation is structured and useful. The description is slightly longer than strictly necessary because it repeats return information already covered by the output schema, but every section is readable and purposeful.

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 one-parameter setter with an output schema, the description covers the important input semantics and points to the sibling for reading the current unit. It could be more complete by stating the active-document precondition or the scope of the change, but overall it contains what an agent needs to call the tool correctly.

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 has 0% description coverage and only declares `unit` as an unconstrained string. The description compensates fully by enumerating every accepted enum value and explaining what each means, including imperial, metric, and auto-scaled options.

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 states a specific verb and resource: set the unit system for the active schematic. It also distinguishes the write operation from the read path by naming `obj_get_document_info` as the way to inspect the current unit, so an agent can tell it apart from the inspection sibling without opening the schema.

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 provides clear usage context by explaining that this tool changes the active schematic's units and that the current value is available through `obj_get_document_info`. It does not explicitly state exclusions or prerequisites such as requiring an open active schematic, which keeps it from a full 5.

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

Deploy Server

Other Tools