Portfolio / Featured / AI / LLM
Contextual-RAG-Chatbot
PDF question answering with Gemini, OCR fallback, an adjustable context window and an analytics dashboard.
Problem
Answer questions from PDFs, including scanned ones, while keeping conversation context and showing usage analytics.
What the repository shows
- Text extraction tries PyPDF2 and pdfplumber, with Tesseract OCR for scanned pages.
- Hybrid search blends dense and sparse scores with a tunable weight (alpha).
- 1,000-character chunks with 200 characters of overlap.
- Context window adjustable from 1 to 20 messages; analytics exportable to Excel or HTML.
Python · Streamlit · Gemini · PyPDF2 · pdfplumber · Tesseract
Evidence for this project2 sources
- Repository documentedRepository documentation
Contextual-RAG-Chatbot processes PDFs with OCR fallback, combines semantic and keyword search and keeps a 1–20 message context window.
Contextual Conversations: Maintains conversation context with adjustable window (1-20 messages)
- The Streamlit app's availability was not checked.
README.md (opens in a new tab) @ 3272463 · reviewed 2026-10-25 · In the ledger
- Repository documentedInspected source code
Contextual-RAG-Chatbot fuses dense and sparse search scores with a tunable weight, alpha.
self.config.hybrid_search_alpha * denseScore +
vector_store.py (opens in a new tab) @ 3272463 · reviewed 2026-10-26 · In the ledger
How it works
- Upload PDFs; text is extracted, with OCR when a page has no text layer.
- Chunks are indexed for dense and keyword search.
- A question is answered by Gemini from the blended top results and the recent conversation.
- Usage is tracked and can be exported.
Engineering evidence
- Tests
- None in the repository
- Licence
- No licence file
Counted from the repository at commit 3272463; the tests were not run for this site.
Links
Link from the owner portfolio; its availability has not been checked.
Next: BoxShield Arena