
Last Update: March 14, 2025 10 min read
BY
eric
I Tried 9 Open-Source RAG Tools on My Own Documents: What Worked
Retrieval-augmented generation (RAG) means the model looks things up in your documents before it answers, instead of relying only on what it learned in training. Every chat UI now claims to do it. In March 2025 I wanted to know which self-hosted tools actually do it well, so I installed nine of them, loaded my own PDFs, and asked questions I could check.
Mostly I used the same small set of documents: six PDFs about options trading (webinar notes, a strategies quick guide, an "understanding options" booklet and similar). I also tried a forex beginners' guide, an Australian BAS and super due-date sheet, a health booklet and a couple of books. Every screenshot below is from my own install.
The short version
If you want one answer: Open WebUI if you just want to add documents to the chat UI you already use, RAGFlow if you want a proper RAG system, Onyx if your documents live in Google Drive, Confluence and the like and a team needs to search them.
Open WebUI
Open WebUI is mainly a chat UI for local and cloud models (I covered it in my chat UI comparison), but its Knowledge feature is a capable RAG system.
# ideally inside a fresh virtual environment
pip install open-webui
open-webui serve
# http://localhost:8080
I created two knowledge collections, Forex Trading For Beginners and a testkb:

Then I created a custom model on top of a base model and attached the forex collection to it:

I asked my "ForexTrading" model a beginner question: "what is the best timeframe I should use a beginner". It thought for 20 seconds, recommended starting on the 4-hour chart, and cited the PDF it took that from (Forex-Trading-For-Beginners-The-Ultimate-Guide.pdf):

You can also pull a collection into any chat by typing # in the prompt box. The RAG docs explain the embedding and chunking settings.
Verdict: the least effort for a useful result. If you already chat through Open WebUI, start here before installing anything else.
RAGFlow
RAGFlow focuses on "deep document understanding": it parses layouts, tables and images instead of blindly chunking text.
git clone https://github.com/infiniflow/ragflow.git
cd ragflow/docker
docker compose up -d
# http://localhost
I made two knowledge bases, a one-document testrag and a 15-document testkb:

Each chat assistant is tied to knowledge bases, and you can switch on quoting, keyword analysis and web search (Tavily):

The best result came from a set of Australian payroll and tax reference sheets, which were images, not text. I asked when BAS is due, and then "when are the super due dates". RAGFlow answered both correctly (BAS: 25 Nov, 28 Feb, 25 May, 25 Aug; super: 28 Oct, 28 Jan, 28 Apr, 28 Jul) and cited the exact image each answer came from (4. BAS Agent Due Dates.png, 5. Super FAQ.png). Reading dates out of images is exactly where simpler tools fall down.

It also has an agent builder with templates (web search assistant, text-to-SQL and others):

Verdict: the most accurate answers I got, and the best handling of messy documents. It's a heavier Docker stack, so give it a machine with plenty of RAM.
Onyx (formerly Danswer)
Onyx is built for teams: 40+ connectors (Google Drive, Confluence, SharePoint, GitHub, email…), access control and custom assistants.
git clone https://github.com/onyx-dot-app/onyx.git
cd onyx/deployment/docker_compose
cp env.prod.template .env
# Onyx expects Google OAuth by default. For a local trial set:
# AUTH_TYPE=basic (or disabled)
cp env.nginx.template .env.nginx
ln -s docker-compose.prod.yml docker-compose.yml
docker compose up -d
# http://localhost
Document processing can optionally go through the Unstructured API; I left it on the built-in parser:

I used the File connector to upload my six options-trading PDFs as Options Trading PDFs:

Then I made an Options Trader assistant ("You are a professional options trader…") linked to a document set:

Two things happened that are worth knowing about. First, when I asked "are options a wasting asset?", Onyx decided "The AI decided this query didn't need a search" and answered from the model's own knowledge. The answer about time decay was fine, but it didn't come from my documents. There's a Force search button for exactly this case.

Second, when it did search, it worked. Asked "is there any options trading game available, and what is the website?" (with GPT-4o as the model), it searched, found the ASX options game in one of my PDFs and showed the sources. The cited snippet says "Sign up to play at optionsgame.com.au", though the answer itself pointed to asx.com.au, so check the source rather than the summary.

Verdict: the most complete platform here, and the obvious choice if your knowledge lives in SaaS tools. It's also the heaviest to set up, and you need to watch whether it actually searched.
MaxKB
MaxKB is a ready-made knowledge-base chatbot with a workflow engine, and it works with many models (OpenAI, Claude, DeepSeek, Qwen, Llama…).
mkdir MaxKB && cd MaxKB
cat > docker-compose.yml <<'EOF'
services:
maxkb:
image: 1panel/maxkb
container_name: maxkb
ports:
- "8080:8080"
volumes:
- ~/.maxkb:/var/lib/postgresql/data
- ~/.python-packages:/opt/maxkb/app/sandbox/python-packages
restart: unless-stopped
EOF
docker compose up -d
# http://localhost:8080 (default login: admin / MaxKB@123..)
Setting up models was the fiddly part. You add each provider and model by hand:

After that it's pleasant. It even generates likely questions from your documents automatically:

