Skip to content

Commit 402536c

Browse files
committed
Todos tool result doesn't duplicate the todos string
1 parent f7de1fe commit 402536c

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

common/src/tools/params/tool/write-todos.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ export const writeTodosParams = {
5757
z.object({
5858
type: z.literal('json'),
5959
value: z.object({
60-
todos: z.array(z.object({ task: z.string(), completed: z.boolean() })),
60+
message: z.string(),
6161
}),
6262
}),
6363
]),

packages/agent-runtime/src/tools/handlers/tool/write-todos.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@ export const handleWriteTodos = (async (params: {
1111
previousToolCallFinished: Promise<void>
1212
toolCall: CodebuffToolCall<ToolName>
1313
}): Promise<{ output: CodebuffToolOutput<ToolName> }> => {
14-
const { previousToolCallFinished, toolCall } = params
15-
const { todos } = toolCall.input
14+
const { previousToolCallFinished } = params
1615

1716
await previousToolCallFinished
18-
return { output: jsonToolResult({ todos }) }
17+
18+
return { output: jsonToolResult({ message: 'Todos written' }) }
1919
}) satisfies CodebuffToolHandlerFunction<ToolName>

0 commit comments

Comments
 (0)