Self-learning browser infrastructure

Stop paying agents to [rediscover] the web.

Webcmd learns websites as agents use them, then compiles that knowledge into faster, cheaper, more reliable commands. Browser-agent token spend drops by up to 90%.

npm install -g @agentrhq/webcmd
webcmd skills add # adds the skill to your agent
webcmd / hackernews.top ready

# ask for data, not a browser session

webcmd hackernews top \

--limit 3 -f json

stories[3]{rank,title,score}:

1, Agent-native interfaces, 418

2, Durable browser workflows, 296

3, Structured tools at scale, 241

completed in 1.2s · 3 results

deterministic output strategy / PUBLIC

The browser should get smarter every time an agent uses it.

Browser agents are excellent explorers. But repeating a known workflow with screenshots, DOM snapshots, and fresh reasoning is slow, expensive, and fragile.

Webcmd keeps what the agent learns: observed pages, actions, APIs, pitfalls, fallback paths, and finally a durable command with named inputs and structured output.

The loop

Four layers. Less variance at every step.

Start with a real browser. Promote repeated knowledge until the browser is no longer needed.

01
</>

Control

Inspect, click, type, extract, and capture network calls in a real browser with structured feedback.

/skill:webcmd-browser
02
{ }

Remember

Capture a sitemap of observed pages, states, actions, workflows, APIs, pitfalls, and fallbacks.

/skill:webcmd-browser-sitemap
03
›_

Author

Build a reusable site adapter with explicit arguments, strategy tags, and consistent output.

/skill:webcmd-adapter-author
04
>>

Execute

Extend the adapter with tailored commands that run instantly with the fewest tokens.

$ webcmd <site> <command>

Move known work out of the reasoning loop.

The task Browser agent, every run Webcmd, after learning
Discover the interface Navigate + inspect + infer Known command
Handle inputs Find and fill page controls Named flags
Read results Parse page state Structured output
Repeat tomorrow Start the reasoning loop again Run the same CLI

Illustrative benchmark

Every layer collapses cost and variance.

Modeled repeat-run index for the same known six-step website task, normalized to a fresh browser replay. Directional placeholder, to be replaced with observed benchmark runs.

Input token index lower is better ↓
Fresh browser replay 100
Sitemap-guided 58
Reusable adapter 24
Tailored command 10
Agent turns per run lower is better ↓
Fresh browser replay 9.0
Sitemap-guided 6.0
Reusable adapter 2.0
Tailored command 1.0
90% lower token index fewer agent turns 14× faster task execution

One small surface. Many execution strategies.

Webcmd chooses the cheapest reliable path: public endpoints, authenticated cookies, intercepted requests, page UI, or a local tool. Agents discover them all the same way.

See how commands are built
agent discovery webcmd list -f json
commands[5]{site,command,strategy,browser}:
  hackernews,top,PUBLIC,false
  twitter,whoami,COOKIE,true
  linkedin,safe-send,INTERCEPT,true
  reddit,comment,UI,true
  docker,ps,LOCAL,false

help[2]:
  webcmd <site> --help
  webcmd <site> <command> -f json

Spend agent attention on the task, not the navigation.

01

Structured by default

Every interaction returns machine-readable matches, confidence, output, and errors.

02

Strategy-aware

Use PUBLIC, COOKIE, INTERCEPT, UI, or LOCAL depending on the cheapest reliable path.

03

Agent-discoverable

One list command exposes arguments, output columns, browser requirements, and strategy.

Start here

Make the browser learn.

Install Webcmd, inspect the command registry, and fall back to live browsing only when you need it.

npm install -g @agentrhq/webcmd
webcmd skills add # adds the skill to your agent
Read the docs