struct AI::OpenAI::OpenAIEmbeddingProviderOptions

Overview

Provider-specific options for OpenAI embedding models.

These options can be passed via provider_options["openai"] in the embedding call options.

Included Modules

Defined in:

ai/openai/embedding/openai_embedding_options.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(pull : JSON::PullParser) #

[View source]
def self.new(dimensions : Int32 | Nil = nil, user : String | Nil = nil) #

[View source]
def self.new(*, __pull_for_json_serializable pull : JSON::PullParser) #

[View source]

Instance Method Detail

def dimensions : Int32 | Nil #

The number of dimensions the resulting output embeddings should have. Only supported in text-embedding-3 and later models.


[View source]
def user : String | Nil #

A unique identifier representing your end-user, which can help OpenAI to monitor and detect abuse.


[View source]