From 0da73f12b9f0dfe6d02abe88d1743c549d9dde87 Mon Sep 17 00:00:00 2001 From: Philippe Prados Date: Sat, 18 Jan 2025 08:09:34 +0100 Subject: [PATCH] Remove Image.__init__ --- .../document_loaders/parsers/images.py | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/libs/community/langchain_community/document_loaders/parsers/images.py b/libs/community/langchain_community/document_loaders/parsers/images.py index 2778db5fc44d8..2a744ce438489 100644 --- a/libs/community/langchain_community/document_loaders/parsers/images.py +++ b/libs/community/langchain_community/document_loaders/parsers/images.py @@ -22,25 +22,6 @@ class BaseImageBlobParser(BaseBlobParser): """Abstract base class for parsing image blobs into text.""" - def __init__( - self, - *, - format: Union[Literal["text", "markdown-img", "html-img"], str] = "text", - ) -> None: - """Initializes the BaseImageBlobParser. - - Args: - format (Literal["text", "markdown-img", "html-img"]|str): - The format for the parsed output. - - "text" = return the content as is - - "markdown-img" = wrap the content into an image markdown link, w/ link - pointing to (`![body)(#)`] - - "html-img" = wrap the content as the `alt` text of an tag and link to - (`{body}`) - - or other formats if the parser supports it - """ - self.format = format - @abstractmethod def _analyze_image(self, img: "Image") -> str: """Abstract method to analyze an image and extract textual content.