调整了agent
This commit is contained in:
@@ -9,16 +9,15 @@ import { ChatDeepSeek } from "@langchain/deepseek";
|
||||
import config from '../../../config.js';
|
||||
import logger from '../../../utils/logger.js';
|
||||
|
||||
// 密钥由 conf.json 统一提供;百度地图 skill 通过 env_get 读环境变量,此处桥接
|
||||
// 密钥由 conf.json 统一提供;百度地图 token 由 http_get 按域名在服务端注入
|
||||
process.env.TAVILY_API_KEY ??= config.agent.tavily?.apiKey;
|
||||
process.env.BAIDU_MAP_AUTH_TOKEN ??= config.agent.baiduMap?.authToken;
|
||||
import Prompts from "./prompts.js";
|
||||
import { createRestrictedBackend } from "../../infra/restricted_fs_backend.js";
|
||||
import { createHospitalInfoSubagent } from "../../subagent/hospital_info.js";
|
||||
import {
|
||||
getEnvTool, webFetchTool, webSearchTool, getCalendarInfoTool,
|
||||
getLunarCalendarInfoTool, getYearHolidaysTool, getYearTermsTool, getLatLngTool,
|
||||
httpGetTool, httpPostTool, createEscortRecordQueryTool
|
||||
webFetchTool, webSearchTool, getCalendarInfoTool, getYearHolidaysTool,
|
||||
httpGetTool, createEscortRecordQueryTool
|
||||
} from "../../infra/tools/index.js";
|
||||
|
||||
export default class EscortAgent {
|
||||
@@ -188,8 +187,8 @@ export default class EscortAgent {
|
||||
systemPrompt: Prompts.buildSystemPrompt(userInfo),
|
||||
memory: ["./agent/bots/bot-escort/AGENTS.md"],
|
||||
backend,
|
||||
tools: [getEnvTool, webFetchTool, webSearchTool, getLatLngTool, httpGetTool, httpPostTool,
|
||||
getCalendarInfoTool, getLunarCalendarInfoTool, getYearHolidaysTool, getYearTermsTool,
|
||||
tools: [webFetchTool, webSearchTool, httpGetTool,
|
||||
getCalendarInfoTool, getYearHolidaysTool,
|
||||
createEscortRecordQueryTool(userInfo)],
|
||||
subagents: [createHospitalInfoSubagent(this.flashModel)],
|
||||
skills: ["./agent/infra/skills/"],
|
||||
|
||||
Reference in New Issue
Block a user