(feat) add better debugging when DB read/write fails

This commit is contained in:
ishaan-jaff 2024-03-05 18:16:59 -08:00
parent 01d3fdbb65
commit 79f5e36540
2 changed files with 44 additions and 19 deletions

View file

@ -4,7 +4,9 @@ import uuid
import traceback
litellm_client = AsyncOpenAI(base_url="http://0.0.0.0:8000", api_key="any")
litellm_client = AsyncOpenAI(
base_url="http://0.0.0.0:4000", api_key="sk-iNwH_oOtAQ6syi_2gkEOpQ"
)
async def litellm_completion():
@ -27,7 +29,7 @@ async def litellm_completion():
async def main():
for i in range(150):
start = time.time()
n = 150 # Number of concurrent tasks
n = 2000 # Number of concurrent tasks
tasks = [litellm_completion() for _ in range(n)]
chat_completions = await asyncio.gather(*tasks)