Skip to main content
Glama

prove_closure

Read-onlyIdempotent

Determine which findings a change actually closed by comparing saved before and after scans, and flag when the runs cannot be compared for closure.

Instructions

Say which findings a change actually closed, by comparing two saved scans of one tree.

First it decides whether the two runs can be compared for closure at all: the same instrument commit, version, rules, file types and exclusions, both trees pinned to a commit and clean, both results quoting lines at the same level. The trees themselves may differ -- that difference is what is measured. If the runs cannot be compared, nothing is reported as closed and the repair is named.

Only then does it match every occurrence without its line number: closed (present before, absent from every file the second run read), still open (and how many only moved lines), relocated to another path (renamed or moved, not fixed), changed (gone from a file in which the second run finds the same family again -- not closed), removed (the whole file is gone from the second tree -- not counted as closed), moved into or out of test code, new, and unverifiable (in a file the second run did not read). A file the second run could not open is never counted as fixed.

To keep the verdict as a file that names the two scans it judged, run qrp-mcp closure BEFORE AFTER --out FILE.

Use it after a fix, to evidence the fix. Do not use it to compare coverage figures between two estates -- compare_coverage answers that. It reads two local files and nothing else.

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": {
      "before": "<before>",
      "after": "<after>"
    },
    "name": "prove_closure"
  }
}

Input Schema

NameRequiredDescriptionDefault
afterYesPath to the JSON result of the scan made AFTER the change, same tree, same instrument, same level.
beforeYesPath to the JSON result of the scan made BEFORE the change (`qrp-mcp scan PATH --out FILE`).

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.27.0

TDQS

A4.9/5.0
Behavior5/5

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

Although annotations already declare read-only, idempotent, and non-destructive behavior, the description adds substantial behavioral detail. It explains comparability preconditions, the matching approach, the possible closure categories, and caveats such as not counting unreadable files as fixed.

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 front-loaded with the core purpose, then moves through comparability, outcome categories, CLI usage, and exclusions. Despite its length, each section carries necessary information for a complex comparison tool.

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

Completeness5/5

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

Given the complexity, annotations, and output schema, the description is complete. It covers eligibility checks, categorization semantics, caveats, an alternative tool, and the fact that it only reads local files.

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?

The schema fully documents both parameters, but the description adds useful context: both are local saved scan files, the before/after scans must be comparable, and nothing else is read. The extra meaning is real but does not go far beyond the already rich schema descriptions.

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 states a specific verb and resource: it says which findings a change closed by comparing two saved scans of one tree. It also explicitly distinguishes itself from compare_coverage, which handles coverage comparisons between estates.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It gives explicit timing and intent: use after a fix, to evidence the fix. It also gives an explicit exclusion and names the correct alternative for coverage comparison, leaving little ambiguity.

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