browser-harness Agent Skills & AI Rules

GitHub

Let Claude Code, Codex or Cursor use your real Chrome, logged in as you. One prompt to set up. Open source, MIT.

RAW Rules
6 Discovered Rules β€’ ~4,853 Estimated Tokens
Quick:
Loading skill content...

AI Agent Protocol & Instructions

AGENTS.md root-instruction ~508 tokens
Raw
browser-harness is a thin layer that connects agents to browsers via an editable CDP harness.

# Code priorities
- Clarity
- Precision
- Low verbosity
- Versatility

# Overview
Core code lives in `src/browser_harness/`:
- `admin.py` β€” daemon lifecycle, diagnostics, updates, profile management
- `daemon.py` β€” the long-lived middleman process between the browser and the agent
- `helpers.py` β€” CDP wrapper and core browser primitives auto-imported into the scripts the CLI reads from stdin
- `run.py` β€” the `browser-harness` CLI

`SKILL.md` tells agents how to use the harness and CLI.
`install.md` tells agents how to install it, attach a browser, and troubleshoot.

An agent operating the harness only edits inside `agent-workspace/`:
- `agent_helpers.py` β€” task-specific browser helpers the agent adds
- `domain-skills/` β€” skills the agent writes and reads

Package/CLI name = `browser-harness`. Skill identity (`name` + trigger) = `browser-use` (do not rename).

# Commands

From a **git checkout** (no global install required for local testing):

```bash
# doctor β€” install/daemon/browser state
./browser-harness --doctor

# smoke β€” CDP attach + page_info (Chrome remote debugging must be allowed)
./browser-harness <<'PY'
print(page_info())
PY

# unit tests (no live browser)
uv run --with pytest python -m pytest tests/unit -q

# after core/src edits: reload daemon so next call picks up code
./browser-harness --reload
```

Notes:
- `./browser-harness` = local tree launcher. Agents/docs outside this repo use the installed `browser-harness` command.
- Integration tests under `tests/integration/` may need a live browser/CDP β€” prefer unit + doctor for routine PR gates.
- First-time install / blocked Chrome: follow `install.md` (`chrome://inspect/#remote-debugging`).

# Security
- Do not commit secrets, Browser Use Cloud tokens, or session cookies.
- Prefer the smallest change that fixes the bug; do not expand CDP surface without need.

# Contributing
Consider what is really needed. Prefer the smallest diff that fixes the bug.
Domain skills under `agent-workspace/domain-skills/` are agent-generated when possible β€” hand-author only when necessary.