Browy in Action: Zero-Cost AI Browser Agents via GitHub Copilot

Chrome extension + local Node.js native messaging host + GitHub Copilot SDK. Zero marginal inference cost for browser AI agents.

16Yun Engineering TeamMay 17, 20266 min read

Introduction: The Hidden Cost of AI Browser Agents

AI browser agents face an underappreciated engineering problem: token consumption.

Every time an agent interacts with a page, it sends the DOM structure (typically 3000–5000 tokens) to an LLM for decision-making, then performs the next action. A moderately complex task — filling a form, navigating, extracting data — easily burns through tens of thousands of tokens. With paid API pricing, a single complex task can cost over $1 in inference.

Dario Amodei, CEO of Anthropic, noted in 2025 that agentic models break the traditional compute economy, with platforms potentially consuming $8 in inference compute for every $1 of subscription revenue.

Browy sidesteps this problem in an elegant way: it routes all model calls through the GitHub Copilot SDK. If you already have a GitHub Copilot subscription (personal $10/mo, enterprise $19/mo), every browser automation task costs zero in marginal inference.

This article covers Browy's architecture, installation, dual-interface operation, and practical workflows.

Architecture: Extension + Native Host + Copilot

Browy's architecture has three layers:

┌─────────────────────────────────────┐
│        Chrome Extension Layer       │
│  ┌─────────────┐  ┌──────────────┐ │
│  │  Side Panel │  │ DevTools CLI │ │
│  └──────┬──────┘  └──────┬───────┘ │
│         │                │          │
│         └──────┬─────────┘          │
│                ▼                    │
│         chrome.debugger API         │
│         (Chrome DevTools Protocol)  │
└──────────────────┬──────────────────┘


┌─────────────────────────────────────┐
│     Native Messaging Host           │
│   (Node.js daemon, runs locally)    │
│                                     │
│   ┌──────────────────────────┐      │
│   │  GitHub Copilot SDK Wrapper      │
│   └──────────┬───────────────┘      │
│              │                      │
│   ┌──────────▼───────────────┐      │
│   │  41 Built-in Tool Registry       │
│   └──────────────────────────┘      │
└──────────────────┬──────────────────┘


┌─────────────────────────────────────┐
│     GitHub Copilot API              │
│  (Claude, GPT-4o, Gemini, etc.)     │
└─────────────────────────────────────┘

Extension layer: A standard Chrome extension that attaches to the active tab via chrome.debugger, intercepting CDP traffic.

Native host layer: A local Node.js process communicating with the extension through Chrome's native messaging protocol. The host wraps the GitHub Copilot SDK, routing all model requests through the Copilot API.

Model layer: The Copilot subscription provides fixed-rate access to frontier models including Claude, GPT-4o, and Gemini. No separate API key required.

Key Design Decisions

DecisionEffect
Accessibility Tree instead of DOMDrops per-step tokens from thousands to hundreds
Indexed element selection (click by number)Eliminates brittle CSS selectors and XPath
Host OS tools disabled by defaultPrevents prompt injection from accessing the filesystem
DevTools CLI + Side PanelCaters to both beginners and power users

Installation

Three steps: extension, native host, Copilot login.

Step 1: Install the Extension

Add "Browy" from the Chrome Web Store (also works with Edge and Brave).

Verify: Pin the toolbar icon and click it. The side panel shows a "host disconnected" banner — expected until Step 2.

Step 2: Install the Native Host

macOS / Linux:

# Fetch and run the install script from Browy's project
curl -fsSL https://example.16yun.cn/browy-install.sh | bash

Windows (PowerShell):

# Fetch and run the install script from Browy's project
irm https://example.16yun.cn/browy-install.ps1 | iex

This installs:

  • The native host binary at ~/.browy/app/ (macOS/Linux) or %LOCALAPPDATA%\Browy\app\ (Windows)
  • The native messaging manifest so Chrome can launch the host process
  • A sandboxed scratch directory at ~/.browy/data/files/

Verify: Reopen the side panel. The host banner should be gone.

Step 3: Sign in to GitHub Copilot

Click "Sign in to GitHub Copilot" in the side panel. A terminal opens with a device-flow link. Paste the code in your browser, authorize, and the terminal closes.

Verify: Send "what is the headline of this page." You should see a snapshot tool call followed by the model reply.

Two Interfaces: Side Panel vs DevTools CLI

InterfaceHow to OpenBest For
Side PanelToolbar icon / keyboard shortcutDaily automation, form filling, data extraction
DevTools CLIF12 → Browy tabPower-user REPL, debugging

Side Panel Daily Operations

Open any page and type natural language instructions:

