Skip to main content
Glama

heuristic_check

Check whether a heuristic is admissible and consistent for a given graph and goal, and optionally compare two heuristics for dominance.

Instructions

Is a heuristic admissible (h ≤ true cost) and consistent (h(n) ≤ c(n,n') + h(n'))? Optionally compare two for dominance.

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": {
      "edges": "<edges>",
      "goal": "<goal>",
      "heuristic": "<heuristic>"
    },
    "name": "heuristic_check"
  }
}

Input Schema

NameRequiredDescriptionDefault
goalYes
edgesYes
directedNo
heuristicYes
compare_withNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.0

TDQS

A3.5/5.0
Behavior3/5

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

With no annotations at all, the description carries the full behavioral burden, and it does supply the actual predicates being tested, which tells the agent this is a pure static analysis rather than a search execution. However, it says nothing about edge cases — unreachable nodes, missing entries in the heuristic map, or whether failures raise errors or are reported in the result.

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?

Two tight sentences, front-loaded with the primary check and ending with the optional mode. Every clause carries information; there is no padding or restatement of the tool name.

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?

The output schema covers return values, so the description needn't explain results, and it adequately conveys the mathematical substance of the tool. It falls short on the opaque 'edges' structure and the 'directed'/'goal' parameters, which leaves a caller guessing about input encoding for a 5-parameter, nested-object tool.

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% across 5 parameters, so the description must compensate. It partially does: the formulas give meaning to 'heuristic' (a per-node estimate) and to the edge cost c(n,n') embedded in 'edges', and it explains that 'compare_with' enables the dominance comparison. 'goal' and 'directed' remain entirely uninterpreted, and nothing explains the nested array-of-arrays shape of 'edges'.

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 names a specific analysis — checking admissibility (h ≤ true cost) and consistency (h(n) ≤ c(n,n') + h(n')) of a heuristic — and flags an optional dominance comparison. That is a concrete verb-and-resource statement an agent can match to a need, though it does not explicitly differentiate itself from siblings such as search_trace, which also involves heuristics.

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: the reader infers this is used to validate a heuristic before running a search, and 'optionally compare two for dominance' hints at the compare mode. There is no explicit when-to-use, when-not-to-use, or named alternative, so the agent must infer the routing decision.

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