forked from phoenix/litellm-mirror
refactor(openai.py): making it compatible for openai v1
BREAKING CHANGE:
This commit is contained in:
parent
833c38edeb
commit
d3323ba637
12 changed files with 622 additions and 370 deletions
|
@ -17,7 +17,10 @@ from concurrent import futures
|
|||
from inspect import iscoroutinefunction
|
||||
from functools import wraps
|
||||
from threading import Thread
|
||||
from openai.error import Timeout
|
||||
try:
|
||||
from openai import Timeout
|
||||
except:
|
||||
from openai.error import Timeout
|
||||
|
||||
|
||||
def timeout(timeout_duration: float = 0.0, exception_to_raise=Timeout):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue