Index Google Drive files into a Supabase vector store with OpenAI embeddings
Ready for 3.0What this workflow does
This AI workflow has 26 nodes and runs when a chat message arrives (plus 2 other triggers). Along the way it connects Embeddings OpenAI, Google Drive, Supabase and Supabase Vector Store and 1 more.
How it runs
Trigger: When a chat message arrives (plus 2 other triggers).
- Create Docs Table and Match Fn (Postgres): run a query
- Loop Over Drive Files (Loop Over Items (Split in Batches)): loops over the items in batches
- Create Document Metadata Table (Postgres): run a query
- Set File Metadata Fields (Edit Fields (Set)): sets 4 fields: file_id, file_type, file_title…
- Create Document Rows Table (Postgres): run a query
- Delete Old Doc Rows in Supabase (Supabase): delete
- Delete Old Data Rows in Supabase (Supabase): delete
- Insert Document Metadata to DB (Postgres): create or update
- Download File from Drive (Google Drive): download
- Route by File Type (Switch): routes items into 4 branches
…plus 10 more steps. See the full node list below.
Services it uses
Other OpenAI + Google Drive templates (628) · Other OpenAI + PostgreSQL templates (191) · Other OpenAI + Supabase templates (149)
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.
Nodes used (15)
- Default Data Loader
@n8n/n8n-nodes-langchain.documentDefaultDataLoader - Embeddings OpenAI
@n8n/n8n-nodes-langchain.embeddingsOpenAi - Google Drive
n8n-nodes-base.googleDrive - Google Drive Trigger
n8n-nodes-base.googleDriveTrigger - Extract from File
n8n-nodes-base.extractFromFile - Supabase
n8n-nodes-base.supabase - Edit Fields (Set)
n8n-nodes-base.set - Aggregate
n8n-nodes-base.aggregate - Character Text Splitter
@n8n/n8n-nodes-langchain.textSplitterCharacterTextSplitter - Summarize
n8n-nodes-base.summarize - Switch
n8n-nodes-base.switch - Supabase Vector Store
@n8n/n8n-nodes-langchain.vectorStoreSupabase - Loop Over Items (Split in Batches)
n8n-nodes-base.splitInBatches - Postgres
n8n-nodes-base.postgres - Chat Trigger
@n8n/n8n-nodes-langchain.chatTrigger
From the author
📺 Full walkthrough video: https://youtu.be/r5kNla0O7I Author: Cole Medin Who it's for This workflow is for developers, data engineers, and knowledge management teams who need to automatically ingest documents stored in Google Drive into a searchable vector…