RAGFlow is an agent-native database: a Retrieval-Augmented Generation (RAG) engine that grew into context infrastructure.
Go agent-harnessagent-native-databaseagentic-aiagentic-retrievalagentic-searchaiai-agentscontext-enginecontext-engineeringcontext-managementharness-engineeringknowledge-compilationragretrieval-augmented-generationretrieval-harnesssearch-harness
Remove <think> for KG extraction. (#5027)
Kevin Huf46448d04c83
diff --git a/graphrag/general/extractor.py b/graphrag/general/extractor.pyindex ffcb889a54..50184002f7 100644--- a/graphrag/general/extractor.py+++ b/graphrag/general/extractor.py@@ -15,6 +15,7 @@#import loggingimport os+import refrom collections import defaultdict, Counterfrom concurrent.futures import ThreadPoolExecutorfrom copy import deepcopy@@ -59,6 +60,7 @@ class Extractor:if response:return responseresponse = self._llm.chat(system, hist, conf)+ response = re.sub(r"<think>.*</think>", "", response)if response.find("**ERROR**") >= 0:raise Exception(response)set_llm_cache(self._llm.llm_name, system, response, history, gen_conf)