LanguageModelV4CallOptions
Namespace: E2E.Decision.Sdk
public sealed record LanguageModelV4CallOptions : IEquatable<LanguageModelV4CallOptions>The AI SDK’s LanguageModelV4CallOptions (language-model-v4-call-options.ts). Upstream’s abortSignal is the
CancellationToken of DoGenerateAsync and DoStreamAsync.
Inheritance: object
Implements: IEquatable<LanguageModelV4CallOptions>
Properties
Section titled “Properties”FrequencyPenalty
Section titled “FrequencyPenalty”public double? FrequencyPenalty { get; init; }Frequency penalty setting: the likelihood of the model repeatedly using the same words or phrases.
Value: double?
Headers
Section titled “Headers”public IReadOnlyDictionary<string, string?>? Headers { get; init; }Additional HTTP headers to be sent with the request. A null value leaves the header out.
Value: IReadOnlyDictionary<string, string>
IncludeRawChunks
Section titled “IncludeRawChunks”public bool? IncludeRawChunks { get; init; }Include raw chunks in the stream. Only applicable for streaming calls.
Value: bool?
MaxOutputTokens
Section titled “MaxOutputTokens”public int? MaxOutputTokens { get; init; }Maximum number of tokens to generate.
Value: int?
PresencePenalty
Section titled “PresencePenalty”public double? PresencePenalty { get; init; }Presence penalty setting: the likelihood of the model repeating information that is already in the prompt.
Value: double?
Prompt
Section titled “Prompt”public required IReadOnlyList<LanguageModelV4Message> Prompt { get; init; }A language model prompt: the standardized prompt type. This is not the user-facing prompt; the AI SDK methods map the user-facing prompt types to this format.
Value: IReadOnlyList<LanguageModelV4Message>
ProviderOptions
Section titled “ProviderOptions”public IReadOnlyDictionary<string, JsonElement>? ProviderOptions { get; init; }Additional provider-specific options, passed through to the provider, keyed by provider name.
Value: IReadOnlyDictionary<string, JsonElement>
Reasoning
Section titled “Reasoning”public string? Reasoning { get; init; }Reasoning effort level for the model: provider-default, none, minimal, low, medium, high,
xhigh, or max. Defaults to provider-default.
Value: string
ResponseFormat
Section titled “ResponseFormat”public LanguageModelV4ResponseFormat? ResponseFormat { get; init; }Response format. The output can either be text or JSON. Default is text.
Value: LanguageModelV4ResponseFormat
public int? Seed { get; init; }The seed (integer) to use for random sampling. If set and supported by the model, calls generate deterministic results.
Value: int?
StopSequences
Section titled “StopSequences”public IReadOnlyList<string>? StopSequences { get; init; }Stop sequences. If set, the model stops generating text when one of them is generated.
Value: IReadOnlyList<string>
Temperature
Section titled “Temperature”public double? Temperature { get; init; }Temperature setting. The range depends on the provider and model.
Value: double?
ToolChoice
Section titled “ToolChoice”public LanguageModelV4ToolChoice? ToolChoice { get; init; }Specifies how the tool should be selected. Defaults to auto.
Value: LanguageModelV4ToolChoice
public IReadOnlyList<LanguageModelV4Tool>? Tools { get; init; }The tools that are available for the model.
Value: IReadOnlyList<LanguageModelV4Tool>
public int? TopK { get; init; }Only sample from the top K options for each subsequent token.
Value: int?
public double? TopP { get; init; }Nucleus sampling.
Value: double?