From c86b257d386ebf0571d5cbc370ee4f97ff54cb87 Mon Sep 17 00:00:00 2001 From: Peter Steinberger Date: Thu, 15 Jan 2026 09:13:07 +0000 Subject: [PATCH] docs(tools): hint chrome extension in browser tool prompt --- ...s-claude-style-aliases-schemas-without-dropping-a.test.ts | 5 +++++ src/agents/tools/browser-tool.ts | 4 +++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/agents/pi-tools.create-clawdbot-coding-tools.adds-claude-style-aliases-schemas-without-dropping-a.test.ts b/src/agents/pi-tools.create-clawdbot-coding-tools.adds-claude-style-aliases-schemas-without-dropping-a.test.ts index ee44b2590..3d593ba0a 100644 --- a/src/agents/pi-tools.create-clawdbot-coding-tools.adds-claude-style-aliases-schemas-without-dropping-a.test.ts +++ b/src/agents/pi-tools.create-clawdbot-coding-tools.adds-claude-style-aliases-schemas-without-dropping-a.test.ts @@ -73,6 +73,11 @@ describe("createClawdbotCodingTools", () => { expect(schema.type).toBe("object"); expect(schema.anyOf).toBeUndefined(); }); + it("mentions Chrome extension relay in browser tool description", () => { + const browser = createBrowserTool(); + expect(browser.description).toMatch(/Chrome extension/i); + expect(browser.description).toMatch(/profile="chrome"/i); + }); it("keeps browser tool schema properties after normalization", () => { const tools = createClawdbotCodingTools(); const browser = tools.find((tool) => tool.name === "browser"); diff --git a/src/agents/tools/browser-tool.ts b/src/agents/tools/browser-tool.ts index 5e794fae3..4ce72285c 100644 --- a/src/agents/tools/browser-tool.ts +++ b/src/agents/tools/browser-tool.ts @@ -124,7 +124,9 @@ export function createBrowserTool(opts?: { label: "Browser", name: "browser", description: [ - "Control clawd's dedicated browser (status/start/stop/profiles/tabs/open/snapshot/screenshot/actions).", + "Control the browser via Clawdbot's browser control server (status/start/stop/profiles/tabs/open/snapshot/screenshot/actions).", + 'Profiles: use profile="chrome" for Chrome extension relay takeover (your existing Chrome tabs). Use profile="clawd" for the isolated clawd-managed browser.', + "Chrome extension relay needs an attached tab: user must click the Clawdbot Browser Relay toolbar icon on the tab (badge ON). If no tab is connected, ask them to attach it.", "Use snapshot+act for UI automation. Avoid act:wait by default; use only in exceptional cases when no reliable UI state exists.", `target selects browser location (sandbox|host|custom). Default: ${targetDefault}.`, "controlUrl implies target=custom (remote control server).",