Skip to content

Transforms complex documents like PDFs and Office docs into LLM-ready markdown/JSON for your Agentic workflows.

feat: retain section end pagination semantics for converted TOC paragraphs

myhloli7a25cec11377
diff --git a/mineru/model/docx/docx_converter.py b/mineru/model/docx/docx_converter.py
index bd6420cf..6835e9d5 100644
--- a/mineru/model/docx/docx_converter.py
+++ b/mineru/model/docx/docx_converter.py
@@ -1089,6 +1089,9 @@ class DocxConverter:
text=text,
equations=equations,
):
+ # 普通 TOC 段落被转换为 INDEX 后,也要保留段落末尾分节分页语义。
+ if is_section_end:
+ self._start_new_page()
return None
self._reset_index_state()