(fix) ssl for acompletion with openai

This commit is contained in:
ishaan-jaff 2023-11-10 15:55:03 -08:00
parent 41c94d50e2
commit f9d4505ea0

View file

@ -257,7 +257,7 @@ class OpenAIChatCompletion(BaseLLM):
data: dict, headers: dict,
model_response: ModelResponse):
async with aiohttp.ClientSession() as session:
async with session.post(api_base, json=data, headers=headers) as response:
async with session.post(api_base, json=data, headers=headers, ssl=False) as response:
response_json = await response.json()
if response.status != 200:
raise OpenAIError(status_code=response.status, message=response.text)