Skip to content

■ PEOPLE // FIELD NOTE

Magnus Muller's Event-Driven Agent Architecture

How the Browser Use co-founder built a CLAUDE.md-powered codebase and event bus system for AI browser automation

Magnus Muller's Event-Driven Agent Architecture
[!] OPERATOR DOSSIER
[!] ON THIS PAGE

Magnus Muller is a software developer and startup founder who co-created Browser Use , the open-source library that lets AI agents control web browsers. While his co-founder Gregor Zunic handles product strategy, Magnus designed the event-driven architecture and maintains the CLAUDE.md file that makes the codebase AI-navigable. The project hit 50,000 GitHub stars in three months and raised $17 million from Felicis, Paul Graham, and Y Combinator (W25 batch).

Background

  • Grew up in a small German farming town (500 people, 5000 cows)
  • BSc Cognitive Science from Osnabruck University (2020-22)
  • Exchange year at National University of Singapore (2022)
  • MSc Computer Science at ETH Zurich (2023-25, paused for Browser Use)
  • AI research at Cambridge CARES in Singapore
  • Previously co-founded GreenWAI (traffic light optimization with reinforcement learning)
  • Twitter: @mamagnus00
  • GitHub: @MagMueller

The CLAUDE.md Approach

Browser Use includes a CLAUDE.md file that gives AI assistants full context on the codebase. This file describes the architecture, code style requirements, and development workflow in a format Claude Code can consume.

From the CLAUDE.md:

# Browser-Use Library: Architecture & Development Guide

## Core Architecture
Browser-Use is an async Python 3.11+ library enabling AI agents
to autonomously navigate and interact with web pages using LLMs
and Chrome DevTools Protocol (CDP).

Key sections in the file:

SectionPurpose
Core ArchitectureMaps Agent, BrowserSession, Tools, DomService, LLM
Code StyleTabs, modern typing, Pydantic v2, service.py pattern
Development Workflowuv commands for setup, testing, quality checks
Testing PhilosophyReal instances over mocks, pytest-httpserver
Strategic DevelopmentEvent buses and job queues for isolation

This makes the codebase navigable by AI agents, not just human developers. Claude Code can understand where to make changes without extensive exploration.

Event-Driven Architecture

Magnus built bubus , a production-ready Python event bus that powers Browser Use. The library coordinates five watchdog services through async event dispatching:

  • DownloadsWatchdog - Monitors file downloads
  • PopupsWatchdog - Handles unexpected dialogs
  • SecurityWatchdog - Manages certificate warnings
  • DOMWatchdog - Tracks page state changes
  • AboutBlankWatchdog - Catches navigation failures
from browser_use import Agent, Browser
from langchain_openai import ChatOpenAI

agent = Agent(
    task="Find the cheapest flight from SF to NYC",
    llm=ChatOpenAI(model="gpt-4o"),
    browser=Browser()
)
result = await agent.run()

The agent observes, reasons, acts, then repeats. All coordination happens through the event bus, keeping components isolated and testable.

Technical decisions encoded in the architecture:

ChoiceRationale
Event busesDecouple watchdogs from main agent loop
uuid7str for IDsTime-ordered UUIDs for debugging
Pydantic v2 modelsStrict validation at boundaries
service.py patternLogic separate from data models
No mocking in testsReal instances catch real bugs

Five-Day Shipping Philosophy

Magnus advocates for rapid iteration over planning:

“Ship so much, see if it works, otherwise build something else. Just ship all the time. That’s the most important thing - don’t overthink, just ship.”

Browser Use was built in five days as an experiment. The prototype combined web scraping with LLMs to enable action-taking. Magnus and Gregor posted it to Hacker News expecting criticism. Instead, it went viral.

His development principles:

  • Five-day MVPs - If it takes longer, scope is wrong
  • Direct user testing - Walked around ETH Zurich’s main building asking students to try the tool
  • Post before you’re ready - The “really shitty” prototype became a company

Cognitive Science Background

Magnus studied cognitive science before computer science. He sees browser automation as an interface problem:

“Computers should understand what you want to do, not force you to learn their interface.”

This shapes Browser Use’s design. Instead of making users learn Selenium selectors or Playwright syntax, agents observe pages like humans do and act accordingly. The LLM handles the translation from intent to action.

Key Takeaways

PrincipleImplementation
Ship in five daysPrototype became a company
Write CLAUDE.mdMake codebase AI-navigable
Use event busesIsolate components, improve testability
Test with real usersWalk around and ask people to try it
Small-town work ethic14-hour days without complaint

Next: Jesse Vincent’s Superpowers Framework