workflows.fit
Back to n8n workflows
n8n templateFreeBy Tricore Infotech Pvt Ltd

Build a RAG chatbot using Google Gemini and a Supabase vector store

🧠 AI Chatbot with RAG: Google Gemini & Supabase Vector Store šŸ“Œ Summary Build a custom, intelligent knowledge base in minutes. This n8n workflow provides a complete Retrieval-Augmented Generation (RAG) system using G...

DevelopmentCore NodesAILangchainUtilitySticky NoteError TriggerSet
Loading interactive preview...

Template notes

🧠 AI Chatbot with RAG: Google Gemini & Supabase Vector Store

šŸ“Œ Summary

Build a custom, intelligent knowledge base in minutes. This n8n workflow provides a complete Retrieval-Augmented Generation (RAG) system using Google Gemini and Supabase. It features a seamless dual-flow design: an ingestion pipeline to process and store your uploaded documents, and a conversational AI agent that queries those documents to provide accurate, context-aware answers while remembering past interactions.

---

✨ Key Features

Two-in-One Architecture: Combines both the document ingestion pipeline and the conversational chat interface into a single, cohesive workflow template. State-of-the-Art AI: Leverages Google Gemini (models/gemini-embedding-001 and models/gemini-2.5-flash) for high-quality text embeddings and intelligent chat generation. Persistent Conversational Memory: Uses PostgreSQL to remember chat histories per sessionId, allowing the AI to maintain context across ongoing conversations. The chat trigger automatically generates a unique Session ID per browser window, keeping individual user conversations completely separate. Vector-Powered Accuracy: Integrates with Supabase (pgvector) to retrieve the top 5 most relevant chunks, ensuring the agent answers based strictly on your uploaded company documents without hallucinating. Global Error Handling: Built-in error triggers actively catch API rate limits, parsing failures, and bad requests, formatting them into clear alerts ready to be routed to your team.

---

šŸ› ļø How It Works