Add native agent control for BB's visible Browser - #2765
Open
divyesh-puri wants to merge 2 commits into
Open
Conversation
Add experiment-gated Browser automation across the desktop, renderer, server, SDK, and CLI with fresh-tab ownership, native CDP input, AX snapshots, screenshots, cancellation, and bounded lifecycle cleanup.\n\nInclude deterministic Electron boundary coverage and a provider-backed trial harness. Supersedes the approach in get-bb#1869 while retaining its bounded lifecycle and correlation concepts.
amitbtcai
added a commit
to amitbtcai/axeai-macos
that referenced
this pull request
Aug 31, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds an experiment-gated, agent-facing Browser automation surface that controls BB's visible in-app Browser through native Electron/Chromium primitives.
This contribution was developed after reviewing #1869 (
dd66e0893) and is intended to supersede #1869. It retains that PR's useful bounded-lifecycle, correlation, cancellation, and navigation-epoch concepts, while replacing the synthetic DOM action/custom snapshot approach with native CDP accessibility and input primitives.Visual demo
This is the full BB desktop running this PR branch, not a mock. A provider-backed agent used
bb browserto open Wikipedia, search for Lean theorem prover, verify the result, scroll with PageDown, follow the homotopy type theory link from a fresh accessibility snapshot, and capture a screenshot. The Browser chrome shows the owning thread and the user-visible Stop control.What this adds
bb browser open|list|navigate|wait|snapshot|click|type|press|select|screenshot|close<select>operation without a generic evaluation surfacebrowserAutomationexperiment, disabled by defaultbb-browserskill, injected only while the experiment is enabledSecurity and ownership model
This stays within BB's existing trusted local/Connect-owner boundary; it does not claim cryptographic desktop attestation.
Validation
bbbinary → HTTP API → renderer WebSocket → preload/IPC → ElectronWebContentsView→ Chromium CDP → visible pageKey commands:
Review order
The change is cohesive but cross-layer. Suggested review order:
packages/domainandpackages/*-contractKnown gap
Native Electron acceptance is currently validated on macOS. Linux native Electron behavior remains explicitly unclaimed and is a follow-up.