From 255c0fab1d39501bdbeb4f43c647422de07b86fc Mon Sep 17 00:00:00 2001 From: ishaan-jaff Date: Tue, 14 Nov 2023 15:27:59 -0800 Subject: [PATCH] (docs) passing azure_ad_token to config --- docs/my-website/docs/simple_proxy.md | 19 +++++++++++++++++-- litellm/proxy/config.yaml | 23 ++++++++++++++--------- 2 files changed, 31 insertions(+), 11 deletions(-) diff --git a/docs/my-website/docs/simple_proxy.md b/docs/my-website/docs/simple_proxy.md index a4ae6267d..04e632620 100644 --- a/docs/my-website/docs/simple_proxy.md +++ b/docs/my-website/docs/simple_proxy.md @@ -523,8 +523,7 @@ model_list: - model_name: claude-2 litellm_params: model: claude-2 - api_key: sk-claude - + api_key: sk-claude ``` #### Default Model - Config: @@ -540,6 +539,22 @@ $ litellm --config /path/to/config.yaml If you're repo let's you set model name, you can call the specific model by just passing in that model's name - +#### Step 4: Use proxy +Curl Command +```shell +curl --location 'http://0.0.0.0:8000/chat/completions' \ +--header 'Content-Type: application/json' \ +--data ' { + "model": "gpt-4-team1", + "messages": [ + { + "role": "user", + "content": "what llm are you" + } + ], + } +' +``` **Setting model name** ```python import openai diff --git a/litellm/proxy/config.yaml b/litellm/proxy/config.yaml index 333c59719..fb0504ca7 100644 --- a/litellm/proxy/config.yaml +++ b/litellm/proxy/config.yaml @@ -4,17 +4,22 @@ model_list: model: huggingface/HuggingFaceH4/zephyr-7b-alpha max_tokens: 20 temperature: 0 - - model_name: gpt-4 - litellm_params: # params for litellm.completion() - https://docs.litellm.ai/docs/completion/input#input---request-body - model: gpt-4 + - model_name: gpt-4-team1 + litellm_params: + model: azure/chatgpt-v-2 + api_base: https://openai-gpt-4-test-v-1.openai.azure.com/ + api_version: "2023-05-15" + azure_ad_token: eyJ0eXAiOiJ + - model_name: gpt-4-team2 + litellm_params: + model: azure/gpt-4 + api_key: sk-123 + api_base: https://openai-gpt-4-test-v-2.openai.azure.com/ + - model_name: gpt-4-team3 + litellm_params: + model: azure/gpt-4 api_key: sk-123 - - model_name: mistral-7b - litellm_params: # params for litellm.completion() - https://docs.litellm.ai/docs/completion/input#input---request-body - model: deepinfra/mistralai/Mistral-7B-Instruct-v0.1 - api_key: sk-1234 litellm_settings: drop_params: True -general_settings: - master_key: sk-12345