Build generative AI applications using AlloyDB AI

AlloyDB AI is a suite of features included with AlloyDB for PostgreSQL that let you apply the semantic and predictive power of machine learning (ML) models to your data. This page provides an overview of the ML-powered AI functions that are available through AlloyDB.

Generate vector embeddings and text predictions

AlloyDB AI extends PostgreSQL syntax with two functions for querying models:

  • Invoke predictions to call a model using SQL within a transaction.

  • Generate embeddings to have an LLM translate text prompts into numerical vectors. You can then apply these vector embeddings as input to pgvector functions. This includes methods to compare and sort samples of text according to their relative semantic distance.

Store, index and query vector embeddings with pgvector

AlloyDB includes optimizations that let it work especially well with the pgvector extension. You can create indexes on vector-storing columns that can significantly speed up certain queries. For more information, see Query and index embeddings with pgvector.

Use local or cloud-based models

AlloyDB integrates with Vertex AI for cloud-based model access. AlloyDB Omni also supports the use of locally stored models.

Use models in the cloud with Vertex AI

You can configure AlloyDB to work with Vertex AI.

This gives your applications the following benefits:

What's next