Skip to main content
Glama

Review Context

review_context

Generate pull request review context from local git diff metadata, optionally adding GitHub PR comments to enrich the raw change context for reviewers.

Instructions

Produce PR review context from local git diff metadata, optionally enriched with GitHub PR comments. Use review_context when you want the raw diff/comment context for a change, not a verdict. Use review_verdict instead for the full impact + review + gate composite, or review_gate for the gate verdict alone.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
baseNoBase ref. Defaults to PR base, upstream, origin/main, or main.
headNoHead ref. Defaults to HEAD.
pathNoRepository path. Defaults to current working directory.
githubNoAsk gh to infer the current branch PR.
numberNoOptional GitHub PR number for gh enrichment.
commentNoCreate or update a sticky GitHub PR comment using gh. This writes to GitHub.
includeMarkdownNoReturn a compact human-readable markdown report instead of the full JSON. Defaults to false.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.2/5.0
Behavior3/5

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

Annotation readOnlyHint=false already signals possible mutationais, and the description does not contradict that. However, the description does not disclose that setting comment=true creates or updates a GitHub comment; that critical side effect is only visible in the schema's parameter description. The description adds scope context but misses the write path.

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?

Three tightly packed sentences with zero filler. The core purpose and scope come first, then explicit routing to alternatives. Every sentence 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?

The tool has seven parameters and no output schema, but the high-coverage schema plus this description cover the main invocation needs. It could add a note about GitHub auth/network requirements for the gh enrichment, but nothing essential is missing for basic tool selection and use.

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 parameters are already fully documented. The description adds the high-level concept of 'raw diff/comment context' but does not enrich individual parameter meanings beyond the schema, which matches the baseline for full schema coverage.

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 'Produce PR review context from local git diff metadata, optionally enriched with GitHub PR comments,' which names a specific verb, resource, and optional data source. It explicitly differentiates from siblings by saying this is raw diff/comment context, not a verdict, and names review_verdict and review_gate as the alternatives.

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 direct when-to-use guidance: 'Use review_context when you want the raw diff/comment context for a change, not a verdict.' It also names the exact sibling tools for alternative scenarios, leaving little room for an agent to select the wrong tool.

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