Repository avatar
AI Tools
v0.2.4
active

glazyr

io.github.mcpmessenger/glazyr

Zero-copy browser perception for AI agents over MCP. ~13x fewer tokens than CDP or Playwright.

Documentation

Glazyr MCP

Zero-copy browser perception infrastructure for AI agents.

npm: @glazyr/mcp · Site: glazyr.com · Benchmark: report and drivers

Glazyr is a patched Chromium whose page-content producer writes the page's semantic tree directly into shared memory. An external process reads that state in microseconds — no CDP round-trip, no accessibility-tree dump, no screenshot guessing. The MCP bridge curates the tree for token cost and exposes it to agents as nine tools.

How it works

Everything runs on your machine — the same machine your agent runs on:

  1. Your MCP client starts the Glazyr server (npx @glazyr/mcp). On first run it downloads the browser bundle (~106 MB) from this repo's Releases and sets up an isolated Python environment under ~/.glazyr.
  2. The server launches your local copy of the Glazyr browser (patched Chromium 158) and manages it for the session.
  3. On page load, the browser itself extracts the page's semantic tree and writes it into a shared-memory region. The bridge reads it from there in ~1–50µs and curates it for token cost: summary-first navigation, find/subtree zoom, sibling collapse, unchanged-state stubs.
  4. Actions (click, type, scroll) go back to the browser over CDP, addressed by node id with layout geometry from the browser itself — no coordinate guessing.

There is no hosted service in the loop: no account, no API key, no telemetry, nothing phones home. Your agent never touches the publisher's computers, and the publisher never touches yours — each install is an independent local browser, like Playwright's, just built for agents instead of test scripts.

Benchmark

Measured on identical tasks, same machine (Nov 21, 2026; every token served to the agent counted with tiktoken cl100k_base):

FlowGlazyrRaw CDPPlaywright MCPText extraction
Wikipedia → Blink7,10865,89171,2666,804
httpbin form1,2962,1122,666226*
python.org fact37146,73457,0616,370
Total8,775114,737130,99313,400

13× fewer tokens than raw CDP, 15× fewer than Playwright MCP. Honest caveat: text extraction wins pure article reading by a hair — it cannot click, type, or act on JavaScript-driven pages. Glazyr can.

Token totals across the four stacks

Full report, method notes, and the driver scripts for all four stacks: benchmarks/comparison-2026-11-21.md

Install

Add to your MCP client config (Claude Code, Claude Desktop, Cursor, Antigravity, any MCP client):

{
  "mcpServers": {
    "glazyr": {
      "command": "npx",
      "args": ["-y", "@glazyr/mcp"]
    }
  }
}

First run downloads the browser bundle (~106 MB) and creates a Python environment under ~/.glazyr — expect a minute or two. After that, startup is silent and the browser launches and manages itself.

Windows: run Glazyr inside WSL2 and point your client at it:

{
  "mcpServers": {
    "glazyr": {
      "command": "wsl.exe",
      "args": ["-d", "Ubuntu", "-u", "root", "--", "npx", "-y", "@glazyr/mcp"]
    }
  }
}

(adjust the distro name and user to yours).

Requirements

  • Linux x64, or Windows with WSL2
  • Node.js 18+
  • Python 3.10+ (the bridge runs in an isolated venv it creates itself)
  • ~450 MB disk for the browser bundle

macOS builds do not exist yet.

The nine tools

ToolWhat it does
glazyr_statusBrowser state, process, shared-memory region status
glazyr_navigateNavigate; returns a summary map first (245 tokens on Wikipedia)
glazyr_peekFiltered page state (~13–14K tokens on a large article)
glazyr_peek_rawUnfiltered state — the escalation path
glazyr_peek_subtreeZoom into one container or element subtree
glazyr_findSearch page structure for matching nodes or text
glazyr_clickClick by node id, using layout geometry from the browser itself
glazyr_typeFocus an element and type
glazyr_scrollScroll the viewport

Repeat reads of unchanged state return a short stub instead of the full payload. Click and type acknowledgments carry their asserted result inline.

What we do not claim yet

  • On-demand re-extraction: the producer currently writes on page load; a DOM-change command channel is next.
  • Pixel streaming: the compositor's shared-memory region carries a live header; the pixel payload pipeline is on the roadmap.

Notes

  • Everything runs locally. No account, no API key, no cloud session — your agent pays only its own token bill, which is the bill Glazyr cuts.
  • The browser binary is a patched build of Chromium 158 (BSD-licensed, Copyright The Chromium Authors). This package's launcher and bridge code are MIT-licensed.
  • Environment overrides: GLAZYR_HOME (install root), GLAZYR_SHELL (use your own build), GLAZYR_BUNDLE_URL (bundle mirror).
NPM
@glazyr/mcp
Install Command
npm install @glazyr/mcp
Runtime: npx