Extract all links from this page and format them as a table
Find the search box, search for "best AI agents 2026," then extract the top 5 results

DevTools CLI Power Features

Slash commands for keyboard-driven workflows:

CommandFunction
/helpList all commands and shortcuts
/modelHot-switch between 19 models
/jsExecute JavaScript in page context
/clearClear chat history and state
/loginRe-authenticate Copilot
# Switch model in DevTools CLI
/model claude-sonnet-4
 
# Debug with JavaScript
/js document.querySelectorAll('.price').map(e => e.textContent)

Core Toolset

Browy includes 41 tools covering browser operations.

Browser Tools

ToolFunction
snapshotGenerate Accessibility Tree index of the page
clickClick an element by index
typeType text into an element
evaluate_jsExecute JavaScript in page context
get_network_requestsInspect network traffic
get_console_logsRead console output
get_cookiesRead page cookies
set_cookiesWrite cookies
screenshotCapture page screenshot
get_storageRead localStorage

Host OS Tools (Disabled by Default)

These touch the host operating system and are disabled by default for security:

ToolFunctionRisk
save_fileWrite to ~/.browy/data/files/Sandbox-limited
read_fileRead from the sandbox directorySandbox-only
run_terminalExecute local shell commandsHigh — keep disabled
notes_memoryPersistent cross-session key-value memoryLow

To enable, go to Browy Settings and toggle each tool individually.

Practical Examples

Example 1: Scrape YC Startup Directory

List all YC Fall 2026 companies with their location and one-line pitch

Browy flow:

1. Load YC startup page
2. snapshot to get page structure
3. Identify each company card in the list
4. Extract: company name, location, description
5. Format as table output

Example 2: Review a GitHub PR

Summarise the changes in this PR and flag anything risky

Browy:

  1. Reads the PR diff view
  2. Analyzes changed files
  3. Extracts key code changes
  4. Applies Copilot's code review capability

Example 3: Set Up a Gmail Filter

Auto-archive everything from no-reply@*.atlassian.net

Browy navigates Gmail settings → Filters → Create new filter and fills the form.

Security Model: Default-Off

Browy uses a default-off security strategy:

  • All OS-level tools (file read/write, terminal) are disabled by default
  • Users enable them individually in Settings
  • This prevents prompt injection from malicious websites
User visits site → Malicious site injects instruction →
┌─────────────────────────────────────┐
│  Browy security barrier:            │
│  - Host tools default off           │
│  - Each tool must be manually enabled
│  - File I/O sandboxed               │
└─────────────────────────────────────┘
         ↓ Attack fails

Using Proxies

Browy runs in the user's real browser, inheriting all existing sessions and cookies. For scraping scenarios requiring IP rotation, configure at the browser level.

Method 1: Chrome startup with proxy flag

google-chrome --proxy-server=http://user:pass@proxy.16yun.cn:8888

Method 2: System environment variable

export HTTP_PROXY=http://user:pass@proxy.16yun.cn:8888
export HTTPS_PROXY=http://user:pass@proxy.16yun.cn:8888
google-chrome
ScenarioRecommended Setup
Temporary IP changeChrome startup flag
Daily scrapingCrawler Proxy (tunnel)
Long-term persistent tasksDedicated Proxy

Browy vs Alternatives

DimensionBrowyNanobrowserOperator (commercial)
CostCopilot ($10/mo+), zero marginalOwn API key, pay-per-use$200/mo fixed
Model choice19 models, hot-switchableMultiple configurableOpenAI only
PrivacyExtension + local process, no middle serverData goes to API providerData sent to OpenAI
Host system accessYes (tools off by default)NoNo
Best forDevelopers with Copilot subscriptionUsers who want model choiceUsers who want zero setup

Limitations

  • No headless: Requires a graphical desktop browser; cannot run on servers
  • No concurrency: Single-user, single-tab tool; not for large-scale extraction
  • Copilot dependency: Copilot's model availability and rate limits affect Browy directly
  • China access: api.githubcopilot.com is reachable but slow from mainland China

Summary

Browy's innovation is finding a specific gap — the existing GitHub Copilot subscription that many developers already pay for — and exploiting it to perfection.

By routing model calls through a fixed-rate subscription, Browy drives the marginal inference cost of browser automation to zero. Combined with its dual-interface design, default-off security, and 41 built-in tools, it's a practical and safe daily automation tool for developers.

The next article covers Steel Browser — a fundamentally different architecture: a Docker-based cloud browser API designed for large-scale concurrent AI agents.

Need an enterprise proxy plan?

We can tailor architecture to your target domains, concurrency, and reliability goals.