2025-04-23 12:11:00
github.com
Index is the SOTA open-source browser agent for autonomously executing complex tasks on the web.
prompt: go to ycombinator.com. summarize first 3 companies in the W25 batch and make new spreadsheet in google sheets.
local_agent_spreadsheet_demo.mp4
Check out full documentation here
The easiest way to use Index in production is via the serverless API. Index API manages remote browser sessions, agent infrastructure and browser observability. To get started, sign up and create project API key. Read the docs to learn more.
from lmnr import Laminar, AsyncLaminarClient
import asyncio
# you can also set LMNR_PROJECT_API_KEY environment variable
# Initialize tracing
Laminar.initialize(project_api_key="your_api_key")
# Initialize the client
client = AsyncLaminarClient(project_api_key="your_api_key")
async def main():
response = await client.agent.run(
prompt="Navigate to news.ycombinator.com, find a post about AI, and summarize it"
)
print(response.result)
if __name__ == "__main__":
asyncio.run(main())
pip install lmnr-index
# Install playwright
playwright install chromium
Setup your model API keys in .env
file in your project root:
ANTHROPIC_API_KEY=
GEMINI_API_KEY=
OPENAI_API_KEY=
You can run Index via interactive CLI. It features:
- Browser state persistence between sessions
- Follow-up messages with support for “give human control” action
- Real-time streaming updates
- Beautiful terminal UI using Textual
You can run the agent with the following command. Remember to set API key for the selected model in the .env
file.
Output will look like this:
Loaded existing browser state
╭───────────────────── Interactive Mode ─────────────────────╮
│ Index Browser Agent Interactive Mode │
│ Type your message and press Enter. The agent will respond. │
│ Press Ctrl+C to exit. │
╰────────────────────────────────────────────────────────────╯
Choose an LLM model:
1. Gemini 2.5 Flash
2. Claude 3.7 Sonnet
3. OpenAI o4-mini
Select model [1/2] (1): 3
Using OpenAI model: o4-mini
Loaded existing browser state
Your message: go to lmnr.ai, summarize pricing page
Agent is working...
Step 1: Opening lmnr.ai
Step 2: Opening Pricing page
Step 3: Scrolling for more pricing details
Step 4: Scrolling back up to view pricing tiers
Step 5: Provided concise summary of the three pricing tiers
import asyncio
from index import Agent, AnthropicProvider
async def main():
llm = AnthropicProvider(
model="claude-3-7-sonnet-20250219",
enable_thinking=True,
thinking_token_budget=2048)
# llm = OpenAIProvider(model="o4-mini") you can also use OpenAI models
agent = Agent(llm=llm)
output = await agent.run(
prompt="Navigate to news.ycombinator.com, find a post about AI, and summarize it"
)
print(output.result)
if __name__ == "__main__":
asyncio.run(main())
async for chunk in agent.run_stream(
prompt="Navigate to news.ycombinator.com, find a post about AI, and summarize it"
):
print(chunk)
To trace Index agent’s actions and record browser session you simply need to initialize Laminar tracing before running the agent.
from lmnr import Laminar
Laminar.initialize(project_api_key="your_api_key")
Then you will get full observability on the agent’s actions synced with the browser session in the Laminar platform.

import asyncio
from index import Agent, AnthropicProvider, BrowserConfig
async def main():
# Configure browser to connect to an existing Chrome DevTools Protocol endpoint
browser_config = BrowserConfig(
cdp_url=""
)
llm = AnthropicProvider(model="claude-3-7-sonnet-20250219", enable_thinking=True, thinking_token_budget=2048)
agent = Agent(llm=llm, browser_config=browser_config)
output = await agent.run(
prompt="Navigate to news.ycombinator.com and find the top story"
)
print(output.result)
if __name__ == "__main__":
asyncio.run(main())
import asyncio
from index import Agent, AnthropicProvider, BrowserConfig
async def main():
# Configure browser with custom viewport size
browser_config = BrowserConfig(
viewport_size={"width": 1200, "height": 900}
)
llm = AnthropicProvider(model="claude-3-7-sonnet-20250219")
agent = Agent(llm=llm, browser_config=browser_config)
output = await agent.run(
"Navigate to a responsive website and capture how it looks in full HD resolution"
)
print(output.result)
if __name__ == "__main__":
asyncio.run(main())
Made with ❤️ by the Laminar team
Keep your files stored safely and securely with the SanDisk 2TB Extreme Portable SSD. With over 69,505 ratings and an impressive 4.6 out of 5 stars, this product has been purchased over 8K+ times in the past month. At only $129.99, this Amazon’s Choice product is a must-have for secure file storage.
Help keep private content private with the included password protection featuring 256-bit AES hardware encryption. Order now for just $129.99 on Amazon!
Help Power Techcratic’s Future – Scan To Support
If Techcratic’s content and insights have helped you, consider giving back by supporting the platform with crypto. Every contribution makes a difference, whether it’s for high-quality content, server maintenance, or future updates. Techcratic is constantly evolving, and your support helps drive that progress.
As a solo operator who wears all the hats, creating content, managing the tech, and running the site, your support allows me to stay focused on delivering valuable resources. Your support keeps everything running smoothly and enables me to continue creating the content you love. I’m deeply grateful for your support, it truly means the world to me! Thank you!
BITCOIN bc1qlszw7elx2qahjwvaryh0tkgg8y68enw30gpvge Scan the QR code with your crypto wallet app |
DOGECOIN D64GwvvYQxFXYyan3oQCrmWfidf6T3JpBA Scan the QR code with your crypto wallet app |
ETHEREUM 0xe9BC980DF3d985730dA827996B43E4A62CCBAA7a Scan the QR code with your crypto wallet app |
Please read the Privacy and Security Disclaimer on how Techcratic handles your support.
Disclaimer: As an Amazon Associate, Techcratic may earn from qualifying purchases.