Skip to content

Vector Stores

List Vector Stores
client.VectorStores.List(ctx, query) (*CursorPageByName[VectorStore], error)
GET/v5/vector-stores
Create Vector Store
client.VectorStores.New(ctx, body) (*VectorStore, error)
POST/v5/vector-stores/create
Get Vector Store
client.VectorStores.Get(ctx, vectorStoreName) (*VectorStore, error)
GET/v5/vector-stores/{vector_store_name}
Configure Vector Store
client.VectorStores.Configure(ctx, vectorStoreName, body) (*VectorStore, error)
POST/v5/vector-stores/{vector_store_name}/configure
Drop Vector Store
client.VectorStores.Drop(ctx, vectorStoreName) (*VectorStoreDropResponse, error)
POST/v5/vector-stores/{vector_store_name}/drop
Upsert Vectors
client.VectorStores.Upsert(ctx, vectorStoreName, body) (*VectorStoreUpsertResponse, error)
POST/v5/vector-stores/{vector_store_name}/upsert
Delete Vectors
client.VectorStores.Delete(ctx, vectorStoreName, body) (*VectorStoreDeleteResponse, error)
POST/v5/vector-stores/{vector_store_name}/delete
Count Vectors
client.VectorStores.Count(ctx, vectorStoreName, body) (*VectorStoreCountResponse, error)
POST/v5/vector-stores/{vector_store_name}/count
Query Vectors
client.VectorStores.Query(ctx, vectorStoreName, body) (*VectorStoreQueryResponse, error)
POST/v5/vector-stores/{vector_store_name}/query
ModelsExpand Collapse
type EmbeddingConfigUnion interface{…}
One of the following:
type EmbeddingConfigModelsAPI struct{…}
ModelDeploymentID string

The ID of the deployment of the created model in the Models API V3.

Type ModelsAPI

The type of the embedding configuration.

type EmbeddingConfigBase struct{…}
EmbeddingModel EmbeddingModelName

The name of the base embedding model to use. Either a known base model (EmbeddingModelName) or, in ray-serve deployments with NATIVE_OPENAI_EMBEDDING_GATEWAY enabled, any model id served by the OpenAI-compatible inference proxy (e.g. ‘nomic-embed-text-v1.5’). For fully custom deployments, use type ‘models_api’ with a model_deployment_id.

One of the following:
type EmbeddingModelName string
One of the following:
const EmbeddingModelNameSentenceTransformersAllMiniLmL12V2 EmbeddingModelName = "sentence-transformers/all-MiniLM-L12-v2"
const EmbeddingModelNameSentenceTransformersMultiQaDistilbertCosV1 EmbeddingModelName = "sentence-transformers/multi-qa-distilbert-cos-v1"
const EmbeddingModelNameOpenAITextEmbeddingAda002 EmbeddingModelName = "openai/text-embedding-ada-002"
const EmbeddingModelNameOpenAITextEmbedding3Small EmbeddingModelName = "openai/text-embedding-3-small"
const EmbeddingModelNameOpenAITextEmbedding3Large EmbeddingModelName = "openai/text-embedding-3-large"
const EmbeddingModelNameEmbedEnglishV3_0 EmbeddingModelName = "embed-english-v3.0"
const EmbeddingModelNameEmbedEnglishLightV3_0 EmbeddingModelName = "embed-english-light-v3.0"
const EmbeddingModelNameEmbedMultilingualV3_0 EmbeddingModelName = "embed-multilingual-v3.0"
const EmbeddingModelNameGeminiTextEmbedding005 EmbeddingModelName = "gemini/text-embedding-005"
const EmbeddingModelNameGeminiTextMultilingualEmbedding002 EmbeddingModelName = "gemini/text-multilingual-embedding-002"
const EmbeddingModelNameGeminiGeminiEmbedding001 EmbeddingModelName = "gemini/gemini-embedding-001"
string
Type EmbeddingConfigBaseTypeOptional

The type of the embedding configuration.

