Skip to main content
Glama

Resolve a pinned commit

resolve_commit
Read-onlyIdempotent

Convert a 7-40 character commit prefix into the full 40-digit commit id required by other tools. Use it to pin a commit before querying code.

Instructions

Resolve a commit id or unique prefix (7-40 lowercase hex digits) to the full id of a pinned commit; branch and tag names are not accepted. Other tools require this full 40-digit id.

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": {
      "commit": "<commit>"
    },
    "name": "resolve_commit"
  }
}

Input Schema

NameRequiredDescriptionDefault
commitYesCommit id or unique prefix, 7-40 lowercase hex digits.

Output Schema

NameRequiredDescriptionDefault
dataNo
toolNo
errorNo
notesNo
commitNo
outcomeNo
warningsNo
truncatedNo
next_cursorNo
schema_versionNo
index_generationNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.11.0

TDQS

A3.9/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false and closed-world scope, so the safety profile is covered. The description adds genuine context beyond that: the accepted input alphabet and length, the rejection of branch/tag names, and the downstream dependency on the 40-digit form. It does not say what happens on an ambiguous (non-unique) prefix, which is the main behavioral gap.

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?

Two tight clauses with no filler: the operation and its input constraint come first, followed by the reason the tool exists. Every sentence carries information an agent needs.

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

Completeness5/5

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

For a single-parameter lookup with rich annotations and an output schema, the description supplies everything else needed: input format, rejected input forms, the result shape, and why the conversion matters. Nothing required to call it correctly is missing.

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% and the single parameter's pattern and description already encode the 7-40 lowercase hex digit rule, which the description largely repeats. The added meaning is modest: the prefix must be unique, and branch/tag names are rejected. Baseline 3 is appropriate when the schema carries the parameter documentation.

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 names a specific verb (resolve) and resource (a commit id or unique prefix), states the exact output (the full 40-digit id of a pinned commit), and rules out branch/tag names. It does not name a sibling tool by name, but 'Other tools require this full 40-digit id' establishes its role in the workflow clearly enough that an agent can tell what it is for.

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

Usage Guidelines4/5

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

It gives a clear condition for use: call this when you hold a short id or prefix and need the full id because other tools require it. It also states an explicit exclusion on inputs (branch and tag names are not accepted). There is no explicit when-not-to-use for the tool itself or a named alternative, which keeps it short of a 5.

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