mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-26 03:04:13 +00:00
feat - allow looking up model_id in model info
This commit is contained in:
parent
d4577fe476
commit
12343650e4
2 changed files with 51 additions and 5 deletions
21
litellm/proxy/common_utils/openai_endpoint_utils.py
Normal file
21
litellm/proxy/common_utils/openai_endpoint_utils.py
Normal file
|
@ -0,0 +1,21 @@
|
|||
"""
|
||||
Contains utils used by OpenAI compatible endpoints
|
||||
"""
|
||||
|
||||
|
||||
def remove_sensitive_info_from_deployment(deployment_dict: dict) -> dict:
|
||||
"""
|
||||
Removes sensitive information from a deployment dictionary.
|
||||
|
||||
Args:
|
||||
deployment_dict (dict): The deployment dictionary to remove sensitive information from.
|
||||
|
||||
Returns:
|
||||
dict: The modified deployment dictionary with sensitive information removed.
|
||||
"""
|
||||
deployment_dict["litellm_params"].pop("api_key", None)
|
||||
deployment_dict["litellm_params"].pop("vertex_credentials", None)
|
||||
deployment_dict["litellm_params"].pop("aws_access_key_id", None)
|
||||
deployment_dict["litellm_params"].pop("aws_secret_access_key", None)
|
||||
|
||||
return deployment_dict
|
Loading…
Add table
Add a link
Reference in a new issue