🧪 RAG‑LCC Your local RAG experimentation lab. Identify where RAG fails

RAG-LCC hedgehog icon

Status: Experimental License: MIT

Built with & integrates:

AI, retrieval & language: Python LangChain ChromaDB PyTorch Transformers Sentence Transformers KeyBERT spaCy NLTK Lingua Argos Translate

Configured LLM families: Qwen Llama Mistral

Document processing: Tesseract OCR pdfplumber

Service & optional integrations: FastAPI Ollama vLLM Open WebUI DuckDuckGo Docker

Jump to a topic

Overview

Experimental Retrieval-Augmented Generation under constraints.

RAG-LCC is a practical lab for understanding where RAG systems fail and how to fix them: retrieval misses, context poisoning, multilingual drift, and compliance edge cases.

Who this is for

Short: If you want to understand why your RAG fails, RAG-LCC gives you a playground to experiment with the parameters that matter. You can tune settings, compare alternatives on a small test corpus, and carry those insights back into your own RAG. In other words, RAG-LCC is an insight tool with reusable ideas, not an everyday production RAG.

Presentation

View or download the PowerPoint presentation, or watch it play below:

Animated RAG-LCC presentation

The presentation also highlights tabular answers, document summarization, and the optional web-retrieval leg.

What you get

Application suite

Confidence logging, quality-scoring switches, and the judge prompt are centralized in Config_Confidence.py. See the configuration reference for defaults, output sections, and the CONFIDENCE_FLAT CSV schema.

Application Purpose Typical output
DocClassify Classify and compress corpus content before indexing CSV metadata used for selective loading
RAGLoad Ingest and index local documents into multiple retrievers ChromaDB + BM25 + Graph + Regex indexes
RAGChat Interactive CLI RAG with grounding and safety checks Grounded multi-turn answers
RAGChatService OpenAI-compatible API wrapper for RAGChat API endpoint for OpenWebUI and clients

For the vLLM backend, the companion project HarinezumIgel/harinezumigel-llm-stack provides configuration-driven orchestration for self-hosted LiteLLM and vLLM deployments. Use it to serve the LLMs, embedder, and reranker required by RAG-LCC.

Why this project is different

Most RAG stacks optimize only retrieval score. RAG-LCC also optimizes context quality.

Quick start

  1. Read installation guide INSTALL.md
  2. Load docs python ./src/Apps/RAGLoad.py –doc-dir TestDocs
  3. Start chat python ./src/Apps/RAGChat.py –doc-dir TestDocs

Query and grounding examples

CLI grounding example: hedgehog query

Hedgehog grounded CLI output

Shows sentence-level overlap markers in the CLI flow. These help inspect matching evidence but do not verify that an answer is factually correct.

Tabular answer with source grounding

Tabular answer with highlighted source documents

A single query can retrieve information and request a table. This example shows an animal classification table alongside highlighted passages in the source documents. The highlights help inspect matching evidence; they do not establish answer accuracy.

Mermaid diagram with grounding

Mermaid diagrams can be viewed by through the RAGChat in memory web server.

Mermaid diagram with grounding

OpenWebUI example (web)

OpenWebUI  output

Shows the same grounding concept through the OpenWebUI integration path (RAGChatService). Useful for validating that API/UI output preserves evidence links, not just CLI output; matching text is not proof of accuracy.

OpenWebUI grounded example (local results)

OpenWebUI grounded answer

This example shows an OpenWebUI answer with source attribution, including a web result. Source links help inspect retrieved evidence but do not prove answer accuracy.

Documentation hub

Source repository

HarinezumIgel/RAG-LCC

⭐ Support the Project

RAG-LCC is developed in personal time and continues to evolve through community interest, feedback, and experimentation.

If the project helped you, please consider:

The RAG-LCC Experimental Lab runs on curiosity, feedback, and GPUs converting electricity into heat. Community interest is a major motivation for continued development.