vectors

Store and search vector embeddings in Postgres using pgvector and HNSW indexing.

Updated Apr 10, 2026
One-click install
npx skills add https://github.com/theslashdojo/dojo --skill vectors
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: vectors
Source: https://github.com/theslashdojo/dojo/tree/main/nodes/supabase/vectors
Command: npx skills add https://github.com/theslashdojo/dojo --skill vectors

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires @supabase/supabase-js, openai, and includes scripts (resource) components.

What problem does it solve?

Persisting high-dimensional representations in a database enables fast similarity search, semantic retrieval, and retrieval-augmented generation over large corpora without leaving the data layer.

Core Features & Use Cases

  • Store embeddings in vector(N) columns using the pgvector extension
  • Build and query HNSW indexes for fast, scalable similarity search
  • Enable RAG pipelines and semantic search across documents, images, or other content

Quick Start

Embed a sample text, store the embedding in a vector column, and query with another embedding to retrieve similar documents.

Frequently Asked Questions about vectors

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I store and search vector embeddings in Postgres for semantic retrieval?▼

You can store vector embeddings in Postgres using the pgvector extension, which adds a vector column type for high-dimensional data. This enables fast similarity search directly within the database layer for semantic retrieval and RAG pipelines.

What is the best way to build a RAG pipeline with pgvector and OpenAI embeddings?▼

Building a RAG pipeline with pgvector involves storing OpenAI embeddings in a Postgres vector column and querying them via an RPC-based match function. This setup retrieves similar documents to augment generation without leaving the data layer.

Does pgvector support HNSW indexing for fast similarity search at scale?▼

Yes, pgvector supports HNSW indexing to enable fast and scalable similarity search across large document corpora. This indexing method accelerates vector comparisons for semantic search and recommendation scenarios.

Can I use Supabase to query vector embeddings for document recommendations?▼

Yes, you can use the Supabase client to query vector embeddings stored in Postgres. By calling an RPC-based query function like match_documents, you can retrieve similar content for recommendation scenarios.

What are the requirements for setting up vector similarity search in a Postgres database?▼

Setting up vector similarity search requires installing the pgvector extension, creating a vector column to store embeddings, and defining an RPC query function. These components work together to enable fast document retrieval.