@chorus-aidlc/chorus-openclaw-plugin 0.2.4 → 0.3.0
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/package.json +1 -1
- package/src/tools/common-tools.ts +40 -8
package/package.json
CHANGED
|
@@ -89,17 +89,20 @@ export function registerCommonTools(api: any, mcpClient: ChorusMcpClient) {
|
|
|
89
89
|
|
|
90
90
|
api.registerTool({
|
|
91
91
|
name: "chorus_get_available_tasks",
|
|
92
|
-
description: "Get tasks available to claim in a project (status=open)",
|
|
92
|
+
description: "Get tasks available to claim in a project (status=open). Optionally filter by proposal UUIDs.",
|
|
93
93
|
parameters: {
|
|
94
94
|
type: "object",
|
|
95
95
|
properties: {
|
|
96
96
|
projectUuid: { type: "string", description: "Project UUID" },
|
|
97
|
+
proposalUuids: { type: "array", items: { type: "string" }, description: "Filter tasks by proposal UUIDs" },
|
|
97
98
|
},
|
|
98
99
|
required: ["projectUuid"],
|
|
99
100
|
additionalProperties: false,
|
|
100
101
|
},
|
|
101
|
-
async execute(_id: string, { projectUuid }: { projectUuid: string }) {
|
|
102
|
-
const
|
|
102
|
+
async execute(_id: string, { projectUuid, proposalUuids }: { projectUuid: string; proposalUuids?: string[] }) {
|
|
103
|
+
const args: Record<string, unknown> = { projectUuid };
|
|
104
|
+
if (proposalUuids && proposalUuids.length > 0) args.proposalUuids = proposalUuids;
|
|
105
|
+
const result = await mcpClient.callTool("chorus_get_available_tasks", args);
|
|
103
106
|
return JSON.stringify(result, null, 2);
|
|
104
107
|
},
|
|
105
108
|
});
|
|
@@ -145,23 +148,25 @@ export function registerCommonTools(api: any, mcpClient: ChorusMcpClient) {
|
|
|
145
148
|
|
|
146
149
|
api.registerTool({
|
|
147
150
|
name: "chorus_list_tasks",
|
|
148
|
-
description: "List tasks for a project. Can filter by status and
|
|
151
|
+
description: "List tasks for a project. Can filter by status, priority, and proposal UUIDs.",
|
|
149
152
|
parameters: {
|
|
150
153
|
type: "object",
|
|
151
154
|
properties: {
|
|
152
155
|
projectUuid: { type: "string", description: "Project UUID" },
|
|
153
156
|
status: { type: "string", description: "Filter by status: open | assigned | in_progress | to_verify | done | closed" },
|
|
154
157
|
priority: { type: "string", description: "Filter by priority: low | medium | high" },
|
|
158
|
+
proposalUuids: { type: "array", items: { type: "string" }, description: "Filter tasks by proposal UUIDs" },
|
|
155
159
|
page: { type: "number", description: "Page number (default: 1)" },
|
|
156
160
|
pageSize: { type: "number", description: "Items per page (default: 20)" },
|
|
157
161
|
},
|
|
158
162
|
required: ["projectUuid"],
|
|
159
163
|
additionalProperties: false,
|
|
160
164
|
},
|
|
161
|
-
async execute(_id: string, { projectUuid, status, priority, page, pageSize }: { projectUuid: string; status?: string; priority?: string; page?: number; pageSize?: number }) {
|
|
165
|
+
async execute(_id: string, { projectUuid, status, priority, proposalUuids, page, pageSize }: { projectUuid: string; status?: string; priority?: string; proposalUuids?: string[]; page?: number; pageSize?: number }) {
|
|
162
166
|
const args: Record<string, unknown> = { projectUuid };
|
|
163
167
|
if (status) args.status = status;
|
|
164
168
|
if (priority) args.priority = priority;
|
|
169
|
+
if (proposalUuids && proposalUuids.length > 0) args.proposalUuids = proposalUuids;
|
|
165
170
|
if (page !== undefined) args.page = page;
|
|
166
171
|
if (pageSize !== undefined) args.pageSize = pageSize;
|
|
167
172
|
const result = await mcpClient.callTool("chorus_list_tasks", args);
|
|
@@ -260,17 +265,20 @@ export function registerCommonTools(api: any, mcpClient: ChorusMcpClient) {
|
|
|
260
265
|
|
|
261
266
|
api.registerTool({
|
|
262
267
|
name: "chorus_get_unblocked_tasks",
|
|
263
|
-
description: "Get tasks that are ready to start — status is open/assigned and all dependencies are resolved (done/closed). Note: to_verify is NOT considered resolved.",
|
|
268
|
+
description: "Get tasks that are ready to start — status is open/assigned and all dependencies are resolved (done/closed). Optionally filter by proposal UUIDs. Note: to_verify is NOT considered resolved.",
|
|
264
269
|
parameters: {
|
|
265
270
|
type: "object",
|
|
266
271
|
properties: {
|
|
267
272
|
projectUuid: { type: "string", description: "Project UUID" },
|
|
273
|
+
proposalUuids: { type: "array", items: { type: "string" }, description: "Filter tasks by proposal UUIDs" },
|
|
268
274
|
},
|
|
269
275
|
required: ["projectUuid"],
|
|
270
276
|
additionalProperties: false,
|
|
271
277
|
},
|
|
272
|
-
async execute(_id: string, { projectUuid }: { projectUuid: string }) {
|
|
273
|
-
const
|
|
278
|
+
async execute(_id: string, { projectUuid, proposalUuids }: { projectUuid: string; proposalUuids?: string[] }) {
|
|
279
|
+
const args: Record<string, unknown> = { projectUuid };
|
|
280
|
+
if (proposalUuids && proposalUuids.length > 0) args.proposalUuids = proposalUuids;
|
|
281
|
+
const result = await mcpClient.callTool("chorus_get_unblocked_tasks", args);
|
|
274
282
|
return JSON.stringify(result, null, 2);
|
|
275
283
|
},
|
|
276
284
|
});
|
|
@@ -424,4 +432,28 @@ export function registerCommonTools(api: any, mcpClient: ChorusMcpClient) {
|
|
|
424
432
|
return JSON.stringify(result, null, 2);
|
|
425
433
|
},
|
|
426
434
|
});
|
|
435
|
+
|
|
436
|
+
api.registerTool({
|
|
437
|
+
name: "chorus_search",
|
|
438
|
+
description: "Search across tasks, ideas, proposals, documents, projects, and project groups.",
|
|
439
|
+
parameters: {
|
|
440
|
+
type: "object",
|
|
441
|
+
properties: {
|
|
442
|
+
query: { type: "string", description: "Search query (matches title, description, content)" },
|
|
443
|
+
scope: { type: "string", enum: ["global", "group", "project"], description: "Search scope (default: global)" },
|
|
444
|
+
scopeUuid: { type: "string", description: "Project group UUID (when scope=group) or project UUID (when scope=project)" },
|
|
445
|
+
entityTypes: { type: "array", items: { type: "string", enum: ["task", "idea", "proposal", "document", "project", "project_group"] }, description: "Entity types to search (default: all). Example: [\"task\", \"idea\"]" },
|
|
446
|
+
},
|
|
447
|
+
required: ["query"],
|
|
448
|
+
additionalProperties: false,
|
|
449
|
+
},
|
|
450
|
+
async execute(_id: string, { query, scope, scopeUuid, entityTypes }: { query: string; scope?: string; scopeUuid?: string; entityTypes?: string[] }) {
|
|
451
|
+
const args: Record<string, unknown> = { query };
|
|
452
|
+
if (scope) args.scope = scope;
|
|
453
|
+
if (scopeUuid) args.scopeUuid = scopeUuid;
|
|
454
|
+
if (entityTypes) args.entityTypes = entityTypes;
|
|
455
|
+
const result = await mcpClient.callTool("chorus_search", args);
|
|
456
|
+
return JSON.stringify(result, null, 2);
|
|
457
|
+
},
|
|
458
|
+
});
|
|
427
459
|
}
|