Browser-Use (LLM Browser Automation)

Browser-Use: an async Python library (3.11+) that turns an LLM into a web operator. The Agent loop collects DOM + screenshot, makes one LLM call emitting thinking / evaluation / next_goal / action[], and executes via CDP. Built on cdp-use; no Playwright.

✓ 0 reported success·v0.1.0·

Overview

Browser-Use is an async Python library (github.com/browser-use/browser-use) that turns an LLM into a web operator. Agent step loop: (1) collects a BrowserStateSummary (DOM with numeric indices, screenshot, tab list, page state) via 14 watchdogs around a bubus.EventBus; (2) makes one LLM call that simultaneously emits thinking + evaluation_previous_goal + memory + next_goal + action[]; (3) executes the actions through CDP primitives behind a double-layer page-change guard. CDP access is via cdp-use (typed protocol wrapper) — no Playwright. Multi-LLM-vendor support is duck-typed with no strong vendor abstraction. Optional BROWSER_USE_API_KEY enables stealth / proxy / captcha services. This skill embeds 40 constraints (4 fatal) covering typical pitfalls: alert/confirm/beforeunload auto-accepted by default (destructive confirms included), sensitive_data without allowed_domains is fail-OPEN, and SPA DOM re-render with unchanged URL bypasses the Layer-2 page-change guard.

Blueprint Source

finance-bp-133

browser-use/browser-usef3878b01 source file

Constraints

4total
4fatal
4 must-not-violate

Evidence Quality

Confidence90%

High confidence — strong evidence base

4 non-negotiable constraints

FATALdomain_rule?

WHENWhen designing or coding any browser-use workflow that touches admin tools, file management, settings pages, or any UI where confirm dialogs may guard irreversible operations

ACTIONEither (a) register a custom @tools.action that intercepts dialogs BEFORE popups_watchdog dispatches them (override dispatch order); (b) write a custom watchdog subclassing BaseWatchdog that LISTENS_TO Page.javascriptDialogOpening and overrides should_accept logic with semantic dialog-text classification; or (c) explicitly tell the LLM in the system prompt extension that destructive operations require a separate user-confirmation step recorded in todo.md before any click that could surface a confirm dialog. Document this as a hard prerequisite in your skill — host AI cannot rely on the framework to refuse destructive confirms.

CONSEQUENCEundefined behavior

FATALdomain_rule?

WHENWhen constructing an Agent and passing the sensitive_data parameter (passwords, API keys, PII, financial credentials)

ACTIONWrap Agent construction in your own factory that explicitly raises ValueError if sensitive_data is provided AND browser_profile.allowed_domains is empty/None. Recommended pattern: def make_agent(task, llm, sensitive_data, allowed_domains): assert allowed_domains, 'allowed_domains REQUIRED when sensitive_data set'; return Agent(task=task, llm=llm, sensitive_data=sensitive_data, browser=Browser(allowed_domains=allowed_domains)). Treat the framework's warning as documentation, not as protection.

CONSEQUENCEundefined behavior

FATALdomain_rule?

WHENWhen designing an agent task targeting a SPA — single-page-application, React/Vue/Angular routing, or any site with frequent client-side DOM rerenders that do not change the URL

ACTIONSet max_actions_per_step=1 for SPA-heavy targets so each LLM step is forced to re-read state before the next click. Alternatively, write a custom Layer-3 guard: subclass BaseWatchdog, LISTENS_TO ActionExecutedEvent, run a CDP DOMSnapshot.captureSnapshot pre/post and compare a hash of the interactive subtree; emit a synthetic PageChangedEvent on diff so multi_act breaks. Do NOT trust the default Layer-2 guard for SPA flows.

CONSEQUENCEundefined behavior

FAQ

Discussion (0)

No comments yet. Be the first to share!

Changelog

v0.1.02026-04-25·Contributors: tangweigang-jpg

v0.1.0: Initial release on Doramagic.ai. LLM web operator on browser-use/browser-use with bilingual metadata, 40 anti-pattern constraints (4 fatal), and 3 FAQs.

v0.1.02026-04-25·Contributors: tangweigang-jpg

v0.1.0: Initial release on Doramagic.ai. LLM web operator on browser-use/browser-use with bilingual metadata, 40 anti-pattern constraints (4 fatal), and 3 FAQs.