Vector assist overview

MySQL  |  PostgreSQL  |  SQL Server

Preview — Vector assist

This feature is subject to the "Pre-GA Offerings Terms" in the General Service Terms section of theService Specific Terms. You can process personal data for this feature as outlined in theCloud Data Processing Addendum, subject to the obligations and restrictions described in the agreement under which you access Google Cloud. Pre-GA features are available "as is" and might have limited support. For more information, see thelaunch stage descriptions.

Vector assist is a Cloud SQL for PostgreSQL extension that simplifies thedeployment and management of your Cloud SQL vector workloads. It provides adeclarative SQL framework that helps you set up production-ready vector searchcapabilities, such as embedding generation, query optimization, and indexcreation. This framework reduces the complexity of vector workloads by:

  • Simplifying intent declaration: requirements (such as table, textcolumn, or target recall) are declared using SQL functions.
  • Automating best practices: generates optimized SQL commands, also knownas recommendations, to set up your vector workload using your definedvector specification and an optimized auto-tuning algorithm thatcomputes optimal index configuration.
  • Providing transparency and control: provides clear explanations for eachrecommendation when automating tasks that let you review, modify, and applyrecommendations at your pace.
  • Enabling rapid prototyping: lets you quickly deploy a well-tuned vectorsearch setup, reducing the time from concept to production.
  • Focusing on ease-of-use: simplifies the complexity of semantic search,bridging the gap between business and engineering requirements.

With vector assist, you can build end-to-end applications with semantic searchfeatures with simplified setup.

How vector assist works

Using vector assist requires you to define your vector specifications. Theframework uses these vector specifications, also known as the vector spec, togenerate the steps required to create a vector index. Vector assist outputs thesteps required to deploy your vector workload as recommendations. Each time youmodify your vector spec, vector assist regenerates the recommendations.

Once you generate the vector index using these recommended steps, you can usevector assist to generate optimized search queries.

Vector assist specification

Setting up your vector index specification, orvector spec, is the firststep in using vector assist. A vector spec is an object where you define theintent and requirements for your vector workload. It includes all necessaryinformation, including:

  • The tables and relevant columns (text or vector)
  • Embedding model preferences (if using embedding generation)
  • Preferred index type, such asHNSWorIVFFlat.
  • Target recall for search queries
  • Memory limitations or other performance constraints
Note: If you define thetarget_recall specification in your vector spec andvector assist is unable to build an index on a given dataset and configuration toachieve the specifiedtarget_recall, it returns configurations that build avector workload with the best possibletarget_recall. This might fall belowthe user-definedtarget_recall.

You define the vector spec using thevector_assist.define_specfunction, and you can modify it at any time. The system assigns each specification aunique ID and stores it in a table calledvector_assist.vector_specs.

Vector assist infers the specification inputs and an optimized auto-tuningalgorithm that computes optimal index configuration.. Although vector assist usesthese values to simplify the development process, you can still customize themto match your preferences.

Vector assist recommendations

After you define the vector spec, vector assist processes your input and generatesrecommendations. These recommendations are an ordered list of useful steps,typically SQL commands, that you must execute to deploy your vector workload peryour specifications. Each recommendation includes:

  • The SQL query to run.
  • A detailed explanation of what the query does and why it's recommended.
  • Information about potential trade-offs or costs, such as estimated indexsize or build time.

Vector assist stores recommendations in a table calledvector_assist.recommendation, and you can review, modify, and apply themindividually, or as a whole.

Each time you modify the vector spec for your workload, vector assist regeneratesthe recommendations to comply with the updated specifications.

Limitations

When using vector assist with your Cloud SQL for PostgreSQL instances, consider thefollowing limitations:

  • Vector assist only supports PostgreSQL versions 12 and later.
  • Although vector assist supports allpgvector versions, we recommend usingthe most recent version for optimal performance and feature support. Formore information, see thepgvectorchangelog.
  • If your instance uses thegoogle_ml_integration extension to generateembeddings, then its restrictions also apply when you use vector assist.For more information, seeModel endpoint managementoverview.
  • Vector assist only supportsHNSW andIVFFlat index types.
  • Vector assist only supports text embedding models for auto-generatingembeddings and uses thetext_column_name as the input parameter. If yourvector workload requires a multimodal embedding model, use thegoogle_ml_integration extension, or another extension to manually generatethese embeddings before using vector assist to enable semantic search on theseembeddings.

What's next

Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025-11-24 UTC.