AWS SDK Version 4 for .NET
API Reference

AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.

DynamoDB property attribute that marks a member as a search vector associated with a vector index on a table. Members marked with this attribute must be of type System.Collections.Generic.List`1 of System.Single.

Inheritance Hierarchy

System.Object
  System.Attribute
    Amazon.DynamoDBv2.DataModel.DynamoDBAttribute
      Amazon.DynamoDBv2.DataModel.DynamoDBRenamableAttribute
        Amazon.DynamoDBv2.DataModel.DynamoDBPropertyAttribute
          Amazon.DynamoDBv2.DataModel.DynamoDBSearchVectorAttribute

Namespace: Amazon.DynamoDBv2.DataModel
Assembly: AWSSDK.DynamoDBv2.dll
Version: 3.x.y.z

Syntax

C#
public sealed class DynamoDBSearchVectorAttribute : DynamoDBPropertyAttribute

The DynamoDBSearchVectorAttribute type exposes the following members

Constructors

NameDescription
Public Method DynamoDBSearchVectorAttribute()

Default constructor.

Public Method DynamoDBSearchVectorAttribute(string)

Constructor that specifies the vector index this search vector belongs to.

Properties

NameTypeDescription
Public Property AttributeName System.String Inherited from Amazon.DynamoDBv2.DataModel.DynamoDBRenamableAttribute.
Public Property Converter System.Type Inherited from Amazon.DynamoDBv2.DataModel.DynamoDBPropertyAttribute.
Public Property IndexName System.String

Name of the vector index this search vector belongs to.

Public Property StoreAsEpoch System.Boolean Inherited from Amazon.DynamoDBv2.DataModel.DynamoDBPropertyAttribute.
Public Property StoreAsEpochLong System.Boolean Inherited from Amazon.DynamoDBv2.DataModel.DynamoDBPropertyAttribute.
Public Property TypeId System.Object Inherited from System.Attribute.

Examples

public class Document
{
    [DynamoDBSearchVector("VectorIndex")]
    public List<float> Embedding { get; set; }
}
             

Remarks

A member can participate in multiple vector indexes by applying this attribute once per index. Search vectors are only supported with Amazon.DynamoDBv2.DynamoDBEntryConversion.V2. Using Amazon.DynamoDBv2.DynamoDBEntryConversion.V1 with a search vector member is not supported and results in an System.InvalidOperationException when the type is configured.

Version Information

.NET:
Supported in: 8.0 and newer, Core 3.1

.NET Standard:
Supported in: 2.0

.NET Framework:
Supported in: 4.7.2 and newer