AI study assistant with RAG - Google Gemini with Drive & Supabase vector search
Ready for 3.0What this workflow does
This AI workflow has 17 nodes and runs when a chat message arrives (plus 1 other trigger). Along the way it connects Embeddings Google Gemini, Supabase Vector Store, Postgres Chat Memory and Google Gemini Chat Model and 2 more.
How it runs
Trigger: When a chat message arrives (plus 1 other trigger).
- Study Agent (AI Agent): runs an AI agent, with model: Google Gemini Chat Model; 3 tools (Calculator, Supabase Vector Store, Folder all file to vector); memory: Postgres Chat Memory
- Code: runs custom JavaScript code
- Execute a SQL query (Postgres): run a query
- Search files and folders (Google Drive): work with file folder
- Loop Over Items (Loop Over Items (Split in Batches)): loops over the items in batches
- Download File (Google Drive): download
- Insert into Supabase Vectorstore (Supabase Vector Store): stores documents in the Supabase vector store, with embeddings: Embeddings Google Gemini; document loader: Default Data Loader
Services it uses
Other Google Gemini + Google Drive templates (272) · Other Google Drive + Supabase templates (67) · Other Google Gemini + Supabase templates (66)
Before you upgrade to n8n 3.0
Nothing in this workflow is removed in n8n 3.0, so it should import and run after the upgrade.
- Code node: the task timeout drops from 300s to 60s. Test with a realistic data volume.
Nodes used (14)
- Embeddings Google Gemini
@n8n/n8n-nodes-langchain.embeddingsGoogleGemini - Supabase Vector Store
@n8n/n8n-nodes-langchain.vectorStoreSupabase - Postgres Chat Memory
@n8n/n8n-nodes-langchain.memoryPostgresChat - Calculator
@n8n/n8n-nodes-langchain.toolCalculator - Chat Trigger
@n8n/n8n-nodes-langchain.chatTrigger - Google Gemini Chat Model
@n8n/n8n-nodes-langchain.lmChatGoogleGemini - Call n8n Workflow Tool
@n8n/n8n-nodes-langchain.toolWorkflow - AI Agent
@n8n/n8n-nodes-langchain.agent - Default Data Loader
@n8n/n8n-nodes-langchain.documentDefaultDataLoader - Postgres
n8n-nodes-base.postgres - Code
n8n-nodes-base.code - Execute Workflow Trigger
n8n-nodes-base.executeWorkflowTrigger - Loop Over Items (Split in Batches)
n8n-nodes-base.splitInBatches - Google Drive
n8n-nodes-base.googleDrive
From the author
How it works A complete AI-powered study assistant system that lets you chat naturally with your documents stored in Google Drive: The system has two connected workflows: 1. Document Indexing Pipeline (Sub-workflow): • Accepts Google Drive folder URLs •…