diff options
author | Heiner Lohaus <hlohaus@users.noreply.github.com> | 2024-11-19 10:23:24 +0100 |
---|---|---|
committer | Heiner Lohaus <hlohaus@users.noreply.github.com> | 2024-11-19 10:23:24 +0100 |
commit | 7c10a036ed63b0a14f69b27552801dde4f220b4e (patch) | |
tree | bb63fe93fdad43581c64c23b92eb773b4ec0263e /g4f/Provider/needs_auth | |
parent | Update unittests (diff) | |
download | gpt4free-7c10a036ed63b0a14f69b27552801dde4f220b4e.tar gpt4free-7c10a036ed63b0a14f69b27552801dde4f220b4e.tar.gz gpt4free-7c10a036ed63b0a14f69b27552801dde4f220b4e.tar.bz2 gpt4free-7c10a036ed63b0a14f69b27552801dde4f220b4e.tar.lz gpt4free-7c10a036ed63b0a14f69b27552801dde4f220b4e.tar.xz gpt4free-7c10a036ed63b0a14f69b27552801dde4f220b4e.tar.zst gpt4free-7c10a036ed63b0a14f69b27552801dde4f220b4e.zip |
Diffstat (limited to 'g4f/Provider/needs_auth')
-rw-r--r-- | g4f/Provider/needs_auth/CopilotAccount.py | 3 | ||||
-rw-r--r-- | g4f/Provider/needs_auth/OpenaiChat.py | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/g4f/Provider/needs_auth/CopilotAccount.py b/g4f/Provider/needs_auth/CopilotAccount.py index fa43867e..76e51278 100644 --- a/g4f/Provider/needs_auth/CopilotAccount.py +++ b/g4f/Provider/needs_auth/CopilotAccount.py @@ -5,4 +5,5 @@ from ..Copilot import Copilot class CopilotAccount(Copilot): needs_auth = True parent = "Copilot" - default_model = ""
\ No newline at end of file + default_model = "Copilot" + default_vision_model = default_model
\ No newline at end of file diff --git a/g4f/Provider/needs_auth/OpenaiChat.py b/g4f/Provider/needs_auth/OpenaiChat.py index 13e15f1d..22264dd9 100644 --- a/g4f/Provider/needs_auth/OpenaiChat.py +++ b/g4f/Provider/needs_auth/OpenaiChat.py @@ -396,7 +396,7 @@ class OpenaiChat(AsyncGeneratorProvider, ProviderModelMixin): f"{cls.url}/backend-anon/sentinel/chat-requirements" if cls._api_key is None else f"{cls.url}/backend-api/sentinel/chat-requirements", - json={"p": get_requirements_token(RequestConfig.proof_token)}, + json={"p": get_requirements_token(RequestConfig.proof_token) if RequestConfig.proof_token else None}, headers=cls._headers ) as response: cls._update_request_args(session) |