But look closely at this answer. I loaded a book about investors and short sellers and asked "how many people's names showed in the book". It said 15 individuals, then listed nine. When I pointed out it had missed some ("like Dalio"), it produced a different list and said the text doesn't mention Ray Dalio.

That's a RAG limitation, not just a MaxKB one: the model only sees the few chunks that were retrieved, so "how many…" and "list all…" questions over a whole book are exactly what RAG is bad at.
Verdict: a good-looking, capable tool once the models are configured. Don't trust counting or "list everything" answers from any RAG system.
Verba
Verba, from the Weaviate team, is the simplest dedicated RAG app here.
git clone https://github.com/weaviate/Verba.git
cd Verba
docker compose up -d --build
# http://localhost:8000
Importing my six options PDFs was quick: split into 25 chunks and vectorized in about 3 seconds.

I asked it to "help me find the best option trading strategy". It sensibly said the documents didn't support recommending a single "best" strategy, then summarized what they did say (mostly about Bollinger Bands), with sources:

Refusing to make up a "best strategy" is good RAG behaviour. The limitation is that Verba has a single document pool ("Chatting with 6 documents"). You can't keep separate knowledge bases per client or project and switch between them.
Verdict: great for one focused knowledge base. Not for multiple.
Kotaemon
Kotaemon is a clean Gradio app with hybrid search, in-document citation highlighting, and GraphRAG and LightRAG collections alongside normal file collections.
mkdir kotaemon && cd kotaemon
git clone https://github.com/Cinnamon/kotaemon.git code
mkdir docker-compose && cp code/.env.example docker-compose/.env
cd docker-compose
cat > docker-compose.yml <<'EOF'
services:
kotaemon:
image: ghcr.io/cinnamon/kotaemon:main-lite
environment:
- GRADIO_SERVER_NAME=0.0.0.0
- GRADIO_SERVER_PORT=7860
ports:
- "7860:7860"
volumes:
- ./ktem_app_data:/app/ktem_app_data
stdin_open: true
tty: true
restart: unless-stopped
EOF
docker compose up -d
# http://localhost:7860 (login admin / admin)
It accepts a wide range of files (PDF, Office, images, HTML, CSV, Markdown, zip):

It didn't work at first. You don't pick a model in the chat; you set a default model under Resources, which took me a while to find. Once configured, it did well. I gave it a Spanish textbook, and it produced a step-by-step study plan from the lessons, with a mind map and the source page highlighted:

Verdict: the nicest citation display of the lot, but the least intuitive configuration.
RAG Web UI
A straightforward full-stack RAG app: knowledge bases, document upload (PDF, DOCX, Markdown, text) and chat.
git clone https://github.com/rag-web-ui/rag-web-ui.git
cd rag-web-ui
cp .env.example .env # set OPENAI_API_KEY
docker compose up -d --build
# http://localhost

I uploaded a health information booklet and asked what it was about, then for more detail. Both answers were accurate summaries with citations:

The rough edges are in management. You can't rename a knowledge base after creating it, and you can't change which knowledge base a chat uses; to switch, you start again.
Verdict: fine for a quick single-purpose setup, if you're happy using OpenAI.
LobeChat
LobeChat is one of the best-looking chat UIs (see my chat UI comparison), and it has a knowledge base feature that handles text, images, audio and video files.
mkdir lobe-chat-db && cd lobe-chat-db
bash <(curl -fsSL https://lobe.li/setup.sh) -l en
docker compose up -d
# http://localhost:3210

I couldn't get its RAG working. With a knowledge base attached and a local Ollama model selected, the chat failed with an OpenAI API key error in the background. My guess is that the embedding step still defaults to OpenAI even when the chat model is local, so check the embedding model settings if you try it.
Verdict: use it as a chat UI. For RAG, I'd pick something else.
Cognita
Cognita, from TrueFoundry, is a modular RAG framework meant for building production systems, with a UI on top.
git clone https://github.com/truefoundry/cognita.git
cd cognita
cp models_config.sample.yaml models_config.yaml
docker compose --env-file compose.env up -d
# http://localhost:5001

I never got past creating a collection: the embedding model dropdown stayed empty. Cognita takes its models from models_config.yaml, and mine evidently wasn't set up with a working embedding model.

Verdict: a framework for developers, not a tool you install and use. Budget time for configuration.
What I learned
- Check the citations, not just the answer. Onyx answered without searching once, and cited the right snippet with the wrong website another time. Every tool that shows its sources makes that checkable. Use one that does.
- RAG can't count. Questions like "how many names are in the book" need the whole document, and RAG only retrieves a few chunks. MaxKB's 15-names-but-lists-9 answer is the typical failure.
- Document parsing matters more than the chat UI. RAGFlow's correct answers from images of tax tables were the most impressive thing I saw. If your documents are scans, tables or slides, pick the tool by its parser.
- The embedding model is the hidden dependency. LobeChat's OpenAI error and Cognita's empty dropdown were both about embeddings. If you want everything local, make sure the embedding model is local too, not just the chat model.
- Start with what you have. If you already run Open WebUI, its Knowledge feature may be all you need.
If you need a private knowledge base for a small business and want help choosing or hosting one, get in touch with TYO Lab.









Comments (0)
Leave a Comment