@craftpipe/git-lens-mcp
v1.0.0
Published
Git history intelligence for AI coding agents — analyze commit patterns, detect code hotspots, trace file blame, measure velocity, and surface contributor insights. Built with AI by Craftpipe
Readme
git-lens-mcp
git-lens-mcp is a Model Context Protocol (MCP) server that brings deep Git history intelligence to AI coding agents — it lets agents analyze commit patterns, detect code hotspots, trace file blame line-by-line, measure development velocity over time, surface contributor insights, summarize diffs between refs, and identify bug-introducing commits, all through a structured tool interface that any MCP-compatible client (such as Claude Desktop) can call without ever touching raw git output.
Prerequisites
- Node.js >= 18
- git installed and available on your
PATH
Installation
npm install && npm run buildMCP Configuration
Add the following to your claude_desktop_config.json (or equivalent MCP client configuration file):
{
"mcpServers": {
"git-lens-mcp": {
"command": "node",
"args": ["/absolute/path/to/git-lens-mcp/dist/index.js"]
}
}
}Replace /absolute/path/to/git-lens-mcp with the actual path where you cloned/installed this package.
Tools
| Tool | Description |
|------|-------------|
| get_file_blame | Traces git blame for a file, showing which commit and author last modified each line or a range of lines. |
| get_hotspots | Identifies files changed most frequently within a time window to surface instability and technical debt. |
| get_commit_history | Retrieves a filtered, paginated commit log scoped by file, author, date range, or keyword. |
| get_contributor_insights | Analyzes contributor activity (commits, lines added/removed, active days) across the repo or a path. |
| measure_velocity | Computes commit frequency, active contributor count, and churn rate across configurable time buckets. |
| diff_summary | Generates a structured summary of the diff between two commits, branches, or tags with per-file statistics. |
| find_bug_introducing_commit | Uses git log and heuristics to identify commits most likely to have introduced a bug or regression. |
