Local Chatbot with Retrieval Augmented Generation (RAG)

Go to Workflow
28,717 views
Built by Thomas Janssen Thomas Janssen
Created on June 06, 2026

Description

Build a 100% local RAG with n8n, Ollama and Qdrant. This agent uses a semantic database (Qdrant) to answer questions about PDF files.

Tutorial

Click here to view the YouTube Tutorial

How it works
Build a chatbot that answers based on documents you provide it (Retrieval Augmented Generation). You can upload as many PDF files as you want to the Qdrant database. The chatbot will use its retrieval tool to fetch the chunks and use them to answer questions.

Installation
Install n8n + Ollama + Qdrant using the Self-hosted AI starter kit
Make sure to install Llama 3.2 and mxbai-embed-large as embeddings model.

How to use it
First run the "Data Ingestion" part and upload as many PDF files as you want
Run the Chatbot and start asking questions about the documents you uploaded

Nodes Used (7)

AI Agent
@n8n/n8n-nodes-langchain.agent
Default Data Loader
@n8n/n8n-nodes-langchain.documentDefaultDataLoader
Embeddings Ollama
@n8n/n8n-nodes-langchain.embeddingsOllama
Ollama Chat Model
@n8n/n8n-nodes-langchain.lmChatOllama
Qdrant Vector Store
@n8n/n8n-nodes-langchain.vectorStoreQdrant
Recursive Character Text Splitter
@n8n/n8n-nodes-langchain.textSplitterRecursiveCharacterTextSplitter
Simple Memory
@n8n/n8n-nodes-langchain.memoryBufferWindow