This project is an AI-powered Study Assistant built using Retrieval-Augmented Generation (RAG). It allows users to ask questions from a PDF document and generates accurate answers based on the document's content using Google's Gemini model.
- Upload and process PDF documents
- Split document into chunks
- Generate embeddings using Sentence Transformers
- Store embeddings using FAISS
- Retrieve relevant context
- Generate answers using Gemini Flash
- Interactive Streamlit interface
- Python
- Streamlit
- Google Gemini API
- Sentence Transformers
- FAISS
- PyPDF
- LangChain Text Splitter
Week_7_Assignment_RAG/
│
├── app.py
├── generator.py
├── retrieval.py
├── embed.py
├── chunk.py
├── ingest.py
├── requirements.txt
├── README.md
├── .env
├── .gitignore
├── data/
│ └── datasciencenotes.pdf
git clone <repository_link>
cd Week_7_Assignment_RAGpip install -r requirements.txtCreate a file named .env in the project folder and add:
GEMINI_API_KEY=YOUR_GEMINI_API_KEY
Replace YOUR_GEMINI_API_KEY with your own Gemini API Key.
streamlit run app.py- Read PDF
- Split into chunks
- Create embeddings
- Store embeddings in FAISS
- Retrieve relevant chunks
- Send context to Gemini
- Display generated answer
- Multiple PDF support
- Chat history
- Source citation
- Better retrieval ranking
- Voice input
Shruti Deshmukh
MCA Student