OperationRequest
Namespace: Vercel.AI.Operations
public class OperationRequestShared request fields for an operation call.
Inheritance: object
Derived: BatchRequestOptions, DecideRequest, EmbedManyRequest, EmbedRequest, EvaluateRequest, GenerateImageRequest, GenerateSpeechRequest, GenerateVideoRequest, GetVideoStatusRequest, RerankRequest, StreamSpeechRequest, StreamTranscribeRequest, StreamTranslateRequest, TranscribeRequest
Properties
Section titled “Properties”AbortReason
Section titled “AbortReason”public Exception? AbortReason { get; set; }Exception thrown when CancellationToken is already cancelled.
Value: Exception
CancellationToken
Section titled “CancellationToken”public CancellationToken CancellationToken { get; set; }Cancels the call.
Value: CancellationToken
GenerateCallId
Section titled “GenerateCallId”public Func<string>? GenerateCallId { get; set; }Supplies call ids. Tests pass a constant generator.
Value: Func<string>
Headers
Section titled “Headers”public IReadOnlyDictionary<string, string>? Headers { get; set; }Extra HTTP headers.
Value: IReadOnlyDictionary<string, string>
MaxRetries
Section titled “MaxRetries”public int? MaxRetries { get; set; }Maximum retries after the first attempt. Default is 2.
Value: int?
public Func<DateTime>? Now { get; set; }Clock used when a provider omits a timestamp.
Value: Func<DateTime>
ProviderOptions
Section titled “ProviderOptions”public JsonElement? ProviderOptions { get; set; }Provider-specific options.
Value: JsonElement?
RuntimeContext
Section titled “RuntimeContext”public IReadOnlyDictionary<string, object?>? RuntimeContext { get; set; }Values copied onto user callbacks. Telemetry receives the filtered copy.
Apache-2.0 · Copyright 2023 Vercel, Inc. · unofficial community port, not an official Vercel product