forked from phoenix/litellm-mirror
refactor: move all testing to top-level of repo
Closes https://github.com/BerriAI/litellm/issues/486
This commit is contained in:
parent
5403c5828c
commit
3560f0ef2c
213 changed files with 74 additions and 217 deletions
29
tests/local_testing/test_model_max_token_adjust.py
Normal file
29
tests/local_testing/test_model_max_token_adjust.py
Normal file
|
@ -0,0 +1,29 @@
|
|||
# What this tests?
|
||||
## Tests if max tokens get adjusted, if over limit
|
||||
|
||||
import sys, os, time
|
||||
import traceback, asyncio
|
||||
import pytest
|
||||
|
||||
sys.path.insert(
|
||||
0, os.path.abspath("../..")
|
||||
) # Adds the parent directory to the system path
|
||||
import litellm
|
||||
from litellm import completion
|
||||
|
||||
|
||||
@pytest.mark.skip(reason="AWS Suspended Account")
|
||||
def test_completion_sagemaker():
|
||||
litellm.set_verbose = True
|
||||
litellm.drop_params = True
|
||||
response = completion(
|
||||
model="sagemaker/berri-benchmarking-Llama-2-70b-chat-hf-4",
|
||||
messages=[{"content": "Hello, how are you?", "role": "user"}],
|
||||
temperature=0.2,
|
||||
max_tokens=80000,
|
||||
hf_model_name="meta-llama/Llama-2-70b-chat-hf",
|
||||
)
|
||||
print(f"response: {response}")
|
||||
|
||||
|
||||
# test_completion_sagemaker()
|
Loading…
Add table
Add a link
Reference in a new issue