Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

README.md

reader-crewai

CrewAI tools for Reader. Give your CrewAI agents the ability to scrape and crawl the web.

Installation

pip install reader-crewai

Tools

ReaderScrapeTool

Scrape a single web page and return its content as markdown.

from reader_crewai import ReaderScrapeTool

tool = ReaderScrapeTool(api_key="rdr_...")

# Use directly
result = tool.run("https://example.com")

# Or give to a CrewAI agent
from crewai import Agent

researcher = Agent(
    role="Researcher",
    goal="Research topics by reading web pages",
    tools=[tool],
)

ReaderCrawlTool

Crawl a website and return all discovered page content.

from reader_crewai import ReaderCrawlTool

tool = ReaderCrawlTool(api_key="rdr_...")

# Crawl up to 50 pages
result = tool.run(url="https://docs.example.com", max_pages=50)

Use in a Crew

from crewai import Agent, Task, Crew
from reader_crewai import ReaderScrapeTool, ReaderCrawlTool

scrape = ReaderScrapeTool(api_key="rdr_...")
crawl = ReaderCrawlTool(api_key="rdr_...")

researcher = Agent(
    role="Web Researcher",
    goal="Find and analyze information from websites",
    tools=[scrape, crawl],
)

task = Task(
    description="Research the pricing page at https://example.com/pricing and summarize the plans",
    agent=researcher,
)

crew = Crew(agents=[researcher], tasks=[task])
result = crew.kickoff()

Options

Both tools accept:

Parameter Type Default Description
api_key str required Reader API key
base_url str None Custom API URL for self-hosted Reader

License

MIT