mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-26 03:04:13 +00:00
(test) semantic cache
This commit is contained in:
parent
1b39454a08
commit
cf4bd1cf4e
1 changed files with 2 additions and 1 deletions
|
@ -990,7 +990,7 @@ def test_cache_context_managers():
|
|||
|
||||
|
||||
def test_redis_semantic_cache_completion():
|
||||
litellm.set_verbose = False
|
||||
litellm.set_verbose = True
|
||||
|
||||
random_number = random.randint(
|
||||
1, 100000
|
||||
|
@ -1003,6 +1003,7 @@ def test_redis_semantic_cache_completion():
|
|||
host=os.environ["REDIS_HOST"],
|
||||
port=os.environ["REDIS_PORT"],
|
||||
password=os.environ["REDIS_PASSWORD"],
|
||||
similarity_threshold=0.5,
|
||||
)
|
||||
print("test2 for Redis Caching - non streaming")
|
||||
response1 = completion(model="gpt-3.5-turbo", messages=messages, max_tokens=20)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue