Building Research Agents

Creating agents that can gather and analyze information

Research agents search the web, gather information, and provide summarized insights on any topic.

Diagram

Research Flow

❓ Question

🤖 Research Agent

🔍 Web Search

📊 Analyze

📋 Summary


Quick Start

python
from praisonaiagents import Agent

# Research agent with web search
researcher = Agent(
    name="Researcher",
    instructions="Research topics and provide clear summaries",
    web=True  # Enable web search
)

researcher.start("What are the latest trends in AI?")

How It Works

Diagram

Research Process

❓ Question

🔍 Search Web

📄 Find Sources

📊 Analyze

📋 Summary


Complete Example

python
from praisonaiagents import Agent

# Create a research agent
researcher = Agent(
    name="ResearchAgent",
    instructions="""You are a research specialist.

When researching:
- Search for accurate, current information
- Organize findings clearly
- Identify key facts and insights
- Present in a structured format""",
    web=True
)

# Research a topic
researcher.start("Research the impact of renewable energy on carbon emissions")

Structured Research Output

python
from praisonaiagents import Agent

researcher = Agent(
    name="StructuredResearcher",
    instructions="""You research topics and provide structured reports.

Format your response as:
## Summary
Brief overview

## Key Facts
- Fact 1
- Fact 2
- Fact 3

## Analysis
Deeper insights

## Sources
List of sources""",
    web=True
)

researcher.start("Research quantum computing advancements")

Specialized Research Agents

Comparison Agent

python
comparison_agent = Agent(
    name="ComparisonAgent",
    instructions="""Compare options and present findings.

- Identify key criteria
- Research each option
- Create side-by-side comparison
- Highlight pros and cons""",
    web=True
)

comparison_agent.start("Compare solar vs wind energy for homes")

Research Team

Multiple agents working together for deep research:

python
from praisonaiagents import Agent, AgentTeam

# Researcher finds information
researcher = Agent(
    name="Researcher",
    instructions="Find comprehensive information on topics",
    web=True
)

# Analyst interprets findings
analyst = Agent(
    name="Analyst",
    instructions="Analyze research and identify key insights"
)

# Writer creates the report
writer = Agent(
    name="Writer",
    instructions="Write clear, structured research reports"
)

# Create research team
team = AgentTeam(
    agents=[researcher, analyst, writer],
    process="sequential"
)

team.start("Research the future of electric vehicles")

Best Practices

Define Clear Scope

Be specific about what you want to research

Request Structure

Ask for organized output with sections

Verify Facts

Use multiple sources for important claims

Use Teams

Combine research + analysis + writing agents


Next: Content Creation Agents

Learn how to build agents that create content.