mirror of
https://github.com/anomalyco/opencode.git
synced 2026-05-30 20:44:31 +00:00
OpenTUI is here (#2685)
This commit is contained in:
parent
81c617770d
commit
96bdeb3c7b
104 changed files with 8459 additions and 716 deletions
|
|
@ -14,8 +14,8 @@ import { Agent } from "../agent/agent"
|
|||
export const WriteTool = Tool.define("write", {
|
||||
description: DESCRIPTION,
|
||||
parameters: z.object({
|
||||
filePath: z.string().describe("The absolute path to the file to write (must be absolute, not relative)"),
|
||||
content: z.string().describe("The content to write to the file"),
|
||||
filePath: z.string().describe("The absolute path to the file to write (must be absolute, not relative)"),
|
||||
}),
|
||||
async execute(params, ctx) {
|
||||
const filepath = path.isAbsolute(params.filePath) ? params.filePath : path.join(Instance.directory, params.filePath)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue