mirror of https://github.com/xtekky/gpt4free.git
Fix attr conversation_id not found
This commit is contained in:
parent
fd92918b77
commit
d0da5900c4
|
@ -392,8 +392,8 @@ class OpenaiChat(AsyncGeneratorProvider, ProviderModelMixin):
|
|||
fields = Conversation() if conversation is None else copy(conversation)
|
||||
fields.finish_reason = None
|
||||
while fields.finish_reason is None:
|
||||
conversation_id = conversation_id if fields.conversation_id is None else fields.conversation_id
|
||||
parent_id = parent_id if fields.message_id is None else fields.message_id
|
||||
conversation_id = fields.conversation_id if hasattr(fields, "conversation_id") else conversation_id
|
||||
parent_id = fields.message_id if hasattr(fields, "message_id") else parent_id
|
||||
websocket_request_id = str(uuid.uuid4())
|
||||
data = {
|
||||
"action": action,
|
||||
|
|
|
@ -20,4 +20,4 @@ aiohttp_socks
|
|||
gpt4all
|
||||
pywebview
|
||||
plyer
|
||||
pycryptodome
|
||||
cryptography
|
24
setup.py
24
setup.py
|
@ -20,22 +20,27 @@ EXTRA_REQUIRE = {
|
|||
"curl_cffi>=0.6.2",
|
||||
"certifi",
|
||||
"browser_cookie3", # get_cookies
|
||||
"PyExecJS", # GptForLove
|
||||
"PyExecJS", # GptForLove, Vercel
|
||||
"duckduckgo-search>=5.0" ,# internet.search
|
||||
"beautifulsoup4", # internet.search and bing.create_images
|
||||
"brotli", # openai
|
||||
#"undetected-chromedriver>=3.5.5", # webdriver
|
||||
#"setuptools", # webdriver
|
||||
"brotli", # openai, bing
|
||||
# webdriver
|
||||
#"undetected-chromedriver>=3.5.5",
|
||||
#"setuptools",
|
||||
#"selenium-wire"
|
||||
# webview
|
||||
"pywebview",
|
||||
"platformdirs",
|
||||
"plyer",
|
||||
"cryptography",
|
||||
####
|
||||
"aiohttp_socks", # proxy
|
||||
"pillow", # image
|
||||
"cairosvg", # svg image
|
||||
"werkzeug", "flask", # gui
|
||||
"loguru", "fastapi",
|
||||
"loguru", "fastapi", # api
|
||||
"uvicorn", "nest_asyncio", # api
|
||||
#"selenium-wire"
|
||||
"pycryptodome" # openai
|
||||
],
|
||||
"image": [
|
||||
"pillow",
|
||||
|
@ -51,9 +56,12 @@ EXTRA_REQUIRE = {
|
|||
"webview": [
|
||||
"webview",
|
||||
"platformdirs",
|
||||
"plyer"
|
||||
"plyer",
|
||||
"cryptography"
|
||||
],
|
||||
"openai": [
|
||||
"pycryptodome"
|
||||
],
|
||||
"openai": [],
|
||||
"api": [
|
||||
"loguru", "fastapi",
|
||||
"uvicorn", "nest_asyncio"
|
||||
|
|
Loading…
Reference in New Issue