RFC lookup

io.github.shbernal由 GitHub 帳號 shbernal 發布v0.6.1更新於 Oct 30, 2026

40x fewer tokens while reading the RFC corpus and flag obsoleted specs.

概覽

AI 產生的概覽

讓助理檢索 IETF RFC、列出某份 RFC 的章節並逐節閱讀,同時提示已被取代的規範。

可以做什麼
  • 依標題檢索 RFC;在具備章節索引或本機鏡像時可做全文檢索
  • 列出某份 RFC 的編號標題、行號及各節長度
  • 依章節編號或標題文字讀取單一節,或讀取指定行範圍,未指定章節的大範圍讀取會被限制
  • 每次回應附帶狀態橫幅,規範被新 RFC 取代時提出警告
適用情境
當你想讓助理回答網際網路標準、協定或 HTTP 細節問題,並希望答案根據 RFC 原文而非模型記憶時適用,特別適合 Claude Desktop 這類無法自行執行指令的用戶端。
執行需求
以 stdio 方式在本機執行,透過 uvx 啟動 PyPI 套件 mcp-server-rfc,需要 Python 與 uv。標題檢索與章節閱讀無需額外設定;全文檢索需另外用 sync 指令下載章節索引或鏡像,約 270 MB 或 512 MB。可選環境變數 RFC_MIRROR、RFC_CLI、RFC_TRANSPORT、HOST、PORT 用於調整路徑與傳輸方式。
安裝前請注意
伺服器本身沒有身分驗證;若以 HTTP 方式對外託管,必須自行在前面加上驗證,否則會成為通往志工維護鏡像的開放代理。沒有索引時全文檢索會退回從 RFC Editor 抓取。下載索引或鏡像會在磁碟上佔用數百 MB,這一步刻意交由使用者而非模型決定。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 RFC lookup,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

mcp-server-rfc

An MCP server that reads the RFC corpus with 40x fewer tokens and flags obsoleted specs.

json
{  "mcpServers": {    "rfc": {      "command": "uvx",      "args": ["mcp-server-rfc"]    }  }}

No clone, no virtualenv, no path. That is the whole installation. Your client spawns the server on your machine and talks to it over stdin and stdout.

A client showing the server as connected has not necessarily used it, and a model will happily answer an RFC question from memory instead. On Claude Desktop the per-server log records only the handshake, so it cannot tell you either way — docs/desktop-verification.md says where the evidence actually is.

Tools

ToolWhat it does
search_rfcsSearch titles, or the full text of every RFC, ranked by section, if the section index is present
list_sectionsAn RFC's headings with line numbers — the cheap first call
get_rfcRead one section, or a line range

With the section index, a full-text query is words, and each result is one section ranked by BM25, carrying the section number to pass to get_rfc and the line that best matches. Without it, full-text search falls back to rg or grep over a synced mirror, where the query is a literal string and results are whole RFCs; regex=true opts into pattern matching there and in titles. The payload names the backend in tool. Title results put current RFCs before superseded ones, so a page cut short at limit keeps the document you want rather than the one it replaced.

get_rfc refuses any read of more than 1500 lines that is not a named section, answering with its size and a pointer to list_sections rather than filling the context with a specification the model had one question about; a start_line of 1 does not get around it. full=true overrides it. A section you asked for by name is never refused: list_sections reports how long each one is, and max_lines caps any read, so the choice is informed rather than blocked.

Every response carries a banner with the RFC's status and, when it applies, a warning that it has been superseded:

RFC 2616 — Hypertext Transfer Protocol -- HTTP/1.1  [DRAFT STANDARD]!! OBSOLETED BY: RFC 7230, 7231, 7232, 7233, 7234, 7235

That warning is the reason to use this rather than let a model fetch rfc-editor.org itself. Models cite dead specifications with great confidence.

Full-text search

Works with no setup, fetching documents on demand. Full-text search additionally needs the section index, which the user downloads from a shell:

bash
uvx mcp-server-rfc sync --index

About 270 MB from this project's GitHub releases, checked against its published SHA-256. It ranks sections by BM25 and serves every read from disk, so the server stops fetching from the RFC Editor. uvx mcp-server-rfc sync instead copies the corpus as 512 MB of text files from the RFC Editor's volunteer-run rsync mirror, which is what rg and regex=true search.

The same command that runs the server runs its CLI: sync downloads, status reports what is present, and uvx mcp-server-rfc <command> --help covers the rest. It is also the command the server names in the error you get when full-text search is asked for without either.

Both are optional. The server deliberately does not expose a sync tool: hundreds of megabytes on someone's disk should be a person's decision, not a model's.

If an index or a mirror already exists — synced for the companion skill, say — this server picks it up automatically. It looks under the platform's data directory: $XDG_DATA_HOME/rfc-ai-tooling, or %LOCALAPPDATA%\rfc-ai-tooling on Windows, falling back to ~/.local/share/rfc-ai-tooling. Set $RFC_MIRROR to point at a non-default location — in a container with no home directory, that or --mirror is what to pass.

In a container, uvx on the host would write to the wrong disk. Keep the mirror in a named volume, fill it through the image, and set $RFC_CLI so the server's errors name that command instead of uvx mcp-server-rfc:

bash
docker build -t mcp-server-rfc mcp/docker run --rm -it -v rfc-mirror:/mirror mcp-server-rfc mcp-server-rfc sync --indexdocker run --rm -i -v rfc-mirror:/mirror -e RFC_TRANSPORT=stdio \  -e RFC_CLI="docker run --rm -it -v rfc-mirror:/mirror mcp-server-rfc mcp-server-rfc" \  mcp-server-rfc

HTTP mode

The config above is the stdio transport, which needs a client that can spawn a process on your machine. A session running in the cloud — claude.ai on the web, Cowork — cannot, and no configuration fixes that. For those, the server has to be deployed somewhere they can reach:

bash
mcp-server-rfc --transport http --host 0.0.0.0 --port 8080

RFC_TRANSPORT, HOST and PORT are read from the environment too. The repository carries a Dockerfile and a fly.toml that do this. No public instance of this server exists and none is planned — if you want one, you host it, and you should put authentication in front of it, since the server has none and would otherwise be an open proxy to a volunteer-run mirror.

Full-text search works hosted only where the section index is on the server's disk (sync --index there). Without it, a hosted instance returns an error saying so instead of silently answering a title search. The obsolescence banner, section reads and the unscoped-read guard work either way, because they need only the 2 MB RFC index.

If your client has a shell

Use the skill instead — Claude Code, Codex CLI, OpenClaw, Cursor and Zed all qualify. It does the same things with fewer moving parts and gives the agent ripgrep over the corpus:

bash
npx skills add shbernal/rfc-ai-tooling      # from the repo, into .claude/skills/clawhub install @shbernal/rfc-lookup        # or the last released version

This server is for clients that give the model no shell of its own. Claude Desktop is the clearest case: its chat cannot run a command on your machine, but it will spawn this server there.

Source, issues and the skill: https://github.com/shbernal/rfc-ai-tooling

MIT.

來源:mcp/README.md,提交 e763589

工具

3

search_rfcs

Search RFCs. scope='title' matches all query terms against RFC titles and always works. scope='fulltext' searches the text of every RFC and needs either the section index or a local mirror the user has set up; it returns an error explaining what to run if there is neither. With the section index ('tool' is 'index'), the query is words, not a phrase: each result is one section, ranked by BM25 with headings weighted, carrying its 'section' number (null for the front matter), 'heading', 'line' and how many 'lines' it runs to, and a 'snippet' quoting its best line. Pass that section straight to get_rfc. Without the index ('tool' is 'rg' or 'grep'), the query is a literal string, each result is one RFC ranked by 'matching_lines', and 'matches' quotes a few lines with the section each falls in. regex=true opts into pattern matching, which only the mirror can do, in the backend's dialect. Results carry each RFC's status and obsolescence, and title results put current RFCs before superseded ones, so a page cut short at 'limit' keeps the replacement rather than the document it replaced. A 'note' says when the index could not be used. 'count' is how many results this page holds and 'total' is how many matched; when 'truncated' is true, report 'total' and raise 'limit' (at most 200) rather than counting the results you were given. An empty query is an error.

輸入參數limitquery必填regexscope

list_sections

List an RFC's numbered headings with their line numbers and how many lines each one runs to. Cheap, and the right first call when you need part of a specification: use it to pick a section, then pass that section to get_rfc. The line counts are there to be read — a section of a few hundred lines is a normal read, and one running to four figures wants a subsection or a max_lines cap instead. Some pre-1990 RFCs have no numbered headings, in which case this returns an empty list and get_rfc's line range is the way in.

輸入參數number必填

get_rfc

Read an RFC. Call list_sections first and pass a section — whole RFCs average 53 KB and run past 1.6 MB, and reading one in full is almost never what the question needs. section accepts a number ('9.3.1') or heading text ('Idempotent Methods') and includes that section's subsections. Any read of more than 1500 lines that is not a named section is an error naming its size, not a silent context-filling dump; pass full=true only when the entire text is genuinely what you need. start_line and max_lines are 1 or more. max_lines caps any read, including a section, and is the way to take the first part of one that list_sections showed is long. start_line is the fallback for RFCs without numbered headings and cannot be combined with section. Page headers and footers are stripped. The response carries a banner naming the RFC's status and, if it has been superseded, what replaced it.

輸入參數fullnumber必填sectionmax_linesstart_line

版本歷史

3
  1. v0.6.1最新Oct 30, 2026
  2. v0.6.0Oct 25, 2026
  3. v0.5.2Oct 24, 2026

評分

已滿足適用檢查項的 90%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分
  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具必需15 分
  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分