pi-browser-use 0.10.1 → 0.11.1
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/dist/annotate.d.ts +0 -14
- package/dist/annotate.js +0 -14
- package/dist/artifacts.d.ts +0 -2
- package/dist/artifacts.js +0 -2
- package/dist/auth-verifiers.d.ts +0 -29
- package/dist/auth-verifiers.js +0 -31
- package/dist/chrome-launcher.d.ts +0 -59
- package/dist/chrome-launcher.js +1 -55
- package/dist/client.d.ts +0 -4
- package/dist/client.js +0 -17
- package/dist/config.d.ts +0 -25
- package/dist/config.js +0 -23
- package/dist/doctor.d.ts +0 -8
- package/dist/doctor.js +0 -5
- package/dist/existing-flow.d.ts +0 -31
- package/dist/existing-flow.js +0 -29
- package/dist/focus-policy.d.ts +0 -13
- package/dist/focus-policy.js +0 -13
- package/dist/index.d.ts +0 -1
- package/dist/index.js +0 -1
- package/dist/mcp-server.d.ts +0 -2
- package/dist/mcp-server.js +0 -10
- package/dist/named-profile.d.ts +0 -36
- package/dist/named-profile.js +0 -37
- package/dist/persistent-backend.d.ts +2 -56
- package/dist/persistent-backend.js +30 -65
- package/dist/persistent-store.d.ts +0 -24
- package/dist/persistent-store.js +0 -24
- package/dist/profile-lock.d.ts +0 -21
- package/dist/profile-lock.js +0 -27
- package/dist/profile.d.ts +0 -10
- package/dist/profile.js +0 -14
- package/dist/runtime.d.ts +0 -3
- package/dist/runtime.js +3 -92
- package/dist/session-manager.d.ts +0 -48
- package/dist/session-manager.js +0 -46
- package/dist/session.d.ts +0 -42
- package/dist/session.js +0 -18
- package/dist/settings.d.ts +0 -5
- package/dist/settings.js +0 -5
- package/dist/setup-flow.d.ts +0 -41
- package/dist/setup-flow.js +0 -37
- package/dist/shared-backend.d.ts +0 -30
- package/dist/shared-backend.js +0 -31
- package/dist/tab-bridge.d.ts +0 -27
- package/dist/tab-bridge.js +0 -27
- package/dist/tool-augment.d.ts +0 -9
- package/dist/tool-augment.js +0 -14
- package/dist/vision.d.ts +0 -17
- package/dist/vision.js +0 -17
- package/docs/performance.md +14 -0
- package/extension/README.md +2 -0
- package/extension/background.js +4 -9
- package/package.json +4 -2
- package/plugin.json +1 -1
package/docs/performance.md
CHANGED
|
@@ -41,6 +41,8 @@ Budgets live in [`performance-budgets.json`](../performance-budgets.json). They
|
|
|
41
41
|
| Published map files | 0 |
|
|
42
42
|
| Production dependency closure | 140 packages |
|
|
43
43
|
|
|
44
|
+
The published artifact stays byte-lean by design: `tsconfig.json` sets `removeComments` so emitted JavaScript and declarations carry no comment bytes, and build maps never ship. Source commentary lives in the repository, not in the installed package.
|
|
45
|
+
|
|
44
46
|
## Reproduce locally and in CI
|
|
45
47
|
|
|
46
48
|
```sh
|
|
@@ -57,3 +59,15 @@ npm run bench -- --startup-only --json
|
|
|
57
59
|
```
|
|
58
60
|
|
|
59
61
|
`perf:audit` and `bench --json` are suitable for machine capture. Use at least seven cold imports and ten runtime iterations when updating the table. Record Node, OS, architecture, commit, and whether Chrome was headless; do not compare results collected with different modes or iteration counts.
|
|
62
|
+
|
|
63
|
+
## Task-level evaluation
|
|
64
|
+
|
|
65
|
+
`npm run eval -- --json` runs deterministic browser tasks against fixed DOM fixtures in a fresh isolated session. Each task attempt gets its own runtime and records objective checks, startup/task/step timings, bounded failure text, evidence-capture error counts, and artifact paths in `eval-results/result.json`. Failed attempts save a screenshot by default; use `--evidence all` to capture evidence after every successful step or `--evidence none` to disable it. Failures are classified as `harness` (the browser environment never became usable: startup failed, no step succeeded, or cleanup broke) or `task` (the scenario regressed), and the summary reports `harnessFailures` separately so a broken browser environment is not mistaken for task regressions. Unknown CLI options are rejected. The report contract is documented in [Eval result schema](eval-results.md), including the `eval-budgets.json` gate that mirrors the Code Foundry eval contract.
|
|
66
|
+
|
|
67
|
+
```sh
|
|
68
|
+
npm run eval -- --iterations 3 --json
|
|
69
|
+
npm run eval -- --task form-submit,extract-list --evidence all
|
|
70
|
+
npm run eval -- --list
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
These tasks evaluate runtime and browser-tool behavior, not model quality. Keep them deterministic and network-free for local/CI regression checks. Model-agent evaluations should use the same task IDs and metadata but run in a separate harness, with the model, prompt, reasoning budget, dependency hash, and retry policy recorded. Do not silently truncate normal browser results; bounded evidence is only for judge-facing output.
|
package/extension/README.md
CHANGED
|
@@ -17,6 +17,8 @@ default, override via `tabBridgePort` in `pi-browser-use` settings plus the
|
|
|
17
17
|
extension's stored `piBridgeUrl`) for open-tab requests, creates each tab
|
|
18
18
|
inactive in the `pi-browser-use` group, keeps the group collapsed, and
|
|
19
19
|
reports back per-token so Pi selects the exact tab — never by URL matching.
|
|
20
|
+
Polling is event-driven plus a one-minute alarm; it does not run a persistent
|
|
21
|
+
timer that can keep Chrome alive after its windows are closed.
|
|
20
22
|
|
|
21
23
|
## Permissions
|
|
22
24
|
|
package/extension/background.js
CHANGED
|
@@ -112,7 +112,6 @@ chrome.runtime.onMessage.addListener((message, _sender, sendResponse) => {
|
|
|
112
112
|
* The bridge URL override lives in local storage (default loopback port).
|
|
113
113
|
*/
|
|
114
114
|
const PI_BRIDGE_DEFAULT_URL = 'http://127.0.0.1:31973'
|
|
115
|
-
const PI_BRIDGE_POLL_MS = 2000
|
|
116
115
|
let piBridgeUrlOverride = null
|
|
117
116
|
|
|
118
117
|
try {
|
|
@@ -163,15 +162,11 @@ async function pollBridgeOnce() {
|
|
|
163
162
|
}
|
|
164
163
|
}
|
|
165
164
|
|
|
166
|
-
setInterval(() => {
|
|
167
|
-
void pollBridgeOnce().catch(() => {})
|
|
168
|
-
}, PI_BRIDGE_POLL_MS)
|
|
169
|
-
|
|
170
165
|
/**
|
|
171
|
-
* MV3 service workers are short-lived
|
|
172
|
-
*
|
|
173
|
-
*
|
|
174
|
-
* every minute (safe floor for the alarm cadence). Re-created on every
|
|
166
|
+
* MV3 service workers are short-lived, and a persistent timer can keep Chrome
|
|
167
|
+
* alive after the user closes its windows. Use an alarm instead: it wakes a
|
|
168
|
+
* suspended worker without holding the browser open, and guarantees a poll at
|
|
169
|
+
* least every minute (safe floor for the alarm cadence). Re-created on every
|
|
175
170
|
* startup since alarm persistence across restarts is not guaranteed.
|
|
176
171
|
*/
|
|
177
172
|
const PI_BRIDGE_ALARM = 'pi-bridge-poll'
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pi-browser-use",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.11.1",
|
|
4
4
|
"description": "Opinionated browser automation via chrome-devtools-mcp: native Pi extension and portable Agent Plugins 1.0 skills + MCP server.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"automation",
|
|
@@ -54,6 +54,8 @@
|
|
|
54
54
|
"typecheck": "tsc -p tsconfig.json --noEmit",
|
|
55
55
|
"prepublishOnly": "npm run build",
|
|
56
56
|
"bench": "node scripts/bench.mjs",
|
|
57
|
+
"eval": "node scripts/eval.mjs",
|
|
58
|
+
"preeval": "npm run build",
|
|
57
59
|
"test": "node --test test/*.test.mjs",
|
|
58
60
|
"preperf:audit": "npm run build",
|
|
59
61
|
"perf:audit": "node scripts/performance.mjs",
|
|
@@ -73,7 +75,7 @@
|
|
|
73
75
|
"@types/node": "^22.0.0",
|
|
74
76
|
"oxfmt": "^0.66.0",
|
|
75
77
|
"oxlint": "^1.81.0",
|
|
76
|
-
"typescript": "^
|
|
78
|
+
"typescript": "^6.0.3"
|
|
77
79
|
},
|
|
78
80
|
"peerDependencies": {
|
|
79
81
|
"@earendil-works/pi-ai": ">=0.80.10",
|
package/plugin.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://agent-plugins.org/schemas/1.0.0/plugin.schema.json",
|
|
3
3
|
"name": "pi-browser-use",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.11.1",
|
|
5
5
|
"description": "Managed persistent, fresh, and existing Chrome sessions with focus-safe browser tools and CLI-first skills.",
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "0xPlayerOne"
|