Serve keeps "text": "" on formula items (do_formula_enrichment=false). The Java DoclingDocument still has text as "", but serialization drops it:
DoclingDocument doc = response.getDocument().getJsonContent();
// doc still has text == ""
byte[] bytes = jsonMapper.writeValueAsBytes(doc); // "text" omitted in JSON
Include.ALWAYS on the mapper does not help — class-level @JsonInclude(NON_EMPTY) wins. No raw json_content accessor either.
Wanted: lossless serialize, or raw json_content bytes/JsonNode.
Related: docling#3780, docling-java#386
Serve keeps
"text": ""on formula items (do_formula_enrichment=false). The JavaDoclingDocumentstill has text as"", but serialization drops it:Include.ALWAYSon the mapper does not help — class-level@JsonInclude(NON_EMPTY)wins. No rawjson_contentaccessor either.Wanted: lossless serialize, or
raw json_contentbytes/JsonNode.Related: docling#3780, docling-java#386