Skip to content

Jogesh6895/ai-deep-research-assistant

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AI Deep Research Assistant

A powerful research assistant that combines web search capabilities with AI analysis to provide comprehensive insights on any topic. Built with Cerebras for fast inference and Exa for intelligent web search.

Features

  • Intelligent Web Search: Uses Exa's AI-powered search engine to find relevant sources
  • Multi-Layer Research: Performs follow-up searches for deeper insights
  • Multi-Agent Research: Implements Anthropic-style parallel agent approach
  • Structured Analysis: Provides summaries, key insights, and actionable recommendations
  • Multiple Research Modes: Choose between basic, deep, or multi-agent research
  • Source Attribution: All findings are linked to their original sources

Installation

  1. Clone the repository:
git clone https://github.com/yourusername/ai-deep-research-assistant.git
cd ai-deep-research-assistant
  1. Create a virtual environment:
python -m venv venv
source venv/bin/activate  # On Windows: venv\Scripts\activate
  1. Install dependencies:
pip install -r requirements.txt
  1. Set up environment variables:
cp .env.example .env
# Edit .env with your API keys

Required API Keys

Usage

Basic Research Mode

Quick research with single search and analysis:

python -m src.main --mode basic --query "latest AI breakthroughs 2025"

Deep Research Mode

Two-layer research with follow-up investigation:

python -m src.main --mode deep --query "quantum computing advances"

Multi-Agent Mode

Parallel agent approach for complex topics:

python -m src.main --mode multi-agent --query "renewable energy policy"

Interactive Mode

Run in interactive mode to ask multiple questions:

python -m src.main --interactive

Research from File

Load queries from a file:

python -m src.main --mode deep --input-file input_docs/research_topics.txt

Project Structure

ai-deep-research-assistant/
├── src/
│   ├── __init__.py
│   ├── main.py              # Entry point
│   ├── research_engine.py   # Core research logic
│   ├── agents.py            # Multi-agent implementation
│   ├── search_client.py     # Exa search wrapper
│   └── config.py            # Configuration management
├── input_docs/              # Research queries and topics
├── config/
│   └── settings.py          # Application settings
├── .env.example            # Environment variables template
├── .gitignore              # Git ignore rules
├── requirements.txt        # Python dependencies
├── README.md              # This file
└── AGENTS.md              # Agent behavior documentation

Research Modes

Basic Mode

  • Single web search (5 sources)
  • AI analysis and synthesis
  • Summary and key insights
  • Best for: Quick fact-checking, general information

Deep Mode

  • Initial broad search (6 sources)
  • AI generates follow-up question
  • Targeted secondary search (4 sources)
  • Comprehensive synthesis
  • Best for: Research projects, detailed analysis

Multi-Agent Mode

  • Lead agent breaks query into 3 parallel subtasks
  • Specialized agents work simultaneously
  • Parallel synthesis of findings
  • Best for: Complex topics, comprehensive coverage

Output Format

All research results follow this structure:

RESEARCH RESULTS
================
Query: [Your query]
Sources analyzed: [Number]

SUMMARY:
[2-3 sentence overview]

INSIGHTS:
• [Key insight 1]
• [Key insight 2]
• [Key insight 3]

DEPTH GAINED: (Deep mode only)
[How follow-up enhanced understanding]

SOURCES:
1. [Title] - [URL]
2. [Title] - [URL]
...

Input Files

Place your research queries in input_docs/ directory:

research_topics.txt (one query per line):

artificial intelligence ethics
climate change solutions
blockchain technology trends

queries.json (structured format):

{
  "queries": ["quantum computing applications", "space exploration news"]
}

Configuration

Environment variables in .env:

CEREBRAS_API_KEY=your_cerebras_api_key
EXA_API_KEY=your_exa_api_key
CEREBRAS_MODEL=llama3.1-70b
DEFAULT_MODE=basic
MAX_SOURCES_BASIC=5
MAX_SOURCES_DEEP=6
MAX_SOURCES_MULTI=2
OUTPUT_FORMAT=structured

Advanced Usage

Custom Source Limits

python -m src.main --mode deep --max-sources 10 --query "your topic"

Save Results to File

python -m src.main --mode deep --query "topic" --output results.md

Batch Processing

python -m src.main --mode deep --input-file queries.txt --output results/

Research Quality Tips

  1. Be specific: "renewable energy storage 2025" vs "energy"
  2. Use time context: Add years for recent developments
  3. Choose right mode: Basic for facts, Deep for analysis, Multi for complexity
  4. Review sources: Check source quality and relevance
  5. Iterate: Use findings to refine follow-up questions

Limitations

  • Web search depends on Exa's index coverage
  • Analysis is based on available sources
  • Complex topics may require multiple queries
  • API rate limits apply

License

This project is licensed under the MIT License - see the LICENSE file for details.

Support

For questions and support, please open an issue on GitHub.

Acknowledgments

  • Built with Cerebras for fast inference
  • Powered by Exa AI search engine
  • Inspired by Perplexity AI and Anthropic's multi-agent research

About

A powerful research assistant that combines web search capabilities with AI analysis to provide comprehensive insights on any topic. Built with Cerebras for fast inference and Exa for intelligent web search.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages