Skip to main content
Glama

triage_pr

Read-onlyIdempotent

Screen pull requests against repository policies to detect rule violations and get a verdict, preflight checks, and recommended actions before submission.

Instructions

Policy-aware PR screening.

Reads docs/policies/-.md and checks the PR against hard/soft rules.

返回: verdict: pass / needs_preflight / warn / reject policy_loaded: bool violations: list of {rule, severity, evidence} generic_checks: list (only when needs_preflight) recommended_action: str (always)

Example: triage_pr("docs: typo", "Ikalus1988/MisakaNet", "fix typo", "docs/faq.md | 3 ++-") → {verdict: "pass", policy_loaded: true, ...}

triage_pr("docs: add installation", "pallets/flask", ...)
→ {verdict: "needs_preflight", generic_checks: [...6 items...], ...}

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bodyNo
repoYes
titleYes
labelsNo
diff_statNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv2.1.4
  2. Removedv1.3.1
  3. First observedv0.1.0

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint, and destructiveHint=false, so the safety profile is covered. Beyond that, the description adds genuine behavioral context: it reads a per-org/repo policy file, applies hard/soft rules, and enumerates the return fields including verdict levels and recommended_action. Undisclosed are edge cases like what happens when the policy file is missing (only hinted at by policy_loaded) — hence not a 5.

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?

Front-loaded purpose, then a compact return-value block, then two short examples — efficient and scannable with minimal waste. The examples repeat fields the return block already listed, but structurally the layout is sound and appropriately sized for the tool's complexity.

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?

With no output schema, the description usefully documents the return shape (verdict, policy_loaded, violations, generic_checks, recommended_action), which is exactly the burden it should carry. Combined with annotations covering the safety profile, it is largely complete; only auth requirements and the behavior when no policy file exists remain unstated.

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 0%, so the schema carries no parameter documentation at all. The example call implicitly maps four of the five parameters (title, repo, body, diff_stat) via positional values, but 'labels' is never mentioned and no parameter's format or constraints are described. Partial compensation for a real 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?

States a specific verb and resource — 'Policy-aware PR screening' — and elaborates that it reads docs/policies/<org>-<repo>.md and checks the PR against hard/soft rules, which is concrete enough to distinguish it from a generic analyzer. It does not, however, contrast itself against close siblings like analyze_pr or coach_pr, so the differentiation is only implied.

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 conveyed only through two worked examples rather than explicit when-to-use/when-not guidance. Given siblings such as analyze_pr, coach_pr, and review_queue that plausibly overlap in PR-evaluation territory, the description leaves the agent to infer when triage_pr is the right choice. This is implied-usage territory, not explicit routing.

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