package
0.9.2
Repository: https://github.com/modernice/dragoman.git
Documentation: pkg.go.dev

# Functions

ChatTokens computes the total number of tokens in a list of ChatCompletionMessages for a given model.
No description provided by the author
MaxTokens sets the maximum number of tokens that the Client's model can generate.
Model is a function that returns an Option which sets the model string field of a Client object when called.
New creates a new Client instance with the specified API token and optional configuration options.
PromptTokens computes the number of tokens in the given prompt string for the specified model.
ResponseFormat configures the format of the response received from the OpenAI API when generating text completions.
Stream is an option function that sets the writer to which the generated text completions will be streamed.
Temperature sets the temperature parameter for the Client.
Timeout is a function that sets the timeout duration for the Client.
TopP sets the topP parameter for the Client.
Verbose sets the verbosity level of the Client instance.

# Constants

No description provided by the author
DefaultModel is the default language model used for generating text when no specific model is set during the client creation.
DefaultTemperature is the default value for the temperature parameter in the AI model.
DefaultTimeout specifies the default duration to wait before timing out requests to the OpenAI API.
DefaultTopP is the default value for the "Top P" parameter used in OpenAI's language models.

# Structs

Client is a configurable interface to the OpenAI API.

# Type aliases

Option is a function type used to configure a Client.