Models
OpenAI Model
Configure OpenAI as your model provider
The openai
function configures OpenAI as your model provider.
Configuration
The openai
function accepts a model name string or a configuration object:
Options
ID of the model to use. See the model endpoint compatibility table for details on which models work with the Chat API.
The OpenAI API key to use for authenticating your request. By default we’ll
search for and use the OPENAI_API_KEY
environment variable.
The base URL for the OpenAI API.
Available Models
gpt-4o
chatgpt-4o-latest
gpt-4o-mini
gpt-4
o1-preview
o1-mini
gpt-3.5-turbo