@vibescope/mcp-server 0.3.0 → 0.3.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api-client/blockers.d.ts +46 -0
- package/dist/api-client/blockers.js +43 -0
- package/dist/api-client/cost.d.ts +112 -0
- package/dist/api-client/cost.js +76 -0
- package/dist/api-client/decisions.d.ts +55 -0
- package/dist/api-client/decisions.js +32 -0
- package/dist/api-client/discovery.d.ts +62 -0
- package/dist/api-client/discovery.js +21 -0
- package/dist/api-client/ideas.d.ts +75 -0
- package/dist/api-client/ideas.js +36 -0
- package/dist/api-client/index.d.ts +749 -0
- package/dist/api-client/index.js +291 -0
- package/dist/api-client/project.d.ts +132 -0
- package/dist/api-client/project.js +45 -0
- package/dist/api-client/session.d.ts +163 -0
- package/dist/api-client/session.js +52 -0
- package/dist/api-client/tasks.d.ts +328 -0
- package/dist/api-client/tasks.js +132 -0
- package/dist/api-client/types.d.ts +25 -0
- package/dist/api-client/types.js +4 -0
- package/dist/api-client/worktrees.d.ts +33 -0
- package/dist/api-client/worktrees.js +26 -0
- package/dist/api-client.d.ts +9 -0
- package/dist/api-client.js +104 -25
- package/dist/cli-init.d.ts +17 -0
- package/dist/cli-init.js +445 -0
- package/dist/cli.js +0 -0
- package/dist/handlers/cloud-agents.d.ts +21 -0
- package/dist/handlers/cloud-agents.js +91 -0
- package/dist/handlers/discovery.js +7 -0
- package/dist/handlers/index.d.ts +1 -0
- package/dist/handlers/index.js +3 -0
- package/dist/handlers/session.js +3 -1
- package/dist/handlers/tasks.js +10 -12
- package/dist/handlers/types.d.ts +2 -1
- package/dist/handlers/validation.js +5 -1
- package/dist/index.js +8 -3
- package/dist/token-tracking.js +2 -2
- package/dist/tools/blockers.d.ts +13 -0
- package/dist/tools/blockers.js +119 -0
- package/dist/tools/bodies-of-work.d.ts +19 -0
- package/dist/tools/bodies-of-work.js +280 -0
- package/dist/tools/cloud-agents.d.ts +9 -0
- package/dist/tools/cloud-agents.js +67 -0
- package/dist/tools/connectors.d.ts +14 -0
- package/dist/tools/connectors.js +188 -0
- package/dist/tools/cost.d.ts +11 -0
- package/dist/tools/cost.js +108 -0
- package/dist/tools/decisions.d.ts +12 -0
- package/dist/tools/decisions.js +108 -0
- package/dist/tools/deployment.d.ts +24 -0
- package/dist/tools/deployment.js +439 -0
- package/dist/tools/discovery.d.ts +10 -0
- package/dist/tools/discovery.js +73 -0
- package/dist/tools/fallback.d.ts +11 -0
- package/dist/tools/fallback.js +108 -0
- package/dist/tools/file-checkouts.d.ts +13 -0
- package/dist/tools/file-checkouts.js +141 -0
- package/dist/tools/findings.d.ts +13 -0
- package/dist/tools/findings.js +98 -0
- package/dist/tools/git-issues.d.ts +11 -0
- package/dist/tools/git-issues.js +127 -0
- package/dist/tools/ideas.d.ts +13 -0
- package/dist/tools/ideas.js +159 -0
- package/dist/tools/index.d.ts +71 -0
- package/dist/tools/index.js +98 -0
- package/dist/tools/milestones.d.ts +12 -0
- package/dist/tools/milestones.js +115 -0
- package/dist/tools/organizations.d.ts +17 -0
- package/dist/tools/organizations.js +221 -0
- package/dist/tools/progress.d.ts +9 -0
- package/dist/tools/progress.js +70 -0
- package/dist/tools/project.d.ts +13 -0
- package/dist/tools/project.js +199 -0
- package/dist/tools/requests.d.ts +10 -0
- package/dist/tools/requests.js +65 -0
- package/dist/tools/roles.d.ts +11 -0
- package/dist/tools/roles.js +109 -0
- package/dist/tools/session.d.ts +15 -0
- package/dist/tools/session.js +178 -0
- package/dist/tools/sprints.d.ts +18 -0
- package/dist/tools/sprints.js +295 -0
- package/dist/tools/tasks.d.ts +27 -0
- package/dist/tools/tasks.js +539 -0
- package/dist/tools/types.d.ts +7 -0
- package/dist/tools/types.js +6 -0
- package/dist/tools/validation.d.ts +10 -0
- package/dist/tools/validation.js +72 -0
- package/dist/tools/worktrees.d.ts +9 -0
- package/dist/tools/worktrees.js +63 -0
- package/dist/utils.d.ts +66 -0
- package/dist/utils.js +102 -0
- package/docs/TOOLS.md +55 -2
- package/package.json +5 -3
- package/scripts/generate-docs.ts +1 -1
- package/src/api-client/blockers.ts +86 -0
- package/src/api-client/cost.ts +185 -0
- package/src/api-client/decisions.ts +87 -0
- package/src/api-client/discovery.ts +81 -0
- package/src/api-client/ideas.ts +112 -0
- package/src/api-client/index.ts +378 -0
- package/src/api-client/project.ts +179 -0
- package/src/api-client/session.ts +220 -0
- package/src/api-client/tasks.ts +450 -0
- package/src/api-client/types.ts +32 -0
- package/src/api-client/worktrees.ts +53 -0
- package/src/api-client.test.ts +136 -9
- package/src/api-client.ts +125 -27
- package/src/cli-init.ts +504 -0
- package/src/handlers/__test-utils__.ts +2 -0
- package/src/handlers/cloud-agents.ts +138 -0
- package/src/handlers/discovery.ts +7 -0
- package/src/handlers/index.ts +3 -0
- package/src/handlers/session.ts +3 -1
- package/src/handlers/tasks.ts +10 -12
- package/src/handlers/tool-categories.test.ts +1 -1
- package/src/handlers/types.ts +2 -1
- package/src/handlers/validation.ts +6 -1
- package/src/index.test.ts +2 -2
- package/src/index.ts +8 -2
- package/src/token-tracking.ts +3 -2
- package/src/tools/blockers.ts +122 -0
- package/src/tools/bodies-of-work.ts +283 -0
- package/src/tools/cloud-agents.ts +70 -0
- package/src/tools/connectors.ts +191 -0
- package/src/tools/cost.ts +111 -0
- package/src/tools/decisions.ts +111 -0
- package/src/tools/deployment.ts +442 -0
- package/src/tools/discovery.ts +76 -0
- package/src/tools/fallback.ts +111 -0
- package/src/tools/file-checkouts.ts +145 -0
- package/src/tools/findings.ts +101 -0
- package/src/tools/git-issues.ts +130 -0
- package/src/tools/ideas.ts +162 -0
- package/src/tools/index.ts +131 -0
- package/src/tools/milestones.ts +118 -0
- package/src/tools/organizations.ts +224 -0
- package/src/tools/progress.ts +73 -0
- package/src/tools/project.ts +202 -0
- package/src/tools/requests.ts +68 -0
- package/src/tools/roles.ts +112 -0
- package/src/tools/session.ts +181 -0
- package/src/tools/sprints.ts +298 -0
- package/src/tools/tasks.ts +542 -0
- package/src/tools/tools.test.ts +222 -0
- package/src/tools/types.ts +9 -0
- package/src/tools/validation.ts +75 -0
- package/src/tools/worktrees.ts +66 -0
- package/src/tools.test.ts +1 -1
- package/src/utils.test.ts +229 -0
- package/src/utils.ts +117 -0
- package/dist/tools.d.ts +0 -2
- package/dist/tools.js +0 -3602
- package/src/tools.ts +0 -3607
|
@@ -0,0 +1,539 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Task Tool Definitions
|
|
3
|
+
*
|
|
4
|
+
* Tools for task CRUD and management:
|
|
5
|
+
* - get_task
|
|
6
|
+
* - search_tasks
|
|
7
|
+
* - get_tasks_by_priority
|
|
8
|
+
* - get_recent_tasks
|
|
9
|
+
* - get_task_stats
|
|
10
|
+
* - get_next_task
|
|
11
|
+
* - add_task
|
|
12
|
+
* - update_task
|
|
13
|
+
* - complete_task
|
|
14
|
+
* - delete_task
|
|
15
|
+
* - cancel_task
|
|
16
|
+
* - release_task
|
|
17
|
+
* - add_task_reference
|
|
18
|
+
* - remove_task_reference
|
|
19
|
+
* - batch_update_tasks
|
|
20
|
+
* - batch_complete_tasks
|
|
21
|
+
* - add_subtask
|
|
22
|
+
* - get_subtasks
|
|
23
|
+
* - get_stale_worktrees
|
|
24
|
+
* - clear_worktree_path
|
|
25
|
+
*/
|
|
26
|
+
export const taskTools = [
|
|
27
|
+
{
|
|
28
|
+
name: 'get_task',
|
|
29
|
+
description: `Get a single task by ID with optional subtasks and milestones.`,
|
|
30
|
+
inputSchema: {
|
|
31
|
+
type: 'object',
|
|
32
|
+
properties: {
|
|
33
|
+
task_id: {
|
|
34
|
+
type: 'string',
|
|
35
|
+
description: 'Task UUID',
|
|
36
|
+
},
|
|
37
|
+
include_subtasks: {
|
|
38
|
+
type: 'boolean',
|
|
39
|
+
description: 'Include subtasks array (default: false)',
|
|
40
|
+
},
|
|
41
|
+
include_milestones: {
|
|
42
|
+
type: 'boolean',
|
|
43
|
+
description: 'Include milestones array (default: false)',
|
|
44
|
+
},
|
|
45
|
+
},
|
|
46
|
+
required: ['task_id'],
|
|
47
|
+
},
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
name: 'search_tasks',
|
|
51
|
+
description: `Search tasks by text query. Supports pagination with offset. Use for finding specific tasks by title or description.`,
|
|
52
|
+
inputSchema: {
|
|
53
|
+
type: 'object',
|
|
54
|
+
properties: {
|
|
55
|
+
project_id: {
|
|
56
|
+
type: 'string',
|
|
57
|
+
description: 'Project UUID',
|
|
58
|
+
},
|
|
59
|
+
query: {
|
|
60
|
+
type: 'string',
|
|
61
|
+
description: 'Search query (min 2 chars). Searches title and description.',
|
|
62
|
+
},
|
|
63
|
+
status: {
|
|
64
|
+
type: 'array',
|
|
65
|
+
items: { type: 'string', enum: ['backlog', 'pending', 'in_progress', 'completed', 'cancelled'] },
|
|
66
|
+
description: 'Filter by status (optional, array)',
|
|
67
|
+
},
|
|
68
|
+
limit: {
|
|
69
|
+
type: 'number',
|
|
70
|
+
description: 'Max results per page (1-20, default: 10)',
|
|
71
|
+
},
|
|
72
|
+
offset: {
|
|
73
|
+
type: 'number',
|
|
74
|
+
description: 'Number of results to skip for pagination (default: 0)',
|
|
75
|
+
},
|
|
76
|
+
},
|
|
77
|
+
required: ['project_id', 'query'],
|
|
78
|
+
},
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
name: 'get_tasks_by_priority',
|
|
82
|
+
description: `Get tasks filtered by priority. Supports pagination with offset. Use for finding high-priority or low-priority tasks.`,
|
|
83
|
+
inputSchema: {
|
|
84
|
+
type: 'object',
|
|
85
|
+
properties: {
|
|
86
|
+
project_id: {
|
|
87
|
+
type: 'string',
|
|
88
|
+
description: 'Project UUID',
|
|
89
|
+
},
|
|
90
|
+
priority: {
|
|
91
|
+
type: 'number',
|
|
92
|
+
minimum: 1,
|
|
93
|
+
maximum: 5,
|
|
94
|
+
description: 'Exact priority to match (1=highest, 5=lowest)',
|
|
95
|
+
},
|
|
96
|
+
priority_max: {
|
|
97
|
+
type: 'number',
|
|
98
|
+
minimum: 1,
|
|
99
|
+
maximum: 5,
|
|
100
|
+
description: 'Max priority (for range, e.g., priority=1, priority_max=2 gets P1 and P2)',
|
|
101
|
+
},
|
|
102
|
+
status: {
|
|
103
|
+
type: 'string',
|
|
104
|
+
enum: ['backlog', 'pending', 'in_progress', 'completed', 'cancelled'],
|
|
105
|
+
description: 'Filter by status (default: pending)',
|
|
106
|
+
},
|
|
107
|
+
limit: {
|
|
108
|
+
type: 'number',
|
|
109
|
+
description: 'Max results per page (1-20, default: 10)',
|
|
110
|
+
},
|
|
111
|
+
offset: {
|
|
112
|
+
type: 'number',
|
|
113
|
+
description: 'Number of results to skip for pagination (default: 0)',
|
|
114
|
+
},
|
|
115
|
+
},
|
|
116
|
+
required: ['project_id'],
|
|
117
|
+
},
|
|
118
|
+
},
|
|
119
|
+
{
|
|
120
|
+
name: 'get_recent_tasks',
|
|
121
|
+
description: `Get tasks ordered by creation date. Supports pagination with offset. Use to find oldest pending tasks or newest additions.`,
|
|
122
|
+
inputSchema: {
|
|
123
|
+
type: 'object',
|
|
124
|
+
properties: {
|
|
125
|
+
project_id: {
|
|
126
|
+
type: 'string',
|
|
127
|
+
description: 'Project UUID',
|
|
128
|
+
},
|
|
129
|
+
order: {
|
|
130
|
+
type: 'string',
|
|
131
|
+
enum: ['newest', 'oldest'],
|
|
132
|
+
description: 'Sort order (default: newest)',
|
|
133
|
+
},
|
|
134
|
+
status: {
|
|
135
|
+
type: 'string',
|
|
136
|
+
enum: ['backlog', 'pending', 'in_progress', 'completed', 'cancelled'],
|
|
137
|
+
description: 'Filter by status (optional)',
|
|
138
|
+
},
|
|
139
|
+
limit: {
|
|
140
|
+
type: 'number',
|
|
141
|
+
description: 'Max results per page (1-20, default: 10)',
|
|
142
|
+
},
|
|
143
|
+
offset: {
|
|
144
|
+
type: 'number',
|
|
145
|
+
description: 'Number of results to skip for pagination (default: 0)',
|
|
146
|
+
},
|
|
147
|
+
},
|
|
148
|
+
required: ['project_id'],
|
|
149
|
+
},
|
|
150
|
+
},
|
|
151
|
+
{
|
|
152
|
+
name: 'get_task_stats',
|
|
153
|
+
description: `Get aggregate task statistics for a project. Returns counts by status and priority, no task data. Most token-efficient way to understand project state.`,
|
|
154
|
+
inputSchema: {
|
|
155
|
+
type: 'object',
|
|
156
|
+
properties: {
|
|
157
|
+
project_id: {
|
|
158
|
+
type: 'string',
|
|
159
|
+
description: 'Project UUID',
|
|
160
|
+
},
|
|
161
|
+
},
|
|
162
|
+
required: ['project_id'],
|
|
163
|
+
},
|
|
164
|
+
},
|
|
165
|
+
{
|
|
166
|
+
name: 'get_next_task',
|
|
167
|
+
description: `Get highest priority pending task. Start it IMMEDIATELY by calling update_task(task_id, status: "in_progress").
|
|
168
|
+
|
|
169
|
+
Do NOT ask the user for permission. Follow the directive in the response.`,
|
|
170
|
+
inputSchema: {
|
|
171
|
+
type: 'object',
|
|
172
|
+
properties: {
|
|
173
|
+
project_id: {
|
|
174
|
+
type: 'string',
|
|
175
|
+
description: 'Project UUID',
|
|
176
|
+
},
|
|
177
|
+
},
|
|
178
|
+
required: ['project_id'],
|
|
179
|
+
},
|
|
180
|
+
},
|
|
181
|
+
{
|
|
182
|
+
name: 'add_task',
|
|
183
|
+
description: `Add a new task. Priority 1=highest, 5=lowest. Include estimated_minutes. Use blocking=true for deployment finalization tasks that must complete before other work.
|
|
184
|
+
|
|
185
|
+
WHEN TO USE: If the user gives you work directly (e.g., "implement feature X", "fix this bug") that isn't already tracked as a task in Vibescope, you MUST create a task first using this tool. This ensures:
|
|
186
|
+
- The work is visible on the dashboard
|
|
187
|
+
- Progress can be tracked
|
|
188
|
+
- Other agents won't duplicate the work
|
|
189
|
+
- The human can see what you're working on`,
|
|
190
|
+
inputSchema: {
|
|
191
|
+
type: 'object',
|
|
192
|
+
properties: {
|
|
193
|
+
project_id: {
|
|
194
|
+
type: 'string',
|
|
195
|
+
description: 'Project UUID',
|
|
196
|
+
},
|
|
197
|
+
title: {
|
|
198
|
+
type: 'string',
|
|
199
|
+
description: 'Task title',
|
|
200
|
+
},
|
|
201
|
+
description: {
|
|
202
|
+
type: 'string',
|
|
203
|
+
description: 'Detailed description',
|
|
204
|
+
},
|
|
205
|
+
priority: {
|
|
206
|
+
type: 'number',
|
|
207
|
+
minimum: 1,
|
|
208
|
+
maximum: 5,
|
|
209
|
+
description: 'Priority 1-5 (1 = highest)',
|
|
210
|
+
},
|
|
211
|
+
estimated_minutes: {
|
|
212
|
+
type: 'number',
|
|
213
|
+
minimum: 1,
|
|
214
|
+
description: 'Estimated time to complete in minutes',
|
|
215
|
+
},
|
|
216
|
+
blocking: {
|
|
217
|
+
type: 'boolean',
|
|
218
|
+
description: 'When true, this task blocks all other work until complete (used for deployment finalization)',
|
|
219
|
+
},
|
|
220
|
+
model_capability: {
|
|
221
|
+
type: 'string',
|
|
222
|
+
enum: ['haiku', 'sonnet', 'opus'],
|
|
223
|
+
description: 'Recommended model capability: haiku (simple tasks), sonnet (standard), opus (complex reasoning)',
|
|
224
|
+
},
|
|
225
|
+
},
|
|
226
|
+
required: ['project_id', 'title'],
|
|
227
|
+
},
|
|
228
|
+
},
|
|
229
|
+
{
|
|
230
|
+
name: 'update_task',
|
|
231
|
+
description: `Update task status, progress, or details. Include progress_note with progress_percentage.
|
|
232
|
+
|
|
233
|
+
CRITICAL - WORKTREE REQUIRED: For projects using github-flow or git-flow, you MUST use a git worktree to isolate your work. This prevents conflicts with other agents working on the same repository.
|
|
234
|
+
|
|
235
|
+
When setting status to "in_progress":
|
|
236
|
+
1. Create worktree FIRST: git worktree add ../PROJECT-PERSONA-task-desc -b feature/TASKID-description BASE_BRANCH
|
|
237
|
+
2. cd into the worktree directory
|
|
238
|
+
3. THEN call update_task with git_branch AND worktree_path
|
|
239
|
+
|
|
240
|
+
Example: update_task(task_id, status: "in_progress", git_branch: "feature/abc123-add-login", worktree_path: "../MyProject-Edge-add-login")
|
|
241
|
+
|
|
242
|
+
For projects without git branching (trunk-based or none), use skip_worktree_requirement: true.`,
|
|
243
|
+
inputSchema: {
|
|
244
|
+
type: 'object',
|
|
245
|
+
properties: {
|
|
246
|
+
task_id: {
|
|
247
|
+
type: 'string',
|
|
248
|
+
description: 'Task UUID',
|
|
249
|
+
},
|
|
250
|
+
title: { type: 'string', description: 'New task title' },
|
|
251
|
+
description: { type: 'string', description: 'New task description' },
|
|
252
|
+
priority: {
|
|
253
|
+
type: 'number',
|
|
254
|
+
minimum: 1,
|
|
255
|
+
maximum: 5,
|
|
256
|
+
description: 'Task priority (1=highest, 5=lowest)',
|
|
257
|
+
},
|
|
258
|
+
status: {
|
|
259
|
+
type: 'string',
|
|
260
|
+
enum: ['backlog', 'pending', 'in_progress', 'completed', 'cancelled'],
|
|
261
|
+
description: 'Task status',
|
|
262
|
+
},
|
|
263
|
+
progress_percentage: {
|
|
264
|
+
type: 'number',
|
|
265
|
+
minimum: 0,
|
|
266
|
+
maximum: 100,
|
|
267
|
+
description: '0-100 completion percentage',
|
|
268
|
+
},
|
|
269
|
+
progress_note: {
|
|
270
|
+
type: 'string',
|
|
271
|
+
description: 'Brief note (auto-logged)',
|
|
272
|
+
},
|
|
273
|
+
estimated_minutes: {
|
|
274
|
+
type: 'number',
|
|
275
|
+
minimum: 1,
|
|
276
|
+
description: 'Revised time estimate',
|
|
277
|
+
},
|
|
278
|
+
git_branch: {
|
|
279
|
+
type: 'string',
|
|
280
|
+
description: 'Git branch associated with this task. REQUIRED when status is "in_progress" (unless skip_worktree_requirement is true)',
|
|
281
|
+
},
|
|
282
|
+
worktree_path: {
|
|
283
|
+
type: 'string',
|
|
284
|
+
description: 'Git worktree path for this task (e.g., "../project-task-abc123"). Store this for cleanup tracking across sessions.',
|
|
285
|
+
},
|
|
286
|
+
worktree_hostname: {
|
|
287
|
+
type: 'string',
|
|
288
|
+
description: 'Machine hostname where worktree was created (os.hostname()). Required with worktree_path to enable machine-aware cleanup.',
|
|
289
|
+
},
|
|
290
|
+
model_capability: {
|
|
291
|
+
type: 'string',
|
|
292
|
+
enum: ['haiku', 'sonnet', 'opus'],
|
|
293
|
+
description: 'Recommended model capability: haiku (simple tasks), sonnet (standard), opus (complex reasoning)',
|
|
294
|
+
},
|
|
295
|
+
skip_worktree_requirement: {
|
|
296
|
+
type: 'boolean',
|
|
297
|
+
description: 'Skip git_branch requirement for projects without branching workflows (trunk-based or none). Default: false',
|
|
298
|
+
},
|
|
299
|
+
},
|
|
300
|
+
required: ['task_id'],
|
|
301
|
+
},
|
|
302
|
+
},
|
|
303
|
+
{
|
|
304
|
+
name: 'complete_task',
|
|
305
|
+
description: `Mark task done. Returns next_task which you MUST start immediately without asking the user.
|
|
306
|
+
|
|
307
|
+
CRITICAL: Before calling complete_task on branching workflows (github-flow, git-flow):
|
|
308
|
+
1. Create your PR targeting the correct branch (develop for git-flow, main for github-flow)
|
|
309
|
+
2. Call add_task_reference(task_id, pr_url) to link the PR to your task
|
|
310
|
+
3. THEN call complete_task - validators CANNOT approve tasks without a PR reference
|
|
311
|
+
|
|
312
|
+
CRITICAL: After calling this tool, you must:
|
|
313
|
+
1. If next_task is returned → Start it immediately by calling update_task(task_id, status: "in_progress")
|
|
314
|
+
2. If no next_task → Call get_next_task() or start a fallback_activity
|
|
315
|
+
3. NEVER ask the user "What should I do next?" or "Should I continue?"
|
|
316
|
+
|
|
317
|
+
The auto_continue: true flag in the response means you are expected to continue working autonomously.`,
|
|
318
|
+
inputSchema: {
|
|
319
|
+
type: 'object',
|
|
320
|
+
properties: {
|
|
321
|
+
task_id: {
|
|
322
|
+
type: 'string',
|
|
323
|
+
description: 'Task UUID',
|
|
324
|
+
},
|
|
325
|
+
summary: {
|
|
326
|
+
type: 'string',
|
|
327
|
+
description: 'Brief summary of what was done. This is stored on the task as completion_summary and displayed when reviewing completed tasks.',
|
|
328
|
+
},
|
|
329
|
+
},
|
|
330
|
+
required: ['task_id'],
|
|
331
|
+
},
|
|
332
|
+
},
|
|
333
|
+
{
|
|
334
|
+
name: 'delete_task',
|
|
335
|
+
description: `Delete a task.`,
|
|
336
|
+
inputSchema: {
|
|
337
|
+
type: 'object',
|
|
338
|
+
properties: {
|
|
339
|
+
task_id: {
|
|
340
|
+
type: 'string',
|
|
341
|
+
description: 'Task UUID',
|
|
342
|
+
},
|
|
343
|
+
},
|
|
344
|
+
required: ['task_id'],
|
|
345
|
+
},
|
|
346
|
+
},
|
|
347
|
+
{
|
|
348
|
+
name: 'cancel_task',
|
|
349
|
+
description: `Cancel a task with an optional reason. Use this when a task should be marked as cancelled rather than deleted (e.g., PR was closed, work was superseded). The task remains visible with a cancelled status for historical tracking.`,
|
|
350
|
+
inputSchema: {
|
|
351
|
+
type: 'object',
|
|
352
|
+
properties: {
|
|
353
|
+
task_id: {
|
|
354
|
+
type: 'string',
|
|
355
|
+
description: 'Task UUID',
|
|
356
|
+
},
|
|
357
|
+
cancelled_reason: {
|
|
358
|
+
type: 'string',
|
|
359
|
+
description: 'Reason for cancellation',
|
|
360
|
+
enum: ['pr_closed', 'superseded', 'user_cancelled', 'validation_failed', 'obsolete', 'blocked'],
|
|
361
|
+
},
|
|
362
|
+
cancellation_note: {
|
|
363
|
+
type: 'string',
|
|
364
|
+
description: 'Optional note explaining the cancellation (logged to progress)',
|
|
365
|
+
},
|
|
366
|
+
},
|
|
367
|
+
required: ['task_id'],
|
|
368
|
+
},
|
|
369
|
+
},
|
|
370
|
+
{
|
|
371
|
+
name: 'release_task',
|
|
372
|
+
description: `Release a claimed task back to pending status. Use when you need to give up a task you've started but cannot complete (e.g., context limits reached, conflicts with other work, user requested different approach). The task becomes available for other agents to claim.`,
|
|
373
|
+
inputSchema: {
|
|
374
|
+
type: 'object',
|
|
375
|
+
properties: {
|
|
376
|
+
task_id: {
|
|
377
|
+
type: 'string',
|
|
378
|
+
description: 'Task UUID',
|
|
379
|
+
},
|
|
380
|
+
reason: {
|
|
381
|
+
type: 'string',
|
|
382
|
+
description: 'Optional reason for releasing the task (logged to progress)',
|
|
383
|
+
},
|
|
384
|
+
},
|
|
385
|
+
required: ['task_id'],
|
|
386
|
+
},
|
|
387
|
+
},
|
|
388
|
+
{
|
|
389
|
+
name: 'add_task_reference',
|
|
390
|
+
description: 'Add a reference URL to a task (docs, PRs, issues).',
|
|
391
|
+
inputSchema: {
|
|
392
|
+
type: 'object',
|
|
393
|
+
properties: {
|
|
394
|
+
task_id: {
|
|
395
|
+
type: 'string',
|
|
396
|
+
description: 'Task UUID',
|
|
397
|
+
},
|
|
398
|
+
url: {
|
|
399
|
+
type: 'string',
|
|
400
|
+
description: 'URL to add as reference',
|
|
401
|
+
},
|
|
402
|
+
label: {
|
|
403
|
+
type: 'string',
|
|
404
|
+
description: 'Optional label/title for the reference',
|
|
405
|
+
},
|
|
406
|
+
},
|
|
407
|
+
required: ['task_id', 'url'],
|
|
408
|
+
},
|
|
409
|
+
},
|
|
410
|
+
{
|
|
411
|
+
name: 'remove_task_reference',
|
|
412
|
+
description: `Remove a reference link from a task by URL.`,
|
|
413
|
+
inputSchema: {
|
|
414
|
+
type: 'object',
|
|
415
|
+
properties: {
|
|
416
|
+
task_id: {
|
|
417
|
+
type: 'string',
|
|
418
|
+
description: 'Task UUID',
|
|
419
|
+
},
|
|
420
|
+
url: {
|
|
421
|
+
type: 'string',
|
|
422
|
+
description: 'URL of the reference to remove',
|
|
423
|
+
},
|
|
424
|
+
},
|
|
425
|
+
required: ['task_id', 'url'],
|
|
426
|
+
},
|
|
427
|
+
},
|
|
428
|
+
{
|
|
429
|
+
name: 'batch_update_tasks',
|
|
430
|
+
description: 'Update multiple tasks at once. Include progress_note with progress_percentage.',
|
|
431
|
+
inputSchema: {
|
|
432
|
+
type: 'object',
|
|
433
|
+
properties: {
|
|
434
|
+
updates: {
|
|
435
|
+
type: 'array',
|
|
436
|
+
description: 'Array of task updates to apply',
|
|
437
|
+
items: {
|
|
438
|
+
type: 'object',
|
|
439
|
+
properties: {
|
|
440
|
+
task_id: { type: 'string', description: 'Task UUID' },
|
|
441
|
+
status: { type: 'string', enum: ['backlog', 'pending', 'in_progress', 'completed', 'cancelled'] },
|
|
442
|
+
progress_percentage: { type: 'number', minimum: 0, maximum: 100 },
|
|
443
|
+
progress_note: { type: 'string', description: 'Brief note about what was achieved' },
|
|
444
|
+
priority: { type: 'number', minimum: 1, maximum: 5 },
|
|
445
|
+
},
|
|
446
|
+
required: ['task_id'],
|
|
447
|
+
},
|
|
448
|
+
},
|
|
449
|
+
},
|
|
450
|
+
required: ['updates'],
|
|
451
|
+
},
|
|
452
|
+
},
|
|
453
|
+
{
|
|
454
|
+
name: 'batch_complete_tasks',
|
|
455
|
+
description: `Mark multiple tasks as completed at once.`,
|
|
456
|
+
inputSchema: {
|
|
457
|
+
type: 'object',
|
|
458
|
+
properties: {
|
|
459
|
+
completions: {
|
|
460
|
+
type: 'array',
|
|
461
|
+
description: 'Array of task completions',
|
|
462
|
+
items: {
|
|
463
|
+
type: 'object',
|
|
464
|
+
properties: {
|
|
465
|
+
task_id: { type: 'string', description: 'Task UUID' },
|
|
466
|
+
summary: { type: 'string', description: 'Optional completion summary' },
|
|
467
|
+
},
|
|
468
|
+
required: ['task_id'],
|
|
469
|
+
},
|
|
470
|
+
},
|
|
471
|
+
},
|
|
472
|
+
required: ['completions'],
|
|
473
|
+
},
|
|
474
|
+
},
|
|
475
|
+
{
|
|
476
|
+
name: 'add_subtask',
|
|
477
|
+
description: `Add a subtask to break down a larger task into smaller workable pieces.
|
|
478
|
+
Subtasks can be claimed and worked on independently by any agent.
|
|
479
|
+
Subtasks inherit the project from their parent task.
|
|
480
|
+
Max depth is 1 (subtasks cannot have their own subtasks).`,
|
|
481
|
+
inputSchema: {
|
|
482
|
+
type: 'object',
|
|
483
|
+
properties: {
|
|
484
|
+
parent_task_id: {
|
|
485
|
+
type: 'string',
|
|
486
|
+
description: 'UUID of the parent task to add subtask to',
|
|
487
|
+
},
|
|
488
|
+
title: {
|
|
489
|
+
type: 'string',
|
|
490
|
+
description: 'Subtask title',
|
|
491
|
+
},
|
|
492
|
+
description: {
|
|
493
|
+
type: 'string',
|
|
494
|
+
description: 'Detailed description (optional)',
|
|
495
|
+
},
|
|
496
|
+
priority: {
|
|
497
|
+
type: 'number',
|
|
498
|
+
minimum: 1,
|
|
499
|
+
maximum: 5,
|
|
500
|
+
description: 'Priority 1-5 (1 = highest). Defaults to parent task priority.',
|
|
501
|
+
},
|
|
502
|
+
estimated_minutes: {
|
|
503
|
+
type: 'number',
|
|
504
|
+
minimum: 1,
|
|
505
|
+
description: 'Estimated time to complete in minutes',
|
|
506
|
+
},
|
|
507
|
+
},
|
|
508
|
+
required: ['parent_task_id', 'title'],
|
|
509
|
+
},
|
|
510
|
+
},
|
|
511
|
+
{
|
|
512
|
+
name: 'get_subtasks',
|
|
513
|
+
description: `Get subtasks for a parent task with pagination.
|
|
514
|
+
Returns subtasks with aggregate completion stats.`,
|
|
515
|
+
inputSchema: {
|
|
516
|
+
type: 'object',
|
|
517
|
+
properties: {
|
|
518
|
+
parent_task_id: {
|
|
519
|
+
type: 'string',
|
|
520
|
+
description: 'UUID of the parent task',
|
|
521
|
+
},
|
|
522
|
+
status: {
|
|
523
|
+
type: 'string',
|
|
524
|
+
enum: ['backlog', 'pending', 'in_progress', 'completed', 'cancelled'],
|
|
525
|
+
description: 'Filter by status (optional)',
|
|
526
|
+
},
|
|
527
|
+
limit: {
|
|
528
|
+
type: 'number',
|
|
529
|
+
description: 'Max subtasks to return (default: 20, max: 50)',
|
|
530
|
+
},
|
|
531
|
+
offset: {
|
|
532
|
+
type: 'number',
|
|
533
|
+
description: 'Number of subtasks to skip (default: 0)',
|
|
534
|
+
},
|
|
535
|
+
},
|
|
536
|
+
required: ['parent_task_id'],
|
|
537
|
+
},
|
|
538
|
+
},
|
|
539
|
+
];
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Validation Tool Definitions
|
|
3
|
+
*
|
|
4
|
+
* Tools for task validation workflow:
|
|
5
|
+
* - get_tasks_awaiting_validation
|
|
6
|
+
* - claim_validation
|
|
7
|
+
* - validate_task
|
|
8
|
+
*/
|
|
9
|
+
export const validationTools = [
|
|
10
|
+
{
|
|
11
|
+
name: 'get_tasks_awaiting_validation',
|
|
12
|
+
description: `Get completed tasks not yet validated.`,
|
|
13
|
+
inputSchema: {
|
|
14
|
+
type: 'object',
|
|
15
|
+
properties: {
|
|
16
|
+
project_id: {
|
|
17
|
+
type: 'string',
|
|
18
|
+
description: 'Project UUID',
|
|
19
|
+
},
|
|
20
|
+
},
|
|
21
|
+
required: ['project_id'],
|
|
22
|
+
},
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
name: 'claim_validation',
|
|
26
|
+
description: 'Claim a completed task for review. Shows "being reviewed" on dashboard.',
|
|
27
|
+
inputSchema: {
|
|
28
|
+
type: 'object',
|
|
29
|
+
properties: {
|
|
30
|
+
task_id: {
|
|
31
|
+
type: 'string',
|
|
32
|
+
description: 'Task UUID to claim for review',
|
|
33
|
+
},
|
|
34
|
+
},
|
|
35
|
+
required: ['task_id'],
|
|
36
|
+
},
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
name: 'validate_task',
|
|
40
|
+
description: 'Validate a completed task. Include test results in validation_notes. For github-flow/git-flow projects, a PR must exist and checks must pass before approval.',
|
|
41
|
+
inputSchema: {
|
|
42
|
+
type: 'object',
|
|
43
|
+
properties: {
|
|
44
|
+
task_id: {
|
|
45
|
+
type: 'string',
|
|
46
|
+
description: 'Task UUID to validate',
|
|
47
|
+
},
|
|
48
|
+
validation_notes: {
|
|
49
|
+
type: 'string',
|
|
50
|
+
description: 'Notes about the validation (what was checked, any issues found)',
|
|
51
|
+
},
|
|
52
|
+
approved: {
|
|
53
|
+
type: 'boolean',
|
|
54
|
+
description: 'Whether the task passes validation (true = approved, false = needs more work)',
|
|
55
|
+
},
|
|
56
|
+
pr_checks_passing: {
|
|
57
|
+
type: 'boolean',
|
|
58
|
+
description: 'REQUIRED when approving tasks with PRs. Confirm you verified PR checks are passing via `gh pr view <PR_NUMBER> --json statusCheckRollup`. Set to true only if all required checks pass.',
|
|
59
|
+
},
|
|
60
|
+
skip_pr_check: {
|
|
61
|
+
type: 'boolean',
|
|
62
|
+
description: 'Skip PR existence check (use only for tasks that legitimately do not need a PR)',
|
|
63
|
+
},
|
|
64
|
+
create_fix_task: {
|
|
65
|
+
type: 'boolean',
|
|
66
|
+
description: 'When rejecting (approved: false), create a new fix task linked to the original. The fix task will contain the rejection reason and be assigned the same git branch.',
|
|
67
|
+
},
|
|
68
|
+
},
|
|
69
|
+
required: ['task_id', 'approved'],
|
|
70
|
+
},
|
|
71
|
+
},
|
|
72
|
+
];
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Git Worktree Tool Definitions
|
|
3
|
+
*
|
|
4
|
+
* Tools for managing git worktrees:
|
|
5
|
+
* - get_stale_worktrees: Get worktrees that need cleanup
|
|
6
|
+
* - clear_worktree_path: Clear worktree_path from a task after cleanup
|
|
7
|
+
*/
|
|
8
|
+
import type { Tool } from './types.js';
|
|
9
|
+
export declare const worktreeTools: Tool[];
|