You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
TLDR: We allow you to use any LLM as a drop in replacement for gpt-3.5-turbo.
If you don't have access to the LLM you can use the LiteLLM proxy to make requests to the LLM
You can use LiteLLM in the following ways:
With your own API KEY:
This calls the provider API directly
fromlitellmimportcompletionimportos## set ENV variables os.environ["OPENAI_API_KEY"] ="your-key"# os.environ["COHERE_API_KEY"] ="your-key"# messages= [{ "content": "Hello, how are you?","role": "user"}]
# openai callresponse=completion(model="gpt-3.5-turbo", messages=messages)
# cohere callresponse=completion(model="command-nightly", messages=messages)
Using the LiteLLM Proxy with a LiteLLM Key
this is great if you don’t have access to claude but want to use the open source LiteLLM proxy to access claude
fromlitellmimportcompletionimportos## set ENV variables os.environ["OPENAI_API_KEY"] ="sk-litellm-5b46387675a944d2"# [OPTIONAL] replace with your openai keyos.environ["COHERE_API_KEY"] ="sk-litellm-5b46387675a944d2"# [OPTIONAL] replace with your cohere keymessages= [{ "content": "Hello, how are you?","role": "user"}]
# openai callresponse=completion(model="gpt-3.5-turbo", messages=messages)
# cohere callresponse=completion(model="command-nightly", messages=messages)
Describe the feature you'd like to request
I've an OpenAI service at MS Azure and I'd like to use it as AI provider instead of OpenAI directly.
Describe the solution you'd like
Into the Connected accounts (OpenAI integration) we could have this option:
Endpoint url: https://testeai.openai.azure.com/ (for example)
Key: ******
Describe alternatives you've considered
Nono
The text was updated successfully, but these errors were encountered: