Retrieves an OpenAI client (sync or async) based on the current configuration.
Returns:
Type |
Description |
Union[AsyncClient, Client, AzureOpenAI, AsyncAzureOpenAI]
|
|
Example
Retrieving an OpenAI client
from marvin.utilities.openai import get_client
client = get_client()