The autonomous JS web performance engineer. Orchestrates chrome-devtools-mcp into one propose → measure → keep/revert loop — with an LCP Attribution Map, a live HTML run report, configurable commit mode, and per-repo performance memory.
The autonomous JS web performance engineer./browsergnome: one command turns scattered
web performance tooling into a single, scientific loop — propose → measure → keep/revert — that
ships only the gains it can prove.
Inspired by Andrej Karpathy's /autoresearch. Fully adapted to the web.
What it solves
Web performance tooling is powerful but scattered — a Lighthouse run, a trace capture, a bundle
analyzer, a hunch about which fix will help — and nothing shares context between sessions or gates a
guess against a measurement. browsergnome routes each check to the right layer and runs a loop with a
real gate: one fix at a time, measured N times, kept only if the gain is clearly bigger than the
run-to-run wobble — otherwise reverted automatically, git as the memory that makes the revert exact.
The two maps, both real:
Perf Map 3D — a static AST scan of a real repo (excalidraw, 527 modules), rendered as an
interactive 3D graph. Node size = perf debt, color = severity. 16 hotspots surfaced out of 527 modules
— signal, not noise.
LCP Attribution Map — a real captured trace (nextjs.org, 922ms LCP), broken into network and
chunk nodes. Solid = measured directly from the trace; translucent = apportioned estimate.
▶ Explore both live — same real scan, same real
capture, plus the live run report.
Install
/plugin marketplace add uphold/browsergnome # or a local path to this repo
/plugin install browsergnome
Scripts need npm install: The SessionStart hook does this automatically inside a Claude session. For by-hand or CI use, run npm install in the plugin directory first.
Then, from inside a Claude Code session with the plugin loaded, run /browsergnome in any web repo.
Or clone it directly (not published to npm yet, so no npx browsergnome@latest fallback)
git clone https://github.com/uphold/browsergnome.git
cd browsergnome
npm install
An AST scan surfaces real structural hotspots — severity-weighted, diminishing-returns-capped,
centrality-amplified — so the loop starts from a hypothesis instead of a blind guess. Opens
perf-map.html when done.
Prefer the raw scripts? (offline, outside a Claude session)
BG="${CLAUDE_PLUGIN_ROOT:-.}" # falls back to repo-root-relative if you cloned the repo directly
node "$BG/skills/browsergnome/scripts/perf_scan.mjs" <path-to-a-web-repo> --out graph.json
node "$BG/skills/browsergnome/scripts/build_perf_map.mjs" graph.json --out perf-map.html --open
Run the loop
Point it at a slow page. It measures, proposes, measures again, and only keeps what it can prove.