Skip to content

release: v0.0.71 — MCP tool surface diet - #54

Merged
attson merged 12 commits into
mainfrom
release/v0.0.71
Sep 2, 2026
Merged

attson merged 12 commits into
mainfrom
release/v0.0.71

Conversation

@attson

@attson attson commented Sep 2, 2026

Copy link
Copy Markdown
Owner

Summary

Breaking change to @attson/atwebpilot-mcp: the advertised MCP tool list drops from ~13.5k tokens to ~4.5k by defaulting to a core set and letting the agent discover the rest on demand.

  • Default core mode (32 browser tools + browser_discoverTools); ATWEBPILOT_MCP_TOOLS=full lists all 51 up front. parity mode removed.
  • browser_discoverTools: no args → catalog of the 19 non-core tools in 7 groups; enable: [...] → adds them process-wide, sends tools/list_changed, returns their schemas. Respects the worker's supported_tools.
  • MCP-layer merges (extension untouched): browser_navigateBack/Forwardbrowser_navigate({action}); browser_highlightElement/Textbrowser_highlight; browser_readStorage/writeStoragebrowser_storage({op}). Resolution runs before capability validation, so tiers and dangerous accounting see the real builtin.
  • English MCP descriptions via a new optional LlmTool.mcp field; side-panel Chinese descriptions unchanged. Schemas stripped of nested descriptions.
  • Token-budget regression test; skill bundle, README and docs-site updated with migration notes.

Spec: docs/superpowers/specs/2026-09-02-mcp-tool-surface-diet-design.md (local).

Test plan

  • pnpm typecheck clean (4 packages)
  • pnpm test: shared 184, coordinator 45, extension 909, mcp-server 129 — all pass
  • Built dist/index.js smoke-tested over stdio: 38 tools / 16,385 chars in core; catalog 19; enable → 39
  • After merge: push tag v0.0.71 to trigger the npm publish workflow, then verify npm view @attson/atwebpilot-mcp version

🤖 Generated with Claude Code

liuzaisen and others added 12 commits September 2, 2026 22:33
Also fixes negotiation.test.ts expectations, which hardcoded the old
full-by-default browser tool counts and now regress under the core
default.
Fold highlightElement/highlightText into browser_highlight and
readStorage/writeStorage into browser_storage, each resolving to the
right builtin via a new GeneratedTool.resolve hook that runs before
capability validation so tiers and dangerous accounting see the real
builtin. Drop navigateBack/navigateForward from the MCP surface in
favour of navigate({action}). Full mode now advertises 51 browser
tools (58 TOOL_DEFS - 3 blocked - 6 merged-away + 2 merged).

handleBrowserTool resolves before validateCall/hub.exec; BROWSER_BY_NAME
now indexes the full tool table so a merged or dropped tool can still be
looked up regardless of the advertised mode; buildToolList filters by
builtinTools.every(...) so a merged tool is only advertised when the
worker supports every underlying builtin.
browser_discoverTools could advertise and enable tools the connected
worker cannot execute, since it only checked whether a name existed in
the catalog. handleDiscover now takes an optional `supported` builtin
set: catalog only lists runnable tools, and enable requests for a tool
that exists but the worker can't run land in a new `unsupported` field
instead of being silently advertised. dispatchCall wires this from the
existing workerToolSupport(deps) (peek-only, never binds a port).
- README: name the legacy-extension fallback set instead of a bare
  "19" that collided with the "其余 19 个" line above, and state the
  actual consequence under the new default (9-tool intersection with
  core, browser_storage never listed since old extensions lack
  writeStorage).
- SKILL.md: the 填表+提交 scenario now calls out that submitForm needs
  browser_discoverTools first, like the 翻页采集 scenario already does;
  replaced askUser/detachTab/attachTab flow instructions (not exposed
  over MCP) with in-reply confirmation and dropped the detach step.
- tests/tool-gen.test.ts: renamed the "55 - 5 + 2" title, which no
  longer matched TOOL_DEFS' actual count, to spell out the real
  arithmetic (58 - 3 blocked - 6 merged-away + 2 merged).
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@attson
attson merged commit 373b5e5 into main Sep 2, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant