Language

VectorPropertyModel.GenerateEmbeddingAsync(Object, CancellationToken) Method

Definition

Generates a single embedding for the given value, using the configured EmbeddingGenerationDispatcher.

public:
 System::Threading::Tasks::Task<Microsoft::Extensions::AI::Embedding ^> ^ GenerateEmbeddingAsync(System::Object ^ value, System::Threading::CancellationToken cancellationToken);
public System.Threading.Tasks.Task<Microsoft.Extensions.AI.Embedding> GenerateEmbeddingAsync(object? value, System.Threading.CancellationToken cancellationToken);
member this.GenerateEmbeddingAsync : obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Extensions.AI.Embedding>
Public Function GenerateEmbeddingAsync (value As Object, cancellationToken As CancellationToken) As Task(Of Embedding)

Parameters

value
Object
cancellationToken
CancellationToken

Returns

The generated embedding.

Exceptions

Thrown if no EmbeddingGenerationDispatcher is configured on this property.

Applies to