Hello Dmytro,
Thanks for reaching out to us, for your question how to extract text with styles, you may want to consider enable the add-on capability - https://learn.microsoft.com/en-us/azure/ai-services/document-intelligence/concept-add-on-capabilities?view=doc-intel-4.0.0&tabs=rest-api#font-property-extraction
Font property extraction
The ocr.font
capability extracts all font properties of text extracted in the styles
collection as a top-level object under content
. Each style object specifies a single font property, the text span it applies to, and its corresponding confidence score. The existing style property is extended with more font properties such as similarFontFamily
for the font of the text, fontStyle
for styles such as italic and normal, fontWeight
for bold or normal, color
for color of the text, and backgroundColor
for color of the text bounding box.
I hope this helps.
Regards,
Yutong