wcc

wcc

WCC is an MCP server that compiles websites into typed capabilities for agents. It enables low-risk search, filter, and navigation actions with verified execution and reduced token usage on repeated tasks.

Category
访问服务器

README

Web Capability Compiler (WCC)

Compile existing websites into reusable, typed capabilities for MCP agents.

WCC is not another browser-use agent. It is a compilation, binding, and caching layer that sits between an existing website and an external AI agent.

Browser agents typically re-interpret low-level UI elements on every task, which costs tokens, reduces repeatability, and ties workflows to transient DOM detail. WCC inspects a page once, compiles the observable controls into a small set of semantic, typed, low-risk capability templates, binds compatible templates to the current session, and lets an MCP client execute them through a stable interface. On repeated use it tries to bind a persisted template before recompiling, so the agent can skip low-level DOM interpretation entirely.

The headline metric is token reduction on repeated tasks, not task success rate.

Status

MVP v0.1 is under construction against spec v0.2.1. Phases 0–6 of 7 are complete, and it runs as an MCP server today. The loop closes: WCC reads a live document into a snapshot, builds an Agent Page IR, compiles typed search, filter, and navigation capabilities with evidence and a deterministic risk classification, persists them as reusable templates, binds a stored template on a later session without recompiling, and executes one — validating arguments against its schema, re-resolving every target, re-checking risk against the page in front of it, running the plan one allowlisted action at a time, and verifying afterwards that the intended effect actually happened.

All of that is reachable from any MCP client over stdio, through six stable tools. An optional LLM pass can improve the names and descriptions, and is off by default — nothing in the loop above depends on it. What remains is Phase 7, the token-reduction benchmark.

Three properties are worth stating plainly, because they are what the design is for: only low-risk capabilities ever execute; an execution is reported as successful only when its effect was observed; and no selector, screenshot, or coordinate crosses the MCP boundary in either direction — a test asserts the last one by searching every tool response for the fixtures' own selectors.

See docs/progress.md for the phase log, which records the reasoning behind each decision and the defects found along the way.

Quickstart

No clone required. uv and Python 3.12+ are the only prerequisites.

# Install the Chromium build the driver uses (once)
uvx --from git+https://github.com/Maaa2005/web-capability-compiler.git wcc install-browser

# Check the machine before pointing a client at it
uvx --from git+https://github.com/Maaa2005/web-capability-compiler.git wcc doctor

# Run the MCP server over stdio
uvx --from git+https://github.com/Maaa2005/web-capability-compiler.git wcc serve

Connecting an MCP client

Claude Code:

claude mcp add wcc -- uvx --from git+https://github.com/Maaa2005/web-capability-compiler.git wcc serve

Claude Desktop (claude_desktop_config.json) or any client that takes a command:

{
  "mcpServers": {
    "wcc": {
      "command": "uvx",
      "args": [
        "--from",
        "git+https://github.com/Maaa2005/web-capability-compiler.git",
        "wcc",
        "serve"
      ]
    }
  }
}

Then ask the agent to open a page and inspect it. It will get back a list of typed capabilities rather than a DOM.

The six tools

Tool What it does
open_session Open a browser session on a URL, subject to the URL policy
inspect_page Compile the page — or rebind a stored template — and report capabilities, entities, and refusals
list_capabilities Filter what the inspection found by category and maximum risk
execute_capability Run one capability and return the complete verified result
get_execution_result Retrieve a stored result, only for the session that produced it
close_session Close the session; idempotent

Generated capabilities are returned as typed data, not registered as MCP tools — so the client's tool list never changes as the agent browses.

Configuration

Set by whoever launches the server, never by an agent over the wire.

Variable Effect
WCC_DATA_DIR Where templates and history are stored. Absolute paths only; defaults to the OS per-user data directory.
WCC_ALLOW_PRIVATE_NETWORK Set to 1 to allow loopback and private addresses. Development only — it switches off the SSRF boundary of specification 10.2.
WCC_ENRICHMENT Set to 1 to let an LLM improve capability names and descriptions. Off by default; needs pip install 'wcc[llm]' and ANTHROPIC_API_KEY.
WCC_ENRICHMENT_MODEL Which model does that naming. Defaults to claude-opus-5.

Optional semantic enrichment

Off unless you turn it on, and the compiler is the product either way — enrichment only rewrites names and descriptions. What it is given is a reduced structured summary: the compiled capability names, categories, risk levels, and parameter names. It is never given the DOM, a selector, a page's text, or a form value. What it gets back is validated before use and cannot change a locator, an execution plan, or lower a risk classification; a risk hint is only ever applied upward. If the provider is unreachable or answers with something invalid, the deterministic result is used unchanged and the reason is logged.

Responses are cached by page signature, so one page class costs one call.

Operating it

uv run wcc diagnostics                        # sanitized counts and environment checks
uv run wcc export --session <id> --output caps.json
uv run wcc import caps.json                   # checked on the way in, re-verified at bind time
uv run wcc clear-data                         # remove all local WCC data

An imported capability is stored, never trusted: it re-resolves its targets and is re-classified for risk against the live page before it can run, exactly as a locally compiled one is.

Development

uv sync
uv run wcc --help
./scripts/test.sh

Scope of MVP v0.1

Supported capability categories are search, filter, and navigate. Only low risk capabilities are executable. Purchases, account changes, message sending, and any state-changing form submission are out of scope, as are CAPTCHA bypass, anti-bot evasion, and credential storage.

The full scope, data model, risk model, and benchmark methodology live in docs/spec/WCC_AGENT_IMPLEMENTATION_SPEC_v0.2.1.md, which is the source of truth for implementation.

License

MIT

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选