WebBrain is an open-source browser extension (GPL-3.0-or-later) that embeds an AI agent in a side panel for Chrome, Firefox, and Edge, enabling users to chat with pages, automate tasks, and execute multi-step workflows using local or cloud LLMs. It supports three permission modes: Ask (read-only), Act (click, type, navigate, upload, download, fill forms), and Dev (adds page source, styles, console, network, and reversible edits), with automatic or manual mode selection via /ask, /act, /dev prefixes. The agent reads pages via the accessibility tree, handles PDFs and interactive elements, and offers a Vision ("Tesla") mode that operates on screenshots with coordinate-based actions, sending only changed screen regions. It runs on a user-chosen backend: local llama.cpp (llama-server), Ollama, vLLM, SGLang, LM Studio, Osaurus, Jan, LocalAI, GPT4All, Rapid-MLX, Unsloth Studio, or a generic OpenAI-compatible proxy, plus 151 built-in cloud provider cards (OpenAI, Anthropic, Google Gemini, Azure, AWS Bedrock, Mistral, DeepSeek, xAI, Groq, Together, Cloudflare, Nvidia NIM, Hugging Face, Fireworks, OpenRouter, etc.) and an experimental local WebGPU option with LFM2.5 2.6B. Tier settings (Compact, Mid, Full) control tool exposure per provider; Compact suits small local models, Full unlocks hover, drag-drop, frames, and shadow DOM. Features include Plan-before-Act with approval, autonomous loops up to 195 steps (default 130), saved workflows, scheduled tasks (/schedule), page watches (/watch polling 30–120s), skills, smart context with auto-compaction, per-tab conversations, optional cross-device recall via MemCode, and deterministic temperatures (0.15 for control, 0.3 for Ask, 0 for vision). A Companion desktop app manages local models (default endpoint http://127.0.0.1:8327/v1). An MCP server (npx -y @webbrain/mcp-server on ws://127.0.0.1:17374) lets Claude Code, Codex, Cursor, OpenClaw, and DeepSeek Harness delegate browser tasks to the user's authenticated session, with HMAC pairing-key authentication. Firefox build lacks CDP capabilities (no shadow-DOM piercing, trusted events, full-page capture). Architecture is shared across Manifest V3 (Chrome) and Manifest V2 (Firefox) builds.
Read original
hackernews