How deveshkd/simple-rag-pipline works
Project Type and Purpose
• This is a mono‐repo “full‐stack” (UI + backend logic) Retrieval‐Augmented Generation (RAG) chatbot.
• Purpose: Let users upload PDFs, extract and index text (including OCR), then answer natural-language questions using an LLM (via Ollama) + FAISS vector search.
File‐Structure Analysis
• Top level
• app.py – Streamlit entry point, HTTP‐style UI/UX
• requirements.txt / Tesseract_req.txt – Python & OCR dependencies
• .devcontainer – VSCode dev‐container config
• src/ (backend modules)
• loader.py – PDF ingestion & text extraction (PyMuPDF + Tesseract)
• splitter.py – Text chunking logic
• embedder.py – Embedding text chunks (SentenceTransformer)
• vectorstore.py – Vector store management (FAISS)
• qa.py – Query orchestration: retrieve top‐k chunks, call LLM via Ollama, assemble response
README Insights
• Highlights the processing pipeline: PDF upload → OCR/text parse → chunking → embedding → vector indexing → similarity search → LLM QA.
• Key external services/libraries: Streamlit (UI), PyMuPDF, Tesseract, FAISS, Ollama, Sentence Transformer.