fix(proxy_cli.py): bump default azure api version

This commit is contained in:
Krrish Dholakia 2024-07-08 16:28:02 -07:00
parent f6a0d6f33d
commit fe62e4e1c4
2 changed files with 10 additions and 2 deletions

View file

@ -72,7 +72,7 @@ def is_port_in_use(port):
@click.option("--api_base", default=None, help="API base URL.")
@click.option(
"--api_version",
default="2023-07-01-preview",
default="2024-02-01",
help="For azure - pass in the api version.",
)
@click.option(

View file

@ -3477,8 +3477,16 @@ def get_optional_params(
model=model, custom_llm_provider="azure"
)
_check_valid_arg(supported_params=supported_params)
verbose_logger.debug(
"Azure optional params - api_version: api_version={}, litellm.api_version={}, os.environ['AZURE_API_VERSION']={}".format(
api_version, litellm.api_version, get_secret("AZURE_API_VERSION")
)
)
api_version = (
api_version or litellm.api_version or get_secret("AZURE_API_VERSION")
api_version
or litellm.api_version
or get_secret("AZURE_API_VERSION")
or litellm.AZURE_DEFAULT_API_VERSION
)
optional_params = litellm.AzureOpenAIConfig().map_openai_params(
non_default_params=non_default_params,