Skip to content

Conversation

@s1v4-d
Copy link
Contributor

@s1v4-d s1v4-d commented Jan 5, 2026

… items

Implements support for linking comments (from Word/PPT documents) to their annotated content using the established FloatingItem/RefItem pattern.

Changes:

  • Add comments: List[RefItem] field to DocItem class
  • Update _update_breadth_first_with_lookup() to handle comment references on deletion
  • Bump CURRENT_VERSION to 1.9.0
  • Fix version comparison bug (string vs integer for minor version)
  • Add 4 new tests for comments functionality
  • Update test data files for new schema

Closes: docling-project/docling#464
Related: docling-project/docling#2834

… items

Implements support for linking comments (from Word/PPT documents) to their
annotated content using the established FloatingItem/RefItem pattern.

Changes:
- Add `comments: List[RefItem]` field to DocItem class
- Update `_update_breadth_first_with_lookup()` to handle comment references on deletion
- Bump CURRENT_VERSION to 1.9.0
- Fix version comparison bug (string vs integer for minor version)
- Add 4 new tests for comments functionality
- Update test data files for new schema

Closes: docling-project/docling#464
Related: docling-project/docling#2834

Signed-off-by: s1v4-d <[email protected]>
@github-actions
Copy link
Contributor

github-actions bot commented Jan 5, 2026

DCO Check Passed

Thanks @s1v4-d, all your commits are properly signed off. 🎉

@dosubot
Copy link

dosubot bot commented Jan 5, 2026

Related Documentation

Checked 7 published document(s) in 0 knowledge base(s). No updates required.

How did I do? Any feedback?  Join Discord

@mergify
Copy link

mergify bot commented Jan 5, 2026

Merge Protections

Your pull request matches the following merge protections and will not be merged until they are valid.

🟢 Enforce conventional commit

Wonderful, this rule succeeded.

Make sure that we follow https://www.conventionalcommits.org/en/v1.0.0/

  • title ~= ^(fix|feat|docs|style|refactor|perf|test|build|ci|chore|revert)(?:\(.+\))?(!)?:

🟢 Require two reviewer for test updates

Wonderful, this rule succeeded.

When test data is updated, we require two reviewers

  • #approved-reviews-by >= 2

@codecov
Copy link

codecov bot commented Jan 7, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

Copy link
Member

@vagenas vagenas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added couple improvements:

  • introduced fine-granular references (FineRef) including span ranges
  • extended API with add_comment() operation encapsulating all relevant labels etc.
  • improved serialization to suppress empty .comments lists (most common case)

@PeterStaar-IBM PeterStaar-IBM merged commit 1d2e0c7 into docling-project:main Jan 8, 2026
20 checks passed
ryyhan pushed a commit to ryyhan/docling-core that referenced this pull request Jan 8, 2026
docling-project#465)

* feat(DocItem): Add comments field for linking annotations to document items

Implements support for linking comments (from Word/PPT documents) to their
annotated content using the established FloatingItem/RefItem pattern.

Changes:
- Add `comments: List[RefItem]` field to DocItem class
- Update `_update_breadth_first_with_lookup()` to handle comment references on deletion
- Bump CURRENT_VERSION to 1.9.0
- Fix version comparison bug (string vs integer for minor version)
- Add 4 new tests for comments functionality
- Update test data files for new schema

Closes: docling-project/docling#464
Related: docling-project/docling#2834

Signed-off-by: s1v4-d <[email protected]>

* improve comment Pydantic serialization

Signed-off-by: Panos Vagenas <[email protected]>

* add add_comment, update tests

Signed-off-by: Panos Vagenas <[email protected]>

* introduce fine-granular references with span ranges

Signed-off-by: Panos Vagenas <[email protected]>

* simplify last test

Signed-off-by: Panos Vagenas <[email protected]>

---------

Signed-off-by: s1v4-d <[email protected]>
Signed-off-by: Panos Vagenas <[email protected]>
Co-authored-by: Panos Vagenas <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants