Share via


EmbeddingsOptions Constructors

Definition

Overloads

EmbeddingsOptions()

Initializes a new instance of EmbeddingsOptions.

EmbeddingsOptions(String, IEnumerable<String>)

Initializes a new instance of EmbeddingsOptions.

EmbeddingsOptions()

Source:
EmbeddingsOptions.cs

Initializes a new instance of EmbeddingsOptions.

public EmbeddingsOptions ();
Public Sub New ()

Exceptions

input is null.

Applies to

EmbeddingsOptions(String, IEnumerable<String>)

Source:
EmbeddingsOptions.cs

Initializes a new instance of EmbeddingsOptions.

public EmbeddingsOptions (string deploymentName, System.Collections.Generic.IEnumerable<string> input);
new Azure.AI.OpenAI.EmbeddingsOptions : string * seq<string> -> Azure.AI.OpenAI.EmbeddingsOptions
Public Sub New (deploymentName As String, input As IEnumerable(Of String))

Parameters

deploymentName
String

The deployment name to use for an embeddings request.

input
IEnumerable<String>

Input texts to get embeddings for, encoded as a an array of strings. Each input must not exceed 2048 tokens in length.

Unless you are embedding code, we suggest replacing newlines (\n) in your input with a single space, as we have observed inferior results when newlines are present.

Exceptions

deploymentName or input is null.

deploymentName is an empty string.

Applies to