Skip to main content
Glama
laszlopere

mcp-gnu-units

convert_to_si

Reduce any unit or compound expression to its SI base units (kg, m, s, etc.) to see the true dimensional makeup and magnitude.

Instructions

Reduce a value or unit expression to its SI base units (GNU units engine, TODO §17).

Rewrites any expression in terms of the database's primitive/base units — kg, m, s, A, K, mol, cd, and the like — collapsing all derived and prefixed units. This is how you see what a quantity really is dimensionally: kW*hour becomes 3600000 kg m^2 / s^2 (3.6 MJ), newton becomes 1 kg m / s^2. Use it to compare or sanity-check units, or to get a magnitude in coherent SI.

Returns: expr (echoed), result (the reduced quantity WITH its base-unit signature, e.g. "3600000 kg m^2 / s^2" — the primary human-readable answer), value (the same magnitude as a bare float for programmatic use), dimension (just the base-unit signature, e.g. "kg m^2 / s^2", or "1" when dimensionless), and exact (true when the result is exact, false when it was rounded). Errors cleanly (isError) when a unit is unknown, an expression is malformed, or it is a nonlinear unit with no linear base form (e.g. tempF). Example: convert_to_si("kWhour") -> {"expr":"kWhour","result":"3600000 kg m^2 / s^2","value":3600000.0, "dimension":"kg m^2 / s^2","exact":true}

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
exprYesThe quantity or unit expression to reduce to SI base units. May carry a numeric coefficient and be compound: 'kW*hour', '100 W', 'acre ft', '55 mile/hour'. A bare unit like 'newton' is treated as one of that unit. ⚠️ In the GNU units database single-letter names are literal: 'h' is Planck's constant, not hour — write 'hour' (so energy is 'kW*hour', not 'kW*h'). Nonlinear units (e.g. 'tempF') have no linear base form and error.
Behavior5/5

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

No annotations provided, so description carries full burden. It discloses edge cases (single-letter names, nonlinear units), error conditions (unknown unit, malformed expression), and return fields (expr, result, value, dimension, exact). No contradictions.

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?

Front-loaded with a clear one-sentence summary, followed by explanation, return field list, example, and edge case notes. Every sentence is informative; no redundancy.

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 one parameter, no output schema, and no annotations, the description fully covers tool behavior: purpose, return fields, example, errors, and unit quirks. Sufficient for an agent to use correctly.

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

Parameters3/5

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

Schema description coverage is 100% with a detailed parameter description. The tool description repeats the same parameter info but adds contextual examples and return field descriptions. It adds value but not beyond what the schema already provides for the parameter itself.

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 it reduces to SI base units, with examples like 'kW*hour' -> '3600000 kg m^2 / s^2'. It distinguishes from siblings by specifying it reveals 'what a quantity *really* is dimensionally', whereas sibling 'convert' likely does generic unit conversion.

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?

Explicitly says 'Use it to compare or sanity-check units, or to get a magnitude in coherent SI.' It hints at when not to use by noting nonlinear units like tempF error. It does not explicitly compare to alternatives but the context implies it's for SI base reduction, not arbitrary conversions.

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/laszlopere/mcp-gnu-units'

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