第二章 官方参考服务器:稳如老狗的七件套
本章导读
modelcontextprotocol/servers 是 MCP 的官方参考实现仓库。2026 年的现实是:它已经被裁剪到只剩 7 个服务器。
这件事本身很重要,因为网上大量教程还在让人装 @modelcontextprotocol/server-github 之类——那些第一方服务器已移至 servers-archived 仓库(约 305 star,不再维护)。照着旧教程做,装到的是废弃包。
本章逐个讲这 7 个:它们维护最规范、规格跟进最紧、出问题最少,是任何配置的地基。
七个服务器总览
| 服务器 | 实现 | 包名 | 一句话 |
|---|---|---|---|
| filesystem | npm | @modelcontextprotocol/server-filesystem |
带访问控制的本地文件读写 |
| memory | npm | @modelcontextprotocol/server-memory |
跨会话知识图谱记忆 |
| sequential-thinking | npm | @modelcontextprotocol/server-sequential-thinking |
结构化多步推理 |
| everything | npm | @modelcontextprotocol/server-everything |
练手用的协议全覆盖测试服务器 |
| fetch | Python | mcp-server-fetch |
抓取网页并转成 LLM 可用内容 |
| git | Python | mcp-server-git |
读取、搜索、操作 Git 仓库 |
| time | Python | mcp-server-time |
时间查询与时区转换 |
七个的版本号均为 2026.10.19(npm 侧显示 2.0.0)。
两类安装方式
npm 类装完直接用可执行名:
npm install --global @modelcontextprotocol/server-filesystem
command: mcp-server-filesystem
Python 类推荐 uvx,免预先安装:
command: uvx
args: ["mcp-server-fetch"]
装机建议
| 你的情况 | 必装 |
|---|---|
| 任何编码场景 | filesystem + git + fetch |
| 需要长会话记忆 | memory |
| 复杂任务经常跑偏 | sequential-thinking |
| 跨时区协作 | time |
| 想学 MCP 协议本身 | everything |
其中 filesystem + git + fetch 是官方与社区都反复推荐的“日常骨干”组合,先装这三个不会错。
本章小节
- 2.1 filesystem:带访问控制的文件读写
- 2.2 memory:跨会话知识图谱
- 2.3 git:把仓库交给 agent
- 2.4 fetch:让模型读网页
- 2.5 sequential-thinking:逼模型想清楚
- 2.6 time:把时区算对
