统一抽象 封装 模型配置配置管理

This commit is contained in:
zk
2026-05-26 15:10:21 +08:00
parent b558863207
commit 18589adf8c
10 changed files with 131 additions and 31 deletions
+2 -3
View File
@@ -5,7 +5,7 @@
"""
from app.ai.job_agent.prompts import SYSTEM_PROMPT
from app.ai.models import LLM
from app.ai.model_config import JobAgentModel
from app.core.logger import log
from app.tool.json_helper import parse_llm_json
@@ -32,8 +32,7 @@ async def agent_chat(resume_text: str, message: str, history: list[dict],
# 3. 调 LLM
try:
llm = LLM.ZM_GPT_5_4.create(temperature=0.7)
result = await llm.ainvoke(messages)
result = await JobAgentModel.CHAT.ainvoke(messages)
raw = result.content
except Exception as e:
log.error(f"求职助手AI调用失败: {e}")