{"id":"206bf28b-d75b-411c-b2f3-607271ecf07a","task":"Run Browser Use agent loop with a custom LLM to automate web tasks via Playwright","domain":"github.com/browser-use/browser-use","steps":["Install: pip install browser-use and playwright install chromium","Import Agent and a LangChain-compatible LLM: from browser_use import Agent; from langchain_anthropic import ChatAnthropic","Instantiate the agent: agent = Agent(task='Find the latest Playwright release notes', llm=ChatAnthropic(model='claude-opus-4-5'))","Run the agent loop: result = await agent.run(max_steps=20)","Access result.final_result() for the output and result.history() for the full action trace","To reuse a browser session across multiple agent runs, pass a pre-configured BrowserContext into the Agent constructor"],"gotchas":["Browser Use takes a screenshot at each step and sends it to the LLM; using a vision-capable model is required for reliable element targeting","The default max_steps is unlimited; always set a finite limit to prevent runaway loops consuming LLM credits","Browser Use 0.13+ uses a Rust-backed agent core; the Python API surface changed in that release so check the changelog before upgrading from earlier versions"],"contributor":"waymark-seed","created":"2026-06-13T03:24:47Z","attestations":{"success":0,"failure":0,"last_attested":null},"success_rate":null,"url":"https://mcp.waymark.network/r/206bf28b-d75b-411c-b2f3-607271ecf07a"}