Skip to main content
Glama

compare_branches

Read-only

Render a side-by-side Mermaid sequence diagram comparing two branches of a design, preset, or feature, so you can see exactly how their version histories diverge before merging or cherry-picking.

Instructions

Render a side-by-side comparison of two branches as a Mermaid sequenceDiagram.

Free door, tiered answer — Free: Branch · merge · cherry-pick · undo, on the designs you keep · Pro: Branch · merge · cherry-pick · undo, on every design · Business: ✓ · Enterprise: ✓.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "artifact_id": "<artifact_id>",
      "branch_a": "<branch_a>",
      "branch_b": "<branch_b>"
    },
    "name": "compare_branches"
  }
}

Input Schema

NameRequiredDescriptionDefault
branch_aYesName of the first branch.
branch_bYesName of the second branch.
artifact_idYesThe design / preset / feature id.
artifact_typeNo``"design"`` (default) / ``"preset"`` / ``"feature"``. Default: "design".

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changedv1.5.1
    • addedInput schema / properties / artifact_id / description
      Added value: +"The design / preset / feature id."
    • changedInput schema / properties / artifact_type / description
      Previous value: -"Default: \"design\"."New value: +"``\"design\"`` (default) / ``\"preset\"`` / ``\"feature\"``. Default: \"design\"."
    • addedInput schema / properties / branch_a / description
      Added value: +"Name of the first branch."
    • addedInput schema / properties / branch_b / description
      Added value: +"Name of the second branch."
  2. Addedv1.5.0

TDQS

C2.9/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, destructiveHint=false, and openWorldHint=false, so safety is covered. The description adds genuinely useful context by stating the result is a rendered Mermaid sequenceDiagram, but says nothing about what is actually compared (commits, versions, settings) or any tier gating beyond opaque boilerplate.

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

Conciseness2/5

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

The opening sentence is tight and front-loaded, but the second sentence is marketing boilerplate ('Free door, tiered answer — Free: Branch · merge ... Business: ✓ · Enterprise: ✓') that is unrelated to invoking the tool and adds noise an agent must parse past.

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?

With no output schema, the description usefully discloses the return format as a Mermaid sequenceDiagram. However, for a comparison tool it omits what dimension is compared and how branches are matched, leaving the agent with a partial picture of the operation's semantics.

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 branch_a, branch_b, artifact_id, and artifact_type are all documented in the schema. The description's phrase 'two branches' loosely reinforces branch_a/branch_b but adds no semantics about artifact_type defaults or cross-artifact usage, so baseline 3 applies.

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 first sentence names a specific verb ('Render'), the operation (side-by-side comparison of two branches), and the output format (Mermaid sequenceDiagram). It is clearly distinguishable from siblings like merge_design_branches or visual_diff_meshes, though it never names those alternatives explicitly.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no guidance on when to use this versus compare_design_versions, diff_design_versions, or merge_design_branches. The trailing tier text lists features (branch, merge, cherry-pick, undo) but never states a condition for selecting this tool.

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

Deploy Server

Other Tools