Lingua

MultimodalMultiVectorEmbedding Class

Definition

The result for one item when vectorKind is multi: one vector per token, for late-interaction (MaxSim) scoring.

public class MultimodalMultiVectorEmbedding : Azure.Data.AI.EmbeddingItem, System.ClientModel.Primitives.IJsonModel<Azure.Data.AI.MultimodalMultiVectorEmbedding>, System.ClientModel.Primitives.IPersistableModel<Azure.Data.AI.MultimodalMultiVectorEmbedding>
type MultimodalMultiVectorEmbedding = class
    inherit EmbeddingItem
    interface IJsonModel<MultimodalMultiVectorEmbedding>
    interface IPersistableModel<MultimodalMultiVectorEmbedding>
Public Class MultimodalMultiVectorEmbedding
Inherits EmbeddingItem
Implements IJsonModel(Of MultimodalMultiVectorEmbedding), IPersistableModel(Of MultimodalMultiVectorEmbedding)
Inheritance
MultimodalMultiVectorEmbedding
Implements

Properties

Name Description
ContentKind

The item's content kind, as supplied in the request's kind.

Format

For images: the detected image format.

Height

For images: the height in pixels.

Id

The item's id from the request, if it had one.

(Inherited from EmbeddingItem)
Index

The zero-based position of the item in the request.

(Inherited from EmbeddingItem)
InputTokens

For truncated items only: the item's tokens before truncation.

IsTruncated

true when the item was over the model's token limit and only its start was embedded; warnings then has an EMBEDDING_INPUT_TRUNCATED entry for it. Omitted otherwise.

MultiEmbedding

The vectors: an array of arrays of numbers, or, when encodingFormat is base64, one base64 string of all their little-endian outputDataKind values in row-major order. Decode it and reshape it to shape.

To assign an object to this property use FromObjectAsJson<T>(T, JsonSerializerOptions).

To assign an already formatted json string to this property use FromString(String).

<remarks> Supported types:

</remarks>

Examples:

  • BinaryData.FromObjectAsJson("foo"). : Creates a payload of "foo".
  • BinaryData.FromString("\"foo\""). : Creates a payload of "foo".
  • BinaryData.FromObjectAsJson(new { key = "value" }). : Creates a payload of { "key": "value" }.
  • BinaryData.FromString("{\"key\": \"value\"}"). : Creates a payload of { "key": "value" }.

Shape

The number of vectors and the number of dimensions: [vectors, dimensions].

Tokens

The tokens the model read for this item, including any text the service adds to queries and, for images, the image prompt and image tokens. For a truncated item, the tokens embedded. Omitted when the model doesn't report it.

VectorKind

The kind of vectors returned.

VisualTokens

For images: how many of tokens were image tokens.

Width

For images: the width in pixels.

Methods

Name Description
JsonModelCreateCore(Utf8JsonReader, ModelReaderWriterOptions)
JsonModelWriteCore(Utf8JsonWriter, ModelReaderWriterOptions)
PersistableModelCreateCore(BinaryData, ModelReaderWriterOptions)
PersistableModelWriteCore(ModelReaderWriterOptions)

Explicit Interface Implementations

Name Description
IJsonModel<EmbeddingItem>.Create(Utf8JsonReader, ModelReaderWriterOptions) (Inherited from EmbeddingItem)
IJsonModel<EmbeddingItem>.Write(Utf8JsonWriter, ModelReaderWriterOptions) (Inherited from EmbeddingItem)
IJsonModel<MultimodalMultiVectorEmbedding>.Create(Utf8JsonReader, ModelReaderWriterOptions)
IJsonModel<MultimodalMultiVectorEmbedding>.Write(Utf8JsonWriter, ModelReaderWriterOptions)
IPersistableModel<EmbeddingItem>.Create(BinaryData, ModelReaderWriterOptions) (Inherited from EmbeddingItem)
IPersistableModel<EmbeddingItem>.GetFormatFromOptions(ModelReaderWriterOptions) (Inherited from EmbeddingItem)
IPersistableModel<EmbeddingItem>.Write(ModelReaderWriterOptions) (Inherited from EmbeddingItem)
IPersistableModel<MultimodalMultiVectorEmbedding>.Create(BinaryData, ModelReaderWriterOptions)
IPersistableModel<MultimodalMultiVectorEmbedding>.GetFormatFromOptions(ModelReaderWriterOptions)
IPersistableModel<MultimodalMultiVectorEmbedding>.Write(ModelReaderWriterOptions)

Applies to