What You’ll Build
A ReAct agent that conducts comprehensive research on any company by combining website crawling with targeted web search. Give it a company name, website URL, and optional research focus — it autonomously crawls the site, extracts key pages, searches for external coverage, and produces a cited research report.View Source on GitHub
Architecture
The agent autonomously decides which tools to use and in what order. A typical research flow:- Crawl the company website to discover and summarize pages
- Extract detailed content from specific URLs found during crawling
- Search the web for external information (news, funding, reviews, competitors)
- Synthesize everything into a structured report with citations
Tools Used
Quick Start
- Anthropic SDK
- LangGraph
Source File
How It Works
Tool Wiring
Tool Wiring
Each tool wraps a Tavily Agent Toolkit function with agent-friendly parameters:
crawl_company_websitecallscrawl_and_summarizewith the company URL, optional extraction instructions, and depth/breadth controls. Returns a summarized overview of the crawled pages.extract_from_urlscallsextract_and_summarizewith specific URLs and an optional query focus. Usesextract_depth="advanced"for full content extraction.tavily_searchcallssearch_dedupwith multiple queries in parallel, returning deduplicated and formatted results withsearch_depth="advanced".
System Prompt
System Prompt
The agent is prompted as a business intelligence analyst:
Streaming Progress
Streaming Progress
Both implementations stream tool calls as they happen, so you can see the agent’s progress in real time:
Summarizer Model
Summarizer Model
The
crawl_and_summarize and extract_and_summarize tools use a dedicated summarizer model (configured via ModelConfig). In the examples, a smaller model is used for summarization to keep costs low while the main agent model handles reasoning.Example Interaction
Example Research Topics
- Company overview and products
- Leadership team and organizational structure
- Recent funding rounds and investors
- Competitive landscape
- Customer reviews and reputation
- Technology stack and engineering culture
Key Parameters to Tune
Next Steps
Social Media Research
Add social media intelligence to your agent with platform-specific search.
Hybrid Research
Combine internal company data with web research for deeper analysis.