完善了agent

This commit is contained in:
lik
2026-05-30 16:41:26 +08:00
parent 797e69a0c2
commit b92853a717
30 changed files with 1972 additions and 22 deletions

View File

@@ -0,0 +1,17 @@
import * as z from "zod"
import { tool } from "langchain"
/**
* 获取系统时间工具
* @returns {string} - 返回当前系统时间
*/
export const getSystemTimeTool = tool(
(input) => {
return new Date().toLocaleString()
},
{
name: "get_system_time",
description: `获取当前系统时间`,
schema: z.object({})
}
)