Skip to main content
Glama

peer_review_diff

Route a full code diff with source files and a task description to specialized peer models for targeted review based on focus area and risk level.

Instructions

Before calling: read relevant source files and attach full contents via files. Pass complete diffs/logs — never prose summaries. Set task with goals, affected behavior, and specific concerns. Route a diff review to the best peer model(s) based on focus and risk.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
diffYesRequired. Full unified diff (`git diff`, `git diff --cached`, or patch file). Do not summarize.
repo_pathYesAbsolute path to the repository root the peer should work in (e.g. /home/user/my-app).
focusNoPrimary review lens. Pair with a detailed diff, related files, and a rich `task` describing risks.
risk_levelNoUse high for auth, payments, migrations, concurrency, and public API changes.
filesNoChanged source files and binary attachments (screenshots, PDFs). Use correct file extensions for images/PDFs and pass base64 or data-URI content.
taskNoHuman-readable session label: what you are trying to achieve, affected behavior, and specific concerns for the peer.
needs_speedNoPrefer a faster peer when true; still include full context.
idempotency_keyYesStable key for this operation (e.g. review-auth-jwt-1). Reuse the same key when retrying after timeout.
Behavior2/5

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

With no annotations, the description must disclose behavior but only mentions 'route to best peer model' without explaining routing logic, side effects, output format, or idempotency implications. The idempotency_key parameter suggests retry safety, but the description is silent on this.

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 three sentences with zero wasted words. It front-loads the most critical instruction ('Before calling: read...') and provides crisp, actionable guidance.

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

Completeness2/5

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

Given 8 parameters (3 required) and no output schema, the description covers only diff, files, and task. It omits context for repo_path, focus, risk_level, needs_speed, and idempotency_key, leaving the agent to rely solely on schema descriptions.

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 coverage is 100%, so baseline is 3. The description reinforces 'files' and 'task' usage (e.g., full contents, specific concerns) but adds no new meaning beyond the schema. It does not elaborate on repo_path, focus, risk_level, or other parameters.

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 clearly states the tool routes a diff review to peer models based on focus and risk. However, it does not differentiate from sibling tools like peer_debate or peer_compare, leaving ambiguity about when each is appropriate.

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 provides explicit prerequisites (read files, attach full contents, pass diffs, set task) and a 'never prose summaries' rule. It gives clear context for use but lacks exclusion criteria or comparison to the extensive list of peer sibling tools.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Rakeen70210/peer-agents-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server