Environment
-OS:Cross-platform (Linux / macOS / Windows)
-Runtime:Node.js v20.x / Standalone Binary
-atomic-agent version:** v0.4.x (main branch)
-Model Provider / Backend:** Ollama / llama.cpp / Anthropic API
Summary
When the agent invokes the browser.inspect tool on web pages with dense or dynamic DOM structures (e.g., complex dashboards, Webpack single-page apps, or heavily nested modern frameworks), the tool returns raw or insufficiently sanitized HTML snapshot trees.
This injects tens of thousands of redundant tokens (CSS styles, SVG paths, data attributes, hidden script tags) directly into the agent's context window. On local models with smaller context limits (e.g., 8k–16k tokens), this instantly causes context window overflow and causes the agent loop to crash or lose earlier prompt instructions.
Steps to Reproduce
- Run
atomic-agent and instruct it to inspect or interact with a heavy web page:
atomic-agent run "Go to [github.com/trending](https://github.com/trending) and give me the top 5 repository descriptions."
Environment
-OS:Cross-platform (Linux / macOS / Windows)
-Runtime:Node.js v20.x / Standalone Binary
-atomic-agent version:**
v0.4.x(main branch)-Model Provider / Backend:** Ollama / llama.cpp / Anthropic API
Summary
When the agent invokes the
browser.inspecttool on web pages with dense or dynamic DOM structures (e.g., complex dashboards, Webpack single-page apps, or heavily nested modern frameworks), the tool returns raw or insufficiently sanitized HTML snapshot trees.This injects tens of thousands of redundant tokens (CSS styles, SVG paths, data attributes, hidden script tags) directly into the agent's context window. On local models with smaller context limits (e.g., 8k–16k tokens), this instantly causes context window overflow and causes the agent loop to crash or lose earlier prompt instructions.
Steps to Reproduce
atomic-agentand instruct it to inspect or interact with a heavy web page:atomic-agent run "Go to [github.com/trending](https://github.com/trending) and give me the top 5 repository descriptions."