type EmbeddingConfigBase struct{…}
EmbeddingModel EmbeddingModelName

The name of the base embedding model to use. Either a known base model (EmbeddingModelName) or, in ray-serve deployments with NATIVE_OPENAI_EMBEDDING_GATEWAY enabled, any model id served by the OpenAI-compatible inference proxy (e.g. ‘nomic-embed-text-v1.5’). For fully custom deployments, use type ‘models_api’ with a model_deployment_id.

One of the following:
type EmbeddingModelName string
One of the following:
const EmbeddingModelNameSentenceTransformersAllMiniLmL12V2 EmbeddingModelName = "sentence-transformers/all-MiniLM-L12-v2"
const EmbeddingModelNameSentenceTransformersMultiQaDistilbertCosV1 EmbeddingModelName = "sentence-transformers/multi-qa-distilbert-cos-v1"
const EmbeddingModelNameOpenAITextEmbeddingAda002 EmbeddingModelName = "openai/text-embedding-ada-002"
const EmbeddingModelNameOpenAITextEmbedding3Small EmbeddingModelName = "openai/text-embedding-3-small"
const EmbeddingModelNameOpenAITextEmbedding3Large EmbeddingModelName = "openai/text-embedding-3-large"
const EmbeddingModelNameEmbedEnglishV3_0 EmbeddingModelName = "embed-english-v3.0"
const EmbeddingModelNameEmbedEnglishLightV3_0 EmbeddingModelName = "embed-english-light-v3.0"
const EmbeddingModelNameEmbedMultilingualV3_0 EmbeddingModelName = "embed-multilingual-v3.0"
const EmbeddingModelNameGeminiTextEmbedding005 EmbeddingModelName = "gemini/text-embedding-005"
const EmbeddingModelNameGeminiTextMultilingualEmbedding002 EmbeddingModelName = "gemini/text-multilingual-embedding-002"
const EmbeddingModelNameGeminiGeminiEmbedding001 EmbeddingModelName = "gemini/gemini-embedding-001"
string
Type EmbeddingConfigBaseTypeOptional

The type of the embedding configuration.

type EmbeddingConfigModelsAPI struct{…}
ModelDeploymentID string

The ID of the deployment of the created model in the Models API V3.

Type ModelsAPI

The type of the embedding configuration.

type EmbeddingModelName string
One of the following:
const EmbeddingModelNameSentenceTransformersAllMiniLmL12V2 EmbeddingModelName = "sentence-transformers/all-MiniLM-L12-v2"
const EmbeddingModelNameSentenceTransformersMultiQaDistilbertCosV1 EmbeddingModelName = "sentence-transformers/multi-qa-distilbert-cos-v1"
const EmbeddingModelNameOpenAITextEmbeddingAda002 EmbeddingModelName = "openai/text-embedding-ada-002"
const EmbeddingModelNameOpenAITextEmbedding3Small EmbeddingModelName = "openai/text-embedding-3-small"
const EmbeddingModelNameOpenAITextEmbedding3Large EmbeddingModelName = "openai/text-embedding-3-large"
const EmbeddingModelNameEmbedEnglishV3_0 EmbeddingModelName = "embed-english-v3.0"
const EmbeddingModelNameEmbedEnglishLightV3_0 EmbeddingModelName = "embed-english-light-v3.0"
const EmbeddingModelNameEmbedMultilingualV3_0 EmbeddingModelName = "embed-multilingual-v3.0"
const EmbeddingModelNameGeminiTextEmbedding005 EmbeddingModelName = "gemini/text-embedding-005"
const EmbeddingModelNameGeminiTextMultilingualEmbedding002 EmbeddingModelName = "gemini/text-multilingual-embedding-002"
const EmbeddingModelNameGeminiGeminiEmbedding001 EmbeddingModelName = "gemini/gemini-embedding-001"
type TextContent struct{…}

Text content for documents.

Text string

Text content to be embedded

Type TextContentTypeOptional

Content type identifier

