PRPilot MCP Agent

PRPilot MCP Agent

Analyzes GitHub Pull Requests (PRs) by querying status, CI checks, reviews, comments, and local git state, and provides next-step suggestions in Chinese.

Category
Visit Server

README

PRPilot MCP Agent

PRPilot 是一个面向开源新手的 PR 状态分析助手。用户给出 GitHub PR 链接和可选的本地仓库路径后,Agent 会通过 MCP 工具查询 PR 基本状态、CI / Checks、评论与 Review、本地 Git 状态,并生成中文下一步建议。

安装步骤

建议使用 Python 3.11+:

python -m venv .venv
.venv\Scripts\activate
pip install -r requirements.txt

如果 MCP SDK API 后续变化,优先检查:

python -c "from mcp.server.fastmcp import FastMCP; from mcp import ClientSession, StdioServerParameters; from mcp.client.stdio import stdio_client; print('ok')"

.env 配置

复制 .env.example.env

OPENAI_API_KEY=你的 OpenAI-compatible API Key
OPENAI_BASE_URL=可选,兼容服务地址;为空时使用 OpenAI SDK 默认地址
OPENAI_MODEL=gpt-4o-mini
GITHUB_TOKEN=可选,建议填写以提高 GitHub API 限额

说明:

  • OPENAI_API_KEYOPENAI_BASE_URL 至少应配置一种可用 LLM 连接方式。
  • GITHUB_TOKEN 不配置时,公开仓库通常仍可匿名访问,但更容易限流,部分 Checks 也可能权限不足。

DeepSeek 配置示例:

OPENAI_API_KEY=你的 DeepSeek API Key
OPENAI_BASE_URL=https://api.deepseek.com
OPENAI_MODEL=deepseek-v4-flash
GITHUB_TOKEN=可选

GUI 的 API 配置 弹窗里也有 DeepSeek 预设 按钮,会自动填入 Base URL 和模型名。

如何运行

图形界面:

start_gui.bat

打开窗口后,先点击左侧 API 配置。如果使用 DeepSeek,点击 DeepSeek 预设,填写 API Key 后保存;其他 OpenAI-compatible 服务则手动填写 OPENAI_API_KEYOPENAI_BASE_URLOPENAI_MODEL

GUI 的最终回复区使用 markdown-it-py + tkinterweb 渲染 Markdown,会按 HTML/CSS 显示标题、表格、列表、代码块和引用。

一键启动:

start.bat

一键运行 demo:

start.bat --demo

交互模式:

python agent_client.py

直接传入问题:

python agent_client.py "分析 https://github.com/OWNER/REPO/pull/123,本地仓库路径是 D:\path\repo"

demo 模式:

python agent_client.py --demo

demo 会读取 data/sample_input.txt,但仍然真实调用 MCP 工具,不会伪造结果。

安全限制

  • GitHub API 只做只读 GET 请求。
  • 本地仓库只执行固定白名单 git 命令。
  • subprocess.run 使用 list 参数,shell=False
  • 不会自动 pushmergecommentcheckoutrebaseresetclean

如果本地仓库检查返回 dubious ownership,说明 Git 发现当前运行用户和仓库所有者不一致。确认该目录是你的仓库后,可以在普通终端运行工具提示的命令,例如:

git config --global --add safe.directory D:/Coding/MAAdev/MaaAssistantArknights

inspect_local_repo 允许的命令只有:

git status --short
git status -sb
git branch --show-current
git remote -v
git rev-parse HEAD
git diff --stat
git log --oneline -5

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured