原型 · 预览版:收录官方注册中心里的全部服务器,每 30 分钟同步一次。评价和账户功能将在后续阶段推出。
PopNx MCP为使用 AI 的人准备的 MCP 服务器 · 用大白话讲清楚

GitHub (read-only)

作者:AbdulMuhaiminKhan版本 1.2.0i★ –i在你的电脑上运行
注册名称io.github.AbdulMuhaiminKhan/github-mcp

安装

概览

作者提供的说明(英文原文)

Read-only GitHub repos, issues, PRs and commits, with tool descriptions tuned on a benchmark.

PopNx MCP 的三大支柱

这三项永远不会合并成一个分数:意见、测量和人气是不同的东西。

它能帮你做什么

我们还没有为它写通俗的介绍。下面是我们从注册中心读取到的事实。

  • 连接方式: 在你的电脑上运行
  • 传输方式: stdio
  • 分类: 开发者工具
  • 你需要填写:GITHUB_TOKEN

安装

选择你使用的 AI 应用,然后复制设置。

安装之前

  • 基础检查:1 项中通过 1 项
  • 在你的电脑上运行,拥有你的用户账户的权限(文件、网络、应用)。
  • 需要你自己填写: GITHUB_TOKEN, GITHUB_MCP_TOOLSET

标为机密的值是你账户的钥匙。千万不要分享给别人,也不要粘贴到聊天里。

你需要

  • PyPI已安装 Python 的 uv(用于 uvx 命令)

你用的是哪个应用?

在上方选择你的应用。我们会记住它,下次按钮会显示“安装到 …”。

打开 Claude Desktop → Settings → Developer → Edit Config,把下面的内容粘贴到 claude_desktop_config.json

{
  "mcpServers": {
    "github": {
      "command": "uvx",
      "args": [
        "github-mcp-readonly"
      ],
      "env": {
        "GITHUB_TOKEN": "your-value",
        "GITHUB_MCP_TOOLSET": "your-value"
      }
    }
  }
}

在终端中运行这条命令

claude mcp add github --env GITHUB_TOKEN=your-value --env GITHUB_MCP_TOOLSET=your-value -- uvx github-mcp-readonly

运行前请先填写空着的值。

在 Cursor 中打开

或者自己复制设置

粘贴到项目中的 .cursor/mcp.json,或 ~/.cursor/mcp.json

{
  "mcpServers": {
    "github": {
      "command": "uvx",
      "args": [
        "github-mcp-readonly"
      ],
      "env": {
        "GITHUB_TOKEN": "your-value",
        "GITHUB_MCP_TOOLSET": "your-value"
      }
    }
  }
}

浏览器会先询问是否打开应用,然后应用会显示设置并请你确认。密钥的值会留空,由你自己填写。

在 VS Code 中打开

或者自己复制设置

粘贴到项目中的 .vscode/mcp.json

{
  "servers": {
    "github": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "github-mcp-readonly"
      ],
      "env": {
        "GITHUB_TOKEN": "your-value",
        "GITHUB_MCP_TOOLSET": "your-value"
      }
    }
  }
}

浏览器会先询问是否打开应用,然后应用会显示设置并请你确认。密钥的值会留空,由你自己填写。

这个服务器在你的电脑上运行,而 ChatGPT 只能连接互联网上的服务器。请选择其他应用。

你的选择通过 Cookie 保存在这台设备上,无需账户。

需要你填写的值

  • GITHUB_TOKEN 机密 必填 env
    Fine-grained GitHub token with read-only access (Metadata, Contents, Issues, Pull requests).
  • GITHUB_MCP_TOOLSET env
    Tool descriptions to serve: v2 (default, optimized), v1 or v1b (benchmark baselines).

这些设置是根据作者在注册中心的条目生成的。如果 README 的写法不同,请以 README 为准。

它能做什么

它在你的电脑上运行;安装后,工具列表会显示在你的 AI 应用中。

基础检查i

我们检查的是任何人都能看到的信息;我们没有阅读代码。不适用的检查项不计入总数。 · 检查于 2026年11月6日

  • ✓ 通过

    作者与仓库一致

    注册名称已通过 GitHub 账户 AbdulMuhaiminKhan 验证,该账户拥有此仓库

  • … 尚未检查

    仍在维护

    我们还没有从 GitHub 读取这个仓库

  • … 尚未检查

    有许可证

    我们还没有从 GitHub 读取这个仓库

  • – 不适用

    端点有响应

    它在你的电脑上运行,没有互联网端点

  • – 不适用

    使用 OAuth 登录

    在你的电脑上运行,改用本地设置

  • … 尚未检查

    工具描述中没有隐藏指令

    它在你的电脑上运行;我们只能读取互联网端点的工具列表

与“开发者工具”中的其他服务器比较i

  • 星标数多于此分类中其他 1385 个服务器的 0%
  • 发布到注册中心的时间比此分类中其他 1385 个服务器的 63% 更新
  • 基础检查结果等于或优于此分类中其他 1385 个服务器的 100%

与注册中心里这个分类中所有活跃的服务器比较。只有当发布者拥有该仓库时,星标数才计入。

常见问题

GitHub (read-only) 安全吗?

它在 1 项适用的基础检查中通过了 1 项。我们没有阅读代码。在添加密钥或令牌之前,请先看看这个服务器要求哪些权限,并使用只具备所需权限的密钥。

它需要哪些密钥或代码?

你需要填写:GITHUB_TOKEN

它在我的电脑上运行还是在云端?

它在你的电脑上运行。你的 AI 应用会在需要时启动它,数据不会经过作者的服务器(除非它自己调用在线服务)。

它还在维护吗?

GitHub 仓库最后更新于–,最新版本(1.2.0)于29天前进入注册中心。

哪些应用可以使用它?

支持 MCP 的应用,例如 Claude Desktop、Claude Code、Cursor 和 VS Code。你的电脑上还需要有 Python (uv)。

有什么可以替代它?

同一分类中有:GitHub, Desktop Commander, Cloudflare MCP

替代选择

同一分类中其他作者的服务器,按星标数排序。

如何看卡片:★ GitHub 星标i三大支柱:评价 · 检查 · 使用情况i更新 = 最新版本发布到注册中心的时间i

GitHub

作者:github

Connect AI assistants to GitHub - manage repos, issues, PRs, and workflows through natural language.

电脑或云端★ 34,245MIT3天前更新
安装

Desktop Commander

作者:wonderwhy-er

MCP server for terminal commands, file operations, and process management

在你的电脑上运行★ 10,225MIT15天前更新
安装

Cloudflare MCP

作者:cloudflare

Cloudflare MCP servers

在云端运行★ 4,446Apache-2.014个月前更新
安装

作者的 README

打开 README

按原文从作者的仓库复制。PopNx MCP 没有审查或背书其内容。HTML、图片和脚本已被移除。链接会离开本站。

GitHub MCP Server: Teaching an AI to Pick the Right Tool

A read-only Model Context Protocol server that lets Claude (or any MCP client) answer questions about my GitHub repos, issues, pull requests and commits. It comes with a benchmark that measures how often the model picks the right tool with the right arguments.

Rewriting the tool descriptions took a local 7B model from 63% to 95% correct, and from 60% to 90% on held-out questions it was never tuned on. An ablation shows where those 32 points came from, and most of them were not the prose:

ChangePointsWhat it was
Accept bare repo names (mcp-bench-app, not only owner/mcp-bench-app)+17input handling in the server
Write the range (1-50) into the limit parameter's description+8one parameter sentence
Rewrite the tool descriptions (when to use, when NOT to, and the alternative)+7the tool wording

Every miss left in v2 is the model asking for something the API doesn't offer: merged PRs, sorting by stars, or closed issues from the open-issues tool. Better wording can't fix those. The next step is to support them in the schema.

[Explore every question in the results dashboard →](https://abdulmuhaiminkhan.github.io/github-mcp/)

What I built

  • MCP server (Python, `mcp` SDK 2.x) with 6 read-only tools over stdio: list_repositories, get_repository, list_open_issues, search_issues, list_pull_requests, get_recent_commits.
  • Least-privilege access: a fine-grained, read-only GitHub token and readOnlyHint annotations. The token stays in the server process and never reaches the model.
  • Production behaviour: schema-validated inputs, retries with backoff and jitter, primary and secondary rate-limit handling, ETag caching (304s don't count against the rate limit), exact totals for list tools, and error messages that tell the model how to recover.
  • A benchmark with known answers: a seed script creates two repos with 15 issues, 5 pull requests and commits from two authors. A fake GitHub API serves the same data offline, so the benchmark also runs in CI with no token.
  • Three evaluations: tool selection with argument grading (60 questions), a held-out set (20), and multi-step agent runs whose final answers are checked against the seeded facts (13).
  • An ablation (v1 → v1b → v2) that separates input handling from description wording.
  • An automatic description optimizer that rewrites descriptions from failures and keeps a change only if held-out accuracy doesn't drop.
  • A harness that benchmarks any MCP server, not just this one (examples/).
  • A results dashboard (docs/) with every question, call and error from the runs.
  • Tests and CI on Python 3.10–3.13 (ruff, mypy, pytest, and an oracle check that the harness scores 100% when the right call is made).

Architecture

flowchart LR

U[User] -->|question| C["Claude Desktop (MCP client)"] C <-->|"JSON-RPC over stdio tools/list · tools/call"| S["github-mcp Python MCP server"] S -->|"HTTPS · read-only token ETags · retries"| G[(GitHub REST API)] E["eval/run_eval.py"] -.->|"same MCP protocol"| S E -.->|"question + tool schemas"| L["LLM under test (Ollama or Claude)"] S -.->|"GITHUB_API_URL (CI)"| F[("fake GitHub seeded repos")]

LayerResponsibility
server.pyRegisters tools, validates arguments, returns compact JSON with exact totals
descriptions.pyVersioned descriptions (v1 baseline, v1b ablation, v2 optimized, or a JSON file)
github_client.pyAuth, pagination, retries, rate limits, ETag cache, typed errors
eval/Benchmark runner, argument grader, seed script, fake GitHub, optimizer, chart, dashboard export

Evaluation

Method. Each question goes to the model with the server's own tool list, exactly what Claude Desktop sends. The harness executes the chosen call through MCP and grades it:

  • ✅ Correct: expected tool, call succeeded, arguments match (e.g. "last 3 days" → since_days=3)
  • 🟡 Wrong Arguments: right tool, call succeeded, but an argument is wrong or missing
  • ⚠️ Wrong Tool: a different tool, or no tool
  • ❌ Tool Failed: right tool, but the call returned an error

There are 60 questions (10 per tool, a third of them in deliberate overlap zones between tools), plus 20 held-out questions written after v2 was frozen and never used for tuning. The data is the seeded benchmark repos on real GitHub, and the model runs locally with Ollama at temperature 0, 3 runs per configuration, medians reported. The three runs differed by at most 2 points on the main set and 5 on held-out.

Configuration (qwen2.5:7b)CorrectWrong ArgumentsWrong ToolTool FailedInput tokens
v1: vague descriptions63%0%8%28%614
v1b: v1 + bare repo names80%0%8%12%614
v2: rewritten descriptions95%0%2%3%1533
v1 on held-out questions60%5%15%20%613
v2 on held-out questions90%0%5%5%1532

The offline run against the fake GitHub gave the same picture (65% / 82% / 95%).

A second model, llama3.1:8b, same questions and settings:

Configuration (llama3.1:8b)CorrectWrong ArgumentsWrong ToolTool FailedInput tokens
v1: vague descriptions32%7%12%50%643
v1b: v1 + bare repo names47%7%12%35%643
v2: rewritten descriptions92%5%2%2%1559
v2 on held-out questions95%0%0%5%1558

Llama picked the right tool 88% of the time even on v1. It failed on arguments: it asked for limit=100 on tools capped at 50 again and again, and passed owner/repo where a bare name was expected. The fixes that helped qwen (bare names, the stated limit range) helped llama even more, so the lesson carries across models: spell out argument constraints, not just what the tool does.

Agent mode (13 multi-step questions, answers checked against the seeded data): v1 62%, v2 69%. With 13 questions one answer is 8 points, so that difference is within noise (offline it went the other way).

Cost of better descriptions: v2 adds about 920 input tokens to every request (614 → 1533).

Raw results, one JSON row per question per run: eval/results/.

Benchmark your own MCP server

The harness isn't tied to this server. Give it the command that starts any stdio MCP server and a JSONL file of questions:

python eval/run_eval.py --server "npx -y @modelcontextprotocol/server-filesystem ." \

--questions my_questions.jsonl --domain "the user's files" --backend ollama --runs 3

examples/ has a small notes server with 10 questions and the question format.

Decision File

1. Why the model picked the wrong tool

Every wrong-tool pick from the v1b run (3 of 3 runs each), and what v2 did about it:

QuestionExpected → chosenRoot causeAfter v2
"What's the exact name of my portfolio website repo?"list_repositories → get_repositoryv1's "Gets info about a repo" invited guessing a name (portfolio-website) instead of listingfixed
"Which repos haven't I pushed to in a long time?"list_repositories → get_recent_commits"Gets recent activity for a repo" sounded like the answer; nothing said repos can be sorted by last pushfixed
"What topics are tagged on mcp-bench-app?"get_repository → search_issues"Searches GitHub" read as a catch-all for anything about a repofixed
"What's the newest issue someone opened on mcp-bench-app?"list_open_issues → search_issuesThe model reached for search and invented query syntax (created:desc)fixed
"Which issues have been closed in mcp-bench-app?"search_issues → list_open_issuesThe model passed state: "closed" to the open-issues tool, trusting its own argument over the tool's namestill wrong, also on held-out
2. What the ablation showed

With an oracle that always picks the right tool, v1 scores 83%: all 10 bare-name questions fail because v1 requires owner/name. So part of any v1 → v2 gain was always going to be input handling. v1b (v1 text + bare names) separates the two:

  • v1 → v1b: +17 points. All 10 bare-name questions went from ❌ to ✅. The wording didn't change at all.
  • v1b → v2: +15 points, from 9 questions:
  • 5 were one parameter sentence. v1's limit said "How many." The model asked for 100, the schema allows 50, and the call failed. v2 says "(1-50)" and those 5 questions pass.
  • 4 were the tool wording: the first four rows of the table above.

The model rarely picked the wrong tool even with vague descriptions (92% right tool on v1). Most of the failures came from calls the server rejected.

3. What I changed
  1. Each description states what it returns, when to use it, and when NOT to use it, naming the alternative, e.g. list_open_issues: *"Do NOT use for closed issues, keyword search, or issues across all repos (use search_issues), or for pull requests (use list_pull_requests)."*
  2. Boundaries are mutually exclusive along one axis each: open vs closed, one repo vs all repos, keyword vs none, metadata vs history, issues vs PRs.
  3. Every parameter documents its format and range with an example. This turned out to matter more than the tool text.
  4. Behaviour fixes, reported separately: bare repo names resolve to the user's repo, and list tools return exact totals instead of a page-sized count.
  5. Error messages carry a next step ("Call list_repositories to check the exact name").
4. The automatic optimizer overfit, and the guard caught it

eval/optimize.py shows a model its training failures, asks it to rewrite the descriptions, and keeps a candidate only if training accuracy rises and held-out accuracy doesn't drop. Starting from v1, with qwen2.5:7b rewriting its own tools (offline data, 4 iterations):

IterationTrain (60)Held-out (20)Kept
0 (v1)65%60%baseline
170%55%no
267%50%no
372%40%no
472%40%no

Every rewrite raised training accuracy and lowered held-out accuracy, so the guard rejected all of them. The 7B model wrote descriptions that fit the questions it had just seen, not the tools. Without the held-out check, iteration 3 would have looked like a 7-point win. The hand-written v2 is what generalized.

5. What's left, and trade-offs
  • The 3 remaining v2 misses all ask for something the API doesn't have: state: "merged" for pull requests, sort: "stars" for repos, and state: "closed" on the open-issues tool. I didn't reword around them, because that would tune to these exact questions. The right fix is in the schema: accept merged (filter on merged_at), sort by stars client-side, and let the issues tool take a state.
  • Longer descriptions cost about 920 tokens per request. That's worth it at 6 tools. With dozens of tools I'd move to tool search and deferred loading.
  • Agent mode needs more questions before its numbers mean anything (13 is too few).
  • Pagination stops at 500 items per lis

只显示了开头部分;其余内容请在仓库中阅读

问 PopNx