jihuaqiang 2 tygodni temu
rodzic
commit
6def920c52
1 zmienionych plików z 3 dodań i 2 usunięć
  1. 3 2
      tools/agent_tools.py

+ 3 - 2
tools/agent_tools.py

@@ -421,8 +421,9 @@ class StructureTool:
                 'structure_status': 'success',
                 'process_time': self._get_current_timestamp()
             }
-            
-            logger.info(f"内容结构化处理成功: content_id={content_data.get('meta', '').get('content_id', '')}, title={content_data.get('title', '')}")
+            content_id = (content_data.get('meta') or {}).get('content_id', '')
+            title = content_data.get('title', '')
+            logger.info(f"内容结构化处理成功: content_id={content_id}, title={title}")
             return result
             
         except Exception as e: