mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-25 18:54:30 +00:00
:test_completion_azure_ad_toke
This commit is contained in:
parent
d4b3082ca2
commit
842625a6f0
1 changed files with 13 additions and 16 deletions
|
@ -102,22 +102,19 @@ class BaseOpenAILLM:
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def _get_async_http_client() -> Optional[httpx.AsyncClient]:
|
def _get_async_http_client() -> Optional[httpx.AsyncClient]:
|
||||||
if litellm.ssl_verify:
|
if litellm.aclient_session is not None:
|
||||||
return httpx.AsyncClient(
|
return litellm.aclient_session
|
||||||
limits=httpx.Limits(
|
|
||||||
max_connections=1000, max_keepalive_connections=100
|
return httpx.AsyncClient(
|
||||||
),
|
limits=httpx.Limits(max_connections=1000, max_keepalive_connections=100),
|
||||||
verify=litellm.ssl_verify,
|
verify=litellm.ssl_verify,
|
||||||
)
|
)
|
||||||
return litellm.aclient_session
|
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def _get_sync_http_client() -> Optional[httpx.Client]:
|
def _get_sync_http_client() -> Optional[httpx.Client]:
|
||||||
if litellm.ssl_verify:
|
if litellm.client_session is not None:
|
||||||
return httpx.Client(
|
return litellm.client_session
|
||||||
limits=httpx.Limits(
|
return httpx.Client(
|
||||||
max_connections=1000, max_keepalive_connections=100
|
limits=httpx.Limits(max_connections=1000, max_keepalive_connections=100),
|
||||||
),
|
verify=litellm.ssl_verify,
|
||||||
verify=litellm.ssl_verify,
|
)
|
||||||
)
|
|
||||||
return litellm.client_session
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue