diff options
Diffstat (limited to 'g4f/Provider/Bing.py')
-rw-r--r-- | g4f/Provider/Bing.py | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/g4f/Provider/Bing.py b/g4f/Provider/Bing.py index 88394f70..5910c6b4 100644 --- a/g4f/Provider/Bing.py +++ b/g4f/Provider/Bing.py @@ -15,8 +15,11 @@ class Bing(AsyncGeneratorProvider): def create_async_generator( model: str, messages: list[dict[str, str]], - cookies: dict = get_cookies(".bing.com"), **kwargs) -> AsyncGenerator: - + cookies: dict = None, + **kwargs + ) -> AsyncGenerator: + if not cookies: + cookies = get_cookies(".bing.com") if len(messages) < 2: prompt = messages[0]["content"] context = None @@ -308,4 +311,5 @@ def run(generator: AsyncGenerator[Union[Any, str], Any]): yield loop.run_until_complete(gen.__anext__()) except StopAsyncIteration: - break
\ No newline at end of file + break + |