Connects to GitHub's API to build a searchable index of your repository's PR history, including review comments, descriptions, and discussion threads. The v0.3.0 engine strips out built-in LLM logic and focuses purely on fast retrieval, letting your IDE agent (Cursor, Claude Desktop, Windsurf) handle the reasoning. You get tools like review_code_with_history to pull historical review patterns for code snippets, get_repo_rules_material to generate .cursorrules files grounded in actual team feedback, and semantic_search_reviews for querying past PR comments. Uses SQLite for progress tracking and async I/O with retries to handle large repository indexing. Reach for this when you want your agent to review code or generate features that actually match how your team works, backed by real repository history instead of generic best practices.
This repository provides two ways to leverage your GitHub PR history in your AI workflows. Choose the tool version that matches your architecture.
The Hardened Pure Context Retrieval Engine.
Designed for users who want maximum speed and reliability by offloading reasoning to their IDE agent (Cursor, Claude Desktop, Windsurf). It focuses exclusively on high-performance retrieval and data pruning.
tenacity retries and non-blocking I/O for heavy repository indexing.[!NOTE] v0.3.0 is currently in pre-release and is not yet live on PyPI. To use the hardened v0.3.0 engine today, you must install it from source:
Fork this repository to your own account on GitHub.
Clone and Checkout the release branch:
git clone https://github.com/YOUR_USERNAME/github-pr-context-mcp.git cd github-pr-context-mcp git checkout v0.3.0-hardeningInstall via pipx (the whole command):
pipx install -e .This links the
github-pr-context-mcpcommand to your local repository folder.Verify Version:
github-pr-context-mcp --help
The Integrated Reasoning Agent.
Designed for users who prefer the server to handle LLM inference internally. This version includes the legacy inference layer and supports direct configuration of OpenAI and Anthropic API keys.
inference/ module for direct model interactions.pipx install github-pr-context-mcp==0.2.9
The v0.3.0 version only requires a GitHub Token.
Environment Variable:
GITHUB_TOKEN=ghp_your_token_here
GitHub PR Review Context MCP gives AI assistants institutional review memory.
It fetches your repository's PR history (descriptions, review threads, comments), transforms them into searchable documents, and provides high-density Context Materials to your IDE agent.
| Capability | What It Delivers |
|---|---|
| Historical Retrieval | Semantic search across prior PR comments and review summaries. |
| Code Review Material | Raw JSON context for the agent to perform grounded code reviews. |
| Rules Material | High-density data for the agent to synthesize .cursorrules or CLAUDE.md. |
| Grounded Generation | Context materials for generating code that matches team style. |
| Namespace Isolation | Strict isolation between users/teams using Gmail-based identity. |
# Run instantly
uvx github-pr-engine
# OR Install permanently
pipx install github-pr-engine
The only required configuration is your GitHub token.
Environment Variable:
GITHUB_TOKEN=ghp_your_token_here
The server provides tools that return raw JSON context objects. The IDE agent then uses its own intelligence to process this data.
| Tool | Action | typical Use Case |
|---|---|---|
ensure_repo_ready | Index a repo and ensure it's ready. | Onboarding a new repository. |
review_code_with_history | Get historical review material for a snippet. | "Review this code based on team history." |
get_repo_rules_material | Get material to write .cursorrules. | "Write a rules file for this repo." |
get_team_review_patterns | Get raw patterns for summarization. | "What are the common review themes?" |
generate_code_from_history | Get context for grounded generation. | "Write this feature in our team's style." |
semantic_search_reviews | Search past PR comments by meaning. | Manual history lookup. |
list_indexed_repos | View all currently indexed repositories. | Storage management. |
MIT
ray0907/git-mcp-server
cyanheads/git-mcp-server
io.github.b1ff/atlassian-dc-mcp-bitbucket
io.github.b1ff/atlassian-dc-mcp-jira
com.mcparmory/atlassian-jira
sirlordt/vscode-terminal-mcp