|
@@ -177,6 +177,15 @@ def create_langgraph_workflow():
|
|
|
crawl_data = item.get('crawl_data') or {}
|
|
|
content_id = item.get('content_id') or ''
|
|
|
task_id = item.get('task_id') or ''
|
|
|
+
|
|
|
+ # 先在库中查询是否已经处理过
|
|
|
+ check_sql = "SELECT id,status FROM knowledge_parsing_content WHERE request_id = %s AND content_id = %s"
|
|
|
+ check_result = MysqlHelper.get_values(check_sql, (state["request_id"], content_id))
|
|
|
+ if check_result:
|
|
|
+ id, status = check_result[0]
|
|
|
+ if status == 5:
|
|
|
+ success_count += 1
|
|
|
+ continue
|
|
|
|
|
|
# Step 1: 识别
|
|
|
identify_result = identify_tool.run(
|