Who it is forA developer who wants LLM help to bootstrap a scraper but not pay model costs on every run.
The problemCalling an LLM on every scrape gets expensive for pages you scrape daily.
The outcomeA Python script that extracts the information you described, ready to schedule.
What you need first
- Python, ideally in a virtual environment
- Playwright browsers, installed with playwright install
- An LLM: a local model through Ollama, or an API key for OpenAI, Groq, Azure, Gemini or another provider
Steps
- Install with
pip install scrapegraphaiand runplaywright install - Configure your LLM in graph_config
- Create a ScriptCreatorGraph with a prompt and the source page; it extracts information and generates a Python script
- Review the generated script, then run it on a schedule like any other Python file
- Use ScriptCreatorMultiGraph when you need one script that covers several pages
Prompt for your agent
Use ScrapeGraphAI/Scrapegraph-ai's ScriptCreatorGraph to generate a Python scraper for <url> that extracts <fields>. Save the generated script to <file>, explain what it does, and run it once to show the output.
Caveat. A generated script is a draft: read it before scheduling it, and expect to fix it when the site changes.
Use this in your AI agent
Ask your agent
Using the Deduped MCP, get the setup steps for ScrapeGraphAI/Scrapegraph-ai and "Generate a plain Python scraper you can run without an LLM"
Add Deduped to Claude Code once
claude mcp add --transport http deduped https://dedupedai.com/mcp
Every Monday: the 5 hottest repos and exactly how to use them. Free, one email a week, unsubscribe anytime.
Get them freeShare: X LinkedIn Hacker News Email Copy link
Third-party repos we don't own. AI-written use cases can be wrong. Disclaimer