fast-xml-parser already resolves the five named entities in text and attribute values, so calling decodeEntities() on parser output decoded them a second time: a document whose visible text literally contains "<" or "&" turned into "<" / "&" at parse time, and editing the paragraph then wrote the corrupted text back to word/document.xml. Split out decodeNumericCharRefs() — numeric character references are the only thing the parser leaves unresolved — and use it at the call sites that read text or attributes off the parse tree. Call sites that decode raw XML slices keep the full decode. Fixes #88 Co-authored-by: codeAnqiang-ma <273298913+codeAnqiang-ma@users.noreply.github.com> Co-authored-by: Cursor <cursoragent@cursor.com>