Skip to content

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

Update llm_aided.py

Xiaomeng Zhaob0c74884f4bb
diff --git a/mineru/utils/llm_aided.py b/mineru/utils/llm_aided.py
index a69ffa9d..d185eec9 100644
--- a/mineru/utils/llm_aided.py
+++ b/mineru/utils/llm_aided.py
@@ -90,7 +90,7 @@ Corrected title list:
content_pieces = []
for chunk in completion:
if chunk.choices:
- content_pieces.append(chunk.choices[0].delta.content)
+ content_pieces.append(chunk.choices[0].delta.content.strip())
content = "".join(content_pieces)
# logger.info(f"Title completion: {content}")
if "</think>" in content: