Controllable-RAG-Agent is an advanced Retrieval-Augmented Generation (RAG) system designed specifically for complex, multi-step question answering over your own documents. Instead of relying solely on simple semantic search, it builds a deterministic control graph that acts as the “brain” of the agent, orchestrating planning, retrieval, reasoning, and verification across many steps. The pipeline ingests PDFs, splits them into chapters, cleans and preprocesses text, then constructs vector stores for fine-grained chunks, chapter summaries, and book quotes to support nuanced queries. At query time, it anonymizes entities, creates a high-level plan, de-anonymizes and expands that plan into concrete retrieval or reasoning tasks, and executes them in sequence while continuously revising the plan. A key focus is hallucination control: each answer is verified against retrieved context, and responses are reworked when they are not sufficiently grounded in the source documents.

Features

  • Deterministic control graph that acts as the agent’s “brain” for multi-step reasoning
  • End-to-end pipeline from PDF ingestion to chapter summaries and vector stores
  • Hallucination prevention through strict grounding and verification against retrieved context
  • Entity anonymization, planning, and de-anonymization to generalize reasoning patterns
  • Modular tasks that decide when to retrieve vs when to answer using chain-of-thought
  • Built-in evaluation using Ragas metrics plus Docker and non-Docker setup paths

Project Samples

Project Activity

See All Activity >

License

Apache License V2.0

Follow Controllable-RAG-Agent

Controllable-RAG-Agent Web Site

Other Useful Business Software
Gen AI apps are built with MongoDB Atlas Icon
Gen AI apps are built with MongoDB Atlas

Build gen AI apps with an all-in-one modern database: MongoDB Atlas

MongoDB Atlas provides built-in vector search and a flexible document model so developers can build, scale, and run gen AI apps without stitching together multiple databases. From LLM integration to semantic search, Atlas simplifies your AI architecture—and it’s free to get started.
Start Free
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of Controllable-RAG-Agent!

Additional Project Details

Programming Language

Python

Related Categories

Python Large Language Models (LLM)

Registered

8 hours ago