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 redandent code. (#5121)
Kevin Huef95f08c481a
diff --git a/graphrag/general/community_reports_extractor.py b/graphrag/general/community_reports_extractor.pyindex 738dc226f4..7157f0b31f 100644--- a/graphrag/general/community_reports_extractor.py+++ b/graphrag/general/community_reports_extractor.py@@ -8,7 +8,6 @@ Reference:import loggingimport jsonimport re-import tracebackfrom typing import Callablefrom dataclasses import dataclassimport networkx as nx@@ -18,7 +17,7 @@ from graphrag.general.community_report_prompt import COMMUNITY_REPORT_PROMPTfrom graphrag.general.extractor import Extractorfrom graphrag.general.leiden import add_community_info2graphfrom rag.llm.chat_model import Base as CompletionLLM-from graphrag.utils import ErrorHandlerFn, perform_variable_replacements, dict_has_keys_with_types+from graphrag.utils import perform_variable_replacements, dict_has_keys_with_typesfrom rag.utils import num_tokens_from_stringfrom timeit import default_timer as timer@@ -36,7 +35,6 @@ class CommunityReportsExtractor(Extractor):_extraction_prompt: str_output_formatter_prompt: str- _on_error: ErrorHandlerFn_max_report_length: intdef __init__(@@ -107,9 +105,8 @@ class CommunityReportsExtractor(Extractor):continueresponse["weight"] = weightresponse["entities"] = ents- except Exception as e:+ except Exception:logging.exception("CommunityReportsExtractor got exception")- self._on_error(e, traceback.format_exc(), None)continueadd_community_info2graph(graph, ents, response["title"])