Skip to main content
Glama

levenshtein

Compute edit distance between two strings with a similarity percentage. Pure CPU, instant. Use for fuzzy matching and dedupe.

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": "levenshtein"
  }
}

Input Schema

NameRequiredDescriptionDefault
aYesFirst string
bNoSecond string

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added
  2. Removed
  3. Changed3 schema fields changed
    • addedInput schema / properties / a
      Added value: +{
      +  "description": "First string",
      +  "type": "string"
      +}
    • addedInput schema / properties / b
      Added value: +{
      +  "description": "Second string",
      +  "type": "string"
      +}
    • addedInput schema / required
      Added value: +[
      +  "a"
      +]
  4. Added

TDQS

A3.5/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the full burden. It does disclose two useful traits — 'Pure CPU, instant' (performance/cost profile) and the fact that a similarity percentage is returned — but it says nothing about symmetry, edge cases (empty strings), or whether 'b' is optional despite being non-required.

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?

Three short sentences, front-loaded with the core operation and free of padding. 'Pure CPU, instant' is borderline filler but does convey a real performance characteristic, so it earns its place.

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 two-parameter pure-computation tool with no output schema, the description covers what it does, the returned value, and a performance profile. The only meaningful gap is the behavior when the optional second string is omitted, which neither schema nor description resolves.

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 coverage is 100%, with both parameters documented as 'First string' and 'Second string', so the baseline is 3. The description adds no format, length, or ordering semantics beyond what the schema already states, and does not explain the effect of omitting the non-required 'b'.

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?

The description uses a specific verb and resource ('Compute edit distance between two strings') and adds the returned metric (similarity percentage), so the operation is unambiguous. It does not, however, distinguish itself from near-neighbors in the catalog such as word_similarity, distance, or text_diff, which an agent could plausibly pick instead.

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?

'Use for fuzzy matching and dedupe' gives a positive usage cue, but there is no when-not guidance and no named alternative for cases where a different similarity or diff tool is the right choice. The guidance is implied rather than explicit.

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