Skip to main content
Glama

Review Gate

review_gate

Gate a change for merge and return a PASS, WARN, or FAIL verdict by running local checks or evaluating an open GitHub PR.

Instructions

Gate a change for merge and return a PASS / WARN / FAIL verdict. Omit pr to run the local, no-GitHub gate against a base ref (changed files, secret safety, risk-sensitive paths, release discipline, validation commands, dependency audit, policy profile). Set pr to gate an open GitHub PR via gh (PR state, review decision, CODEOWNERS approvals, unresolved conversations, branch protection, status checks). A check the mode cannot evaluate is SKIPPED and never changes the verdict. Use review_verdict instead when you want the full impact + review + gate composite, or review_context when you want diff/comment context with no verdict.

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": "review_gate"
  }
}

Input Schema

NameRequiredDescriptionDefault
prNoPR selector (number, URL, or branch). Set, runs the GitHub gate on that PR; omitted or blank, runs the local gate.
baseNoBase ref for the local gate. Defaults to origin/main, then HEAD. Ignored in PR mode.
headNoGate exactly base..head; uncommitted files play no part. Cannot be combined with staged. Ignored in GitHub PR mode.
pathNoRepository path. Defaults to current working directory.
intentNoDeclared intent from change_impact declare (record, JSON, or path): fails the gate when a changed file was never declared.
policyNoPolicy profile: standard, company, or high-risk. Omitted, the repository's .solumberc.json or user config decides, else standard.
stagedNoGate the Git index instead of the working tree. Ignored in GitHub PR mode.
receiptNoConvergence receipt: inputs hash, JSON object, or path. A head- or staged-bound receipt verifies only in that mode.
requestNoOptional change request for context evidence output.
governanceNoGovernance: team or solo. Omitted, the repository's .solumberc.json or user config decides, else team.
minConvergenceNoOptional minimum convergence score (0–100). Enables a failing gate when the task/diff score is below this floor.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changedv4.10.0
    • changedInput schema / properties / head / description
      Previous value: -"Gate exactly base..head: changed-path, risk, secret, and convergence evidence come from the head commit's tree, so uncommitted and untracked files play no part. Release discipline reads version metadata from that same exact tree; validation-command and optional analyzer checks still inspect the working tree. Cannot be combined with staged. Ignored in GitHub PR mode."New value: +"Gate exactly base..head; uncommitted files play no part. Cannot be combined with staged. Ignored in GitHub PR mode."
    • changedInput schema / properties / intent / description
      Previous value: -"Optional declared intent (from change_impact with declare: the record, its JSON, or a path to it). Adds a Scope contract check that fails when a changed file was never declared, implied by a declared file, or named in an amendment."New value: +"Declared intent from change_impact declare (record, JSON, or path): fails the gate when a changed file was never declared."
    • changedInput schema / properties / receipt / description
      Previous value: -"Optional convergence inputs hash, JSON object, or path to a JSON receipt artifact. Exact-subject v2 receipts require the full hash; legacy v1 display IDs remain accepted. A receipt bound to a head commit or the staged index verifies only in the same mode (head / staged); a JSON receipt names the mode it needs when they differ."New value: +"Convergence receipt: inputs hash, JSON object, or path. A head- or staged-bound receipt verifies only in that mode."
    • changedInput schema / properties / staged / description
      Previous value: -"Use the exact Git index for changed-path, risk, secret, and convergence evidence. Release discipline reads version metadata from that same exact tree; validation-command and optional analyzer checks still inspect the working tree. May create Git object or index-cache metadata; source files are unchanged. Ignored in GitHub PR mode."New value: +"Gate the Git index instead of the working tree. Ignored in GitHub PR mode."
  2. Changed3 schema fields changedv4.7.2
    • changedInput schema / properties / head / description
      Previous value: -"Gate exactly base..head: changed-path, risk, secret, and convergence evidence come from the head commit's tree, so uncommitted and untracked files play no part. Release, validation-command, and optional analyzer checks still inspect the working tree. Cannot be combined with staged. Ignored in GitHub PR mode."New value: +"Gate exactly base..head: changed-path, risk, secret, and convergence evidence come from the head commit's tree, so uncommitted and untracked files play no part. Release discipline reads version metadata from that same exact tree; validation-command and optional analyzer checks still inspect the working tree. Cannot be combined with staged. Ignored in GitHub PR mode."
    • addedInput schema / properties / intent
      Added value: +{
      +  "description": "Optional declared intent (from change_impact with declare: the record, its JSON, or a path to it). Adds a Scope contract check that fails when a changed file was never declared, implied by a declared file, or named in an amendment."
      +}
    • changedInput schema / properties / staged / description
      Previous value: -"Use the exact Git index for changed-path, risk, secret, and convergence evidence. Release, validation-command, and optional analyzer checks still inspect the working tree. May create Git object or index-cache metadata; source files are unchanged. Ignored in GitHub PR mode."New value: +"Use the exact Git index for changed-path, risk, secret, and convergence evidence. Release discipline reads version metadata from that same exact tree; validation-command and optional analyzer checks still inspect the working tree. May create Git object or index-cache metadata; source files are unchanged. Ignored in GitHub PR mode."
  3. Changed2 schema fields changedv3.5.1
    • changedInput schema / properties / governance / description
      Previous value: -"Governance: team or solo. Omitted, the repository's .otitorc.json or user config decides, else team."New value: +"Governance: team or solo. Omitted, the repository's .solumberc.json or user config decides, else team."
    • changedInput schema / properties / policy / description
      Previous value: -"Policy profile: standard, company, or high-risk. Omitted, the repository's .otitorc.json or user config decides, else standard."New value: +"Policy profile: standard, company, or high-risk. Omitted, the repository's .solumberc.json or user config decides, else standard."
  4. Changed3 schema fields changedv3.2.0
    • changedInput schema / properties / governance / description
      Previous value: -"Governance: team (default) or solo."New value: +"Governance: team or solo. Omitted, the repository's .otitorc.json or user config decides, else team."
    • changedInput schema / properties / policy / description
      Previous value: -"Policy profile: standard (default), company, or high-risk."New value: +"Policy profile: standard, company, or high-risk. Omitted, the repository's .otitorc.json or user config decides, else standard."
    • changedInput schema / properties / pr / description
      Previous value: -"Optional PR selector (number, URL, or branch). When set, runs the GitHub gate; when absent, runs the local gate."New value: +"PR selector (number, URL, or branch). Set, runs the GitHub gate on that PR; omitted or blank, runs the local gate."
  5. Changed2 schema fields changedv1.15.2
    • addedInput schema / properties / head
      Added value: +{
      +  "description": "Gate exactly base..head: changed-path, risk, secret, and convergence evidence come from the head commit's tree, so uncommitted and untracked files play no part. Release, validation-command, and optional analyzer checks still inspect the working tree. Cannot be combined with staged. Ignored in GitHub PR mode.",
      +  "type": "string"
      +}
    • changedInput schema / properties / receipt / description
      Previous value: -"Optional convergence inputs hash, JSON object, or path to a JSON receipt artifact. Exact-subject v2 receipts require the full hash; legacy v1 display IDs remain accepted."New value: +"Optional convergence inputs hash, JSON object, or path to a JSON receipt artifact. Exact-subject v2 receipts require the full hash; legacy v1 display IDs remain accepted. A receipt bound to a head commit or the staged index verifies only in the same mode (head / staged); a JSON receipt names the mode it needs when they differ."
  6. First observed

