bump version

This commit is contained in:
Krrish Dholakia 2023-09-08 13:12:18 -07:00
parent b0a2e57a8a
commit 8acf959430
2 changed files with 13 additions and 1 deletions

View file

@ -1411,6 +1411,18 @@ def valid_model(model):
except:
raise InvalidRequestError(message="", model=model, llm_provider="")
# check valid api key
def check_valid_key(model: str, api_key: str):
messages = [{"role": "user", "content": "Hey, how's it going?"}]
try:
litellm.completion(model=model, messages=messages, api_key=api_key)
return True
except AuthenticationError as e:
return False
except Exception as e:
raise ValueError(str(e))
# integration helper function
def modify_integration(integration_name, integration_params):

View file

@ -1,6 +1,6 @@
[tool.poetry]
name = "litellm"
version = "0.1.561"
version = "0.1.562"
description = "Library to easily interface with LLM API providers"
authors = ["BerriAI"]
license = "MIT License"