Skip to main content
Glama

briefcheck_annotate_diff

Annotates unified diffs from raw text, local git changes, or GitHub PRs with explicit base and new line numbers so citations stay accurate.

Instructions

Render a unified diff (or local git diff / staged changes / GitHub PR) with explicit base | new line numbers for every hunk line so citations never drift.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "briefcheck_annotate_diff"
  }
}

Input Schema

NameRequiredDescriptionDefault
prNoGitHub PR reference (`owner/repo#123` or full PR URL).
diffNoRaw unified diff text.
stagedNoWhen true, read staged git changes (`git diff --cached`).
git_baseNoLocal git base ref (e.g. `origin/main`) to diff against `git_head`.
git_headNoLocal git head ref when using `git_base` (defaults to `HEAD`).
repo_dirNoOptional local repository path for `git_base` or `staged`.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.3/5.0
Behavior2/5

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

With no annotations, the description must carry the full behavioral burden. It discloses accepted input sources and the annotated line-number output, but does not state that the operation is read-only, whether GitHub access requires auth, how local git commands are executed, or how errors are handled.

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 a single front-loaded sentence with no wasted wording. It states the operation, input modes, output annotation convention, and rationale efficiently.

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 description covers the core purpose and output intent for a six-parameter tool whose parameters are fully documented in the schema. However, with no annotations and no output schema, it leaves meaningful gaps around mode selection, read-only behavior, authentication for GitHub PRs, and return details.

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 100%, so the parameter meanings are already documented in the schema. The description adds only loose mapping between input modes and parameters, without additional syntax, precedence rules, or mutual-exclusion guidance beyond the schema.

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 ('Render') and resource ('unified diff') and adds the distinctive output trait of explicit `base | new` line numbers. It does not explicitly differentiate itself from sibling tools such as `briefcheck_check_citations`, so it falls short of a 5 on sibling distinction.

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 parenthetical lists supported input modes (raw diff, local git diff, staged changes, GitHub PR), which implies when the tool is applicable. However, it does not state when to choose this tool over alternatives or how to select among the listed modes.

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