You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[CLI]: find returns the full ancestor chain, and neither find nor snapshot can bound their output #42077
find returns the whole ancestor chain of the match, so most of the output is wrapper nodes rather than the thing found. Searching a job board for one heading gave me eight levels of generic [ref=eN] to deliver three useful lines:
For agent use this matters because the output is the context budget. A mode that returns the matched node plus its immediate children, without the path back to root, would cut that several-fold.
Related, there is no way to bound the output when a query is common: no --max-results on find, and no depth limit on snapshot, so a deeply nested SPA produces a large tree when two levels would do. Version 0.1.17.
For agent use this matters because the output is the context budget. A mode that returns the matched node plus its immediate children, without the path back to root, would cut that several-fold.
We are optimizing for a 1M context window size at this point.
Related, there is no way to bound the output when a query is common: no --max-results on find
This is something we can add, as well as control of the size of the context (ancestor chain length).
I'd like to work on the remaining browser_find scope. Current main already exposes depth on browser_snapshot, so I propose a focused change that adds optional maxResults and maxAncestorDepth inputs to browser_find while preserving today's defaults.
Unlike the closed #42127 approach, this would keep each match window separate with the existing ---- boundary, retain surrounding context, and render an explicit ellipsis when ancestors are omitted. I would add hermetic MCP tests for result limiting, ancestor truncation, multiple disjoint matches, and unchanged default output.
If that scope is acceptable for a community contribution, please assign #42077 to me.
I have submitted PR #42947 to add the maxResults parameter to �rowser_find and the --max-results option to the ind CLI command. It includes input validation for positive integers, clear header messaging when results are truncated (Found X matches for Y (showing first N):), and hermetic MCP and CLI test coverage while maintaining 100% backward compatibility.
Activity
pavelfeldman commentedon Aug 3, 2026
We are optimizing for a 1M context window size at this point.
This is something we can add, as well as control of the size of the context (ancestor chain length).
sashankh commentedon Aug 21, 2026
I'd like to work on the remaining
browser_findscope. Currentmainalready exposesdepthonbrowser_snapshot, so I propose a focused change that adds optionalmaxResultsandmaxAncestorDepthinputs tobrowser_findwhile preserving today's defaults.Unlike the closed #42127 approach, this would keep each match window separate with the existing
----boundary, retain surrounding context, and render an explicit ellipsis when ancestors are omitted. I would add hermetic MCP tests for result limiting, ancestor truncation, multiple disjoint matches, and unchanged default output.If that scope is acceptable for a community contribution, please assign #42077 to me.
alok-108 commentedon Sep 26, 2026
I have submitted PR #42947 to add the maxResults parameter to �rowser_find and the --max-results option to the ind CLI command. It includes input validation for positive integers, clear header messaging when results are truncated (Found X matches for Y (showing first N):), and hermetic MCP and CLI test coverage while maintaining 100% backward compatibility.
chore: mark v0.0.83 (#1779)
chore: mark v0.1.22 (#473)
feat(mcp): add maxResults option to browser_find (microsoft#42077)
chore(deps): update all non-major dependencies (#199)
chore(deps): update dependency @playwright/mcp to v0.0.83 (#1108)
feat(mcp): add maxResults option to browser_find (#42077) (#42947)
chore: mark v0.0.83 (microsoft#1779)
Update agent CLIs