文件历史

提交图

9 次代码提交

作者 SHA1 备注 提交日期
Alex Rudenko 028748663d chore: minor fixes to build and evals (#1875) 2026-04-16 11:59:06 +00:00
Stanislav Publika caf601a328 feat: add pageId routing for parallel multi-agent workflows (#1022)
## Summary

Adds optional `pageId` routing to page-scoped tools, gated behind
`--experimental-page-id-routing`. When enabled, multi-agent callers can
target a specific page without relying on global selection state. Fully
backward-compatible: without the flag, behavior is unchanged.

### Key changes

- **`pageScoped` annotation**: tools declare `pageScoped: true`; the
server merges `pageId` into their schema at registration time (when the
flag is on)
- **`McpPage` wrapper**: consolidates per-page state (numeric id,
isolated context name, focus tracking) into a single class
- **Request-scoped page routing**: `resolvePageById()` resolves the
target page, `setRequestPage()` threads it through the handler so tools
like `getSelectedPage()` see the right page
- **`assertPageIsFocused`**: keyboard/input tools validate that the
target page holds browser focus, returning an actionable error ("call
select_page first") instead of silently dispatching to the wrong page
- **`--experimental-page-id-routing` CLI flag** (hidden): gates schema
injection and request-scoped routing so the feature can be tested before
graduating
- **Eval scenarios**: `page_id_routing_test` and
`page_focus_keyboard_test` with `serverArgs` support in the eval harness

Addresses #1019
2026-02-26 11:39:38 +00:00
Stanislav Publika a10617002f chore: make eval scripts cross-platform compatible (Windows) (#1030)
Fixes #1029

## Summary
- Use `pathToFileURL()` from `node:url` for dynamic imports in
`eval_gemini.ts` to fix `ERR_UNSUPPORTED_ESM_URL_SCHEME` on Windows -
converts absolute paths like `D:\projects\...\console_test.ts` to proper
`file:///D:/projects/.../console_test.ts` URLs that the Node.js ESM
loader accepts on all platforms
- Move `CHROME_DEVTOOLS_MCP_NO_USAGE_STATISTICS=true` from Unix-only
shell env var prefix in `package.json` into `eval_gemini.ts` code,
matching the pattern already used in `scripts/test.mjs`
- Add `.gitattributes` with `* text=auto eol=lf` to enforce LF line
endings on checkout - Windows contributors cloning the repo would
otherwise get CRLF endings, which conflicts with the project's Prettier
`endOfLine: 'lf'` config and causes spurious diffs or formatting
failures
2026-02-24 13:16:27 +00:00
Alex Rudenko 482a288c7e chore: evaluate select_page scenario (#925)
Passes the test with gemini-2.5-flash with no errors.

Closes https://github.com/ChromeDevTools/chrome-devtools-mcp/issues/921
2026-02-10 10:11:23 +00:00
Alex Rudenko aa0a3679f5 feat: add a skill for using chrome-devtools-mcp (#830)
Closes https://github.com/ChromeDevTools/chrome-devtools-mcp/pull/710
Closes https://github.com/ChromeDevTools/chrome-devtools-mcp/issues/709
2026-01-26 10:04:39 +00:00
Alex Rudenko aa9a176956 fix: improve performance tool description (#800)
Drive-by: refactor and improve eval scripts.
2026-01-20 11:38:51 +00:00
Alex Rudenko 67c1f80b28 chore: refactor eval script more (#781)
add args parsing and simplify output (support debug logging + headless).
2026-01-16 08:49:06 +00:00
Alex Rudenko 0284d18b7b chore: support an html route in evals (#770)
Allows using the server URL in the prompt.
2026-01-14 17:11:53 +00:00
Alex Rudenko 257b9943e9 chore: add basic eval (#766)
This PR adds a tool based on the node test runner that runs a loop to
see what tools a model chooses given a prompt. The expectations are
encoding for each prompt. Run `npm run eval` to get results. Currently,
only Gemini and needs and API key.
2026-01-14 14:15:21 +00:00