search_content_1047433b.txt 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217
  1. {
  2. "success": true,
  3. "matches": [
  4. {
  5. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\component\\ai_review_engine.py",
  6. "line_number": 17,
  7. "line_content": "├── basic_compliance_check() # 基础合规性检查 (语法/语义/完整性)",
  8. "context": "\n🏗️ 核心审查流程:\n├── basic_compliance_check() # 基础合规性检查 (语法/语义/完整性)\n├── technical_compliance_check() # 技术性合规检查 (标准/设计/参数)\n├── rag_enhanced_check() # RAG增强审查 (向量/混合检索)\n"
  9. },
  10. {
  11. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\component\\ai_review_engine.py",
  12. "line_number": 25,
  13. "line_content": "├── check_completeness() # 完整性检查",
  14. "context": "├── check_grammar() # 词句语法检查\n├── check_semantic_logic() # 语义逻辑检查\n├── check_completeness() # 完整性检查\n├── check_mandatory_standards() # 强制性标准检查\n├── check_design_values() # 设计值检查\n"
  15. },
  16. {
  17. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\component\\ai_review_engine.py",
  18. "line_number": 658,
  19. "line_content": " 完整性检查",
  20. "context": " state: str, stage_name: str) -> Dict[str, Any]:\n \"\"\"\n 完整性检查\n\n Args:\n"
  21. },
  22. {
  23. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\component\\ai_review_engine.py",
  24. "line_number": 667,
  25. "line_content": " Dict[str, Any]: 完整性检查结果",
  26. "context": "\n Returns:\n Dict[str, Any]: 完整性检查结果\n \"\"\"\n\n"
  27. },
  28. {
  29. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\component\\ai_review_engine.py",
  30. "line_number": 750,
  31. "line_content": " logger.info(f\"[完整性检查] 准备将大纲审查结果存储到Redis,bind_id: {trace_id_idx}\")",
  32. "context": " review_results_df.to_csv(str(Path(\"temp\") / f'{trace_id_idx}_completeness_review_results.csv'), encoding='utf-8-sig', index=False)\n # 将审查结果存储到Redis,供 outline_check 使用\n logger.info(f\"[完整性检查] 准备将大纲审查结果存储到Redis,bind_id: {trace_id_idx}\")\n from .reviewers.check_completeness.utils.redis_csv_utils import df_store_to_redis\n df_store_to_redis(self.redis_client, data=review_results_df, bind_id=trace_id_idx)\n"
  33. },
  34. {
  35. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\component\\ai_review_engine.py",
  36. "line_number": 753,
  37. "line_content": " logger.info(f\"[完整性检查] 数据已成功存储到Redis,bind_id: {trace_id_idx}\")",
  38. "context": " from .reviewers.check_completeness.utils.redis_csv_utils import df_store_to_redis\n df_store_to_redis(self.redis_client, data=review_results_df, bind_id=trace_id_idx)\n logger.info(f\"[完整性检查] 数据已成功存储到Redis,bind_id: {trace_id_idx}\")\n\n df_filtered = review_results_df.drop_duplicates(subset='title', keep='first').reset_index(drop=True)\n"
  39. },
  40. {
  41. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\component\\report_generator.py",
  42. "line_number": 325,
  43. "line_content": " 'completeness_check': '完整性审查',",
  44. "context": " check_item_names = {\n 'timeliness_check': '时效性审查',\n 'completeness_check': '完整性审查',\n 'semantic_logic_check': '语义逻辑审查',\n 'reference_check': '参考文献审查',\n"
  45. },
  46. {
  47. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\workflows\\ai_review_workflow.py",
  48. "line_number": 367,
  49. "line_content": " # 筛选完整性存在完整性审查的分类,将其整章进行合并",
  50. "context": " # ]\n\n # 筛选完整性存在完整性审查的分类,将其整章进行合并\n filtered_chunks = self.core_fun._merge_chunks_for_completeness_check(\n filtered_chunks, review_item_dict_sorted\n"
  51. },
  52. {
  53. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\component\\doc_worker\\docx_worker\\text_splitter.py",
  54. "line_number": 7,
  55. "line_content": "3. 对超过最大字符数的块按段落-句子进行再次切分,保持语义完整性",
  56. "context": "1. 跳过目录页,只在正文中定位章节标题\n2. 按最低目录层级进行切分,形成章节块\n3. 对超过最大字符数的块按段落-句子进行再次切分,保持语义完整性\n\"\"\"\n\n"
  57. },
  58. {
  59. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\component\\doc_worker\\pdf_worker\\text_splitter.py",
  60. "line_number": 7,
  61. "line_content": "3. 对超过最大字符数的块按段落-句子进行再次切分,保持语义完整性",
  62. "context": "1. 跳过目录页,只在正文中定位章节标题\n2. 按最低目录层级进行切分,形成章节块\n3. 对超过最大字符数的块按段落-句子进行再次切分,保持语义完整性\n4. 支持层级路径构建和子标题查找\n\"\"\"\n"
  63. },
  64. {
  65. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\component\\reviewers\\catalogues_check\\catalogues_check.py",
  66. "line_number": 559,
  67. "line_content": " \"suggestion\": f\"目录缺失:目录中缺失'{missing_item}'这个小节;当前章节仅涉及'{title if title else chapter_label}',目录中未体现'{missing_item}'相关内容;整改建议:建议在目录中补充'{missing_item}'相关内容,确保目录完整性。\",",
  68. "context": " \"issue_point\": f\"{missing_item}缺失\",\n \"location\": title if title else chapter_label,\n \"suggestion\": f\"目录缺失:目录中缺失'{missing_item}'这个小节;当前章节仅涉及'{title if title else chapter_label}',目录中未体现'{missing_item}'相关内容;整改建议:建议在目录中补充'{missing_item}'相关内容,确保目录完整性。\",\n \"reason\": f\"该章节应具备要点:{specification_items_text}\" if specification_items_text else \"\",\n \"risk_level\": \"高风险\",\n"
  69. },
  70. {
  71. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\component\\reviewers\\catalogues_check\\catalogues_check.py",
  72. "line_number": 585,
  73. "line_content": " \"suggestion\": f\"大纲缺失:大纲中缺失'{miss_outline}'这个小节;当前章节仅涉及'{title if title else chapter_label}',大纲中未涵盖'{miss_outline}'相关内容;整改建议:建议在大纲中补充'{miss_outline}'相关内容,确保大纲完整性。\",",
  74. "context": " \"issue_point\": f\"{miss_outline}缺失\",\n \"location\": title if title else chapter_label,\n \"suggestion\": f\"大纲缺失:大纲中缺失'{miss_outline}'这个小节;当前章节仅涉及'{title if title else chapter_label}',大纲中未涵盖'{miss_outline}'相关内容;整改建议:建议在大纲中补充'{miss_outline}'相关内容,确保大纲完整性。\",\n \"reason\": f\"该章节应具备要点:{specification_items_text}\" if specification_items_text else \"\",\n \"risk_level\": \"高风险\",\n"
  75. },
  76. {
  77. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\component\\reviewers\\utils\\punctuation_checker.py",
  78. "line_number": 53,
  79. "line_content": "- 仅检查包裹的**完整性**:书名号是否包裹了规范名称的全部内容;括号是否包裹了编号的全部内容",
  80. "context": "\n【判断原则】\n- 仅检查包裹的**完整性**:书名号是否包裹了规范名称的全部内容;括号是否包裹了编号的全部内容\n- 中文括号()和英文括号()混用视为正常,不区分\n- 若内容在符号外遗漏,或符号包裹了多余内容,则判定为false\n"
  81. },
  82. {
  83. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\component\\reviewers\\utils\\punctuation_checker.py",
  84. "line_number": 119,
  85. "line_content": " 检查规范文本中的书名号和括号使用是否正确,先进行成对预检,再用LLM判断包裹完整性",
  86. "context": "async def check_punctuation(items: List[str]) -> str:\n \"\"\"\n 检查规范文本中的书名号和括号使用是否正确,先进行成对预检,再用LLM判断包裹完整性\n \n Args:\n"
  87. },
  88. {
  89. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\component\\reviewers\\utils\\punctuation_checker.py",
  90. "line_number": 132,
  91. "line_content": " llm_inputs = [] # 需要LLM判定包裹完整性的文本",
  92. "context": " # 1) 预检:是否存在且成对出现\n pre_results = [] # 预填结果,若需LLM再补充\n llm_inputs = [] # 需要LLM判定包裹完整性的文本\n\n for text in items:\n"
  93. },
  94. {
  95. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\workflows\\core_functions\\ai_review_core_fun.py",
  96. "line_number": 266,
  97. "line_content": " # 只有非完整性审查的chunk才执行RAG检索(注意括号位置,确保运算符优先级正确)",
  98. "context": " is_complete_field = chunk.get('is_complete_field', False)\n logger.info(f\"检查is_complete_field值是否正常: {is_complete_field}\")\n # 只有非完整性审查的chunk才执行RAG检索(注意括号位置,确保运算符优先级正确)\n if ('check_parameter_compliance' in func_names or 'check_non_parameter_compliance' in func_names) and not is_complete_field:\n logger.debug(\"开始执行RAG检索增强\")\n"
  99. },
  100. {
  101. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\workflows\\core_functions\\ai_review_core_fun.py",
  102. "line_number": 1223,
  103. "line_content": " 筛选包含完整性审查的分类,将其整章进行合并",
  104. "context": " ) -> List[Dict[str, Any]]:\n \"\"\"\n 筛选包含完整性审查的分类,将其整章进行合并\n\n Args:\n"
  105. },
  106. {
  107. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\workflows\\core_functions\\ai_review_core_fun.py",
  108. "line_number": 1243,
  109. "line_content": " # 1. 找出包含完整性审查的章节分类",
  110. "context": " \"\"\"\n try:\n # 1. 找出包含完整性审查的章节分类\n completeness_chapters = set()\n for chapter_code, func_names in review_item_dict.items():\n"
  111. },
  112. {
  113. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\workflows\\core_functions\\ai_review_core_fun.py",
  114. "line_number": 1250,
  115. "line_content": " logger.info(\"没有包含完整性审查的章节,无需合并\")",
  116. "context": "\n if not completeness_chapters:\n logger.info(\"没有包含完整性审查的章节,无需合并\")\n return chunks\n\n"
  117. },
  118. {
  119. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\workflows\\core_functions\\ai_review_core_fun.py",
  120. "line_number": 1253,
  121. "line_content": " logger.info(f\"包含完整性审查的章节分类: {completeness_chapters}\")",
  122. "context": " return chunks\n\n logger.info(f\"包含完整性审查的章节分类: {completeness_chapters}\")\n\n # 2. 筛选出需要合并的chunks(属于完整性审查章节的)\n"
  123. },
  124. {
  125. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\core\\construction_review\\workflows\\core_functions\\ai_review_core_fun.py",
  126. "line_number": 1255,
  127. "line_content": " # 2. 筛选出需要合并的chunks(属于完整性审查章节的)",
  128. "context": " logger.info(f\"包含完整性审查的章节分类: {completeness_chapters}\")\n\n # 2. 筛选出需要合并的chunks(属于完整性审查章节的)\n chunks_to_merge = []\n for chunk in chunks:\n"
  129. },
  130. {
  131. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\foundation\\ai\\models\\model_handler.py",
  132. "line_number": 341,
  133. "line_content": " # 验证配置完整性",
  134. "context": " doubao_api_key = self.config.get(\"doubao\", \"DOUBAO_API_KEY\")\n\n # 验证配置完整性\n if not all([doubao_url, doubao_model_id, doubao_api_key]):\n missing = []\n"
  135. },
  136. {
  137. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\foundation\\ai\\models\\model_handler.py",
  138. "line_number": 390,
  139. "line_content": " # 验证配置完整性",
  140. "context": " qwen_api_key = self.config.get(\"qwen\", \"QWEN_API_KEY\")\n\n # 验证配置完整性\n if not all([qwen_url, qwen_model_id, qwen_api_key]):\n missing = []\n"
  141. },
  142. {
  143. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\foundation\\ai\\models\\model_handler.py",
  144. "line_number": 439,
  145. "line_content": " # 验证配置完整性",
  146. "context": " qwen3_30b_api_key = self.config.get(\"qwen3_30b\", \"QWEN3_30B_API_KEY\")\n\n # 验证配置完整性\n if not all([qwen3_30b_url, qwen3_30b_model_id, qwen3_30b_api_key]):\n missing = []\n"
  147. },
  148. {
  149. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\foundation\\ai\\models\\model_handler.py",
  150. "line_number": 488,
  151. "line_content": " # 验证配置完整性",
  152. "context": " deepseek_api_key = self.config.get(\"deepseek\", \"DEEPSEEK_API_KEY\")\n\n # 验证配置完整性\n if not all([deepseek_url, deepseek_model_id, deepseek_api_key]):\n missing = []\n"
  153. },
  154. {
  155. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\foundation\\ai\\models\\model_handler.py",
  156. "line_number": 537,
  157. "line_content": " # 验证配置完整性",
  158. "context": " gemini_api_key = self.config.get(\"gemini\", \"GEMINI_API_KEY\")\n\n # 验证配置完整性\n if not all([gemini_url, gemini_model_id, gemini_api_key]):\n missing = []\n"
  159. },
  160. {
  161. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\foundation\\ai\\models\\model_handler.py",
  162. "line_number": 617,
  163. "line_content": " # 验证配置完整性",
  164. "context": " api_key = self.config.get(\"lq_qwen3_8B_lora\", \"LQ_QWEN3_8B_LQ_LORA_API_KEY\", \"dummy\")\n\n # 验证配置完整性\n if not all([server_url, model_id]):\n missing = []\n"
  165. },
  166. {
  167. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\foundation\\ai\\models\\model_handler.py",
  168. "line_number": 762,
  169. "line_content": " # 验证配置完整性",
  170. "context": " dimensions = self.config.get(\"siliconflow_embed\", \"SLCF_EMBED_DIMENSIONS\", \"4096\")\n\n # 验证配置完整性\n if not all([server_url, api_key, model_id]):\n missing = []\n"
  171. },
  172. {
  173. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\views\\construction_review\\launch_review.py",
  174. "line_number": 93,
  175. "line_content": " 'completeness_check', # 条文完整性审查",
  176. "context": " 'sensitive_word_check', # 词句语法检查\n 'semantic_logic_check', # 语义逻辑审查\n 'completeness_check', # 条文完整性审查\n 'timeliness_check', # 时效性审查\n 'reference_check', # 规范性审查\n"
  177. },
  178. {
  179. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\views\\construction_review\\launch_review.py",
  180. "line_number": 178,
  181. "line_content": " catalogue_invalid = [] # 目录章节使用了非完整性审查",
  182. "context": " invalid_chapter = [] # 章节code不支持\n invalid_review = [] # 审查项code不支持\n catalogue_invalid = [] # 目录章节使用了非完整性审查\n\n for item in review_item_config:\n"
  183. },
  184. {
  185. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\views\\construction_review\\launch_review.py",
  186. "line_number": 193,
  187. "line_content": " # 5. 特殊规则:目录章节只能使用完整性审查",
  188. "context": " continue # 章节不支持时不继续检查审查项\n\n # 5. 特殊规则:目录章节只能使用完整性审查\n if chapter_code == \"catalogue\" and review_dim != \"completeness_check\":\n catalogue_invalid.append(item)\n"
  189. },
  190. {
  191. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\views\\construction_review\\schemas\\error_schemas.py",
  192. "line_number": 227,
  193. "line_content": " \"message\": \"目录章节仅支持完整性审查\",",
  194. "context": " \"code\": \"QDSC021\",\n \"error_type\": \"CATALOGUE_COMPLETENESS_ONLY\",\n \"message\": \"目录章节仅支持完整性审查\",\n \"status_code\": 400\n }\n"
  195. },
  196. {
  197. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\views\\construction_review\\schemas\\error_schemas.py",
  198. "line_number": 516,
  199. "line_content": " \"\"\"目录章节仅支持完整性审查\"\"\"",
  200. "context": " @staticmethod\n def catalogue_completeness_only(invalid_items: list = None):\n \"\"\"目录章节仅支持完整性审查\"\"\"\n logger.error(f\"目录章节使用了非完整性审查: {invalid_items}\")\n message = f\"参数错误:目录章节(catalogue)仅支持完整性审查(completeness_check)。无效配置项: {invalid_items}\"\n"
  201. },
  202. {
  203. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\views\\construction_review\\schemas\\error_schemas.py",
  204. "line_number": 517,
  205. "line_content": " logger.error(f\"目录章节使用了非完整性审查: {invalid_items}\")",
  206. "context": " def catalogue_completeness_only(invalid_items: list = None):\n \"\"\"目录章节仅支持完整性审查\"\"\"\n logger.error(f\"目录章节使用了非完整性审查: {invalid_items}\")\n message = f\"参数错误:目录章节(catalogue)仅支持完整性审查(completeness_check)。无效配置项: {invalid_items}\"\n return create_http_exception(ErrorCodes.QDSC021, message)\n"
  207. },
  208. {
  209. "file": "D:\\wx_work\\sichuan_luqiao\\LQAgentPlatform\\views\\construction_review\\schemas\\error_schemas.py",
  210. "line_number": 518,
  211. "line_content": " message = f\"参数错误:目录章节(catalogue)仅支持完整性审查(completeness_check)。无效配置项: {invalid_items}\"",
  212. "context": " \"\"\"目录章节仅支持完整性审查\"\"\"\n logger.error(f\"目录章节使用了非完整性审查: {invalid_items}\")\n message = f\"参数错误:目录章节(catalogue)仅支持完整性审查(completeness_check)。无效配置项: {invalid_items}\"\n return create_http_exception(ErrorCodes.QDSC021, message)\n\n"
  213. }
  214. ],
  215. "count": 35,
  216. "has_more": false
  217. }