Elffuss BraidHub

kikocis/continue public

dfc814e4318e · 1.0 KiBRawPermalink
1import type { Tool } from "./types.js";
2
3export const writeChecklistTool: Tool = {
4 name: "Checklist",
5 displayName: "Checklist",
6 description:
7 "Create or update a task checklist. The old checklist can be seen in the chat history if it exists. Use this tool to write a new checklist or edit the existing one.",
8 readonly: false,
9 isBuiltIn: true,
10 parameters: {
11 checklist: {
12 type: "string",
13 description:
14 "The complete checklist in markdown format using - [ ] for incomplete tasks and - [x] for completed tasks. Avoid headers and additional content unless specifically being used to group checkboxes. Try to keep the list short, and make each item specific and actionable.",
15 required: true,
16 },
17 },
18 preprocess: async (args: { checklist: string }) => {
19 return {
20 preview: [
21 {
22 type: "checklist" as const,
23 content: args.checklist,
24 },
25 ],
26 args,
27 };
28 },
29 run: async (args: { checklist: string }) => {
30 return `Task list status:\n${args.checklist}`;
31 },
32};