Skip to main content
Glama
pratik73

git-mcp

by pratik73

prepare_merge_request

Gathers diffs, commit logs, changed files, and templates to compile all data needed for composing a pull or merge request title and body.

Instructions

Gather all the data needed to create a Pull Request or Merge Request:

  • Git diff between the current branch and the default branch

  • Commit log

  • List of changed files

  • PR/MR template (if one exists in the repo)

  • Repository metadata (platform, owner, repo)

The returned data is intended for the LLM to use when composing the PR/MR title and body. If a template is found, the LLM should fill it in. Otherwise, the LLM should generate appropriate content based on the diff and commit log.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
cwdYesWorking directory — must be inside a git repository
baseNoBase branch to compare against. Defaults to the repository's default branch (e.g. main).
Behavior3/5

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

Annotations are absent, so the description carries the full burden. It discloses that returned data is intended for LLM use in composing PR/MR content, which is helpful context about the tool's role. However, it doesn't disclose whether the tool performs any side effects (like creating local state, modifying files, or network calls), the format of the returned data, or whether it can fail on certain repo states (e.g., dirty working tree, no commits).

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 well-structured with a bulleted list followed by concise context about intended use. Every sentence earns its place — the purpose list is complete, and the two follow-up sentences clarify the LLM's expected downstream behavior. No fluff or redundancy.

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?

The tool is moderately complex (gathers multiple data types) and has no output schema and no annotations, yet the description clearly explains what data is collected and how the LLM should use it. It could add detail about return format or potential failure modes, but the described purpose is sufficiently complete for an agent to select and invoke it correctly.

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 100%, with both cwd and base well-described in the schema ('must be inside a git repository', 'defaults to the repository's default branch'). The description itself adds limited parameter-level detail beyond this, but the high schema coverage means the baseline 3 applies. The description doesn't add behavioral context about parameter usage beyond the schema.

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 uses a clear verb ('Gather') with a specific resource (data for PR/MR creation) and enumerates exactly what's collected (diff, commit log, changed files, template, repo metadata). It clearly distinguishes itself from siblings like publish_merge_request (creation vs gathering) and list_templates (broader template listing vs repo-specific template retrieval).

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?

The description states it's used before composing a PR/MR title and body, and explains the downstream behavior (fill template vs generate content). It clearly positions itself as a preparatory step for the LLM. However, it doesn't explicitly name alternatives or say when NOT to use it, though sibling differentiation is implicit.

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/pratik73/git-mcp'

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