VectorIndex(
name: typing.Optional[str] = None,
index_type: typing.Optional[
langchain_google_cloud_sql_mysql.indexes.IndexType
] = None,
distance_measure: typing.Optional[
langchain_google_cloud_sql_mysql.indexes.DistanceMeasure
] = None,
num_partitions: typing.Optional[int] = None,
num_neighbors: typing.Optional[int] = None,
)
Represents a vector index for storing and querying vectors.
Attributes |
|
---|---|
Name | Description |
name
:noindex: |
Optional[str]
The name of the index. |
index_type
:noindex: |
Optional[IndexType]
The type of index. |
distance_measure
:noindex: |
Optional[DistanceMeasure]
The distance measure to use for the index. |
num_partitions
:noindex: |
Optional[int]
The number of partitions for the index. None for default. |
num_neighbors
:noindex: |
Optional[int]
The default number of neighbors to return for queries. |
Methods
VectorIndex
VectorIndex(
name: typing.Optional[str] = None,
index_type: typing.Optional[
langchain_google_cloud_sql_mysql.indexes.IndexType
] = None,
distance_measure: typing.Optional[
langchain_google_cloud_sql_mysql.indexes.DistanceMeasure
] = None,
num_partitions: typing.Optional[int] = None,
num_neighbors: typing.Optional[int] = None,
)
Initializes a new instance of the VectorIndex class.