Pulkit Aggarwal

Open Extractor Agent, an AI agent for web extraction

Open Extractor Agent is a local, open-source web app that turns public websites into structured data. You give it a URL and say in plain English what you want, and it captures the page, plans the extraction, writes Python, runs it and gives you the result.

Case study, June 2026. Built with FastAPI and Playwright, MIT licence. Source on GitHub.

What it does
Turns a public URL and a plain-English request into structured data
Runs as
A local FastAPI web app that you open in your browser
Page capture
Playwright for JavaScript-rendered pages, httpx for simpler fetches
Agents
Structure capture, parallel scouts, planner, code writer, execution, presenter
Output
CSV, HTML table, JSON, Markdown, table views and downloadable results
Models
OpenAI, Claude, DeepSeek, Grok, MiniMax, OpenRouter and custom endpoints
What you see
A live SVG flow, token events, a stop control, an inspector and the generated Python
Licence
Open source, MIT

Scraping is only half of it. The other half is that you can see everything: the flow diagram, the plan, the generated Python and the raw trace. You can stop a run, and afterwards you can work out why the agent produced the result it did.

What you can ask for

Use it for the first rough pass, when you know the website and the data you need but don’t want to hand-write selectors before you know the extraction works. Some requests it handles:

  • “extract every product name, price, rating, and detail link as CSV”
  • “crawl all pages and return a clean table of job titles, companies, and apply links”
  • “find every pricing tier, feature, and limit, then return JSON”
  • “collect article titles, authors, dates, tags, and canonical links”
  • “extract forms, hidden fields, API hints, and visible table data”
  • “summarize the result and give me a Markdown table I can paste into Notion”

How it works

The app treats the page as evidence. It captures the rendered structure, static HTML, visible tables, forms and network hints, then gives each agent a narrow job before any Python is written. That keeps the output tied to what the page actually exposes. A run goes through these stages, repeating execute and repair until the output is usable:

  1. Compose. You paste a URL, describe what to extract, and choose the output format, the maximum number of pages, the provider and model, and whether to render the page in a browser.
  2. Orchestrate. FastAPI streams NDJSON events, so the interface shows progress as it happens rather than waiting for one response at the end.
  3. Capture. Playwright reads the rendered DOM, visible text, screenshots and interaction traces. httpx and the parsers collect static structure, links, forms and tables.
  4. Package context. The raw page evidence becomes a compact site context package: a DOM summary, network hints, goal memory and the tables it found.
  5. Scout in parallel. Specialised scouts look at structure, network and API hints, page patterns and extraction risks before the planner decides anything.
  6. Plan. The planner returns strict JSON: what data to extract, which selectors or APIs matter, how many pages to crawl, and which output format fits.
  7. Write code. A code-writing agent generates a one-off Python extractor for that page, using Playwright, httpx, BeautifulSoup and custom selectors.
  8. Execute and repair. The script runs with a wall-clock timeout. If the output is empty or wrong, an evaluation loop can repair the plan or the code.
  9. Present. The presenter shows a table, JSON, CSV, Markdown or a summary. The inspector keeps the plan, the generated Python and the raw trace available.

The backend uses FastAPI, Uvicorn, Playwright, httpx and BeautifulSoup, in Python. The frontend is plain HTML, CSS and JavaScript, with an SVG flow diagram fed by NDJSON streaming.

Open Extractor Agent architecture: URL input, FastAPI orchestrator, Playwright capture, parser, API inspector, agent harness, Python extractor, execution step and final result.

The diagram shows the same path: URL input, FastAPI orchestrator, Playwright capture, parser, API inspector, agent harness, Python extractor, execution step and final result.

Features