TDQS

A4.1/5.0
Behavior3/5

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

The description adds genuine behavioral context the annotation does not: mode-dependent check sets, the 'SKIPPED never changes the verdict' rule, and the implicit `gh` CLI dependency in PR mode. However, annotations declare readOnlyHint=false while the description never discloses any side effects or writes (e.g. whether a convergence receipt is emitted), which is a real gap for a tool flagged as non-read-only.

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 with the verb and verdict, then mode behavior, then alternatives — a logical order with no filler sentences. The long parenthetical enumerations of checks in each mode make it dense, but each item is substantive information an agent cannot get elsewhere.

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?

For an 11-parameter, no-required-parameter tool with no output schema, the description covers verdict values, mode selection, check enumeration, and skip semantics — enough to call it correctly. It falls short only on side effects given readOnlyHint=false, which matters for a non-read-only tool.

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% with all 11 parameters documented, so the schema already carries parameter meaning, making 3 the baseline. The description reinforces the pr-versus-local mode switch and the base-ref scoping, but adds no syntax or format detail beyond what the schema states (e.g. no guidance on valid intent or receipt shapes).

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 opens with a concrete verb and outcome ('Gate a change for merge and return a PASS / WARN / FAIL verdict') and then differentiates two modes by name. It explicitly names the siblings review_verdict and review_context and states how they differ, so an agent can distinguish this tool from all 13 siblings without opening a schema.

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 explicit when-to-use rules for both modes ('Omit pr' vs 'Set pr') and names two alternatives with the exact condition that selects each ('full impact + review + gate composite', 'diff/comment context with no verdict'). Nothing about routing is left to inference.

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