docling-core 2.48.0__tar.gz → 2.48.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of docling-core might be problematic. Click here for more details.
- {docling_core-2.48.0 → docling_core-2.48.1}/PKG-INFO +1 -1
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/serializer/markdown.py +1 -1
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core.egg-info/PKG-INFO +1 -1
- {docling_core-2.48.0 → docling_core-2.48.1}/pyproject.toml +1 -1
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_serialization.py +30 -1
- {docling_core-2.48.0 → docling_core-2.48.1}/LICENSE +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/README.md +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/__init__.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/cli/__init__.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/cli/view.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/experimental/__init__.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/py.typed +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/resources/schemas/doc/ANN.json +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/resources/schemas/doc/DOC.json +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/resources/schemas/doc/OCR-output.json +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/resources/schemas/doc/RAW.json +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/resources/schemas/generated/ccs_document_schema.json +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/resources/schemas/generated/minimal_document_schema_flat.json +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/resources/schemas/search/search_doc_mapping.json +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/resources/schemas/search/search_doc_mapping_v2.json +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/search/__init__.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/search/json_schema_to_search_mapper.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/search/mapping.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/search/meta.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/search/package.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/__init__.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/chunker/__init__.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/chunker/base.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/chunker/hierarchical_chunker.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/chunker/hybrid_chunker.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/chunker/page_chunker.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/chunker/tokenizer/__init__.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/chunker/tokenizer/base.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/chunker/tokenizer/huggingface.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/chunker/tokenizer/openai.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/serializer/__init__.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/serializer/base.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/serializer/common.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/serializer/doctags.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/serializer/html.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/serializer/html_styles.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/visualizer/__init__.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/visualizer/base.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/visualizer/key_value_visualizer.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/visualizer/layout_visualizer.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/visualizer/reading_order_visualizer.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/visualizer/table_visualizer.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/__init__.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/base.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/doc/__init__.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/doc/base.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/doc/document.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/doc/labels.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/doc/page.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/doc/tokens.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/doc/utils.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/gen/__init__.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/gen/generic.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/io/__init__.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/legacy_doc/__init__.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/legacy_doc/base.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/legacy_doc/doc_ann.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/legacy_doc/doc_ocr.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/legacy_doc/doc_raw.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/legacy_doc/document.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/legacy_doc/tokens.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/nlp/__init__.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/nlp/qa.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/nlp/qa_labels.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/rec/__init__.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/rec/attribute.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/rec/base.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/rec/predicate.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/rec/record.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/rec/statement.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/types/rec/subject.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/utils/__init__.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/utils/alias.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/utils/file.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/utils/generate_docs.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/utils/generate_jsonschema.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/utils/legacy.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/utils/validate.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core/utils/validators.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core.egg-info/SOURCES.txt +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core.egg-info/dependency_links.txt +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core.egg-info/entry_points.txt +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core.egg-info/requires.txt +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/docling_core.egg-info/top_level.txt +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/setup.cfg +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_base.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_collection.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_data_gen_flag.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_doc_base.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_doc_legacy_convert.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_doc_schema.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_doc_schema_extractor.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_docling_doc.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_doctags_load.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_hierarchical_chunker.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_hybrid_chunker.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_json_schema_to_search_mapper.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_nlp_qa.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_otsl_table_export.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_page.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_page_chunker.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_rec_schema.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_search_meta.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_utils.py +0 -0
- {docling_core-2.48.0 → docling_core-2.48.1}/test/test_visualization.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: docling-core
|
|
3
|
-
Version: 2.48.
|
|
3
|
+
Version: 2.48.1
|
|
4
4
|
Summary: A python library to define and validate data types in Docling.
|
|
5
5
|
Author-email: Cesar Berrospi Ramis <ceb@zurich.ibm.com>, Panos Vagenas <pva@zurich.ibm.com>, Michele Dolfi <dol@zurich.ibm.com>, Christoph Auer <cau@zurich.ibm.com>, Peter Staar <taa@zurich.ibm.com>
|
|
6
6
|
Maintainer-email: Panos Vagenas <pva@zurich.ibm.com>, Michele Dolfi <dol@zurich.ibm.com>, Christoph Auer <cau@zurich.ibm.com>, Peter Staar <taa@zurich.ibm.com>, Cesar Berrospi Ramis <ceb@zurich.ibm.com>
|
|
@@ -332,7 +332,7 @@ class MarkdownTableSerializer(BaseTableSerializer):
|
|
|
332
332
|
]
|
|
333
333
|
for row in item.data.grid
|
|
334
334
|
]
|
|
335
|
-
if len(rows) >
|
|
335
|
+
if len(rows) > 0:
|
|
336
336
|
try:
|
|
337
337
|
table_text = tabulate(rows[1:], headers=rows[0], tablefmt="github")
|
|
338
338
|
except ValueError:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: docling-core
|
|
3
|
-
Version: 2.48.
|
|
3
|
+
Version: 2.48.1
|
|
4
4
|
Summary: A python library to define and validate data types in Docling.
|
|
5
5
|
Author-email: Cesar Berrospi Ramis <ceb@zurich.ibm.com>, Panos Vagenas <pva@zurich.ibm.com>, Michele Dolfi <dol@zurich.ibm.com>, Christoph Auer <cau@zurich.ibm.com>, Peter Staar <taa@zurich.ibm.com>
|
|
6
6
|
Maintainer-email: Panos Vagenas <pva@zurich.ibm.com>, Michele Dolfi <dol@zurich.ibm.com>, Christoph Auer <cau@zurich.ibm.com>, Peter Staar <taa@zurich.ibm.com>, Cesar Berrospi Ramis <ceb@zurich.ibm.com>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "docling-core"
|
|
3
|
-
version = "2.48.
|
|
3
|
+
version = "2.48.1" # DO NOT EDIT, updated automatically
|
|
4
4
|
description = "A python library to define and validate data types in Docling."
|
|
5
5
|
license = "MIT"
|
|
6
6
|
license-files = ["LICENSE"]
|
|
@@ -25,7 +25,13 @@ from docling_core.transforms.serializer.markdown import (
|
|
|
25
25
|
)
|
|
26
26
|
from docling_core.transforms.visualizer.layout_visualizer import LayoutVisualizer
|
|
27
27
|
from docling_core.types.doc.base import ImageRefMode
|
|
28
|
-
from docling_core.types.doc.document import
|
|
28
|
+
from docling_core.types.doc.document import (
|
|
29
|
+
DoclingDocument,
|
|
30
|
+
MiscAnnotation,
|
|
31
|
+
TableCell,
|
|
32
|
+
TableData,
|
|
33
|
+
TableItem,
|
|
34
|
+
)
|
|
29
35
|
from docling_core.types.doc.labels import DocItemLabel
|
|
30
36
|
|
|
31
37
|
from .test_data_gen_flag import GEN_TEST_DATA
|
|
@@ -317,6 +323,29 @@ def test_md_rich_table():
|
|
|
317
323
|
verify(exp_file=exp_file, actual=actual)
|
|
318
324
|
|
|
319
325
|
|
|
326
|
+
def test_md_single_row_table():
|
|
327
|
+
exp_file = Path("./test/data/doc/single_row_table.gt.md")
|
|
328
|
+
words = ["foo", "bar"]
|
|
329
|
+
doc = DoclingDocument(name="")
|
|
330
|
+
row_idx = 0
|
|
331
|
+
table = doc.add_table(data=TableData(num_rows=1, num_cols=len(words)))
|
|
332
|
+
for col_idx, word in enumerate(words):
|
|
333
|
+
doc.add_table_cell(
|
|
334
|
+
table_item=table,
|
|
335
|
+
cell=TableCell(
|
|
336
|
+
start_row_offset_idx=row_idx,
|
|
337
|
+
end_row_offset_idx=row_idx + 1,
|
|
338
|
+
start_col_offset_idx=col_idx,
|
|
339
|
+
end_col_offset_idx=col_idx + 1,
|
|
340
|
+
text=word,
|
|
341
|
+
),
|
|
342
|
+
)
|
|
343
|
+
|
|
344
|
+
ser = MarkdownDocSerializer(doc=doc)
|
|
345
|
+
actual = ser.serialize().text
|
|
346
|
+
verify(exp_file=exp_file, actual=actual)
|
|
347
|
+
|
|
348
|
+
|
|
320
349
|
# ===============================
|
|
321
350
|
# HTML tests
|
|
322
351
|
# ===============================
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{docling_core-2.48.0 → docling_core-2.48.1}/docling_core/resources/schemas/doc/OCR-output.json
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{docling_core-2.48.0 → docling_core-2.48.1}/docling_core/search/json_schema_to_search_mapper.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/chunker/hierarchical_chunker.py
RENAMED
|
File without changes
|
{docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/chunker/hybrid_chunker.py
RENAMED
|
File without changes
|
|
File without changes
|
{docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/chunker/tokenizer/__init__.py
RENAMED
|
File without changes
|
{docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/chunker/tokenizer/base.py
RENAMED
|
File without changes
|
{docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/chunker/tokenizer/huggingface.py
RENAMED
|
File without changes
|
{docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/chunker/tokenizer/openai.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/serializer/html_styles.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/visualizer/layout_visualizer.py
RENAMED
|
File without changes
|
|
File without changes
|
{docling_core-2.48.0 → docling_core-2.48.1}/docling_core/transforms/visualizer/table_visualizer.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|