diff --git a/strix/agents/prompts/system_prompt.jinja b/strix/agents/prompts/system_prompt.jinja index 6763f9d8..23493d2d 100644 --- a/strix/agents/prompts/system_prompt.jinja +++ b/strix/agents/prompts/system_prompt.jinja @@ -264,11 +264,12 @@ Remember: A single well-validated high-impact vulnerability is worth more than d AGENT ISOLATION & SANDBOXING: - All agents run in the same shared Docker container for efficiency - Each agent has its own terminal sessions -- Browsers are NOT per-agent: `agent-browser` shares one browser across every agent - using the default session, so another agent may be driving it. Pass - `--session ` only when you genuinely need an isolated browser (separate - cookies/logins, e.g. testing two users at once) — each one costs a full Chromium - (~340 MB) on the shared box, and `close` it as soon as you're done with it +- Browsers are NOT per-agent by default: `agent-browser` with no `--session` is one + shared browser, so a concurrent agent's navigation invalidates your page and refs. + Pass `--session ` for any browser work of your own — then it is + yours alone. Each session is a full Chromium (~340 MB) on this shared box, so keep + one, not several, and `agent-browser --session close` when you're done with + the target; an idle browser is reclaimed automatically after 3 minutes - All agents share the same /workspace directory and proxy history - Agents can see each other's files and proxy traffic for better collaboration diff --git a/strix/skills/tooling/agent_browser.md b/strix/skills/tooling/agent_browser.md index bcacf37a..bceac552 100644 --- a/strix/skills/tooling/agent_browser.md +++ b/strix/skills/tooling/agent_browser.md @@ -58,13 +58,17 @@ agent-browser screenshot The browser stays running across commands so these feel like a single session. Use `agent-browser close` (or `close --all`) when you're done. -The default session is **shared with every other agent in the sandbox**, and each -extra `--session ` is a whole extra Chromium (~340 MB) on a box you share — -so open one only when you need isolated cookies, and close it when you're done. -A browser left idle for 3 minutes is reclaimed automatically; the next command -relaunches it, but the page, tabs, refs and cookies are gone. If you're -authenticated and about to go do something else for a while, save the state -first (see [Persist session across runs](#persist-session-across-runs)). +The default session is **shared with every other agent in the sandbox** — if +another agent navigates it, your page and your refs are gone from under you. Use +`--session ` for your own browser work so nobody else can move +it. Each session is a separate Chromium (~340 MB) on a shared box, so keep one +rather than several, and close it when you're finished with the target. + +A browser left idle for 3 minutes is reclaimed automatically to free memory for +the other agents; the next command relaunches it, but the page, tabs, refs and +cookies are gone. If you're authenticated and about to go do something else for a +while, save the state first (see +[Persist session across runs](#persist-session-across-runs)). ## Reading a page @@ -315,9 +319,10 @@ agent-browser --session b fill @e1 "bob@test.com" `AGENT_BROWSER_SESSION=myapp` sets the default session for the current shell. -Every session is a separate Chromium, so this is the most expensive thing you can -do to the shared sandbox — use it for genuine isolation (two users, two cookie -jars), not as a habit, and close each one when the flow is finished: +Use a session named after yourself for your own work — that's what keeps a +concurrent agent from navigating the page out from under you. Every session is a +separate Chromium though, so hold one at a time rather than a collection, and +close each one when its flow is finished: ```bash agent-browser --session a close