Skip to content
    AI engineering roles via the DiamantAI Collective.See open roles
    FoundationalRAG Techniques

    Basic RAG

    This code implements a basic Retrieval-Augmented Generation (RAG) system for processing and querying PDF documents. The system encodes the document content into a vector store, which can then be queried to retrieve relevant information.

    What you'll learn

    • 1
      PDF processing and text extraction
    • 2
      Text chunking for manageable processing
    • 3
      Vector store creation using FAISS and OpenAI embeddings
    • 4
      Retriever setup for querying the processed documents
    • 5
      Evaluation of the RAG system

    About this tutorial

    This hands-on Jupyter notebook is part of RAG Techniques, a free open-source repository by Nir Diamant covering rag techniques with runnable code examples and detailed explanations.

    Free and open-sourceRunnable Jupyter notebookActive community support
    Go deeper · Amazon Bestseller in Generative AI

    RAG Made Simple

    The book that extends this repo: 22 RAG techniques with the intuition behind each, side-by-side comparisons of when each wins (and quietly fails), and original illustrations.

    Get it on Amazon

    ⭐ 4.4 stars · 1,500+ readers · Kindle $9.99 · Paperback $24.99 · Free with Kindle Unlimited

    More Foundational tutorials

    More from RAG Techniques