Skip to main content
Glama
kinbinghua-lgtm

agent-core-mcp

base_convert

Read-onlyIdempotent

Convert integer strings between bases 2 and 36 exactly, preserving values beyond 2^53 where naive conversion loses precision.

Instructions

Convert an integer string between bases 2 and 36 with arbitrary precision. Uses big-integer parsing, so values beyond IEEE-754 double precision (2^53) stay exact, which is exactly where naive conversion goes wrong. A leading 0b/0x/0o prefix is ignored.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
valueYesInteger as text, e.g. "ff" or "255"
toBaseYesTarget base
fromBaseYesSource base

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

A4.1/5.0
Behavior5/5

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

Annotations already cover the safety profile (readOnly, idempotent, non-destructive, closed-world), yet the description still adds real behavioral context: arbitrary precision via big-integer parsing, exactness beyond 2^53 where naive conversion fails, and tolerance of leading 0b/0x/0o prefixes. These are traits an agent cannot recover from the structured fields.

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?

Three tight sentences, front-loaded with the core action and scope, then precision guarantees, then the prefix edge case. Every sentence carries information; nothing is redundant padding.

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?

With no output schema, the description should ideally specify the return representation (a string in the target base), which it leaves unstated, and it says nothing about error behavior for out-of-range digits. All three required parameters are documented and the precision caveat is covered, so it is close to complete for a simple deterministic tool.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3, but the description adds meaning beyond it by clarifying that 'value' may carry a 0b/0x/0o prefix that is ignored. It does not clarify the return type (string vs number) or behavior on invalid digits, so it falls short of fully complementing the schema.

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 (convert), a specific resource (integer string), and an explicit scope (bases 2-36), which is far more precise than the sibling name 'convert' alone. It does not explicitly contrast itself with the sibling 'convert', so sibling differentiation is only implicit.

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 implied by the narrow purpose: use it when you need a base-to-base integer conversion. There is no explicit when-to-use/when-not guidance and no mention of how it relates to the nearby 'convert' or 'hash' siblings; an agent must infer the boundary.

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