Chat with Internal Documents using Ollama, Supabase Vector DB & Google Drive
š Chat with Internal Documents (RAG AI Agent) ā Features Answers should given only within provided text. Chat interface powered by LLM (Ollama) Retrieval-Augmented Generation (RAG) using Supabase Vector DB Multi-format file support (PDF, Excel, Google Docs, text files) Automated file ingestion from Google Drive Real-time document update handling Embedding generation via Ollama for semantic search Memory-enabled agent using PostgreSQL Custom tools for document lookup with context-aware chat
āļø How It Works š„ Document Ingestion & Vectorization Watches a Google Drive folder for new or updated files.
Deletes old vector entries for the file.
Uses conditional logic to extract content from PDFs, Excel, Docs, or text
Summarizes and preprocesses content. (if needed)
Splits and embeds the text via Ollama.
Stores embeddings in Supabase Vector DB
š¬ RAG Chat Agent Chat is initiated via Webhook or built-in chat interface.
User input is passed to the RAG Agent.
Agent queries the User_documents tool (Supabase vector store) using the Ollama model to fetch relevant content.
If context is found, it answers directly.
Otherwise, it can call tools or request clarification.
Responses are returned to the user, with memory stored in PostgreSQL for continuity.
š Supabase Database Configuration Create a Supabase project at https://supabase.com and go to the SQL editor.
Create a documents table with the following schema: id - int8 content - text metadata - jsonb embedding - vector
Generate an API Key
Related Templates
USDT And TRC20 Wallet Tracker API Workflow for n8n
Overview This n8n workflow is specifically designed to monitor USDT TRC20 transactions within a specified wallet. It u...
Automate Daily Keyword Research with Google Sheets, Suggest API & Custom Search
Who's it for This workflow is perfect for SEO specialists, marketers, bloggers, and content creators who want to automa...
Bulk Automated Google Drive Files Sharing and Direct Download Link Generation
This N8N workflow automates the process of sharing files from Google Drive. It includes OAuth2 authentication, batch pro...
š Please log in to import templates to n8n and favorite templates
Workflow Visualization
Loading...
Preparing workflow renderer
Comments (0)
Login to post comments