Automate Storing Notion Pages as Vector Documents in Supabase with OpenAI
detail.loadingPreview
This workflow automatically stores Notion pages as vector documents in Supabase using OpenAI for embeddings. It triggers on new Notion pages, fetches content, filters media, and then stores the processed text and metadata in Supabase.
🚀Ready to Deploy This Workflow?
About This Workflow
Overview
This n8n workflow automates the process of capturing information from Notion pages and storing it as searchable vector documents within a Supabase database. It leverages OpenAI for generating embeddings, making the stored content amenable to semantic search and AI-powered applications. This is particularly useful for building knowledge bases, content analysis tools, or augmenting AI chatbots with your Notion content.
The workflow is designed to be triggered whenever a new page is added to a designated Notion database. It then fetches the page's content, filters out non-textual elements like images and videos, concatenates the remaining text, and generates embeddings using OpenAI. Finally, it stores this processed content along with relevant metadata into a Supabase table that is configured with a vector column.
Key Features
- Trigger automatically when a new page is added to a specified Notion database.
- Fetches all block content from Notion pages.
- Filters out non-textual content (images, videos).
- Concatenates and summarizes block content for embedding.
- Generates vector embeddings using OpenAI.
- Stores text chunks, embeddings, and metadata in a Supabase table with a vector column.
- Provides a foundation for semantic search and AI applications based on your Notion data.
How To Use
- Set up Supabase: Ensure you have a Supabase project with a table that includes a vector column. Refer to the Supabase Vector Columns Guide for assistance.
- Configure Notion Trigger: In the
Notion - Page Added Triggernode, specify the database ID you want to monitor for new pages. - Configure OpenAI Embeddings: Set up your OpenAI API key and parameters in the
Embeddings OpenAInode. - Configure Supabase Vector Store: In the
Supabase Vector Storenode, select the Supabase connection and specify the target table name where vectors will be stored. - Map Metadata: In the
Create metadata and load contentnode, configure the metadata fields (e.g.,pageId,createdTime,pageTitle) to pull relevant information from the Notion trigger. - Adjust Token Splitter: Customize
Token Splitternode'schunkSizeandchunkOverlapparameters based on your content and embedding model requirements. - Run the Workflow: Activate the workflow. When a new page is added to your specified Notion database, it will be processed and stored in Supabase.
Apps Used
Workflow JSON
{
"id": "896673ca-9f36-431b-a857-e924aed93ae9",
"name": "Automate Storing Notion Pages as Vector Documents in Supabase with OpenAI",
"nodes": 0,
"category": "Data Management",
"status": "active",
"version": "1.0.0"
}Note: This is a sample preview. The full workflow JSON contains node configurations, credentials placeholders, and execution logic.
Get This Workflow
ID: 896673ca-9f36...
About the Author
SaaS_Connector
Integration Guru
Connecting CRM, Notion, and Slack to automate your life.
Statistics
Verification Info
Related Workflows
Discover more workflows you might like
Sync Google Drive Files with OpenAI Vector Store
Automatically syncs files from Google Drive to an OpenAI vector store, ensuring up-to-date embeddings for AI applications.
FileMaker Data Entry and Update
Workflow to create a record in FileMaker, then edit it with additional data.
Dynamically Create Airtable Tables for Webflow Form Submissions
Automatically create dedicated Airtable tables for each Webflow form and log submissions.