@@ -21,6 +21,7 @@ class SummaryAgent:
3. 确保回复结构清晰、易读
4. 适当添加表情符号或格式化增强可读性
5. 根据问题类型调整回复风格
+6. 如果专家回复结果包含图片链接,请务必在回复中保留图片链接
用户问题:{user_question}
问题类型:{question_type}
@@ -167,7 +167,7 @@ class RAGService:
async def _load_system_guide_from_json(self) -> List[Dict[str, Any]]:
"""从JSON文件加载系统指南文档"""
- json_file_path = f"{self.knowledge_base_path}/mom_knowledge.json"
+ json_file_path = f"{self.knowledge_base_path}/manual_converted_mom_knowledge.json"
try:
if not os.path.exists(json_file_path):
@@ -54,7 +54,8 @@ async def test_agv_diagnosis_service():
# 创建模拟OpenAI客户端
- client = OpenAI(api_key="test-key", base_url="http://localhost:8000")
+ client = OpenAI(
+ api_key=settings.OPENAI_API_KEY, base_url="http://localhost:8000")
except Exception:
print(" ⚠️ OpenAI客户端创建失败,使用模拟模式")
client = None