refactor EXCEL to XLSX

Signed-off-by: Peter Staar <taa@zurich.ibm.com>
This commit is contained in:
Peter Staar 2024-11-16 08:05:30 +01:00
parent bc31f2a973
commit c9c4810c25
2 changed files with 3 additions and 3 deletions

View File

@ -67,7 +67,7 @@ class MsExcelDocumentBackend(DeclarativeDocumentBackend):
@classmethod
def supported_formats(cls) -> Set[InputFormat]:
return {InputFormat.EXCEL}
return {InputFormat.XLSX}
def convert(self) -> DoclingDocument:
# Parses the DOCX into a structured document model.
@ -76,7 +76,7 @@ class MsExcelDocumentBackend(DeclarativeDocumentBackend):
origin = DocumentOrigin(
filename=self.file.name or "file",
mimetype="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
mimetype="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
binary_hash=self.document_hash,
)

View File

@ -86,7 +86,7 @@ class ImageFormatOption(FormatOption):
_format_to_default_options = {
InputFormat.EXCEL: FormatOption(
InputFormat.XLSX: FormatOption(
pipeline_cls=SimplePipeline, backend=MsExcelDocumentBackend
),
InputFormat.DOCX: FormatOption(