Repository navigation
v1.0.0 - Browser Extension Agent
Autonomous Browser Agent Extension
A cross-browser extension (Chrome MV3 + Firefox) that acts as an autonomous agent, navigating pages and executing actions based on user-defined goals.
Features
- Autonomous Navigation: Reads DOM, identifies interactive elements, and executes actions
- 10 LLM Providers: OpenAI, Anthropic, Google, Groq, OpenRouter, Mistral, xAI (Grok), DeepSeek, Together AI, Ollama (local)
- React + Tailwind Sidepanel UI: Styled after Claude for Chrome with Codex color palette (dark navy, emerald accents)
- Human-in-the-Loop: Confirmation prompts for sensitive actions (purchase, delete, payment)
- Loop Prevention: Max action limits and consecutive error detection
- Background Processing: Service worker handles LLM API calls without blocking UI
Playwright Integration
- Standalone Agent: Run
node src/playwright/agent.js --goal "your goal"for direct browser automation - Full DOM Control: Uses Playwright's locator API for reliable element interaction
- Screenshot Support: Capture pages during autonomous workflows
- Headless or Visible: Toggle headless mode for CI/CD pipelines
MCP Connectors
Extensible connector system for adding external tool access:
- Clipboard: Read/write clipboard content
- Screenshot: Capture visible tab screenshots
- Storage: Extension storage read/write/delete
- Filesystem: Local file operations (requires native messaging host)
- Custom Connectors: Register new connectors via the ConnectorRegistry API
Components
- Content Script: DOM serialization into simplified JSON for LLM consumption
- Background Worker: LLM orchestration, action planning, state management, and connector registry
- Sidepanel UI: Chat interface, live action log, autonomous mode toggle, and settings panel
Build
cd browser-extension-agent
npm install
npm run buildLoad the dist/ folder as an unpacked extension in Chrome or Firefox.
Playwright Usage
npx playwright install
node src/playwright/agent.js --goal "Find the cheapest flight to Tokyo"
node src/playwright/agent.js --goal "Extract all prices from this page" --headless