@bastani/atomic 0.8.26-alpha.6 → 0.8.26-alpha.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +29 -0
- package/README.md +5 -5
- package/dist/builtin/intercom/CHANGELOG.md +12 -0
- package/dist/builtin/intercom/package.json +2 -2
- package/dist/builtin/mcp/CHANGELOG.md +12 -0
- package/dist/builtin/mcp/package.json +3 -3
- package/dist/builtin/subagents/CHANGELOG.md +12 -0
- package/dist/builtin/subagents/agents/codebase-online-researcher.md +9 -9
- package/dist/builtin/subagents/agents/debugger.md +6 -6
- package/dist/builtin/subagents/package.json +4 -4
- package/dist/builtin/subagents/prompts/parallel-handoff-plan.md +1 -1
- package/dist/builtin/subagents/skills/browser/EXAMPLES.md +151 -0
- package/dist/builtin/subagents/skills/browser/LICENSE.txt +21 -0
- package/dist/builtin/subagents/skills/browser/REFERENCE.md +451 -0
- package/dist/builtin/subagents/skills/browser/SKILL.md +170 -0
- package/dist/builtin/subagents/skills/subagent/SKILL.md +4 -4
- package/dist/builtin/web-access/CHANGELOG.md +12 -0
- package/dist/builtin/web-access/package.json +2 -2
- package/dist/builtin/workflows/CHANGELOG.md +17 -0
- package/dist/builtin/workflows/builtin/deep-research-codebase.ts +4 -1
- package/dist/builtin/workflows/builtin/goal.ts +127 -99
- package/dist/builtin/workflows/builtin/open-claude-design.ts +224 -147
- package/dist/builtin/workflows/builtin/ralph.ts +160 -197
- package/dist/builtin/workflows/package.json +2 -2
- package/dist/builtin/workflows/skills/research-codebase/SKILL.md +1 -1
- package/dist/builtin/workflows/src/extension/wiring.ts +13 -1
- package/dist/builtin/workflows/src/runs/foreground/executor.ts +12 -6
- package/dist/builtin/workflows/src/runs/foreground/stage-runner.ts +2 -2
- package/dist/builtin/workflows/src/shared/authoring-contract.d.ts +2 -2
- package/dist/builtin/workflows/src/shared/types.ts +3 -3
- package/dist/builtin/workflows/src/tui/stage-chat-view.ts +2 -1
- package/dist/core/agent-session.d.ts +33 -6
- package/dist/core/agent-session.d.ts.map +1 -1
- package/dist/core/agent-session.js +155 -182
- package/dist/core/agent-session.js.map +1 -1
- package/dist/core/atomic-guide-command.d.ts.map +1 -1
- package/dist/core/atomic-guide-command.js +1 -1
- package/dist/core/atomic-guide-command.js.map +1 -1
- package/dist/core/compaction/branch-summarization.d.ts +1 -1
- package/dist/core/compaction/branch-summarization.d.ts.map +1 -1
- package/dist/core/compaction/branch-summarization.js +6 -3
- package/dist/core/compaction/branch-summarization.js.map +1 -1
- package/dist/core/compaction/compaction.d.ts.map +1 -1
- package/dist/core/compaction/compaction.js +23 -10
- package/dist/core/compaction/compaction.js.map +1 -1
- package/dist/core/compaction/context-compaction.d.ts +61 -0
- package/dist/core/compaction/context-compaction.d.ts.map +1 -0
- package/dist/core/compaction/context-compaction.js +602 -0
- package/dist/core/compaction/context-compaction.js.map +1 -0
- package/dist/core/compaction/index.d.ts +1 -0
- package/dist/core/compaction/index.d.ts.map +1 -1
- package/dist/core/compaction/index.js +1 -0
- package/dist/core/compaction/index.js.map +1 -1
- package/dist/core/extensions/types.d.ts +3 -2
- package/dist/core/extensions/types.d.ts.map +1 -1
- package/dist/core/extensions/types.js.map +1 -1
- package/dist/core/index.d.ts +1 -1
- package/dist/core/index.d.ts.map +1 -1
- package/dist/core/index.js.map +1 -1
- package/dist/core/session-manager.d.ts +41 -1
- package/dist/core/session-manager.d.ts.map +1 -1
- package/dist/core/session-manager.js +146 -7
- package/dist/core/session-manager.js.map +1 -1
- package/dist/core/slash-commands.d.ts.map +1 -1
- package/dist/core/slash-commands.js +1 -1
- package/dist/core/slash-commands.js.map +1 -1
- package/dist/index.d.ts +3 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/dist/modes/index.d.ts +1 -1
- package/dist/modes/index.d.ts.map +1 -1
- package/dist/modes/index.js.map +1 -1
- package/dist/modes/interactive/components/chat-session-host.d.ts.map +1 -1
- package/dist/modes/interactive/components/chat-session-host.js +17 -0
- package/dist/modes/interactive/components/chat-session-host.js.map +1 -1
- package/dist/modes/interactive/components/context-compaction-summary-message.d.ts +17 -0
- package/dist/modes/interactive/components/context-compaction-summary-message.d.ts.map +1 -0
- package/dist/modes/interactive/components/context-compaction-summary-message.js +83 -0
- package/dist/modes/interactive/components/context-compaction-summary-message.js.map +1 -0
- package/dist/modes/interactive/components/index.d.ts +1 -0
- package/dist/modes/interactive/components/index.d.ts.map +1 -1
- package/dist/modes/interactive/components/index.js +1 -0
- package/dist/modes/interactive/components/index.js.map +1 -1
- package/dist/modes/interactive/interactive-mode.d.ts +1 -0
- package/dist/modes/interactive/interactive-mode.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-mode.js +72 -8
- package/dist/modes/interactive/interactive-mode.js.map +1 -1
- package/dist/modes/rpc/rpc-client.d.ts +13 -8
- package/dist/modes/rpc/rpc-client.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-client.js +8 -1
- package/dist/modes/rpc/rpc-client.js.map +1 -1
- package/dist/modes/rpc/rpc-mode.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-mode.js +4 -0
- package/dist/modes/rpc/rpc-mode.js.map +1 -1
- package/dist/modes/rpc/rpc-types.d.ts +14 -3
- package/dist/modes/rpc/rpc-types.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-types.js.map +1 -1
- package/docs/compaction.md +89 -37
- package/docs/custom-provider.md +11 -9
- package/docs/extensions.md +44 -40
- package/docs/index.md +2 -9
- package/docs/json.md +15 -12
- package/docs/packages.md +2 -0
- package/docs/providers.md +4 -1
- package/docs/quickstart.md +5 -12
- package/docs/rpc.md +38 -23
- package/docs/sdk.md +3 -10
- package/docs/session-format.md +26 -13
- package/docs/sessions.md +3 -3
- package/docs/settings.md +2 -2
- package/docs/skills.md +1 -15
- package/docs/termux.md +9 -10
- package/docs/themes.md +2 -2
- package/docs/tmux.md +3 -3
- package/docs/tui.md +19 -32
- package/docs/usage.md +2 -2
- package/docs/workflows.md +44 -2
- package/package.json +4 -12
- package/dist/builtin/subagents/skills/browser-use/SKILL.md +0 -234
- package/dist/builtin/subagents/skills/browser-use/references/cdp-python.md +0 -76
- package/dist/builtin/subagents/skills/browser-use/references/multi-session.md +0 -92
- package/node_modules/@earendil-works/pi-tui/README.md +0 -779
- package/node_modules/@earendil-works/pi-tui/dist/autocomplete.d.ts +0 -54
- package/node_modules/@earendil-works/pi-tui/dist/autocomplete.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/autocomplete.js +0 -632
- package/node_modules/@earendil-works/pi-tui/dist/autocomplete.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/box.d.ts +0 -22
- package/node_modules/@earendil-works/pi-tui/dist/components/box.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/box.js +0 -104
- package/node_modules/@earendil-works/pi-tui/dist/components/box.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/cancellable-loader.d.ts +0 -22
- package/node_modules/@earendil-works/pi-tui/dist/components/cancellable-loader.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/cancellable-loader.js +0 -35
- package/node_modules/@earendil-works/pi-tui/dist/components/cancellable-loader.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/editor.d.ts +0 -249
- package/node_modules/@earendil-works/pi-tui/dist/components/editor.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/editor.js +0 -1857
- package/node_modules/@earendil-works/pi-tui/dist/components/editor.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/image.d.ts +0 -28
- package/node_modules/@earendil-works/pi-tui/dist/components/image.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/image.js +0 -89
- package/node_modules/@earendil-works/pi-tui/dist/components/image.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/input.d.ts +0 -37
- package/node_modules/@earendil-works/pi-tui/dist/components/input.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/input.js +0 -378
- package/node_modules/@earendil-works/pi-tui/dist/components/input.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/loader.d.ts +0 -31
- package/node_modules/@earendil-works/pi-tui/dist/components/loader.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/loader.js +0 -69
- package/node_modules/@earendil-works/pi-tui/dist/components/loader.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/markdown.d.ts +0 -96
- package/node_modules/@earendil-works/pi-tui/dist/components/markdown.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/markdown.js +0 -644
- package/node_modules/@earendil-works/pi-tui/dist/components/markdown.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/select-list.d.ts +0 -50
- package/node_modules/@earendil-works/pi-tui/dist/components/select-list.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/select-list.js +0 -159
- package/node_modules/@earendil-works/pi-tui/dist/components/select-list.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/settings-list.d.ts +0 -50
- package/node_modules/@earendil-works/pi-tui/dist/components/settings-list.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/settings-list.js +0 -185
- package/node_modules/@earendil-works/pi-tui/dist/components/settings-list.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/spacer.d.ts +0 -12
- package/node_modules/@earendil-works/pi-tui/dist/components/spacer.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/spacer.js +0 -23
- package/node_modules/@earendil-works/pi-tui/dist/components/spacer.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/text.d.ts +0 -19
- package/node_modules/@earendil-works/pi-tui/dist/components/text.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/text.js +0 -89
- package/node_modules/@earendil-works/pi-tui/dist/components/text.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/truncated-text.d.ts +0 -13
- package/node_modules/@earendil-works/pi-tui/dist/components/truncated-text.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/components/truncated-text.js +0 -51
- package/node_modules/@earendil-works/pi-tui/dist/components/truncated-text.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/editor-component.d.ts +0 -39
- package/node_modules/@earendil-works/pi-tui/dist/editor-component.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/editor-component.js +0 -2
- package/node_modules/@earendil-works/pi-tui/dist/editor-component.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/fuzzy.d.ts +0 -16
- package/node_modules/@earendil-works/pi-tui/dist/fuzzy.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/fuzzy.js +0 -110
- package/node_modules/@earendil-works/pi-tui/dist/fuzzy.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/index.d.ts +0 -23
- package/node_modules/@earendil-works/pi-tui/dist/index.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/index.js +0 -32
- package/node_modules/@earendil-works/pi-tui/dist/index.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/keybindings.d.ts +0 -193
- package/node_modules/@earendil-works/pi-tui/dist/keybindings.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/keybindings.js +0 -174
- package/node_modules/@earendil-works/pi-tui/dist/keybindings.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/keys.d.ts +0 -184
- package/node_modules/@earendil-works/pi-tui/dist/keys.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/keys.js +0 -1173
- package/node_modules/@earendil-works/pi-tui/dist/keys.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/kill-ring.d.ts +0 -28
- package/node_modules/@earendil-works/pi-tui/dist/kill-ring.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/kill-ring.js +0 -44
- package/node_modules/@earendil-works/pi-tui/dist/kill-ring.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/native-modifiers.d.ts +0 -3
- package/node_modules/@earendil-works/pi-tui/dist/native-modifiers.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/native-modifiers.js +0 -53
- package/node_modules/@earendil-works/pi-tui/dist/native-modifiers.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/stdin-buffer.d.ts +0 -50
- package/node_modules/@earendil-works/pi-tui/dist/stdin-buffer.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/stdin-buffer.js +0 -361
- package/node_modules/@earendil-works/pi-tui/dist/stdin-buffer.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/terminal-image.d.ts +0 -90
- package/node_modules/@earendil-works/pi-tui/dist/terminal-image.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/terminal-image.js +0 -366
- package/node_modules/@earendil-works/pi-tui/dist/terminal-image.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/terminal.d.ts +0 -113
- package/node_modules/@earendil-works/pi-tui/dist/terminal.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/terminal.js +0 -472
- package/node_modules/@earendil-works/pi-tui/dist/terminal.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/tui.d.ts +0 -227
- package/node_modules/@earendil-works/pi-tui/dist/tui.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/tui.js +0 -1106
- package/node_modules/@earendil-works/pi-tui/dist/tui.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/undo-stack.d.ts +0 -17
- package/node_modules/@earendil-works/pi-tui/dist/undo-stack.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/undo-stack.js +0 -25
- package/node_modules/@earendil-works/pi-tui/dist/undo-stack.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/utils.d.ts +0 -84
- package/node_modules/@earendil-works/pi-tui/dist/utils.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/utils.js +0 -1029
- package/node_modules/@earendil-works/pi-tui/dist/utils.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/word-navigation.d.ts +0 -25
- package/node_modules/@earendil-works/pi-tui/dist/word-navigation.d.ts.map +0 -1
- package/node_modules/@earendil-works/pi-tui/dist/word-navigation.js +0 -96
- package/node_modules/@earendil-works/pi-tui/dist/word-navigation.js.map +0 -1
- package/node_modules/@earendil-works/pi-tui/native/darwin/prebuilds/darwin-arm64/darwin-modifiers.node +0 -0
- package/node_modules/@earendil-works/pi-tui/native/darwin/prebuilds/darwin-x64/darwin-modifiers.node +0 -0
- package/node_modules/@earendil-works/pi-tui/native/win32/prebuilds/win32-arm64/win32-console-mode.node +0 -0
- package/node_modules/@earendil-works/pi-tui/native/win32/prebuilds/win32-x64/win32-console-mode.node +0 -0
- package/node_modules/@earendil-works/pi-tui/package.json +0 -47
- package/node_modules/get-east-asian-width/index.d.ts +0 -60
- package/node_modules/get-east-asian-width/index.js +0 -30
- package/node_modules/get-east-asian-width/license +0 -9
- package/node_modules/get-east-asian-width/lookup-data.js +0 -21
- package/node_modules/get-east-asian-width/lookup.js +0 -138
- package/node_modules/get-east-asian-width/package.json +0 -71
- package/node_modules/get-east-asian-width/readme.md +0 -65
- package/node_modules/get-east-asian-width/utilities.js +0 -24
- package/node_modules/marked/LICENSE.md +0 -44
- package/node_modules/marked/README.md +0 -106
- package/node_modules/marked/bin/main.js +0 -282
- package/node_modules/marked/bin/marked.js +0 -15
- package/node_modules/marked/lib/marked.cjs +0 -2211
- package/node_modules/marked/lib/marked.cjs.map +0 -7
- package/node_modules/marked/lib/marked.d.cts +0 -728
- package/node_modules/marked/lib/marked.d.ts +0 -728
- package/node_modules/marked/lib/marked.esm.js +0 -2189
- package/node_modules/marked/lib/marked.esm.js.map +0 -7
- package/node_modules/marked/lib/marked.umd.js +0 -2213
- package/node_modules/marked/lib/marked.umd.js.map +0 -7
- package/node_modules/marked/man/marked.1 +0 -111
- package/node_modules/marked/man/marked.1.md +0 -92
- package/node_modules/marked/marked.min.js +0 -69
- package/node_modules/marked/package.json +0 -111
|
@@ -0,0 +1,451 @@
|
|
|
1
|
+
# Browser Automation CLI Reference
|
|
2
|
+
|
|
3
|
+
Technical reference for the `browse` CLI tool.
|
|
4
|
+
|
|
5
|
+
## Table of Contents
|
|
6
|
+
|
|
7
|
+
- [Architecture](#architecture)
|
|
8
|
+
- [Command Reference](#command-reference)
|
|
9
|
+
- [Navigation](#navigation)
|
|
10
|
+
- [Page State](#page-state)
|
|
11
|
+
- [Interaction](#interaction)
|
|
12
|
+
- [Session Management](#session-management)
|
|
13
|
+
- [JavaScript Evaluation](#javascript-evaluation)
|
|
14
|
+
- [Viewport](#viewport)
|
|
15
|
+
- [Network Capture](#network-capture)
|
|
16
|
+
- [Configuration](#configuration)
|
|
17
|
+
- [Global Flags](#global-flags)
|
|
18
|
+
- [Environment Variables](#environment-variables)
|
|
19
|
+
- [Error Messages](#error-messages)
|
|
20
|
+
|
|
21
|
+
## Architecture
|
|
22
|
+
|
|
23
|
+
The browse CLI is a **daemon-based** command-line tool:
|
|
24
|
+
|
|
25
|
+
- **Daemon process**: A background process manages the browser instance. Auto-starts on the first command (e.g., `browse open`), persists across commands, and stops with `browse stop`.
|
|
26
|
+
- **Local mode**: `browse open <url> --local` launches a clean isolated local browser. It is the default when `BROWSERBASE_API_KEY` is unset. Use `browse open <url> --auto-connect` to attach to an existing debuggable Chrome, or `browse open <url> --cdp <port|url>` to attach to a specific CDP target.
|
|
27
|
+
- **Remote mode** (Browserbase): Connects to a Browserbase cloud browser session when `BROWSERBASE_API_KEY` is set.
|
|
28
|
+
- **Accessibility-first**: Use `browse snapshot` to get the page's accessibility tree with element refs, then interact using those refs.
|
|
29
|
+
|
|
30
|
+
## Command Reference
|
|
31
|
+
|
|
32
|
+
### Navigation
|
|
33
|
+
|
|
34
|
+
#### `open <url>`
|
|
35
|
+
|
|
36
|
+
Navigate to a URL. Auto-starts the daemon if not running.
|
|
37
|
+
|
|
38
|
+
```bash
|
|
39
|
+
browse open https://example.com
|
|
40
|
+
browse open https://example.com --wait networkidle # wait for all network requests to finish (useful for SPAs)
|
|
41
|
+
browse open https://example.com --wait domcontentloaded
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
The `--wait` flag controls when navigation is considered complete. Values: `load` (default), `domcontentloaded`, `networkidle`. Use `networkidle` for JavaScript-heavy pages that fetch data after initial load.
|
|
45
|
+
|
|
46
|
+
##### Context persistence (remote mode only)
|
|
47
|
+
|
|
48
|
+
Create a Browserbase session with `browse cloud sessions create --context-id <id>`, then attach to its CDP endpoint with `browse open <url> --cdp <connectUrl>`. Add `--persist` to the cloud session if state changes should save back to the context.
|
|
49
|
+
|
|
50
|
+
```bash
|
|
51
|
+
SESSION_JSON="$(browse cloud sessions create --context-id ctx_abc123 --persist --keep-alive)"
|
|
52
|
+
SESSION_ID="$(echo "$SESSION_JSON" | jq -r .id)"
|
|
53
|
+
CONNECT_URL="$(echo "$SESSION_JSON" | jq -r .connectUrl)"
|
|
54
|
+
|
|
55
|
+
browse open https://example.com --cdp "$CONNECT_URL"
|
|
56
|
+
# ...interact with the page...
|
|
57
|
+
browse stop
|
|
58
|
+
browse cloud sessions update "$SESSION_ID" --status REQUEST_RELEASE
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
- `--context-id <id>` — Browserbase context ID to load when creating the cloud session.
|
|
62
|
+
- `--persist` — Save cookies/storage changes back to the context when the Browserbase session is released. Requires `--context-id`.
|
|
63
|
+
- `--keep-alive` — Keep the Browserbase session alive while the local browse daemon attaches and detaches.
|
|
64
|
+
- After `browse open ... --cdp "$CONNECT_URL"`, follow-up commands in that session do not repeat `--cdp`; the daemon remembers the attached target.
|
|
65
|
+
|
|
66
|
+
#### `reload`
|
|
67
|
+
|
|
68
|
+
Reload the current page.
|
|
69
|
+
|
|
70
|
+
```bash
|
|
71
|
+
browse reload
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
#### `back` / `forward`
|
|
75
|
+
|
|
76
|
+
Navigate browser history.
|
|
77
|
+
|
|
78
|
+
```bash
|
|
79
|
+
browse back
|
|
80
|
+
browse forward
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
---
|
|
84
|
+
|
|
85
|
+
### Page State
|
|
86
|
+
|
|
87
|
+
#### `snapshot`
|
|
88
|
+
|
|
89
|
+
Get the accessibility tree with interactive element refs. This is the primary way to understand page structure.
|
|
90
|
+
|
|
91
|
+
```bash
|
|
92
|
+
browse snapshot
|
|
93
|
+
browse snapshot --compact # tree only, no ref maps
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
Returns a text representation of the page with refs like `@0-5` that can be passed to `click`. Use `--compact` for shorter output when you only need the tree.
|
|
97
|
+
|
|
98
|
+
#### `screenshot [path]`
|
|
99
|
+
|
|
100
|
+
Take a visual screenshot. Slower than snapshot and uses vision tokens.
|
|
101
|
+
|
|
102
|
+
```bash
|
|
103
|
+
browse screenshot # print base64 JSON
|
|
104
|
+
browse screenshot --path ./capture.png # custom path
|
|
105
|
+
browse screenshot --full-page # capture entire scrollable page
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
#### `get <property> [selector]`
|
|
109
|
+
|
|
110
|
+
Get page properties. Available properties: `url`, `title`, `text`, `html`, `value`, `box`, `visible`, `checked`.
|
|
111
|
+
|
|
112
|
+
```bash
|
|
113
|
+
browse get url # current URL
|
|
114
|
+
browse get title # page title
|
|
115
|
+
browse get text "body" # all visible text (selector required)
|
|
116
|
+
browse get text ".product-info" # text within a CSS selector
|
|
117
|
+
browse get html "#main" # inner HTML of an element
|
|
118
|
+
browse get value "#email-input" # value of a form field
|
|
119
|
+
browse get box "#header" # bounding box (centroid coordinates)
|
|
120
|
+
browse get visible ".modal" # check if element is visible
|
|
121
|
+
browse get checked "#agree" # check if checkbox/radio is checked
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
**Note**: `get text` requires a CSS selector argument — use `"body"` for full page text.
|
|
125
|
+
|
|
126
|
+
#### `refs`
|
|
127
|
+
|
|
128
|
+
Show the cached ref map from the last `browse snapshot`. Useful for looking up element refs without re-running a full snapshot.
|
|
129
|
+
|
|
130
|
+
```bash
|
|
131
|
+
browse refs
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
---
|
|
135
|
+
|
|
136
|
+
### Interaction
|
|
137
|
+
|
|
138
|
+
#### `click <ref>`
|
|
139
|
+
|
|
140
|
+
Click an element by its ref from `browse snapshot` output.
|
|
141
|
+
|
|
142
|
+
```bash
|
|
143
|
+
browse click @0-5 # click element with ref 0-5
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
#### `click_xy <x> <y>`
|
|
147
|
+
|
|
148
|
+
Click at exact viewport coordinates.
|
|
149
|
+
|
|
150
|
+
```bash
|
|
151
|
+
browse click_xy 500 300
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
#### `hover <x> <y>`
|
|
155
|
+
|
|
156
|
+
Hover at viewport coordinates.
|
|
157
|
+
|
|
158
|
+
```bash
|
|
159
|
+
browse hover 500 300
|
|
160
|
+
```
|
|
161
|
+
|
|
162
|
+
#### `type <text>`
|
|
163
|
+
|
|
164
|
+
Type text into the currently focused element.
|
|
165
|
+
|
|
166
|
+
```bash
|
|
167
|
+
browse type "Hello, world!"
|
|
168
|
+
browse type "slow typing" --delay 100 # 100ms between keystrokes
|
|
169
|
+
browse type "human-like" --mistakes # simulate human typing with typos
|
|
170
|
+
```
|
|
171
|
+
|
|
172
|
+
#### `fill <selector> <value>`
|
|
173
|
+
|
|
174
|
+
Fill an input element matching a CSS selector. Add `--press-enter` when Enter is needed.
|
|
175
|
+
|
|
176
|
+
```bash
|
|
177
|
+
browse fill "#search" "browser automation"
|
|
178
|
+
browse fill "input[name=email]" "user@example.com"
|
|
179
|
+
browse fill "#search" "query" --press-enter # fill and press Enter
|
|
180
|
+
```
|
|
181
|
+
|
|
182
|
+
#### `select <selector> <values...>`
|
|
183
|
+
|
|
184
|
+
Select option(s) from a dropdown.
|
|
185
|
+
|
|
186
|
+
```bash
|
|
187
|
+
browse select "#country" "United States"
|
|
188
|
+
browse select "#tags" "javascript" "typescript" # multi-select
|
|
189
|
+
```
|
|
190
|
+
|
|
191
|
+
#### `press <key>`
|
|
192
|
+
|
|
193
|
+
Press a keyboard key or key combination.
|
|
194
|
+
|
|
195
|
+
```bash
|
|
196
|
+
browse press Enter
|
|
197
|
+
browse press Tab
|
|
198
|
+
browse press Escape
|
|
199
|
+
browse press Cmd+A # select all (Mac)
|
|
200
|
+
browse press Ctrl+C # copy (Linux/Windows)
|
|
201
|
+
```
|
|
202
|
+
|
|
203
|
+
#### `mouse scroll <x> <y> <deltaX> <deltaY>`
|
|
204
|
+
|
|
205
|
+
Scroll at a given position by a given amount.
|
|
206
|
+
|
|
207
|
+
```bash
|
|
208
|
+
browse mouse scroll 500 300 0 -300 # scroll up at (500, 300)
|
|
209
|
+
browse mouse scroll 500 300 0 500 # scroll down
|
|
210
|
+
```
|
|
211
|
+
|
|
212
|
+
#### `mouse drag <fromX> <fromY> <toX> <toY>`
|
|
213
|
+
|
|
214
|
+
Drag from one viewport coordinate to another.
|
|
215
|
+
|
|
216
|
+
```bash
|
|
217
|
+
browse mouse drag 80 80 310 100 # drag with default 10 steps
|
|
218
|
+
browse mouse drag 80 80 310 100 --steps 20 # more intermediate steps
|
|
219
|
+
browse mouse drag 80 80 310 100 --delay 50 # 50ms between steps
|
|
220
|
+
browse mouse drag 80 80 310 100 --button right # use right mouse button
|
|
221
|
+
browse mouse drag 80 80 310 100 --return-xpath # return source/target XPaths
|
|
222
|
+
```
|
|
223
|
+
|
|
224
|
+
#### `highlight <selector>`
|
|
225
|
+
|
|
226
|
+
Highlight an element on the page for visual debugging.
|
|
227
|
+
|
|
228
|
+
```bash
|
|
229
|
+
browse highlight "#submit-btn" # highlight for 2 seconds (default)
|
|
230
|
+
browse highlight ".nav" -d 5000 # highlight for 5 seconds
|
|
231
|
+
```
|
|
232
|
+
|
|
233
|
+
#### `is <check> <selector>`
|
|
234
|
+
|
|
235
|
+
Check element state. Available checks: `visible`, `checked`.
|
|
236
|
+
|
|
237
|
+
```bash
|
|
238
|
+
browse is visible ".modal" # returns { visible: true/false }
|
|
239
|
+
browse is checked "#agree" # returns { checked: true/false }
|
|
240
|
+
```
|
|
241
|
+
|
|
242
|
+
#### `wait <type> [arg]`
|
|
243
|
+
|
|
244
|
+
Wait for a condition.
|
|
245
|
+
|
|
246
|
+
```bash
|
|
247
|
+
browse wait load # wait for page load
|
|
248
|
+
browse wait "selector" ".results" # wait for element to appear
|
|
249
|
+
browse wait timeout 3000 # wait 3 seconds
|
|
250
|
+
```
|
|
251
|
+
|
|
252
|
+
---
|
|
253
|
+
|
|
254
|
+
### Session Management
|
|
255
|
+
|
|
256
|
+
#### `start`
|
|
257
|
+
|
|
258
|
+
Start the browser daemon manually. Usually not needed — the daemon auto-starts on first command.
|
|
259
|
+
|
|
260
|
+
```bash
|
|
261
|
+
browse start
|
|
262
|
+
```
|
|
263
|
+
|
|
264
|
+
#### `stop`
|
|
265
|
+
|
|
266
|
+
Stop the browser daemon and close the browser.
|
|
267
|
+
|
|
268
|
+
```bash
|
|
269
|
+
browse stop
|
|
270
|
+
browse stop --force # force kill if daemon is unresponsive
|
|
271
|
+
```
|
|
272
|
+
|
|
273
|
+
#### `status`
|
|
274
|
+
|
|
275
|
+
Check whether the daemon is running, its connection details, and current environment.
|
|
276
|
+
|
|
277
|
+
```bash
|
|
278
|
+
browse status
|
|
279
|
+
```
|
|
280
|
+
|
|
281
|
+
#### Starting sessions with a mode flag
|
|
282
|
+
|
|
283
|
+
Choose the browser target on the command that starts the session:
|
|
284
|
+
|
|
285
|
+
```bash
|
|
286
|
+
browse open https://example.com --local
|
|
287
|
+
browse open https://example.com --local --headed
|
|
288
|
+
browse open https://example.com --auto-connect
|
|
289
|
+
browse open https://example.com --cdp 9222
|
|
290
|
+
browse open https://example.com --cdp ws://localhost:9222/devtools/browser/...
|
|
291
|
+
browse open https://example.com --remote
|
|
292
|
+
```
|
|
293
|
+
|
|
294
|
+
- `browse status` shows the resolved mode and active target once the daemon is running.
|
|
295
|
+
- `browse stop` closes the current daemon session; the next `browse open` chooses mode from its flags or environment.
|
|
296
|
+
|
|
297
|
+
#### `tab new [url]`
|
|
298
|
+
|
|
299
|
+
Create a new tab, optionally navigating to a URL.
|
|
300
|
+
|
|
301
|
+
```bash
|
|
302
|
+
browse tab new # open blank tab
|
|
303
|
+
browse tab new https://example.com # open tab with URL
|
|
304
|
+
```
|
|
305
|
+
|
|
306
|
+
#### `tab list`
|
|
307
|
+
|
|
308
|
+
List all open tabs.
|
|
309
|
+
|
|
310
|
+
```bash
|
|
311
|
+
browse tab list
|
|
312
|
+
```
|
|
313
|
+
|
|
314
|
+
#### `tab switch <index-or-target-id>`
|
|
315
|
+
|
|
316
|
+
Switch to a tab by its index or target ID (from `browse tab list`).
|
|
317
|
+
|
|
318
|
+
```bash
|
|
319
|
+
browse tab switch 1
|
|
320
|
+
```
|
|
321
|
+
|
|
322
|
+
#### `tab close [index-or-target-id]`
|
|
323
|
+
|
|
324
|
+
Close a tab. Closes current tab if no index given. The CLI refuses to close the last remaining tab.
|
|
325
|
+
|
|
326
|
+
```bash
|
|
327
|
+
browse tab close # close current tab
|
|
328
|
+
browse tab close 2 # close tab at index 2
|
|
329
|
+
```
|
|
330
|
+
|
|
331
|
+
---
|
|
332
|
+
|
|
333
|
+
### JavaScript Evaluation
|
|
334
|
+
|
|
335
|
+
#### `eval <expression>`
|
|
336
|
+
|
|
337
|
+
Evaluate JavaScript in the page context.
|
|
338
|
+
|
|
339
|
+
```bash
|
|
340
|
+
browse eval "document.title"
|
|
341
|
+
browse eval "document.querySelectorAll('a').length"
|
|
342
|
+
```
|
|
343
|
+
|
|
344
|
+
---
|
|
345
|
+
|
|
346
|
+
### Viewport
|
|
347
|
+
|
|
348
|
+
#### `viewport <width> <height>`
|
|
349
|
+
|
|
350
|
+
Set the browser viewport size.
|
|
351
|
+
|
|
352
|
+
```bash
|
|
353
|
+
browse viewport 1920 1080
|
|
354
|
+
```
|
|
355
|
+
|
|
356
|
+
---
|
|
357
|
+
|
|
358
|
+
### Network Capture
|
|
359
|
+
|
|
360
|
+
Capture network requests to the filesystem for inspection.
|
|
361
|
+
|
|
362
|
+
#### `network on`
|
|
363
|
+
|
|
364
|
+
Enable network request capture. Creates a temp directory where requests and responses are saved as JSON files.
|
|
365
|
+
|
|
366
|
+
```bash
|
|
367
|
+
browse network on
|
|
368
|
+
```
|
|
369
|
+
|
|
370
|
+
#### `network off`
|
|
371
|
+
|
|
372
|
+
Disable network capture.
|
|
373
|
+
|
|
374
|
+
```bash
|
|
375
|
+
browse network off
|
|
376
|
+
```
|
|
377
|
+
|
|
378
|
+
#### `network path`
|
|
379
|
+
|
|
380
|
+
Show the capture directory path.
|
|
381
|
+
|
|
382
|
+
```bash
|
|
383
|
+
browse network path
|
|
384
|
+
```
|
|
385
|
+
|
|
386
|
+
#### `network clear`
|
|
387
|
+
|
|
388
|
+
Clear all captured requests.
|
|
389
|
+
|
|
390
|
+
```bash
|
|
391
|
+
browse network clear
|
|
392
|
+
```
|
|
393
|
+
|
|
394
|
+
---
|
|
395
|
+
|
|
396
|
+
## Configuration
|
|
397
|
+
|
|
398
|
+
### Common Flags
|
|
399
|
+
|
|
400
|
+
#### `--session <name>`
|
|
401
|
+
|
|
402
|
+
Run commands against a named session, enabling multiple concurrent browsers.
|
|
403
|
+
|
|
404
|
+
```bash
|
|
405
|
+
browse open https://a.com --session work
|
|
406
|
+
browse open https://b.com --session personal
|
|
407
|
+
```
|
|
408
|
+
|
|
409
|
+
Context flags such as `--context-id` and `--persist` live on `browse cloud sessions create`; attach to the resulting `connectUrl` with `browse open ... --cdp <connectUrl>`.
|
|
410
|
+
|
|
411
|
+
### Environment Variables
|
|
412
|
+
|
|
413
|
+
| Variable | Required | Description |
|
|
414
|
+
|----------|----------|-------------|
|
|
415
|
+
| `BROWSE_SESSION` | No | Default session name (alternative to `--session`) |
|
|
416
|
+
| `BROWSERBASE_API_KEY` | For remote mode | API key from https://browserbase.com/settings; makes Browserbase the default desired mode when no override is set |
|
|
417
|
+
| `BROWSERBASE_PROJECT_ID` | No | Passed through to Browserbase when set |
|
|
418
|
+
|
|
419
|
+
Without an override, setting `BROWSERBASE_API_KEY` makes Browserbase the default desired mode. Otherwise the default desired mode is local. Use `--local`, `--remote`, `--auto-connect`, or `--cdp <port|url>` on `browse open` when you need an explicit target.
|
|
420
|
+
|
|
421
|
+
### Setting credentials
|
|
422
|
+
|
|
423
|
+
```bash
|
|
424
|
+
export BROWSERBASE_API_KEY="bb_live_..."
|
|
425
|
+
```
|
|
426
|
+
|
|
427
|
+
Get these values from https://browserbase.com/settings.
|
|
428
|
+
|
|
429
|
+
---
|
|
430
|
+
|
|
431
|
+
## Error Messages
|
|
432
|
+
|
|
433
|
+
**"No active page"**
|
|
434
|
+
- The daemon is running but has no page open.
|
|
435
|
+
- Fix: Run `browse open <url>`. If the issue persists, run `browse stop` and retry. For zombie daemons: `pkill -f "browse.*daemon"`.
|
|
436
|
+
|
|
437
|
+
**"Chrome not found"** / **"Could not find local Chrome installation"**
|
|
438
|
+
- Chrome/Chromium is not installed or not in a standard location.
|
|
439
|
+
- Fix: Install Chrome, use `browse open <url> --auto-connect` if you already have a debuggable Chrome running, or switch to remote with `browse open <url> --remote` (no local browser needed).
|
|
440
|
+
|
|
441
|
+
**"Daemon not running"**
|
|
442
|
+
- No daemon process is active. Most commands auto-start the daemon, but `snapshot`, `click`, etc. require an active session.
|
|
443
|
+
- Fix: Run `browse open <url>` to start a session.
|
|
444
|
+
|
|
445
|
+
**Element ref not found (e.g., "@0-5")**
|
|
446
|
+
- The ref from a previous snapshot is no longer valid (page changed).
|
|
447
|
+
- Fix: Run `browse snapshot` again to get fresh refs.
|
|
448
|
+
|
|
449
|
+
**Timeout errors**
|
|
450
|
+
- The page took too long to load or an element didn't appear.
|
|
451
|
+
- Fix: Try `browse wait load` before interacting, or increase wait time.
|
|
@@ -0,0 +1,170 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: browser
|
|
3
|
+
description: Automate web browser interactions using natural language via CLI commands. Use when the user asks to browse websites, navigate web pages, extract data from websites, take screenshots, fill forms, click buttons, or interact with web applications. Supports remote Browserbase sessions with Browserbase Identity, Verified browsers, automatic CAPTCHA solving, and residential proxies — ideal for protected websites and JavaScript-heavy pages.
|
|
4
|
+
compatibility: "Requires the browse CLI (`npm install -g browse`). Remote Browserbase sessions need `BROWSERBASE_API_KEY`. Local mode uses Chrome/Chromium on your machine."
|
|
5
|
+
license: MIT
|
|
6
|
+
allowed-tools: Bash
|
|
7
|
+
metadata:
|
|
8
|
+
openclaw:
|
|
9
|
+
requires:
|
|
10
|
+
bins:
|
|
11
|
+
- browse
|
|
12
|
+
install:
|
|
13
|
+
- kind: node
|
|
14
|
+
package: "browse"
|
|
15
|
+
bins: [browse]
|
|
16
|
+
homepage: https://github.com/browserbase/skills
|
|
17
|
+
---
|
|
18
|
+
|
|
19
|
+
# Browser Automation
|
|
20
|
+
|
|
21
|
+
Automate browser interactions using the browse CLI with Claude.
|
|
22
|
+
|
|
23
|
+
## Setup check
|
|
24
|
+
|
|
25
|
+
Before running any browser commands, verify the CLI is available:
|
|
26
|
+
|
|
27
|
+
```bash
|
|
28
|
+
which browse || npm install -g browse
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
## Environment Selection (Local vs Remote)
|
|
32
|
+
|
|
33
|
+
The CLI supports explicit per-command environment flags. If you do nothing, the next session defaults to Browserbase when `BROWSERBASE_API_KEY` is set and to local otherwise.
|
|
34
|
+
|
|
35
|
+
### Local mode
|
|
36
|
+
- `browse open <url> --local` starts a clean isolated local browser
|
|
37
|
+
- `browse open <url> --auto-connect` attaches to an already-running debuggable Chrome; use `--local` when no debuggable Chrome is available
|
|
38
|
+
- `browse open <url> --cdp <port|url>` attaches to a specific CDP target
|
|
39
|
+
- Best for: development, localhost, trusted sites, and reproducible runs
|
|
40
|
+
|
|
41
|
+
### Remote mode (Browserbase)
|
|
42
|
+
- `browse open <url> --remote` starts a Browserbase session
|
|
43
|
+
- Without a local flag, Browserbase is also the default when `BROWSERBASE_API_KEY` is set
|
|
44
|
+
- Provides: Browserbase Identity, Verified browsers, automatic CAPTCHA solving, residential proxies, session persistence
|
|
45
|
+
- **Use remote mode when:** the target site has bot detection, CAPTCHAs, IP rate limiting, Cloudflare protection, or requires geo-specific access
|
|
46
|
+
- Get credentials at https://browserbase.com/settings
|
|
47
|
+
|
|
48
|
+
### When to choose which
|
|
49
|
+
- **Repeatable local testing / clean state**: `browse open <url> --local`
|
|
50
|
+
- **Reuse your local login/cookies**: `browse open <url> --auto-connect`
|
|
51
|
+
- **Simple browsing** (docs, wikis, public APIs): local mode is fine
|
|
52
|
+
- **Protected sites** (login walls, CAPTCHAs, anti-scraping): use remote mode
|
|
53
|
+
- **If local mode fails** with bot detection or access denied: switch to remote mode
|
|
54
|
+
|
|
55
|
+
## Commands
|
|
56
|
+
|
|
57
|
+
Most driver commands work across local, remote, and CDP sessions after the daemon starts.
|
|
58
|
+
|
|
59
|
+
### Navigation
|
|
60
|
+
```bash
|
|
61
|
+
browse open <url> # Go to URL
|
|
62
|
+
browse open <url> --local # Go to URL in a clean local browser
|
|
63
|
+
browse open <url> --remote # Go to URL in a Browserbase session
|
|
64
|
+
browse reload # Reload current page
|
|
65
|
+
browse back # Go back in history
|
|
66
|
+
browse forward # Go forward in history
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
### Page state (prefer snapshot over screenshot)
|
|
70
|
+
```bash
|
|
71
|
+
browse snapshot # Get accessibility tree with element refs (fast, structured)
|
|
72
|
+
browse screenshot --path <path> # Take visual screenshot (slow, uses vision tokens)
|
|
73
|
+
browse get url # Get current URL
|
|
74
|
+
browse get title # Get page title
|
|
75
|
+
browse get text <selector> # Get text content (use "body" for all text)
|
|
76
|
+
browse get html <selector> # Get HTML content of element
|
|
77
|
+
browse get value <selector> # Get form field value
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
Use `browse snapshot` as your default for understanding page state — it returns the accessibility tree with element refs you can use to interact. Only use `browse screenshot` when you need visual context (layout, images, debugging).
|
|
81
|
+
|
|
82
|
+
### Interaction
|
|
83
|
+
```bash
|
|
84
|
+
browse click <ref> # Click element by ref from snapshot (e.g., @0-5)
|
|
85
|
+
browse type <text> # Type text into focused element
|
|
86
|
+
browse fill <selector> <value> # Fill input; add --press-enter if Enter is needed
|
|
87
|
+
browse select <selector> <values...> # Select dropdown option(s)
|
|
88
|
+
browse press <key> # Press key (Enter, Tab, Escape, Cmd+A, etc.)
|
|
89
|
+
browse mouse drag <fromX> <fromY> <toX> <toY> # Drag from one point to another
|
|
90
|
+
browse mouse scroll <x> <y> <deltaX> <deltaY> # Scroll at coordinates
|
|
91
|
+
browse highlight <selector> # Highlight element on page
|
|
92
|
+
browse is visible <selector> # Check if element is visible
|
|
93
|
+
browse is checked <selector> # Check if element is checked
|
|
94
|
+
browse wait <type> [arg] # Wait for: load, selector, timeout
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
### Session management
|
|
98
|
+
```bash
|
|
99
|
+
browse stop # Stop the browser daemon
|
|
100
|
+
browse status # Check daemon status and resolved mode
|
|
101
|
+
browse tab list # List all open tabs
|
|
102
|
+
browse tab switch <index-or-target-id> # Switch to tab by index or target ID
|
|
103
|
+
browse tab close [index-or-target-id] # Close tab
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
### Typical workflow
|
|
107
|
+
If the environment matters, put `--local`, `--remote`, `--auto-connect`, or `--cdp <port|url>` on the first browser command.
|
|
108
|
+
|
|
109
|
+
1. `browse open <url> --local` or `browse open <url> --remote` — navigate to the page
|
|
110
|
+
2. `browse snapshot` — read the accessibility tree to understand page structure and get element refs
|
|
111
|
+
3. `browse click <ref>` / `browse type <text>` / `browse fill <selector> <value>` — interact using refs from snapshot
|
|
112
|
+
4. `browse snapshot` — confirm the action worked
|
|
113
|
+
5. Repeat 3-4 as needed
|
|
114
|
+
6. `browse stop` — close the browser when done
|
|
115
|
+
|
|
116
|
+
## Quick Example
|
|
117
|
+
|
|
118
|
+
```bash
|
|
119
|
+
browse open https://example.com
|
|
120
|
+
browse snapshot # see page structure + element refs
|
|
121
|
+
browse click @0-5 # click element with ref 0-5
|
|
122
|
+
browse get title
|
|
123
|
+
browse stop
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
## Mode Comparison
|
|
127
|
+
|
|
128
|
+
| Feature | Local | Browserbase |
|
|
129
|
+
|---------|-------|-------------|
|
|
130
|
+
| Speed | Faster | Slightly slower |
|
|
131
|
+
| Setup | Chrome required | API key required |
|
|
132
|
+
| Reuse existing local cookies | With `browse open <url> --auto-connect` | N/A |
|
|
133
|
+
| Verified browser | No | Yes (Browserbase Verified browser via Identity) |
|
|
134
|
+
| CAPTCHA solving | No | Yes (automatic reCAPTCHA/hCaptcha) |
|
|
135
|
+
| Residential proxies | No | Yes (201 countries, geo-targeting) |
|
|
136
|
+
| Session persistence | No | Yes (cookies/auth persist via contexts) |
|
|
137
|
+
| Best for | Development/simple pages | Protected sites, Browserbase Identity + Verified access, production scraping |
|
|
138
|
+
|
|
139
|
+
## Best Practices
|
|
140
|
+
|
|
141
|
+
1. **Choose the local strategy deliberately**: use `browse open <url> --local` for clean state, `browse open <url> --auto-connect` for existing local credentials, and `browse open <url> --remote` for protected sites
|
|
142
|
+
2. **Always `browse open` first** before interacting
|
|
143
|
+
3. **Use `browse snapshot`** to check page state — it's fast and gives you element refs
|
|
144
|
+
4. **Only screenshot when visual context is needed** (layout checks, images, debugging)
|
|
145
|
+
5. **Use refs from snapshot** to click/interact — e.g., `browse click @0-5`
|
|
146
|
+
6. **`browse stop`** when done to clean up the browser session and clear the env override
|
|
147
|
+
|
|
148
|
+
## Troubleshooting
|
|
149
|
+
|
|
150
|
+
- **"No active page"**: Run `browse stop`, then check `browse status`. If it still says running, kill the zombie daemon with `pkill -f "browse.*daemon"`, then retry `browse open`
|
|
151
|
+
- **Chrome not found**: Install Chrome, use `browse open <url> --auto-connect` if you already have a debuggable Chrome running, or switch to `browse open <url> --remote`
|
|
152
|
+
- **Action fails**: Run `browse snapshot` to see available elements and their refs
|
|
153
|
+
- **Browserbase fails**: Verify API key is set
|
|
154
|
+
|
|
155
|
+
## Switching to Remote Mode
|
|
156
|
+
|
|
157
|
+
Switch to remote when you detect: CAPTCHAs (reCAPTCHA, hCaptcha, Turnstile), bot detection pages ("Checking your browser..."), HTTP 403/429, empty pages on sites that should have content, or the user asks for it.
|
|
158
|
+
|
|
159
|
+
Don't switch for simple sites (docs, wikis, public APIs, localhost).
|
|
160
|
+
|
|
161
|
+
```bash
|
|
162
|
+
browse open <url> --local # clean isolated local browser
|
|
163
|
+
browse open <url> --auto-connect # attach to existing debuggable Chrome
|
|
164
|
+
browse open <url> --remote # Browserbase session
|
|
165
|
+
```
|
|
166
|
+
|
|
167
|
+
Mode flags are applied when a session starts. After `browse stop`, the next start falls back to env-var-based auto detection. Use `browse status` to inspect the resolved mode and target while the daemon is running.
|
|
168
|
+
|
|
169
|
+
For detailed examples, see [EXAMPLES.md](EXAMPLES.md).
|
|
170
|
+
For API reference, see [REFERENCE.md](REFERENCE.md).
|
|
@@ -20,7 +20,7 @@ Use this skill when the parent orchestrator needs to launch a specialized subage
|
|
|
20
20
|
- **Parallel codebase discovery**: combine `codebase-locator`, `codebase-analyzer`, and `codebase-pattern-finder` to map where code lives, how it works, and what existing conventions look like — concurrently, with fresh context per child.
|
|
21
21
|
- **Local research mining**: pair `codebase-research-locator` with `codebase-research-analyzer` to surface prior decisions in `research/` and `specs/` and extract what still applies.
|
|
22
22
|
- **External research**: use `codebase-online-researcher` for authoritative web sources, with persisted findings in `research/web/`.
|
|
23
|
-
- **Debug and fix**: use `debugger` to reproduce, diagnose, and patch failing behavior with `tdd` and `browser
|
|
23
|
+
- **Debug and fix**: use `debugger` to reproduce, diagnose, and patch failing behavior with `tdd` and `browser` support.
|
|
24
24
|
- **Refinement**: use `code-simplifier` to clean up recently changed code without altering behavior.
|
|
25
25
|
- **Adversarial review**: compose read-only specialists (`codebase-analyzer`, `codebase-pattern-finder`, `debugger` in inspect-only mode, `codebase-online-researcher`) into a parallel review pass — there is no generic `reviewer` agent.
|
|
26
26
|
- **Long-running work**: launch async/background runs and inspect them later.
|
|
@@ -158,9 +158,9 @@ Builtin agents load at the lowest priority. Project agents override user agents,
|
|
|
158
158
|
| `codebase-pattern-finder` | Find similar implementations or conventions | `openai/gpt-5.4-mini` | low | read, grep, find, ls, bash | Read-only. Returns code snippets with `file:line` references. |
|
|
159
159
|
| `codebase-research-locator` | Discover prior `research/` and `specs/` docs | `openai/gpt-5.4-mini` | low | read, grep, find, ls, bash | Read-only. Sorts by date, tiers by recency, flags supersession. |
|
|
160
160
|
| `codebase-research-analyzer` | Extract decisions and constraints from prior docs | `openai/gpt-5.5` | low | read, grep, find, ls, bash | Read-only. Filters aggressively for what still applies today. |
|
|
161
|
-
| `codebase-online-researcher` | Web research with authoritative sources | `openai/gpt-5.5` | low | read, grep, find, ls, bash, write, web_search, fetch_content, get_search_content | Has the `browser
|
|
161
|
+
| `codebase-online-researcher` | Web research with authoritative sources | `openai/gpt-5.5` | low | read, grep, find, ls, bash, write, web_search, fetch_content, get_search_content | Has the `browser` skill. Persists keepers to `research/web/`. |
|
|
162
162
|
| `code-simplifier` | Clean up recently changed code without changing behavior | `openai/gpt-5.5` | low | read, edit, write, grep, find, ls, bash | **Writer.** Scopes to recently modified code by default; preserves all observable behavior. |
|
|
163
|
-
| `debugger` | Reproduce, diagnose, and fix failing behavior | `openai/gpt-5.5` | high | read, edit, write, grep, find, ls, bash, web_search, fetch_content, get_search_content | **Writer.** Has the `tdd` and `browser
|
|
163
|
+
| `debugger` | Reproduce, diagnose, and fix failing behavior | `openai/gpt-5.5` | high | read, edit, write, grep, find, ls, bash, web_search, fetch_content, get_search_content | **Writer.** Has the `tdd` and `browser` skills. Inspect-only mode requires an explicit instruction. |
|
|
164
164
|
|
|
165
165
|
Each builtin declares an explicit `model` and `fallbackModels` chain (typically `github-copilot/<same>`, then `anthropic/claude-opus-4-8`, then `github-copilot/claude-opus-4.7`). The current user-selected model is automatically appended as the last fallback and de-duplicated. Override per run with inline config:
|
|
166
166
|
|
|
@@ -186,7 +186,7 @@ A strong subagent prompt usually includes:
|
|
|
186
186
|
- **Output**: the expected summary shape, artifact path, or finding format.
|
|
187
187
|
- **Stop rules**: when to stop after enough evidence, and when not to keep searching.
|
|
188
188
|
|
|
189
|
-
Avoid carrying over old prompt habits that over-specify every step. Use `must`, `always`, and `never` for real invariants; for judgment calls, give decision rules. For example, tell `codebase-analyzer` to trace the staged diff directly and report only evidence-backed findings, rather than prescribing every file or command. Tell `codebase-online-researcher` the retrieval budget: start with broad targeted searches, fetch the strongest sources via `fetch_content`, fall back to `browser
|
|
189
|
+
Avoid carrying over old prompt habits that over-specify every step. Use `must`, `always`, and `never` for real invariants; for judgment calls, give decision rules. For example, tell `codebase-analyzer` to trace the staged diff directly and report only evidence-backed findings, rather than prescribing every file or command. Tell `codebase-online-researcher` the retrieval budget: start with broad targeted searches, fetch the strongest sources via `fetch_content`, fall back to `browser` only when JS execution is required, and stop when the question is answered.
|
|
190
190
|
|
|
191
191
|
For implementation handoffs to `debugger` or `code-simplifier`, name the approved scope and success criteria more clearly than the process. Good prompts say what to change, what not to change, where the evidence lives, how to validate, and when to escalate. They should not ask the child to create another subagent plan or continue the parent conversation.
|
|
192
192
|
|
|
@@ -4,6 +4,18 @@ All notable changes to this project will be documented in this file.
|
|
|
4
4
|
|
|
5
5
|
## [Unreleased]
|
|
6
6
|
|
|
7
|
+
## [0.8.26-alpha.8] - 2026-06-07
|
|
8
|
+
|
|
9
|
+
### Changed
|
|
10
|
+
|
|
11
|
+
- Bumped package version for the Atomic 0.8.26-alpha.8 prerelease.
|
|
12
|
+
|
|
13
|
+
## [0.8.26-alpha.7] - 2026-06-07
|
|
14
|
+
|
|
15
|
+
### Changed
|
|
16
|
+
|
|
17
|
+
- Bumped package version for the Atomic 0.8.26-alpha.7 prerelease.
|
|
18
|
+
|
|
7
19
|
## [0.8.26-alpha.6] - 2026-06-06
|
|
8
20
|
|
|
9
21
|
### Changed
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bastani/web-access",
|
|
3
|
-
"version": "0.8.26-alpha.
|
|
3
|
+
"version": "0.8.26-alpha.8",
|
|
4
4
|
"private": true,
|
|
5
5
|
"description": "Atomic extension for web search, URL fetching, GitHub repo cloning, PDF/video extraction. Fork of: https://github.com/nicobailon/pi-web-access",
|
|
6
6
|
"contributors": [
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
},
|
|
31
31
|
"peerDependencies": {
|
|
32
32
|
"@bastani/atomic": "*",
|
|
33
|
-
"@earendil-works/pi-tui": "
|
|
33
|
+
"@earendil-works/pi-tui": "^0.78.1"
|
|
34
34
|
},
|
|
35
35
|
"peerDependenciesMeta": {
|
|
36
36
|
"@bastani/atomic": {
|