docling-project / docling-project/docling

Incorrect Reading Order in Single-page Image-Text Layouts

Open
#570 7 comments 1 reaction 1 assignee Claimed by @PeterStaar-IBM View on GitHub
bug pdf
Dominant language
Python
Stars
66.4k
Forks
4.8k
Avg merge
2d 21h
Merged PRs (30d)
84

Description

### Bug
There is an issue with the page reading order. Especially in single-page documents, the reading order of images on the left and text content on the right is not working as expected. This causes incorrect information mapping under images when converting to Markdown format.

### Steps to reproduce
1. Upload a single-page document
2. Use a page layout with an image on the left and text on the right
3. Convert the document to Markdown format
4. Check the output

### Expected Behavior:
Reading order should be: Page Title => Image 1 => Section-Header 1 => List Items => Image 2

### Actual Behavior:
Reading order is incorrect: Page Title => Image 1 => Image 2 => Section-Header 1

### Docling version
2.10.0

### Python version
3.10

### Sample layout
sample-layout

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.