Skip to content

CreateVectorIndexAction

Source code in docs_src/capo_dynamodb/types/create_vector_index_action.py
class CreateVectorIndexAction(TypedDict, closed=True):
    index_name: "capo_dynamodb.types.index_name.IndexName"
    """<p>The name of the vector index. Must be unique within the table.</p>"""
    vector_attribute: (
        "capo_dynamodb.types.vector_attribute_definition.VectorAttributeDefinition"
    )
    """<p>The attribute that contains vector embeddings. If multiple vector indexes reference the same attribute, they must all use the same number of dimensions.</p>"""
    search_schema: NotRequired["capo_dynamodb.types.search_schema.SearchSchema"]
    """<p>The partition key and inline filter attribute definitions for the vector index.</p>"""
    projection: "capo_dynamodb.types.projection.Projection"
    """<p>Specifies attributes that are copied (projected) from the table into the vector index.</p>"""
    dimensions: "capo_dynamodb.types.positive_long_object.PositiveLongObject"
    """<p>The number of dimensions in each vector.</p>"""
    distance_function: (
        "capo_dynamodb.types.vector_distance_function.VectorDistanceFunction"
    )
    """<p>The distance function used to calculate similarity. Valid values: <code>COSINE</code>, <code>EUCLIDEAN</code>, <code>DOT_PRODUCT</code>.</p>"""

dimensions instance-attribute

dimensions: PositiveLongObject

The number of dimensions in each vector.

distance_function instance-attribute

distance_function: VectorDistanceFunction

The distance function used to calculate similarity. Valid values: COSINE, EUCLIDEAN, DOT_PRODUCT.

index_name instance-attribute

index_name: IndexName

The name of the vector index. Must be unique within the table.

projection instance-attribute

projection: Projection

Specifies attributes that are copied (projected) from the table into the vector index.

search_schema instance-attribute

search_schema: NotRequired[SearchSchema]

The partition key and inline filter attribute definitions for the vector index.

vector_attribute instance-attribute

vector_attribute: VectorAttributeDefinition

The attribute that contains vector embeddings. If multiple vector indexes reference the same attribute, they must all use the same number of dimensions.