type VectorStore struct{…}

Response model for vector store operations.

ID string

The unique identifier of the vector store

CreatedAt Time

Timestamp of creation

formatdate-time
EmbeddingDimensions int64

Dimensionality of the embedding vectors

Name string

The name of the vector store

UpdatedAt Time

Timestamp of last update

formatdate-time
EmbeddingConfig EmbeddingConfigUnionOptional

Embedding configuration identifying the model and its type. None for raw-embedding-only stores.

One of the following:
type EmbeddingConfigModelsAPI struct{…}
ModelDeploymentID string

The ID of the deployment of the created model in the Models API V3.

Type ModelsAPI

The type of the embedding configuration.

type EmbeddingConfigBase struct{…}
EmbeddingModel EmbeddingModelName

The name of the base embedding model to use. Either a known base model (EmbeddingModelName) or, in ray-serve deployments with NATIVE_OPENAI_EMBEDDING_GATEWAY enabled, any model id served by the OpenAI-compatible inference proxy (e.g. ‘nomic-embed-text-v1.5’). For fully custom deployments, use type ‘models_api’ with a model_deployment_id.

One of the following:
type EmbeddingModelName string
One of the following:
const EmbeddingModelNameSentenceTransformersAllMiniLmL12V2 EmbeddingModelName = "sentence-transformers/all-MiniLM-L12-v2"
const EmbeddingModelNameSentenceTransformersMultiQaDistilbertCosV1 EmbeddingModelName = "sentence-transformers/multi-qa-distilbert-cos-v1"
const EmbeddingModelNameOpenAITextEmbeddingAda002 EmbeddingModelName = "openai/text-embedding-ada-002"
const EmbeddingModelNameOpenAITextEmbedding3Small EmbeddingModelName = "openai/text-embedding-3-small"
const EmbeddingModelNameOpenAITextEmbedding3Large EmbeddingModelName = "openai/text-embedding-3-large"
const EmbeddingModelNameEmbedEnglishV3_0 EmbeddingModelName = "embed-english-v3.0"
const EmbeddingModelNameEmbedEnglishLightV3_0 EmbeddingModelName = "embed-english-light-v3.0"
const EmbeddingModelNameEmbedMultilingualV3_0 EmbeddingModelName = "embed-multilingual-v3.0"
const EmbeddingModelNameGeminiTextEmbedding005 EmbeddingModelName = "gemini/text-embedding-005"
const EmbeddingModelNameGeminiTextMultilingualEmbedding002 EmbeddingModelName = "gemini/text-multilingual-embedding-002"
const EmbeddingModelNameGeminiGeminiEmbedding001 EmbeddingModelName = "gemini/gemini-embedding-001"
string
Type EmbeddingConfigBaseTypeOptional

The type of the embedding configuration.

IndexedMetadataFields map[string, string]Optional

Dictionary mapping metadata field names to their types

One of the following:
const VectorStoreIndexedMetadataFieldString VectorStoreIndexedMetadataField = "string"
const VectorStoreIndexedMetadataFieldNumber VectorStoreIndexedMetadataField = "number"
const VectorStoreIndexedMetadataFieldBoolean VectorStoreIndexedMetadataField = "boolean"

Vector StoresVectors

List Vectors
client.VectorStores.Vectors.List(ctx, vectorStoreName, query) (*CursorPageVectors[VectorDocument], error)
GET/v5/vector-stores/{vector_store_name}/vectors
Get Vector
client.VectorStores.Vectors.Get(ctx, vectorID, params) (*VectorDocument, error)
GET/v5/vector-stores/{vector_store_name}/vectors/{vector_id}
ModelsExpand Collapse
type VectorDocument struct{…}

A document returned from direct lookups (get/list operations).

ID string

Document ID

Content TextContentOptional

Text content for documents.

Text string

Text content to be embedded

Type TextContentTypeOptional

Content type identifier

Metadata map[string, any]Optional

Key-value metadata

Vector []float64Optional

Embedding vector (if requested)