Skip to main content
Glama

pi_diff

Review a worker's actual changes by retrieving a git diff with stat from its worktree directory before merge.

Instructions

git diff (with stat) of a worker's directory so you can review the real changes.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesWorker id from pi_spawn
maxCharsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.0

TDQS

B3.2/5.0
Behavior3/5

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

No annotations are provided, so the description carries the full behavioral burden. It discloses that the tool runs a git diff with stat scoped to a worker directory, implying a read-only review operation, but it omits permissions, side effects, rate limits, and output characteristics.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single front-loaded sentence with no filler. The parenthetical '(with stat)' is slightly dense but earns its place by specifying output content.

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?

There is no output schema and no annotations. The description gives enough to know it is a diff review tool, but it does not explain the return format, the effect of maxChars, or how it fits into the worker workflow, leaving gaps for an agent.

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 50%. The id parameter is already documented in the schema as 'Worker id from pi_spawn,' and the description adds no further meaning. The maxChars parameter is undocumented in both the schema and the description, so the description does not compensate for the coverage gap.

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 states a specific verb and resource: 'git diff (with stat) of a worker's directory.' It clearly distinguishes this from most siblings, though it does not explicitly name an alternative. The intent 'so you can review the real changes' reinforces the purpose.

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 implied by 'so you can review the real changes,' suggesting it is used after a worker has produced changes. However, there is no explicit when-to-use, when-not-to-use, prerequisites, or reference to alternatives such as pi_status or pi_merge.

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