OpenAI provider implementation for LiteLLM
OpenAI provider implementation for LiteLLM
Default cost per token for OpenAI models (in USD)
Default cost per token for OpenAI models (in USD)
Cost per token for OpenAI embedding models (in USD)
Cost per token for OpenAI embedding models (in USD)
(get-cost-per-token-impl provider-name model)OpenAI-specific get-cost-per-token implementation
OpenAI-specific get-cost-per-token implementation
(get-rate-limits-impl provider-name)OpenAI-specific get-rate-limits implementation
OpenAI-specific get-rate-limits implementation
(handle-error-response provider response)Handle OpenAI API error responses
Handle OpenAI API error responses
(health-check-impl provider-name thread-pool config)OpenAI-specific health-check implementation
OpenAI-specific health-check implementation
(list-models provider)List available OpenAI models
List available OpenAI models
(make-embedding-request-impl provider-name
transformed-request
thread-pool
telemetry
config)OpenAI-specific make-embedding-request implementation
OpenAI-specific make-embedding-request implementation
(make-request-impl provider-name
transformed-request
thread-pool
telemetry
config)OpenAI-specific make-request implementation
OpenAI-specific make-request implementation
(make-streaming-request-impl provider-name
transformed-request
thread-pool
config)OpenAI-specific make-streaming-request implementation
OpenAI-specific make-streaming-request implementation
(supports-embeddings-impl provider-name)OpenAI-specific supports-embeddings? implementation
OpenAI-specific supports-embeddings? implementation
(supports-function-calling-impl provider-name)OpenAI-specific supports-function-calling? implementation
OpenAI-specific supports-function-calling? implementation
(supports-streaming-impl provider-name)OpenAI-specific supports-streaming? implementation
OpenAI-specific supports-streaming? implementation
(test-openai-connection provider thread-pool telemetry)Test OpenAI connection with a simple request
Test OpenAI connection with a simple request
(transform-choice choice)Transform OpenAI choice to standard format
Transform OpenAI choice to standard format
(transform-embedding-request-impl provider-name request config)OpenAI-specific transform-embedding-request implementation
OpenAI-specific transform-embedding-request implementation
(transform-embedding-response-impl provider-name response)OpenAI-specific transform-embedding-response implementation
OpenAI-specific transform-embedding-response implementation
(transform-function-call function-call)Transform function call to OpenAI format (legacy)
Transform function call to OpenAI format (legacy)
(transform-function-call-response function-call)Transform OpenAI function call response to standard format
Transform OpenAI function call response to standard format
(transform-functions functions)Transform functions to OpenAI format (legacy)
Transform functions to OpenAI format (legacy)
(transform-message message)Transform OpenAI message to standard format
Transform OpenAI message to standard format
(transform-messages messages)Transform messages to OpenAI format
Transform messages to OpenAI format
(transform-request-impl provider-name request config)OpenAI-specific transform-request implementation
OpenAI-specific transform-request implementation
(transform-response-impl provider-name response)OpenAI-specific transform-response implementation
OpenAI-specific transform-response implementation
(transform-streaming-chunk-impl provider-name chunk)OpenAI-specific transform-streaming-chunk implementation
OpenAI-specific transform-streaming-chunk implementation
(transform-tool-calls tool-calls)Transform OpenAI tool calls to standard format
Transform OpenAI tool calls to standard format
(transform-tool-choice tool-choice)Transform tool choice to OpenAI format
Transform tool choice to OpenAI format
(transform-tools tools)Transform tools to OpenAI format
Transform tools to OpenAI format
(transform-usage usage)Transform OpenAI usage to standard format
Transform OpenAI usage to standard format
(validate-api-key api-key)Validate OpenAI API key
Validate OpenAI API key
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |