Deep Agents
AgentContextOrchestratorRetrievalText2SQLToolbox

Recipes

Production-ready examples for common RAG applications

Complete, production-ready examples showing how to build real-world RAG applications with the retrieval package.

Available Recipes

Documentation Chatbot

Build an AI assistant that answers questions about your documentation using semantic search. Combines the retrieval package with @deepagents/agent to create a conversational interface with source citations.

Key features:

  • RAG-powered Q&A
  • Source citations
  • Streaming responses

News Aggregator

Aggregate content from multiple RSS feeds and generate AI-powered daily digests. Demonstrates multi-source ingestion with TTL-based refresh and structured output generation.

Key features:

  • Multi-feed aggregation
  • Automatic refresh with TTL
  • AI-generated summaries

Research Paper Assistant

Search and summarize research papers from arXiv or local PDFs. Shows how to build a research tool that indexes academic papers and answers questions about them.

Key features:

  • PDF indexing
  • Paper summarization
  • Research Q&A

Build a semantic code search system across multiple local and GitHub repositories. Useful for understanding large codebases and finding relevant implementations.

Key features:

  • Local + GitHub repos
  • Language-aware filtering
  • Cross-project search

Knowledge Base with Citations

Create a knowledge base that combines multiple source types (docs, releases, news) and provides answers with proper source attribution.

Key features:

  • Multi-source ingestion
  • Source tracking
  • Citation formatting

Incremental Indexing Pipeline

Build a production indexing pipeline with different refresh strategies for different content types. Shows how to efficiently manage large-scale content ingestion.

Key features:

  • Mixed ingestion modes
  • Scheduled updates
  • Pipeline orchestration

Choosing a Recipe

Use CaseRecipe
Customer support botDocumentation Chatbot
Content monitoringNews Aggregator
Academic researchResearch Assistant
Code understandingCode Search
Enterprise knowledgeKnowledge Base
Large-scale indexingIndexing Pipeline

Common Patterns

All recipes follow these patterns:

  1. Store creation - Initialize SQLite with matching dimensions
  2. Connector setup - Configure data sources with ingestion modes
  3. Embedder config - Use FastEmbed with appropriate model
  4. Search integration - Combine with agents or direct queries
// Common setup across all recipes
import { similaritySearch, fastembed, nodeSQLite } from '@deepagents/retrieval';

const store = nodeSQLite('./knowledge.db', 384);
const embedder = fastembed();

const results = await similaritySearch(query, {
  connector,
  store,
  embedder,
});

Next Steps