Skip to main content
Glama

search_commits

Search Git commit messages and code changes by keyword to find when features were added, bugs fixed, or dependencies changed, with linked pull requests and issues.

Instructions

Search commits by keyword across commit messages (and optionally code changes). Returns matching commits annotated with their pull requests and linked issues. Useful for finding when a feature was added, a bug was fixed, or a dependency was changed.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYesKeyword or phrase to search for (case-insensitive)
repo_pathNoWorking directory / repo root (defaults to cwd)
limitNoMax number of results to return (default 20)
search_codeNoAlso search the actual code changes (git pickaxe / -S), not just commit messages (default false)
Behavior3/5

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

No annotations are provided, so the description carries the full burden. It discloses key behavioral traits like case-insensitive search, optional code change searching, and that results include annotations with pull requests and linked issues. However, it lacks details on permissions, rate limits, or error handling, which are important for a search tool with no structured annotations.

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 appropriately sized and front-loaded, with two concise sentences that directly state the tool's function and utility. Every sentence earns its place by clarifying search scope and use cases without unnecessary elaboration or repetition.

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?

Given the tool's moderate complexity (4 parameters, no output schema, no annotations), the description is somewhat complete but has gaps. It explains the search functionality and use cases but does not cover return values, pagination, or error scenarios, which are important for an agent to invoke the tool correctly without structured output information.

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%, so the schema already documents all parameters thoroughly. The description adds minimal value beyond the schema, mentioning 'keyword' and 'optionally code changes' which align with the schema's 'query' and 'search_code' parameters, but does not provide additional syntax or format details, meeting the baseline for high schema coverage.

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 clearly states the tool's purpose with specific verbs ('search commits by keyword') and resources ('commit messages', 'code changes'), distinguishing it from siblings like 'blame_context' or 'file_history' by focusing on keyword-based search across commits rather than line-level attribution or file-specific history.

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 provides clear context for when to use this tool ('useful for finding when a feature was added, a bug was fixed, or a dependency was changed'), but it does not explicitly mention when not to use it or name specific alternatives among the sibling tools, such as 'file_history' for tracking file changes over time.

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/muhannad-hash/git-context-mcp'

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