docling-project / docling-project/docling
Include page images as REFERENCED when saving a docling document as json
Open
enhancement
triage/close-stale
- Dominant language
- Python
- Stars
- 66.4k
- Forks
- 4.8k
- Avg merge
- 2d 21h
- Merged PRs (30d)
- 84
Description
When you save a docling document as json using save_as_json and set the image_mode as imageRefMode.REFERENCED the images in the document are saved as references. However, if you generate page imags then the page_images are still embedded in the json file. This can make the json file very large.
It would be helpful if the page images were also referenced as well. Perhaps this could be handled by adding a page_mode argument, similar to image_mode. Alternatively the page images could follow the image_mode setting.
This capability would also be useful in export_to_dict.
Contributor guide
Assessment
This issue has not been assessed yet.