TF2 Wiki

io.github.yusufaf由 GitHub 账号 yusufaf 发布v0.1.2更新于 Oct 30, 2026

Live Team Fortress Wiki access: search, pages, weapon stats, loadouts, patch notes.

概览

AI 生成的概览

非官方 MCP 服务器,让助手实时访问《军团要塞2》Wiki:搜索、页面、武器数据、配装、饰品与更新日志。

可以做什么
  • 搜索 Wiki,并以 wikitext、纯文本或 HTML 形式读取页面,附带摘要与章节目录
  • 按命名空间列出最近编辑的页面
  • 获取从信息框解析的结构化武器数据,并列出某职业的全部武器
  • 查询饰品信息框参数,以及某次活动或更新新增的物品
  • 获取指定更新或补丁页面的更新日志
适用场景
适合让助手依据真实 Wiki 回答 TF2 问题,而不是凭猜测:武器伤害与属性、职业配装、饰品细节、活动物品清单和更新日志。
运行要求
以 PyPI 包形式通过 stdio 在本地运行;README 要求安装 uv,并用 uvx 启动。未声明账号、API 密钥或环境变量。内容为实时抓取,需要能访问 TF2 Wiki 的网络。
安装前请注意
仅做只读查询,但每次请求都会发往外部 TF2 Wiki 站点,查询词和页面标题会离开本机。属非官方粉丝工具,与 Valve 及 Wiki 贡献者无关;Wiki 内容不随包分发,使用者需自行遵守 Valve 的条款。

安装

在 SourceWeft 中

  1. 打开 控制台中的 TF2 Wiki,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

tf2-wiki-mcp

An MCP server that exposes the Team Fortress Wiki to LLM clients (Claude Desktop, Claude Code, Cursor, VS Code) over stdio.

[Install in VS Code] [Install in VS Code Insiders] [Install in Visual Studio] [Install in Cursor]

Not affiliated with Valve Corporation or the Team Fortress Wiki contributors. Team Fortress 2 is a trademark of Valve Corporation. This is unofficial fan tooling.

What it does

Gives an LLM live, accurate access to TF2 wiki content so it stops guessing at weapon stats, patch notes, and cosmetic details.

  • Generic wiki access — search, fetch pages, get summaries, list recent changes.
  • TF2 domain tools — structured weapon stats, class loadouts, cosmetic lookup, event item lists, patch notes.

Tools

ToolPurpose
search_wiki(query, limit)Full-text search
get_page(title, format)Page content as wikitext, plain, or html
get_page_summary(title)Lead-section plaintext
get_page_sections(title)Section TOC for selective fetching
get_recent_changes(limit, namespace)Recently edited pages
get_weapon_stats(weapon_name)Parsed weapon infobox → structured stats
list_class_loadout(class_name)All weapons in a class's wiki category
get_cosmetic(name)Cosmetic item infobox params
list_event_items(event_name)Items added in an update/event
get_patch_notes(update_name)Patch notes for a specific update

Plus: resource tf2wiki://main, prompts analyze_loadout and compare_weapons.

Installation

Requires uv (which manages the Python toolchain for you). Once installed, uvx tf2-wiki-mcp will fetch and run the server on demand — no manual clone needed.

Standard config works in most MCP clients:

json
{  "mcpServers": {    "tf2-wiki-mcp": {      "command": "uvx",      "args": ["tf2-wiki-mcp"],      "env": {}    }  }}
Claude Desktop

Add the standard config above to claude_desktop_config.json:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json

Restart Claude Desktop. The TF2 wiki tools appear in the tool picker.

Claude Code
bash
claude mcp add tf2-wiki-mcp -- uvx tf2-wiki-mcp
Codex

Add to ~/.codex/config.toml:

toml
[mcp_servers.tf2-wiki-mcp]command = "uvx"args = ["tf2-wiki-mcp"]

See the Codex MCP docs.

Cursor

[Install in Cursor]

Or add the standard config to ~/.cursor/mcp.json.

Gemini CLI

Add the standard config to your Gemini CLI settings.json per the Gemini CLI MCP guide.

VS Code

[Install in VS Code]

Or via the VS Code CLI:

bash
code --add-mcp '{"name":"tf2-wiki-mcp","command":"uvx","args":["tf2-wiki-mcp"],"env":{}}'

See the VS Code MCP guide for details.

VS Code Insiders

[Install in VS Code Insiders]

Or via the CLI:

bash
code-insiders --add-mcp '{"name":"tf2-wiki-mcp","command":"uvx","args":["tf2-wiki-mcp"],"env":{}}'
Visual Studio

[Install in Visual Studio]

Or manually:

  1. Open the GitHub Copilot Chat window.
  2. Click the tools icon (🛠️) → + Add Server.
  3. Fill in: Server ID tf2-wiki-mcp, Type stdio, Command uvx, Arguments tf2-wiki-mcp.
  4. Save.

See the Visual Studio MCP docs.

GitHub Copilot Coding Agent
json
{  "mcpServers": {    "tf2-wiki-mcp": {      "command": "uvx",      "args": ["tf2-wiki-mcp"],      "env": {},      "type": "local",      "tools": ["*"]    }  }}

Add this in repository settings under Copilot → Coding agent. See the Copilot Coding Agent MCP docs.

Development

Run from a local clone instead of PyPI:

bash
git clone https://github.com/yusufaf/tf2-wiki-mcpcd tf2-wiki-mcpuv sync --devuv run pytest              # offline, uses recorded cassettesuv run pytest --live       # also hits the real wiki

To point an MCP client at the local checkout:

json
{  "mcpServers": {    "tf2-wiki-mcp": {      "command": "uv",      "args": ["run", "--directory", "/absolute/path/to/tf2-wiki-mcp", "tf2-wiki-mcp"]    }  }}

Licensing & Attribution

Code: MIT (see LICENSE).

Wiki content: Not redistributed. This project contains zero scraped wiki data. All page content is fetched live from wiki.teamfortress.com at the user's request and returned directly to the user's LLM client — the same posture as a browser extension.

Wiki content is © its respective contributors under Valve's Steam Subscriber Agreement (Game Site terms). Users of this tool are responsible for compliance with Valve's terms. Code license ≠ content license: MIT covers this codebase, not the wiki content it fetches.

Requests to the wiki include a descriptive User-Agent (tf2-wiki-mcp/<version> (https://github.com/yusufaf/tf2-wiki-mcp)) per MediaWiki etiquette and respect maxlag/Retry-After responses.

Contributing

Don't check in scraped wiki text. Infobox examples for parser tests are fine (short, fair-use-grade fixtures). Full page dumps are not.

来源:README.md,提交 46ed09b

工具

10

search_wiki

Search Wiki

Full-text search the TF2 Wiki. Returns title + snippet + wordcount for each hit.

输入参数limitquery必填

get_page

Get Page

Fetch a single TF2 Wiki page. `format` picks raw wikitext, plaintext extract, or rendered HTML.

输入参数title必填format

get_page_summary

Get Page Summary

Lead-section plaintext summary of a page. Fast context anchor.

输入参数title必填

get_page_sections

Get Page Sections

Section table-of-contents for a page; use before get_page to fetch selectively.

输入参数title必填

get_recent_changes

Get Recent Changes

Recently edited pages in the given namespace (0 = main/articles).

输入参数limitnamespace

get_weapon_stats

Get Weapon Stats

Fetch a weapon page and return structured stats parsed from its infobox. Returns damage, rate-of-fire, reload, clip size, attributes (+/- effects), etc.

输入参数weapon_name必填

list_class_loadout

List Class Loadout

List all weapons for the given class. Intersects Category:<Class> with Category:Weapons on the wiki.

输入参数class_name必填

get_cosmetic

Get Cosmetic

Fetch a cosmetic item page and return its infobox params.

输入参数name必填

list_event_items

List Event Items

List items added during a given TF2 event/update (e.g. 'Jungle Inferno Update', 'Smissmas 2023').

输入参数event_name必填

get_patch_notes

Get Patch Notes

Fetch patch notes for a named update or patch page (e.g. 'October 5, 2023 Patch').

输入参数update_name必填

版本历史

1
  1. v0.1.2最新Oct 29, 2026

评分

已满足适用检查项的 90%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通25 分
  • 已声明认证方式10 分

    请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。

  • 已列出工具必需15 分
  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分