browser-pilot 0.0.15 → 0.0.17
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/README.md +38 -3
- package/dist/actions.cjs +848 -105
- package/dist/actions.d.cts +101 -4
- package/dist/actions.d.ts +101 -4
- package/dist/actions.mjs +17 -1
- package/dist/{browser-MEWT75IB.mjs → browser-4ZHNAQR5.mjs} +2 -2
- package/dist/browser.cjs +1684 -130
- package/dist/browser.d.cts +230 -6
- package/dist/browser.d.ts +230 -6
- package/dist/browser.mjs +37 -5
- package/dist/chunk-EZNZ72VA.mjs +563 -0
- package/dist/{chunk-ZAXQ5OTV.mjs → chunk-FEEGNSHB.mjs} +606 -12
- package/dist/{chunk-WPNW23CE.mjs → chunk-IRLHCVNH.mjs} +345 -7
- package/dist/chunk-MIJ7UIKB.mjs +96 -0
- package/dist/{chunk-USYSHCI3.mjs → chunk-MRY3HRFJ.mjs} +841 -370
- package/dist/chunk-OIHU7OFY.mjs +91 -0
- package/dist/{chunk-7YVCOL2W.mjs → chunk-ZDODXEBD.mjs} +637 -105
- package/dist/cli.mjs +1280 -549
- package/dist/combobox-RAKBA2BW.mjs +6 -0
- package/dist/index.cjs +1976 -144
- package/dist/index.d.cts +57 -6
- package/dist/index.d.ts +57 -6
- package/dist/index.mjs +206 -7
- package/dist/{page-XPS6IC6V.mjs → page-SD64DY3F.mjs} +1 -1
- package/dist/providers.cjs +637 -2
- package/dist/providers.d.cts +2 -2
- package/dist/providers.d.ts +2 -2
- package/dist/providers.mjs +17 -3
- package/dist/{types-Cvvf0oGu.d.ts → types-B_v62K7C.d.ts} +147 -3
- package/dist/types-DeVSWhXj.d.cts +142 -0
- package/dist/types-DeVSWhXj.d.ts +142 -0
- package/dist/{types-C9ySEdOX.d.cts → types-Yuybzq53.d.cts} +147 -3
- package/dist/upload-E6MCC2OF.mjs +6 -0
- package/package.json +10 -3
- package/dist/chunk-BRAFQUMG.mjs +0 -229
- package/dist/types--wXNHUwt.d.cts +0 -56
- package/dist/types--wXNHUwt.d.ts +0 -56
package/README.md
CHANGED
|
@@ -12,6 +12,7 @@ Browser Pilot now teaches one workflow model:
|
|
|
12
12
|
|
|
13
13
|
- inspect the page
|
|
14
14
|
- act in the browser
|
|
15
|
+
- review structured business state
|
|
15
16
|
- record a manual workflow
|
|
16
17
|
- trace behavior over time
|
|
17
18
|
- exercise voice/media and browser conditions
|
|
@@ -26,7 +27,20 @@ bun add browser-pilot
|
|
|
26
27
|
npm install browser-pilot
|
|
27
28
|
```
|
|
28
29
|
|
|
29
|
-
For local Chrome
|
|
30
|
+
For local Chrome on Chrome 144+:
|
|
31
|
+
|
|
32
|
+
```bash
|
|
33
|
+
# 1. Start Chrome normally
|
|
34
|
+
# 2. Open chrome://inspect/#remote-debugging
|
|
35
|
+
# 3. Enable remote debugging, then run:
|
|
36
|
+
bp connect
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
Tip: try plain `bp connect` first. Only add `--channel` or `--user-data-dir` if auto-discovery finds more than one eligible profile.
|
|
40
|
+
|
|
41
|
+
Use `bp connect --channel beta` or `bp connect --user-data-dir <path>` when more than one Chrome profile is eligible.
|
|
42
|
+
|
|
43
|
+
Legacy/manual fallback still works with a separate debug profile:
|
|
30
44
|
|
|
31
45
|
```bash
|
|
32
46
|
/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome \
|
|
@@ -39,16 +53,22 @@ For local Chrome:
|
|
|
39
53
|
| Job | Primary commands |
|
|
40
54
|
| --- | --- |
|
|
41
55
|
| Inspect page state | `snapshot`, `page`, `forms`, `text`, `targets`, `diagnose` |
|
|
56
|
+
| Review structured state | `review` |
|
|
42
57
|
| Act in the browser | `exec`, `run` |
|
|
43
58
|
| Capture a human demo | `record` |
|
|
44
59
|
| Investigate behavior over time | `trace` |
|
|
45
60
|
| Exercise voice/media | `audio` |
|
|
46
61
|
| Change browser conditions | `env` |
|
|
47
62
|
|
|
63
|
+
Start with `bp --help` to see the routed command tree and `bp --version` to confirm the CLI build.
|
|
64
|
+
|
|
65
|
+
Use `bp snapshot -i` to find clickable/fillable refs, `bp text` for long-form copy, `bp review` for structured business outcomes, and `bp diagnose` when targeting fails. Use `bp eval` only as an escape hatch.
|
|
66
|
+
|
|
48
67
|
## Golden path 1: automate a page
|
|
49
68
|
|
|
50
69
|
```bash
|
|
51
|
-
bp connect --
|
|
70
|
+
bp connect --name dev
|
|
71
|
+
bp exec -s dev '{"action":"goto","url":"https://example.com"}'
|
|
52
72
|
bp snapshot -i -s dev
|
|
53
73
|
bp exec -s dev '[
|
|
54
74
|
{"action":"fill","selector":"ref:e5","value":"user@example.com"},
|
|
@@ -59,6 +79,21 @@ bp exec -s dev '[
|
|
|
59
79
|
|
|
60
80
|
Use `bp snapshot -i` first. Refs are the default targeting strategy.
|
|
61
81
|
|
|
82
|
+
For reading or verification after actions:
|
|
83
|
+
|
|
84
|
+
```bash
|
|
85
|
+
bp text -s dev --selector main
|
|
86
|
+
bp review -s dev --json
|
|
87
|
+
bp diagnose -s dev 'submit'
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
Best practices from real usage:
|
|
91
|
+
|
|
92
|
+
- `bp page` is a compact overview. It caches the refs it shows, but use `bp snapshot -i` when you need the full actionable list.
|
|
93
|
+
- On commerce and content-heavy sites, scope reading with `bp text --selector main` to avoid nav, drawers, and footer noise.
|
|
94
|
+
- `bp review` works best on confirmations, detail pages, tables, alerts, and key-value layouts. It is usually the wrong first read on catalog grids.
|
|
95
|
+
- After `bp trace start`, begin with `bp trace summary --view session` before narrower views like `console` or `ws`.
|
|
96
|
+
|
|
62
97
|
## Golden path 2: capture a manual workflow and derive automation
|
|
63
98
|
|
|
64
99
|
```bash
|
|
@@ -74,7 +109,7 @@ Do not start by opening the raw artifact. Use `record summary`, `record inspect`
|
|
|
74
109
|
## Golden path 3: debug a realtime or voice session
|
|
75
110
|
|
|
76
111
|
```bash
|
|
77
|
-
bp connect --
|
|
112
|
+
bp connect --name realtime
|
|
78
113
|
bp trace start -s realtime --timeout 20000
|
|
79
114
|
# reproduce the issue in the app
|
|
80
115
|
bp trace summary -s realtime --view ws
|