Function: createTodoListTool()
createTodoListTool():
ZodToolDefinition<ZodObject<{completed:ZodOptional<ZodArray<ZodNumber>>;new:ZodOptional<ZodArray<ZodString>>;newSubtask:ZodOptional<ZodObject<{items:ZodArray<ZodString>;parentId:ZodNumber; },$strip>>;remove:ZodOptional<ZodArray<ZodNumber>>; },$strip>, {todos:TodoItem[]; }>
Defined in: packages/core/src/tools/todo-list.ts:31
Creates a todo_list tool with its own state.
Each call to createTodoListTool() creates a new independent todo list.
Returns
ZodToolDefinition<ZodObject<{ completed: ZodOptional<ZodArray<ZodNumber>>; new: ZodOptional<ZodArray<ZodString>>; newSubtask: ZodOptional<ZodObject<{ items: ZodArray<ZodString>; parentId: ZodNumber; }, $strip>>; remove: ZodOptional<ZodArray<ZodNumber>>; }, $strip>, { todos: TodoItem[]; }>
Example
const todoTool = createTodoListTool();
const bot = Baleybot.create({
name: 'task-manager',
goal: 'Help manage tasks',
model: 'gpt-4o-mini',
tools: { todo_list: todoTool },
});