Skip to content

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

refactor: remove debug print statements (#12534)

lys1313013b226e06e2d36
diff --git a/deepdoc/parser/figure_parser.py b/deepdoc/parser/figure_parser.py
index caf4f5b7b5..ec5e333de2 100644
--- a/deepdoc/parser/figure_parser.py
+++ b/deepdoc/parser/figure_parser.py
@@ -124,18 +124,13 @@ def vision_figure_parser_pdf_wrapper(tbls, callback=None, **kwargs):
def vision_figure_parser_docx_wrapper_naive(chunks, idx_lst, callback=None, **kwargs):
-
- print("\n\n hello here i am \n\n")
-
if not chunks:
return []
try:
vision_model = LLMBundle(kwargs["tenant_id"], LLMType.IMAGE2TEXT)
callback(0.7, "Visual model detected. Attempting to enhance figure extraction...")
- print(" \n\n Yes vision model \n\n")
except Exception:
vision_model = None
- print(" \n\n No vision model \n\n")
if vision_model:
@timeout(30, 3)
def worker(idx, ck):
diff --git a/rag/app/one.py b/rag/app/one.py
index e445f881f1..d8bfdf58b8 100644
--- a/rag/app/one.py
+++ b/rag/app/one.py
@@ -82,8 +82,6 @@ def chunk(filename, binary=None, from_page=0, to_page=100000, lang="Chinese", ca
cks.append({"text": text, "image": image, "ck_type": ck_type})
vision_figure_parser_docx_wrapper_naive(cks, image_idxs, callback, **kwargs)
- for ck in cks:
- print(ck)
sections = [ck["text"] for ck in cks if ck.get("text")]
callback(0.8, "Finish parsing.")
diff --git a/rag/nlp/__init__.py b/rag/nlp/__init__.py
index 1b0029d2c6..e4cefd993f 100644
--- a/rag/nlp/__init__.py
+++ b/rag/nlp/__init__.py
@@ -815,11 +815,6 @@ def append_context2table_image4pdf(sections: list, tabls: list, table_context_si
if len(contexts) < len(res) + 1:
contexts.append(("", ""))
res.append(((img, tb), poss))
-
- print("\n\n")
- for c in contexts:
- print(c)
- print("\n\n")
return contexts if return_context else res