Liking cljdoc? Tell your friends :D

litellm.providers.openai

OpenAI provider implementation for LiteLLM

OpenAI provider implementation for LiteLLM
raw docstring

default-cost-mapclj

Default cost per token for OpenAI models (in USD)

Default cost per token for OpenAI models (in USD)
sourceraw docstring

default-model-mappingclj

Default model name mappings

Default model name mappings
sourceraw docstring

get-cost-per-token-implclj

(get-cost-per-token-impl provider-name model)

OpenAI-specific get-cost-per-token implementation

OpenAI-specific get-cost-per-token implementation
sourceraw docstring

get-rate-limits-implclj

(get-rate-limits-impl provider-name)

OpenAI-specific get-rate-limits implementation

OpenAI-specific get-rate-limits implementation
sourceraw docstring

handle-error-responseclj

(handle-error-response provider response)

Handle OpenAI API error responses

Handle OpenAI API error responses
sourceraw docstring

health-check-implclj

(health-check-impl provider-name thread-pool config)

OpenAI-specific health-check implementation

OpenAI-specific health-check implementation
sourceraw docstring

list-modelsclj

(list-models provider)

List available OpenAI models

List available OpenAI models
sourceraw docstring

make-request-implclj

(make-request-impl provider-name
                   transformed-request
                   thread-pool
                   telemetry
                   config)

OpenAI-specific make-request implementation

OpenAI-specific make-request implementation
sourceraw docstring

make-streaming-request-implclj

(make-streaming-request-impl provider-name
                             transformed-request
                             thread-pool
                             config)

OpenAI-specific make-streaming-request implementation

OpenAI-specific make-streaming-request implementation
sourceraw docstring

supports-function-calling-implclj

(supports-function-calling-impl provider-name)

OpenAI-specific supports-function-calling? implementation

OpenAI-specific supports-function-calling? implementation
sourceraw docstring

supports-streaming-implclj

(supports-streaming-impl provider-name)

OpenAI-specific supports-streaming? implementation

OpenAI-specific supports-streaming? implementation
sourceraw docstring

test-openai-connectionclj

(test-openai-connection provider thread-pool telemetry)

Test OpenAI connection with a simple request

Test OpenAI connection with a simple request
sourceraw docstring

transform-choiceclj

(transform-choice choice)

Transform OpenAI choice to standard format

Transform OpenAI choice to standard format
sourceraw docstring

transform-function-callclj

(transform-function-call function-call)

Transform function call to OpenAI format (legacy)

Transform function call to OpenAI format (legacy)
sourceraw docstring

transform-function-call-responseclj

(transform-function-call-response function-call)

Transform OpenAI function call response to standard format

Transform OpenAI function call response to standard format
sourceraw docstring

transform-functionsclj

(transform-functions functions)

Transform functions to OpenAI format (legacy)

Transform functions to OpenAI format (legacy)
sourceraw docstring

transform-messageclj

(transform-message message)

Transform OpenAI message to standard format

Transform OpenAI message to standard format
sourceraw docstring

transform-messagesclj

(transform-messages messages)

Transform messages to OpenAI format

Transform messages to OpenAI format
sourceraw docstring

transform-request-implclj

(transform-request-impl provider-name request config)

OpenAI-specific transform-request implementation

OpenAI-specific transform-request implementation
sourceraw docstring

transform-response-implclj

(transform-response-impl provider-name response)

OpenAI-specific transform-response implementation

OpenAI-specific transform-response implementation
sourceraw docstring

transform-streaming-chunk-implclj

(transform-streaming-chunk-impl provider-name chunk)

OpenAI-specific transform-streaming-chunk implementation

OpenAI-specific transform-streaming-chunk implementation
sourceraw docstring

transform-tool-callsclj

(transform-tool-calls tool-calls)

Transform OpenAI tool calls to standard format

Transform OpenAI tool calls to standard format
sourceraw docstring

transform-tool-choiceclj

(transform-tool-choice tool-choice)

Transform tool choice to OpenAI format

Transform tool choice to OpenAI format
sourceraw docstring

transform-toolsclj

(transform-tools tools)

Transform tools to OpenAI format

Transform tools to OpenAI format
sourceraw docstring

transform-usageclj

(transform-usage usage)

Transform OpenAI usage to standard format

Transform OpenAI usage to standard format
sourceraw docstring

validate-api-keyclj

(validate-api-key api-key)

Validate OpenAI API key

Validate OpenAI API key
sourceraw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
Move to previous article
Move to next article
Ctrl+/Jump to the search field
× close