Plain-English extraction
You describe the data you want instead of writing selectors first: products, prices, links, tables, APIs, forms, article metadata or job listings.
Rendered pages
Playwright can inspect JavaScript-heavy pages and SPAs, WordPress, Next.js and ASP.NET sites, and ordinary server-rendered sites.
Multi-page crawls
Ask for all pages, set a page limit, or name a fixed number of pages. The orchestrator keeps the run bounded.
Live agent diagram
The SVG flow draws itself stage by stage, including how many agents are running in parallel.
Readable code
The inspector shows the generated Python before and after it runs.
Provider per run
OpenAI, Anthropic, DeepSeek, xAI, MiniMax, OpenRouter or any custom OpenAI-compatible endpoint can be picked for each run.
Fallback mode
With no API key it still runs deterministic extraction for headings, links, tables, API hints and a text sample.
Stop control and token events
Long runs can be cancelled, and token events are shown as they happen, so you can see what a run is spending.

Where it fits

It isn’t trying to be the biggest scraping platform. It is a local agent you can watch, meant for learning, prototyping and getting from a public page to a structured result quickly.

AlternativeKindHow this differs
Octoparse, ParseHubVisual scraper toolsOpen Extractor Agent is code-first and local. It writes a one-off Python extractor you can read, change and rerun.
Browse AIHosted automationThis is not a hosted bot platform. It is a local agent for public web extraction, with the planning and the code on screen.
Apify actorsCloud actor marketplaceApify is the better choice for production scraping fleets. This is better for learning, prototyping and seeing how an agent reasons.
BeautifulSoup scriptsManual PythonHand-written scripts are precise but slow to start. Here the agent drafts the script from the page evidence and shows it to you.
ChatGPT copy-pasteManual workflowInstead of pasting snippets into a chat, the app captures the page, plans, writes, runs and presents the result in one local interface.

Design decisions

Why the generated Python is visible

The extractor is as useful as the final table. Showing the code means you can audit it, learn from it and fork it.

Why there is a live diagram

It tells you what the agent is doing at each moment: capture, scouts, planner, code, run, repair, present.

Why the provider is chosen per run

Some sites need a cheap, fast planner and some need a stronger, more careful one. Choosing per run keeps both options open.

Why fallback mode exists

A local tool should be testable before you spend tokens. Fallback mode checks the installation, the crawler and the interface without an API key.

Limitations

  • Generated Python runs in a subprocess with a timeout. That is not a true sandbox.
  • It only uses what the browser can see. It will not get past logins, CAPTCHAs or paywalls.
  • Hostile or changing page markup can still break selectors.
  • Small models fail the strict JSON protocol more often.
  • Some sites never reach browser network idle. Plain HTTP mode can work better there.
  • Keep max pages reasonable. The tool is meant for bounded extraction, not for hammering sites.

What’s next

  • A stronger execution sandbox for generated Python.
  • Reusable extraction recipes saved from successful runs.
  • XLSX export and better table cleaning.
  • Optional session cookies, supplied by you, for sites you are allowed to access.
  • Selectors that repair themselves when a page changes.
  • Scheduled runs and diff detection for repeat monitoring.

Questions people ask

What is Open Extractor Agent?

Open Extractor Agent is a local, open-source web extraction agent that turns a public URL and a plain-English request into structured data such as CSV, tables, JSON, Markdown or HTML.

Does it work without an LLM API key?

Yes. Without a key it runs in deterministic fallback mode and extracts headings, links, tables, API hints and a text sample. LLM planning and code generation need a configured provider.

Which LLM providers does it support?

It supports OpenAI, Anthropic Claude, DeepSeek, xAI Grok, MiniMax, OpenRouter, and custom OpenAI-compatible endpoints.

Is it a safe sandbox?

No. The generated Python is run in a subprocess with a wall-clock timeout, but it is not a true sandbox. The inspector exists so you can read generated code and traces.

What stack is it built with?

The backend uses FastAPI, Uvicorn, Playwright, httpx and BeautifulSoup. The frontend is plain HTML, CSS and JavaScript with a live SVG flow diagram and NDJSON streaming.

Source

The code is on GitHub at pulket/web-extractor-agent, under the MIT licence. The other things I’ve built are on the projects page.