Skip to content

Feature request: add rtk agent-browser support #2100

Closed

Description

@jcgiustoast

Summary

Request first-class rtk agent-browser support to compress output from agent-browser, a CLI browser automation tool used by Claude Code agents.

Why

agent-browser is a high-volume, high-token CLI in Claude Code workflows. In my last 30 days of sessions:

Subcommand Calls Notes
agent-browser eval 356 Returns arbitrary JS-evaluated JSON — frequently huge
agent-browser navigate 116 Small status output
agent-browser snapshot 112 Full DOM / accessibility tree — very large
agent-browser click 101 Small status output
agent-browser screenshot 75 Writes file, returns path
agent-browser close 44 Tiny
agent-browser set 29 Small
Total 833

These currently bypass rtk entirely (no rewrite target), so all output enters the model context unfiltered.

eval and snapshot are the meaningful targets — both return structured payloads that compress well. The other subcommands return small fixed acknowledgments and don't need compression.

Suggested compression strategies

  • eval: detect JSON output, prune null fields, truncate long string values with `[…+N chars]` markers, collapse repeated array elements beyond N (similar to how `rtk grep` handles long match lines).
  • snapshot: accessibility-tree output is hierarchical and repetitive. Collapse nodes with no semantic role/label, drop empty containers, keep interactive elements (`@eXX` refs) intact since downstream `click`/`fill` commands depend on them.
  • navigate / click / close / set: pass-through or minimal trim.

Reference

Tool: https://www.npmjs.com/package/agent-browser (v0.26.0 tested)

Detected via `rtk discover --all`:

```
TOP UNHANDLED COMMANDS
agent-browser eval 356
agent-browser navigate 116
agent-browser snapshot 112
agent-browser click 101
agent-browser screenshot 75
agent-browser close 44
agent-browser set 29
```

Happy to share representative output samples if useful.

Activity

  1. added
    duplicate
    on May 27, 2026
  2. pszymkowiak commented on May 27, 2026

    @pszymkowiak
    Collaborator

    Closing as duplicate of #2007. See the original issue for updates.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:cliduplicatepriority:medium

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions