Skip to main content
Glama

单位换算

unit_convert
Read-onlyIdempotent

在长度/重量/温度/体积/速度/面积/数据量单位间换算,单位支持中英文。Example: {"value":100,"from":"km","to":"mi"}

Example tool call

This call uses example arguments supplied in the tool’s input schema.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "to": "mi",
      "from": "km",
      "value": 100
    },
    "name": "unit_convert"
  }
}

Input Schema

NameRequiredDescriptionDefault
toYes目标单位,如 mi、斤、°F、MB
fromYes源单位(中英文均可),如 km、公斤、°C、GB
valueYes数值,如 100

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / examples
      Added value: +[
      +  {
      +    "from": "km",
      +    "to": "mi",
      +    "value": 100
      +  }
      +]
  2. First observed

TDQS

A3.5/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, idempotentHint=true, destructiveHint=false, so the safety profile is fully covered. The description adds the useful fact that units accept both Chinese and English names, but says nothing about handling of incompatible units, precision/rounding of results, or error behavior.

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?

A single compact sentence followed by an example; the capability is front-loaded. The inline example slightly duplicates the schema's examples array, keeping it from a perfect score.

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 simple three-parameter, read-only conversion tool with full schema coverage and no output schema, the description covers what the tool does and its category scope. Remaining gaps (result precision, incompatible-unit errors) are minor for this complexity level.

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% and each of the three parameters (value/from/to) is documented with examples in the schema. The description's note that units support Chinese and English merely repeats what the schema already states for 'from', so it adds no meaning beyond structured data.

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?

States a specific verb (换算) and enumerates the supported unit categories (length/weight/temperature/volume/speed/area/data), which effectively distinguishes it from currency_convert and timestamp_convert without naming them. Clear enough for an agent to match a conversion request.

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 only implied by the enumerated unit categories; there is no explicit statement of when to use this versus currency_convert for money or timestamp_convert for time. An agent must infer the boundary from the category list.

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.