@roll-agent/browser-use-agent 0.12.0 → 0.13.0

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/SKILL.md CHANGED
@@ -15,7 +15,7 @@ metadata:
15
15
  - 通过 Roll 调用本 Agent 时,先用 `roll skills get browser-use-agent --include-references --json` 读取当前说明和 `references/*`,再用 `roll agent tools browser-use-agent --json` 读取真实 schema。
16
16
  - 完整 `inputSchema` 以 `roll agent tools browser-use-agent --json` 为准。
17
17
  - `REPLY_AUTHORITY_URL` / `REPLY_AUTHORITY_BEARER_TOKEN` 是生成智能回复预览的必填环境变量;`REPLY_AUTHORITY_KEYS_URL` 是发送预备回复前验签的必填环境变量。`roll doctor` 会通过 `references/env.yaml` 和 `browser_status.effectiveEnvSources` 检查它们是否声明并在运行态生效。
18
- - `BROWSER_SECURITY_JSON` 可选配置浏览器硬安全策略;`browser_status.security` 会返回实际加载后的 `domainAllowlist`、`maxPageContentBytes`、`maxSnapshotNodes` 和 `actionPolicy`。Boss 日常编排建议使用 `actionPolicy:"log"`,`confirm/deny` 只作为高级调试模式。
18
+ - `BROWSER_SECURITY_JSON` 可选配置浏览器硬安全策略;`browser_status.security` 会返回实际加载后的 `domainAllowlist`、`maxPageContentBytes`、`maxSnapshotNodes`、`actionPolicy` 和 `foregroundPolicy`。`foregroundPolicy` 默认 `when-minimized`,普通后台窗口不抢桌面焦点;仅需要旧行为时才显式设为 `always`。
19
19
  - `BROWSER_USE_POLICY_JSON` 可选配置 browser-use 工具级业务策略;日常推荐只把 `zhipin_send_prepared_reply` 配为 `confirm`。
20
20
  - 长任务前或状态异常时先跑 `roll doctor --fix-plan --json`;仅对配置迁移、`agents.dataDir`、孤儿 runtime 元数据这类安全项才使用 `roll doctor --fix --json`。
21
21
  - 页内反馈默认开启:
@@ -0,0 +1,10 @@
1
+ import type { BrowserRuntime } from "@roll-agent/browser";
2
+ type ForegroundRuntime = Pick<BrowserRuntime, "getConfig" | "getNativePageWindowState">;
3
+ type ForegroundTarget = {
4
+ readonly targetId: string;
5
+ bringToFront(): Promise<void>;
6
+ };
7
+ export declare function maybeBringToFront(target: ForegroundTarget, options?: {
8
+ readonly runtime?: ForegroundRuntime;
9
+ }): Promise<void>;
10
+ export {};