Skip to content

RAGFlow is an agent-native database: a Retrieval-Augmented Generation (RAG) engine that grew into context infrastructure.

Fix: no chunks parsed out for Law (#8842)

Yongteng Leidbc2a8689abc
diff --git a/rag/nlp/__init__.py b/rag/nlp/__init__.py
index fd302fac36..e54eb96b63 100644
--- a/rag/nlp/__init__.py
+++ b/rag/nlp/__init__.py
@@ -210,6 +210,7 @@ def bullets_category(sections):
hits = [0] * len(BULLET_PATTERN)
for i, pro in enumerate(BULLET_PATTERN):
for sec in sections:
+ sec = sec.strip()
for p in pro:
if re.match(p, sec) and not not_bullet(sec):
hits[i] += 1