Portfolio / Featured / AI / LLM

RAG

Gemini, LangChain and Streamlit document Q&A with hybrid retrieval and chat memory.

Repository inspected: view the source for this claimReviewed at ac1fe8b · last commit 2026-03-07No licence file

Problem

Make uploaded business documents searchable and answerable with sources, across spreadsheets, PDFs, Word and text files.

What the repository shows

  • FAISS vector search combined with BM25 keyword matching: both scores are normalized, weighted and summed per chunk.
  • Documents are split into 2,000-character chunks with 300 characters of overlap and embedded with sentence-transformers all-MiniLM-L6-v2.
  • Answers come from Gemini 2.5 Flash at temperature 0.1.
  • Ingests Excel, CSV, PDF, DOCX, text, Markdown and JSON, with multi-turn chat memory and Markdown export.

Python · Streamlit · LangChain · FAISS · BM25 · Gemini

Evidence for this project2 sources
  1. Repository documentedRepository documentation

    RAG combines FAISS vector search with BM25 keyword matching and ingests Excel, CSV, PDF, DOCX, text, Markdown and JSON.

    Hybrid Search | Combines vector similarity (FAISS) with keyword matching (BM25)
    • The Streamlit app's availability was not checked.

    README.md (opens in a new tab) @ ac1fe8b · reviewed 2026-10-25 · In the ledger

  2. Repository documentedInspected source code

    RAG's configuration splits documents into 2,000-character chunks with 300 of overlap, embeds them with all-MiniLM-L6-v2 and answers with Gemini 2.5 Flash at temperature 0.1.

    chunk_size: int = 2000

    config.py (opens in a new tab) @ ac1fe8b · reviewed 2026-10-26 · In the ledger

How it works

  1. Upload documents; they are parsed and split into overlapping chunks.
  2. Chunks are embedded into a FAISS index and tokenized for BM25.
  3. A question retrieves candidates from both, and the normalized scores are blended.
  4. Gemini answers from the top chunks, keeping the conversation history.

Engineering evidence

Tests
None in the repository
Licence
No licence file

Counted from the repository at commit ac1fe8b; the tests were not run for this site.