A conversational AI chatbot that lets you upload any PDF and ask questions about it in natural language. Built using Retrieval-Augmented Generation (RAG) architecture.
- Frontend: Streamlit
- LLM: Google Gemini
- Embeddings: Google Gemini Embedding
- Vector Store: FAISS
- PDF Processing: LangChain PyPDFLoader
- Language: Python
- Upload any PDF document
- PDF is split into chunks of 1000 characters with 200 character overlap
- Each chunk is converted to vector embeddings using Gemini
- Embeddings are stored in a FAISS vector database
- When you ask a question, FAISS finds the 8 most relevant chunks
- Those chunks are sent to Gemini with your question
- Gemini answers based only on your PDF content
git clone https://github.com/mohammed-ma01/pdf-chatbot.git
cd pdf-chatbot
python -m venv venv
venv\Scripts\activate
pip install -r requirements.txt
Create a .env file:
GOOGLE_API_KEY=your_key_here
streamlit run app.py
Mohammed Mubeen Ahmed | CSE AI/ML | GitHub