mirror of
https://github.com/DS4SD/docling.git
synced 2025-07-27 04:24:45 +00:00
Fix datamodel usage for Figure
Signed-off-by: Christoph Auer <cau@zurich.ibm.com>
This commit is contained in:
parent
c308d7e87a
commit
fd23432f6e
@ -11,6 +11,7 @@ from docling_core.types import FileInfoObject as DsFileInfoObject
|
|||||||
from docling_core.types import PageDimensions, PageReference, Prov, Ref
|
from docling_core.types import PageDimensions, PageReference, Prov, Ref
|
||||||
from docling_core.types import Table as DsSchemaTable
|
from docling_core.types import Table as DsSchemaTable
|
||||||
from docling_core.types import TableCell
|
from docling_core.types import TableCell
|
||||||
|
from docling_core.types.doc.base import Figure
|
||||||
from pydantic import BaseModel
|
from pydantic import BaseModel
|
||||||
from typing_extensions import deprecated
|
from typing_extensions import deprecated
|
||||||
|
|
||||||
@ -279,7 +280,7 @@ class ConvertedDocument(BaseModel):
|
|||||||
),
|
),
|
||||||
)
|
)
|
||||||
figures.append(
|
figures.append(
|
||||||
BaseCell(
|
Figure(
|
||||||
prov=[
|
prov=[
|
||||||
Prov(
|
Prov(
|
||||||
bbox=target_bbox,
|
bbox=target_bbox,
|
||||||
@ -344,7 +345,7 @@ class ConvertedDocument(BaseModel):
|
|||||||
"subtitle-level-1",
|
"subtitle-level-1",
|
||||||
"paragraph",
|
"paragraph",
|
||||||
"caption",
|
"caption",
|
||||||
]
|
],
|
||||||
):
|
):
|
||||||
return self.output.export_to_markdown(
|
return self.output.export_to_markdown(
|
||||||
delim=delim,
|
delim=delim,
|
||||||
|
Loading…
Reference in New Issue
Block a user