{"id":30208482,"url":"https://github.com/anandvai/ai_rag_chatbot_multi_pdf_support","last_synced_at":"2026-05-01T18:32:34.956Z","repository":{"id":309511988,"uuid":"1036552429","full_name":"anandvai/AI_RAG_Chatbot_Multi_PDF_Support","owner":"anandvai","description":" RAG (Retrieval-Augmented Generation) Chatbot built with Streamlit and LangChain, powered by Groq's blazing-fast LLaMA3-8B. It allows you to upload multiple PDFs, ask questions, and get precise, context-aware answers in a conversational format.","archived":false,"fork":false,"pushed_at":"2025-08-12T08:44:13.000Z","size":12,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-08-12T10:27:22.869Z","etag":null,"topics":["ai","data","data-science","data-visualization","data-visualizations","dataengineering","fastapi","langchain","langgraph","python","sql","streamlit"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/anandvai.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-08-12T08:40:24.000Z","updated_at":"2025-08-12T08:46:28.000Z","dependencies_parsed_at":"2025-08-12T10:41:05.030Z","dependency_job_id":null,"html_url":"https://github.com/anandvai/AI_RAG_Chatbot_Multi_PDF_Support","commit_stats":null,"previous_names":["anandvai/ai_rag_chatbot_multi_pdf_support"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/anandvai/AI_RAG_Chatbot_Multi_PDF_Support","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anandvai%2FAI_RAG_Chatbot_Multi_PDF_Support","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anandvai%2FAI_RAG_Chatbot_Multi_PDF_Support/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anandvai%2FAI_RAG_Chatbot_Multi_PDF_Support/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anandvai%2FAI_RAG_Chatbot_Multi_PDF_Support/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/anandvai","download_url":"https://codeload.github.com/anandvai/AI_RAG_Chatbot_Multi_PDF_Support/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anandvai%2FAI_RAG_Chatbot_Multi_PDF_Support/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271723011,"owners_count":24809669,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-22T02:00:08.480Z","response_time":65,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai","data","data-science","data-visualization","data-visualizations","dataengineering","fastapi","langchain","langgraph","python","sql","streamlit"],"created_at":"2025-08-13T18:00:50.252Z","updated_at":"2026-05-01T18:32:34.924Z","avatar_url":"https://github.com/anandvai.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🤖RAG_AI_Chatbot_Multi_PDF_Support[Streamlit + Groq (LLaMA3)]\n\nThis project is a fully interactive **RAG (Retrieval-Augmented Generation) Chatbot** built with **Streamlit** and **LangChain**, powered by **Groq's blazing-fast LLaMA3-8B**. It allows you to upload **multiple PDFs**, ask questions, and get precise, context-aware answers in a conversational format.\n\n---\n\n## 🚀 Features\n\n- 📤 Upload **multiple PDF documents**\n- 🤖 LLM-powered answers via **Groq LLaMA3-8B**\n- 📑 **Document viewer** in sidebar (first 3 pages per PDF)\n- 🔄 **Loading spinner** while processing queries\n- 💬 Chat-style history and interface\n- 🧠 Uses **HuggingFace sentence-transformers** for embeddings\n\n---\n\n## 📸 Demo\n\n\u003e Upload PDFs → Ask Questions → Get Context-Aware Answers\n\n![Screenshot 2025-06-17 225618](https://github.com/user-attachments/assets/dc83f75a-465b-40b8-bf8a-9f322f3f1d03)\n\n---\n\n## 🧱 Tech Stack\n\n| Layer        | Tool/Library                      |\n|--------------|-----------------------------------|\n| UI           | [Streamlit](https://streamlit.io) |\n| Backend      | [LangChain](https://www.langchain.com) |\n| LLM Host     | [Groq](https://console.groq.com/) (LLaMA3) |\n| Embeddings   | `sentence-transformers/all-MiniLM-L6-v2` |\n| PDF Handling | PyPDF2, LangChain PDF Loader      |\n\n---\n---\n## 🗂️ Project Structure\n```bash\nrag_chatbot/\n├── app.py               # Streamlit frontend\n├── rag_engine.py        # Core RAG logic (PDF loading, LLM response)\n├── .env                 # API key for Groq\n├── temp/                # Temporary file storage\n├── requirements.txt     # Project dependencies\n└── README.md            # Project documentation\n\n---\n\n\n\n---\n\n## ⚙️ Setup Instructions\n\n### ✅ Step 1: Clone the Repository\n\n```bash\ngit clone https://github.com/your-username/rag-chatbot.git\ncd rag-chatbot\n\n### ✅ Step 2: Create Virtual Environment\npython -m venv venv\n# Activate it\nsource venv/bin/activate       # On Linux/Mac\nvenv\\Scripts\\activate          # On Windows\n\n### ✅ Step 3: Install Dependencies\npip install -r requirements.txt\n\n### requirements.txt\nstreamlit\npython-dotenv\nlangchain\nlangchain-community\nlangchain-core\nlangchain-groq\nPyPDF2\nsentence-transformers\n\n### ✅ Step 4: Set Environment Variables\nGROQ_API_KEY=your_actual_groq_api_key\n\n### ▶️ Run the Application\nstreamlit run app.py\n\n## 💡 How It Works\n\n- PDF files are uploaded and stored temporarily in a `/temp/` directory.\n- Text is extracted using `PyPDF2` and `LangChain`’s `PyPDFLoader`.\n- Text chunks are embedded using `HuggingFace` sentence-transformers (`all-MiniLM-L6-v2`).\n- A vectorstore is created and queried via `LangChain's RetrievalQA`.\n- User queries are answered using `Groq’s LLaMA3-8B` model, delivering fast and accurate responses grounded in the uploaded content.\n\n---\n\n## ✨ Future Enhancements\n\n- [ ] Source highlighting in answers\n- [ ] Export chat to PDF/Markdown\n- [ ] Upload `.docx` / `.txt` files\n- [ ] Switchable LLMs (OpenAI, Claude, Mixtral)\n\n---\n\n## 🙏 Acknowledgments\n\n- [LangChain](https://www.langchain.com)\n- [Groq](https://console.groq.com)\n- [Streamlit](https://streamlit.io)\n- [HuggingFace](https://huggingface.co)\n\n---\n\n## 📜 License\n\nThis project is licensed under the [MIT License](LICENSE).\n\n---\n\n## 🧠 Author\n\n**Vaibhav Anand**  \nFeel free to reach out or contribute!\n\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fanandvai%2Fai_rag_chatbot_multi_pdf_support","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fanandvai%2Fai_rag_chatbot_multi_pdf_support","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fanandvai%2Fai_rag_chatbot_multi_pdf_support/lists"}