Skip to main content
Glama

Scan a grid for a counterexample

scan_counterexample
Read-onlyIdempotent

Bounded deterministic float64 scan of a scalar <= or >= claim over a declared grid of 1–6 variables. Reports numerical witnesses, undefined and uncertain evaluations, and the exact stop reason. A propagated screening guard rejects near-boundary candidates; it is not a certified interval or formal proof. An inconclusive outcome preserves unresolved sampled cells; absence of a witness does not establish the claim over the continuous box.

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": {
      "bound": "<bound>",
      "expression": "<expression>",
      "relation": "<relation>",
      "variables": "<variables>"
    },
    "name": "scan_counterexample"
  }
}

Input Schema

NameRequiredDescriptionDefault
boundYes
relationYes
toleranceNo
variablesYes
expressionYes
max_evaluationsNo
max_counterexamplesNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -{
      -  "$schema": "http://json-schema.org/draft-07/schema#",
      -  "additionalProperties": false,
      -  "properties": {
      -    "assumptions": {
      -      "items": {
      -        "maxLength": 512,
      -        "minLength": 1,
      -        "type": "string"
      -      },
      -      "maxItems": 16,
      -      "minItems": 1,
      -      "type": "array"
      -    },
      -    "bound": {
      -      "maximum": 1000000000000,
      -      "minimum": -1000000000000,
      -      "type": "number"
      -    },
      -    "complete": {
      -      "type": "boolean"
      -    },
      -    "contract_version": {
      -      "const": "0.2.0",
      -      "type": "string"
      -    },
      -    "counterexamples": {
      -      "items": {
      -        "additionalProperties": false,
      -        "properties": {
      -          "comparison_guard": {
      -            "maximum": 1.7976931348623157e+308,
      -            "minimum": 0,
      -            "type": "number"
      -          },
      -          "expression_value": {
      -            "maximum": 1.7976931348623157e+308,
      -            "minimum": -1.7976931348623157e+308,
      -            "type": "number"
      -          },
      -          "margin": {
      -            "maximum": 1.7976931348623157e+308,
      -            "minimum": 0,
      -            "type": "number"
      -          },
      -          "values": {
      -            "items": {
      -              "additionalProperties": false,
      -              "properties": {
      -                "name": {
      -                  "maxLength": 32,
      -                  "minLength": 1,
      -                  "type": "string"
      -                },
      -                "value": {
      -                  "maximum": 1000000,
      -                  "minimum": -1000000,
      -                  "type": "number"
      -                }
      -              },
      -              "required": [
      -                "name",
      -                "value"
      -              ],
      -              "type": "object"
      -            },
      -            "maxItems": 6,
      -            "minItems": 1,
      -            "type": "array"
      -          }
      -        },
      -        "required": [
      -          "comparison_guard",
      -          "expression_value",
      -          "margin",
      -          "values"
      -        ],
      -        "type": "object"
      -      },
      -      "maxItems": 16,
      -      "minItems": 0,
      -      "type": "array"
      -    },
      -    "elapsed_ms": {
      -      "maximum": 1000000000,
      -      "minimum": 0,
      -      "type": "number"
      -    },
      -    "engine": {
      -      "const": "rust-cpu",
      -      "type": "string"
      -    },
      -    "evaluated": {
      -      "maximum": 200000,
      -      "minimum": 0,
      -      "type": "integer"
      -    },
      -    "expression": {
      -      "maxLength": 512,
      -      "minLength": 1,
      -      "type": "string"
      -    },
      -    "finite_evaluations": {
      -      "maximum": 200000,
      -      "minimum": 0,
      -      "type": "integer"
      -    },
      -    "first_counterexample": {
      -      "anyOf": [
      -        {
      -          "additionalProperties": false,
      -          "properties": {
      -            "comparison_guard": {
      -              "maximum": 1.7976931348623157e+308,
      -              "minimum": 0,
      -              "type": "number"
      -            },
      -            "expression_value": {
      -              "maximum": 1.7976931348623157e+308,
      -              "minimum": -1.7976931348623157e+308,
      -              "type": "number"
      -            },
      -            "margin": {
      -              "maximum": 1.7976931348623157e+308,
      -              "minimum": 0,
      -              "type": "number"
      -            },
      -            "values": {
      -              "items": {
      -                "additionalProperties": false,
      -                "properties": {
      -                  "name": {
      -                    "maxLength": 32,
      -                    "minLength": 1,
      -                    "type": "string"
      -                  },
      -                  "value": {
      -                    "maximum": 1000000,
      -                    "minimum": -1000000,
      -                    "type": "number"
      -                  }
      -                },
      -                "required": [
      -                  "name",
      -                  "value"
      -                ],
      -                "type": "object"
      -              },
      -              "maxItems": 6,
      -              "minItems": 1,
      -              "type": "array"
      -            }
      -          },
      -          "required": [
      -            "comparison_guard",
      -            "expression_value",
      -            "margin",
      -            "values"
      -          ],
      -          "type": "object"
      -        },
      -        {
      -          "type": "null"
      -        }
      -      ]
      -    },
      -    "grid_total": {
      -      "maximum": 68719476736,
      -      "minimum": 1,
      -      "type": "integer"
      -    },
      -    "limits": {
      -      "items": {
      -        "maxLength": 512,
      -        "minLength": 1,
      -        "type": "string"
      -      },
      -      "maxItems": 16,
      -      "minItems": 0,
      -      "type": "array"
      -    },
      -    "method": {
      -      "maxLength": 4096,
      -      "minLength": 1,
      -      "type": "string"
      -    },
      -    "notes": {
      -      "items": {
      -        "maxLength": 512,
      -        "minLength": 1,
      -        "type": "string"
      -      },
      -      "maxItems": 16,
      -      "minItems": 0,
      -      "type": "array"
      -    },
      -    "provenance": {
      -      "additionalProperties": false,
      -      "properties": {
      -        "client": {
      -          "additionalProperties": {},
      -          "properties": {
      -            "name": {
      -              "type": "string"
      -            },
      -            "version": {
      -              "type": "string"
      -            }
      -          },
      -          "required": [
      -            "name",
      -            "version"
      -          ],
      -          "type": "object"
      -        },
      -        "identity_source": {
      -          "type": "string"
      -        },
      -        "model": {
      -          "type": "null"
      -        },
      -        "server": {
      -          "const": "scorecompute",
      -          "type": "string"
      -        },
      -        "tool": {
      -          "const": "scan_counterexample",
      -          "type": "string"
      -        }
      -      },
      -      "required": [
      -        "tool",
      -        "server",
      -        "client",
      -        "identity_source",
      -        "model"
      -      ],
      -      "type": "object"
      -    },
      -    "relation": {
      -      "anyOf": [
      -        {
      -          "const": "le",
      -          "type": "string"
      -        },
      -        {
      -          "const": "ge",
      -          "type": "string"
      -        }
      -      ]
      -    },
      -    "statement": {
      -      "maxLength": 4096,
      -      "minLength": 1,
      -      "type": "string"
      -    },
      -    "stop_reason": {
      -      "anyOf": [
      -        {
      -          "const": "grid_complete",
      -          "type": "string"
      -        },
      -        {
      -          "const": "evaluation_budget",
      -          "type": "string"
      -        },
      -        {
      -          "const": "counterexample_limit",
      -          "type": "string"
      -        }
      -      ]
      -    },
      -    "stopped_early": {
      -      "type": "boolean"
      -    },
      -    "tolerance": {
      -      "maximum": 1000000000000,
      -      "minimum": 0,
      -      "type": "number"
      -    },
      -    "uncertain_evaluations": {
      -      "maximum": 200000,
      -      "minimum": 0,
      -      "type": "integer"
      -    },
      -    "undefined_evaluations": {
      -      "maximum": 200000,
      -      "minimum": 0,
      -      "type": "integer"
      -    },
      -    "verdict": {
      -      "anyOf": [
      -        {
      -          "const": "counterexamples_found",
      -          "type": "string"
      -        },
      -        {
      -          "const": "no_counterexample_in_scanned_box",
      -          "type": "string"
      -        },
      -        {
      -          "const": "inconclusive",
      -          "type": "string"
      -        }
      -      ]
      -    },
      -    "work_units": {
      -      "maximum": 200000,
      -      "minimum": 0,
      -      "type": "integer"
      -    }
      -  },
      -  "required": [
      -    "assumptions",
      -    "bound",
      -    "complete",
      -    "contract_version",
      -    "counterexamples",
      -    "elapsed_ms",
      -    "engine",
      -    "evaluated",
      -    "expression",
      -    "finite_evaluations",
      -    "first_counterexample",
      -    "grid_total",
      -    "limits",
      -    "method",
      -    "notes",
      -    "relation",
      -    "statement",
      -    "stop_reason",
      -    "stopped_early",
      -    "tolerance",
      -    "uncertain_evaluations",
      -    "undefined_evaluations",
      -    "verdict",
      -    "work_units",
      -    "provenance"
      -  ],
      -  "type": "object"
      -}New value: +null
  2. Changed13 schema fields changed
    • changedOutput schema / properties / contract_version / const
      Previous value: -"0.1.0"New value: +"0.2.0"
    • addedOutput schema / properties / counterexamples / items / properties / comparison_guard
      Added value: +{
      +  "maximum": 1.7976931348623157e+308,
      +  "minimum": 0,
      +  "type": "number"
      +}
    • changedOutput schema / properties / counterexamples / items / properties / expression_value / maximum
      Previous value: -1e+308New value: +1.7976931348623157e+308
    • changedOutput schema / properties / counterexamples / items / properties / expression_value / minimum
      Previous value: --1e+308New value: +-1.7976931348623157e+308
    • changedOutput schema / properties / counterexamples / items / properties / margin / maximum
      Previous value: -1e+308New value: +1.7976931348623157e+308
    • changedOutput schema / properties / counterexamples / items / required
      Previous value: -[
      -  "expression_value",
      -  "margin",
      -  "values"
      -]New value: +[
      +  "comparison_guard",
      +  "expression_value",
      +  "margin",
      +  "values"
      +]
    • addedOutput schema / properties / finite_evaluations
      Added value: +{
      +  "maximum": 200000,
      +  "minimum": 0,
      +  "type": "integer"
      +}
    • changedOutput schema / properties / first_counterexample / anyOf
      Previous value: -[
      -  {
      -    "additionalProperties": false,
      -    "properties": {
      -      "expression_value": {
      -        "maximum": 1e+308,
      -        "minimum": -1e+308,
      -        "type": "number"
      -      },
      -      "margin": {
      -        "maximum": 1e+308,
      -        "minimum": 0,
      -        "type": "number"
      -      },
      -      "values": {
      -        "items": {
      -          "additionalProperties": false,
      -          "properties": {
      -            "name": {
      -              "maxLength": 32,
      -              "minLength": 1,
      -              "type": "string"
      -            },
      -            "value": {
      -              "maximum": 1000000,
      -              "minimum": -1000000,
      -              "type": "number"
      -            }
      -          },
      -          "required": [
      -            "name",
      -            "value"
      -          ],
      -          "type": "object"
      -        },
      -        "maxItems": 6,
      -        "minItems": 1,
      -        "type": "array"
      -      }
      -    },
      -    "required": [
      -      "expression_value",
      -      "margin",
      -      "values"
      -    ],
      -    "type": "object"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "additionalProperties": false,
      +    "properties": {
      +      "comparison_guard": {
      +        "maximum": 1.7976931348623157e+308,
      +        "minimum": 0,
      +        "type": "number"
      +      },
      +      "expression_value": {
      +        "maximum": 1.7976931348623157e+308,
      +        "minimum": -1.7976931348623157e+308,
      +        "type": "number"
      +      },
      +      "margin": {
      +        "maximum": 1.7976931348623157e+308,
      +        "minimum": 0,
      +        "type": "number"
      +      },
      +      "values": {
      +        "items": {
      +          "additionalProperties": false,
      +          "properties": {
      +            "name": {
      +              "maxLength": 32,
      +              "minLength": 1,
      +              "type": "string"
      +            },
      +            "value": {
      +              "maximum": 1000000,
      +              "minimum": -1000000,
      +              "type": "number"
      +            }
      +          },
      +          "required": [
      +            "name",
      +            "value"
      +          ],
      +          "type": "object"
      +        },
      +        "maxItems": 6,
      +        "minItems": 1,
      +        "type": "array"
      +      }
      +    },
      +    "required": [
      +      "comparison_guard",
      +      "expression_value",
      +      "margin",
      +      "values"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedOutput schema / properties / stop_reason
      Added value: +{
      +  "anyOf": [
      +    {
      +      "const": "grid_complete",
      +      "type": "string"
      +    },
      +    {
      +      "const": "evaluation_budget",
      +      "type": "string"
      +    },
      +    {
      +      "const": "counterexample_limit",
      +      "type": "string"
      +    }
      +  ]
      +}
    • addedOutput schema / properties / uncertain_evaluations
      Added value: +{
      +  "maximum": 200000,
      +  "minimum": 0,
      +  "type": "integer"
      +}
    • addedOutput schema / properties / undefined_evaluations
      Added value: +{
      +  "maximum": 200000,
      +  "minimum": 0,
      +  "type": "integer"
      +}
    • changedOutput schema / properties / verdict / anyOf
      Previous value: -[
      -  {
      -    "const": "counterexamples_found",
      -    "type": "string"
      -  },
      -  {
      -    "const": "no_counterexample_in_scanned_box",
      -    "type": "string"
      -  }
      -]New value: +[
      +  {
      +    "const": "counterexamples_found",
      +    "type": "string"
      +  },
      +  {
      +    "const": "no_counterexample_in_scanned_box",
      +    "type": "string"
      +  },
      +  {
      +    "const": "inconclusive",
      +    "type": "string"
      +  }
      +]
    • changedOutput schema / required
      Previous value: -[
      -  "assumptions",
      -  "bound",
      -  "complete",
      -  "contract_version",
      -  "counterexamples",
      -  "elapsed_ms",
      -  "engine",
      -  "evaluated",
      -  "expression",
      -  "first_counterexample",
      -  "grid_total",
      -  "limits",
      -  "method",
      -  "notes",
      -  "relation",
      -  "statement",
      -  "stopped_early",
      -  "tolerance",
      -  "verdict",
      -  "work_units",
      -  "provenance"
      -]New value: +[
      +  "assumptions",
      +  "bound",
      +  "complete",
      +  "contract_version",
      +  "counterexamples",
      +  "elapsed_ms",
      +  "engine",
      +  "evaluated",
      +  "expression",
      +  "finite_evaluations",
      +  "first_counterexample",
      +  "grid_total",
      +  "limits",
      +  "method",
      +  "notes",
      +  "relation",
      +  "statement",
      +  "stop_reason",
      +  "stopped_early",
      +  "tolerance",
      +  "uncertain_evaluations",
      +  "undefined_evaluations",
      +  "verdict",
      +  "work_units",
      +  "provenance"
      +]
  3. Added

TDQS

A4.1/5.0
Behavior5/5

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

Beyond the annotations, the description discloses key behavioral traits: deterministic float64 arithmetic, a propagated screening guard for near-boundary candidates, possible undefined and uncertain evaluations, exact stop reasons, and the fact that inconclusive results preserve unresolved sampled cells. It also correctly cautions that absence of a witness is not a proof over the continuous box, which is essential for interpreting results.

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?

The description is dense and front-loaded: the core operation is stated first, followed by output classes and important interpretive limits. Every sentence adds substantive meaning, with no filler.

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 complex numerical search tool with no output schema, the description adequately explains the conceptual output classes, stop behavior, and proof limitations. It is less complete on individual parameter semantics, but the central behavior an agent needs in order to interpret results is present.

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

Parameters2/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 parameter meaning. It partially explains the variables grid, claim relation, and numerical scanning, but it does not define the roles of bound, tolerance, expression, max_evaluations, or max_counterexamples. Most parameter semantics are left to infer from names and schema constraints.

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?

The description gives a specific verb and resource: a bounded deterministic float64 scan of a scalar <= or >= claim over a declared 1-6 variable grid. It clearly distinguishes this from a general evaluator by emphasizing counterexample search, numerical witnesses, and a bounded grid.

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?

The description implies when the tool is appropriate by explaining the claim types, variable grid, and proof limitations. It does not explicitly compare against sibling tools or state when to choose an alternative, so usage guidance is present but inferred rather than directive.

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