Vector Engine (PGvector)

Vector Engine

Vector Engine is part of EDB Postgres® AI (EDB PG AI), enabling advanced vector search and hybrid search capabilities directly in your Postgres databases.

It leverages the open source PGvector extension to provide efficient storage and similarity search for high-dimensional vector data — a foundational capability for Retrieval-Augmented Generation (RAG), semantic search, and intelligent applications.

PGvector is an independent extension, maintained by the open source community. EDB PG AI leverages PGvector as part of its stack:

  • Pipelines can automatically populate vector columns using embedding models.
  • Gen AI Builder and Knowledge Bases use PGvector-backed retrievals.
  • You can also use PGvector independently — it is not a proprietary component.

Why Vector Search in Postgres?

Traditional databases excel at structured data and transactional workloads. AI-powered applications increasingly rely on vector embeddings — numeric representations of unstructured content such as text, images, or audio.

Vector Engine enables you to:

  • Store vector embeddings in your Postgres clusters — no separate vector database required
  • Search and retrieve content by similarity, using Approximate Nearest Neighbor (ANN) indexes
  • Combine vector search + SQL search for hybrid queries across structured and unstructured data
  • Power Sovereign Gen AI — keeping embeddings, metadata, and results in your Postgres estate
  • Audit and govern AI search and retrieval as part of your Postgres data platform

Who Should Use Vector Engine?

Vector Engine is designed for:

  • Data teams building RAG pipelines and semantic search on top of Postgres
  • Developers building Gen AI assistants that integrate with existing Postgres data
  • Analytics teams augmenting BI and analytics with vector-based search patterns
  • Architects designing Sovereign AI solutions that must govern embeddings and results

If your application uses vector embeddings and you want to keep both the vectors and the source data in Postgres — Vector Engine provides a scalable, production-ready path.


What Does It Provide?

At its core, Vector Engine — using PGvector — adds:

  • The vector column type — to store high-dimensional vector data
  • Distance functions:
  • vector <-> vector — Euclidean distance (L2)
  • vector <#> vector — inner product
  • vector <=> vector — cosine distance
  • Support for Approximate Nearest Neighbor (ANN) indexes:
  • IVFFlat index type
  • Tunable lists and probes for balancing accuracy vs. speed

PGvector itself is open source — EDB PG AI uses it to power:

  • Retrieval in Knowledge Bases (via Gen AI Builder)
  • Vector search in Pipelines-based RAG pipelines
  • Hybrid AI + SQL query patterns in Postgres

How Vector Engine Works

  1. Install and enable PGvector in your Postgres database:
CREATE EXTENSION IF NOT EXISTS vector;
  1. Define vector columns in your tables:
ALTER TABLE documents ADD COLUMN embedding vector(768);
  1. Index vector columns for fast similarity search:
CREATE INDEX ON documents USING ivfflat (embedding vector_l2_ops) WITH (lists = 100);
  1. Populate embeddings:

Use Pipelines to generate embeddings

Or use any external embedding model and insert vectors manually

  1. Query using similarity search:
FROM documents
ORDER BY embedding <-> '[0.12, 0.34, 0.56, ...]'::vector
LIMIT 5;

When Should You Use Vector Engine?

Use Vector Engine when:

  • You are building Gen AI or AI-powered applications that require grounding in your own data

  • You want to perform semantic search across documents, web pages, knowledge bases

  • You need a Sovereign AI architecture — embeddings and source data fully inside your Postgres clusters

  • You want to support hybrid structured + unstructured search in a unified data platform

  • You are developing RAG pipelines using EDB PG AI and AI Accelerator Pipelines

Example Use Cases

  • Enterprise RAG Assistants — combine knowledge base retrieval with LLMs

  • Internal semantic search — search corporate content across multiple repositories

  • Recommendation systems — similarity search for content or products

  • Vision/audio similarity — image or audio embedding search

Integration with AI Accelerator Pipelines and Gen AI Builder

AI Accelerator Pipelines makes it easy to:

Vectorize documents and populate Postgres vector columns

Automate and orchestrate RAG pipelines

Use Supported Embedding Models for your vectorization

Pipelines uses PGvector-based retrieval when building Knowledge Bases:

Knowledge Bases store embeddings in Postgres vector columns

RAG flows query using PGvector functions for similarity search

Next Steps

  • Learn about AI Accelerator Pipelines

  • Explore Pipeline Preparer Examples for vectorization patterns

  • Review Supported Embedding Models

  • Explore Gen AI Builder Knowledge Bases and RAG pipelines

  • See full PGvector Documentation

EDB PG AI Vector Engine helps you build powerful Sovereign AI solutions — with your data, your embeddings, your control — directly in your Postgres estate.


Could this page be better? Report a problem or suggest an addition!