browser-use agent with the Laminar debugger end to end: record a run, find the step that went wrong, and rerun from that point with the earlier LLM calls served from cache. Browser runs are slow and every rerun costs real minutes, which makes Browser Use exactly the kind of agent the debugger is built for.
1. Install prerequisites
Installuv if you do not already have it:
2. Run Laminar setup
setup logs you in, links the directory to a Laminar project, and writes LMNR_PROJECT_API_KEY to your .env file. See debugger setup for what else it does.
Add your LLM provider key to the same .env. For Claude:
Replay caching is served through Laminar’s provider integrations. With
ChatAnthropic or ChatOpenAI, cached calls on a replay run come back instantly. With other providers (including ChatBrowserUse), recording and rerunning still work, but every LLM call on a rerun goes live.3. Create the entrypoint
Instrumentation is one call:Laminar.initialize() before the agent is created. Browser Use is auto-instrumented, so every LLM step and browser action lands in the trace, along with a session recording of the browser synced to the trace.
agent.py
4. Record a run
Run the agent with debug mode on:.lmnr/debug-session.json so later runs in this directory rejoin the same session automatically. When the run finishes, the LMNR_DEBUG_RUN line carries the run’s trace_id.
5. Find the step that went wrong
Open the trace from the session view and read the transcript: each Browser Use step is an LLM turn with the actions it chose, and the synced browser recording shows what the page actually looked like at that moment. Find the LLM call before the step you want to change and copy its span id (hover the span row and click Copy span ID), or locate it with SQL:6. Change and rerun from the checkpoint
Edit the agent (the task prompt, the model,Agent settings, your own tool code), then rerun with replay armed:
What’s next
The debugger process
Sessions, notes, SQL inspection, replay, and evals, step by step.
How caching works
What gets cached, the input hash, and which integrations support it.
Browser Use integration
Full tracing reference for Browser Use, including session recordings.
Viewing traces
Read the transcript view: inputs, LLM turns, tool calls, and recordings.