Stay organized with collections
Save and categorize content based on your preferences.
This page describes how to use stored embeddings to generate indexes and query
embeddings using ScaNN, IVF, IVFFlat, and HNSW indexes with AlloyDB for PostgreSQL.
For more information about storing embedding, see
Store vector embeddings.
Before you begin
Before you can start creating indexes, you must complete the following
prerequisites.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-03-05 UTC."],[[["This page guides you on creating and querying indexes using stored embeddings with `ScaNN`, `IVF`, `IVFFlat`, and `HNSW` indexes in AlloyDB for PostgreSQL."],["Prerequisites include having embedding vectors in an AlloyDB table and installing the `vector` extension version `0.5.0` or later."],["The `alloydb_scann` extension, compatible with PostgreSQL 14 and 15, must also be installed to create `ScaNN` indexes."],["You can create various index types, such as `ScaNN`, `IVF`, `IVFFlat`, and `HNSW`, but remember that index names are shared across the database."]]],[]]