Skip to main content
Glama

Lookup Kit

semver_compare

Read-only

Semver compare, version comparison and range check (npm semver). Compare two semantic versions (e.g. 1.2.3 vs 1.10.0-beta.1), check whether a version satisfies a range (^1.2, ~2.0, >=3 <4), or get the newest version from a list that satisfies a range. Uses npm's semver rules. Price: $0.001 per call (x402, USDC on Base).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "a": "<a>"
    },
    "name": "semver_compare"
  }
}

Input Schema

NameRequiredDescriptionDefault
aYes
bNo
rangeNo
versionsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.8/5.0
Behavior3/5

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

Annotations already establish readOnlyHint=true and openWorldHint=false, consistent with a pure-computation tool. The description adds genuinely useful non-schema context — deterministic npm semver semantics and a $0.001-per-call x402/USDC-on-Base price — but says nothing about error behavior on invalid versions, output shape, or what is returned when a range is unsatisfiable.

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?

Single front-loaded paragraph that leads with the operations and closes with the runtime and pricing facts; every clause adds information. The opening keyword string ("Semver compare, version comparison and range check") is slightly redundant padding.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a four-parameter tool with no output schema and zero parameter documentation, the definition explains what the tool computes but not the shape of its response (boolean vs. version string vs. comparison sign) or failure modes. Adequate to select the tool, insufficient to invoke it confidently across all three modes.

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 0%, so the description must carry the burden. It does implicitly map the four fields (two versions, a range, a version list), but the opaque names 'a' and 'b' are never disambiguated even though comparison order determines the result, and no format or maxLength guidance is given.

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?

States the resource and verb precisely ("Compare two semantic versions", "check whether a version satisfies a range", "get the newest version from a list that satisfies a range") and enumerates all three operating modes with concrete examples (^1.2, ~2.0, >=3 <4). No sibling tool covers semver logic, and the npm-semver qualifier pins down the exact dialect.

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?

Each mode is illustrated with a realistic input pattern, so an agent can infer which inputs trigger which behavior. It does not explicitly tie modes to parameter names or state what happens with insufficient inputs, and no when-not/alternative routing is given, which keeps it below a 5.

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.

Resources