docling-project / docling-project/docling-core
Enhancement: Recognize Split words with - at the end of a line
- Dominant language
- HTML
- Stars
- 282
- Forks
- 214
- Avg merge
- 2d 16h
- Merged PRs (30d)
- 23
Description
Docling does not recognize that word that are at the end on a line with a - are often the same word or strongly connected to the word in the next line.
Since my professor did this a lot in the script I am currently working through I wrote a script for myself that checks all the text ending in -, but I think this is worth looking into.
Here is an example:

Docling correctly recognizes part of it as the caption (I exported to json to get an idea what is going on):


But the second part is read as normal text not caption and is not connected.
Contributor guide
Research direction
Start by reproducing the attached example and inspecting the exported JSON to understand how the line-ending hyphen and following line are represented. Trace the document transformation path responsible for connecting text and assigning captions. Done means hyphenated words are recognized as connected across lines without losing the correct caption classification.
Written by the indexing model from the issue text.
Assessment
- Domain
- content
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100