diff options
Diffstat (limited to 'g4f/image.py')
-rw-r--r-- | g4f/image.py | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/g4f/image.py b/g4f/image.py index 270b59ad..3d339266 100644 --- a/g4f/image.py +++ b/g4f/image.py @@ -275,6 +275,18 @@ class ImagePreview(ImageResponse): def to_string(self): return super().__str__() +class ImageDataResponse(): + def __init__( + self, + images: Union[str, list], + alt: str, + ): + self.images = images + self.alt = alt + + def get_list(self) -> list[str]: + return [self.images] if isinstance(self.images, str) else self.images + class ImageRequest: def __init__( self, |