summaryrefslogtreecommitdiffstats
path: root/g4f/Provider/BingCreateImages.py
diff options
context:
space:
mode:
authorH Lohaus <hlohaus@users.noreply.github.com>2024-03-13 15:17:25 +0100
committerGitHub <noreply@github.com>2024-03-13 15:17:25 +0100
commit9c381f29060d697fe2d2c4768cd51b37d98ef3e0 (patch)
tree08a729476060f61f16ac8e909ed7dfe1cf4b2843 /g4f/Provider/BingCreateImages.py
parentMerge pull request #1680 from Zero6992/main (diff)
parentUpdate Bing.py (diff)
downloadgpt4free-9c381f29060d697fe2d2c4768cd51b37d98ef3e0.tar
gpt4free-9c381f29060d697fe2d2c4768cd51b37d98ef3e0.tar.gz
gpt4free-9c381f29060d697fe2d2c4768cd51b37d98ef3e0.tar.bz2
gpt4free-9c381f29060d697fe2d2c4768cd51b37d98ef3e0.tar.lz
gpt4free-9c381f29060d697fe2d2c4768cd51b37d98ef3e0.tar.xz
gpt4free-9c381f29060d697fe2d2c4768cd51b37d98ef3e0.tar.zst
gpt4free-9c381f29060d697fe2d2c4768cd51b37d98ef3e0.zip
Diffstat (limited to 'g4f/Provider/BingCreateImages.py')
-rw-r--r--g4f/Provider/BingCreateImages.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/g4f/Provider/BingCreateImages.py b/g4f/Provider/BingCreateImages.py
index c465c1d8..f9c4f3b3 100644
--- a/g4f/Provider/BingCreateImages.py
+++ b/g4f/Provider/BingCreateImages.py
@@ -7,14 +7,15 @@ from typing import Iterator, Union
from ..cookies import get_cookies
from ..image import ImageResponse
from ..errors import MissingRequirementsError, MissingAuthError
+from ..typing import Cookies
from .bing.create_images import create_images, create_session, get_cookies_from_browser
class BingCreateImages:
"""A class for creating images using Bing."""
- def __init__(self, cookies: dict[str, str] = {}, proxy: str = None) -> None:
- self.cookies = cookies
- self.proxy = proxy
+ def __init__(self, cookies: Cookies = None, proxy: str = None) -> None:
+ self.cookies: Cookies = cookies
+ self.proxy: str = proxy
def create(self, prompt: str) -> Iterator[Union[ImageResponse, str]]:
"""