Skip to content

About

An AI-powered PDF Question Answering Assistant built with LangGraph, LangChain, Groq, Google Gemini Embeddings, and Streamlit using Retrieval-Augmented Generation (RAG).

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

5 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 

Repository files navigation

📄 PDF RAG Assistant

An AI-powered Retrieval-Augmented Generation (RAG) application that enables users to upload PDF documents and ask natural language questions. The application retrieves relevant information from the document using semantic search and generates context-aware responses using Large Language Models (LLMs).


🚀 Live Demo

👉 Streamlit App: [(https://ragagentlangchain.streamlit.app/)]


📂 GitHub Repository

👉 https://github.com/yourusername/PDF-RAG-Assistant


✨ Features

  • 📄 Upload any PDF document
  • 🤖 AI-powered question answering
  • 🔍 Semantic search using vector embeddings
  • 🧠 Retrieval-Augmented Generation (RAG)
  • 💬 Conversational chat interface
  • 📝 Context-aware responses
  • ⚡ Fast inference with Groq LLM
  • 🔄 Conversation memory using LangGraph
  • 🌐 Streamlit-based interactive UI

🛠 Tech Stack

AI & LLM

  • LangChain
  • LangGraph
  • Groq LLM
  • Google Gemini Embeddings

Vector Database

  • InMemory Vector Store

Frontend

  • Streamlit

Language

  • Python

🏗 Architecture

               Upload PDF
                    │
                    ▼
           PDF Loader (PyPDF)
                    │
                    ▼
      Recursive Text Splitter
                    │
                    ▼
      Google Gemini Embeddings
                    │
                    ▼
         InMemory Vector Store
                    │
                    ▼
          LangGraph AI Agent
                    │
         ┌──────────┴──────────┐
         │                     │
         ▼                     ▼
  Semantic Search Tool      Groq LLM
         │                     │
         └──────────┬──────────┘
                    ▼
             AI Generated Answer
                    │
                    ▼
             Streamlit Interface

⚙️ Installation

Clone the repository

git clone https://github.com/yourusername/PDF-RAG-Assistant.git

Move into the project

cd PDF-RAG-Assistant

Install dependencies

pip install -r requirements.txt

Create a .env file

GOOGLE_API_KEY=YOUR_GOOGLE_API_KEY
GROQ_API_KEY=YOUR_GROQ_API_KEY

Run the application

streamlit run app.py

📁 Project Structure

PDF-RAG-Assistant
│
├── app.py
├── requirements.txt
├── README.md
├── .env.example
├── doc_files/
└── assets/

💡 How It Works

  1. Upload a PDF document.
  2. The document is parsed using PyPDFLoader.
  3. Text is divided into smaller chunks.
  4. Each chunk is converted into vector embeddings.
  5. Embeddings are stored in an in-memory vector database.
  6. User questions are semantically matched against the stored vectors.
  7. Relevant context is retrieved.
  8. The Groq LLM generates an answer using the retrieved context.
  9. Responses are displayed in a conversational Streamlit interface.

📸 Demo

Add screenshots or a GIF here.

Example:

  • Upload PDF
  • Ask Questions
  • AI Generated Answers

📚 Future Improvements

  • FAISS / ChromaDB support
  • Multi-PDF chat
  • PDF summarization
  • Source citations
  • Conversation export
  • Streaming responses
  • Hybrid Search (BM25 + Vector Search)
  • Persistent chat history

👨‍💻 Author

Veer Tiwari

AI Engineer | Machine Learning | Generative AI

GitHub: https://github.com/yourusername

LinkedIn: (Add your LinkedIn URL)


⭐ If you found this project helpful, consider giving it a star!

About

An AI-powered PDF Question Answering Assistant built with LangGraph, LangChain, Groq, Google Gemini Embeddings, and Streamlit using Retrieval-Augmented Generation (RAG).

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages