@codebolt/codeboltjs 5.0.8 → 5.1.10
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/core/Codebolt.d.ts +48 -5
- package/dist/core/Codebolt.js +76 -16
- package/dist/core/websocket.js +16 -18
- package/dist/index.d.ts +3 -0
- package/dist/index.js +9 -3
- package/dist/modules/agentDeliberation.js +3 -1
- package/dist/modules/dynamicPanel.d.ts +106 -0
- package/dist/modules/dynamicPanel.js +122 -0
- package/dist/modules/environment.d.ts +24 -0
- package/dist/modules/environment.js +51 -0
- package/dist/modules/mcp.js +3 -0
- package/dist/tools/actionBlock/action-block-start.js +1 -4
- package/dist/tools/actionPlan/action-plan-create.js +1 -2
- package/dist/tools/completion/attempt-completion.d.ts +25 -0
- package/dist/tools/completion/attempt-completion.js +45 -0
- package/dist/tools/completion/index.d.ts +3 -0
- package/dist/tools/completion/index.js +9 -0
- package/dist/tools/environment/environment-create.d.ts +23 -0
- package/dist/tools/environment/environment-create.js +90 -0
- package/dist/tools/environment/environment-delete.d.ts +17 -0
- package/dist/tools/environment/environment-delete.js +70 -0
- package/dist/tools/environment/environment-get.d.ts +17 -0
- package/dist/tools/environment/environment-get.js +73 -0
- package/dist/tools/environment/environment-list.d.ts +15 -0
- package/dist/tools/environment/environment-list.js +72 -0
- package/dist/tools/environment/environment-providers.d.ts +24 -0
- package/dist/tools/environment/environment-providers.js +130 -0
- package/dist/tools/environment/environment-restart.d.ts +17 -0
- package/dist/tools/environment/environment-restart.js +70 -0
- package/dist/tools/environment/environment-send-message.d.ts +19 -0
- package/dist/tools/environment/environment-send-message.js +74 -0
- package/dist/tools/environment/environment-start.d.ts +17 -0
- package/dist/tools/environment/environment-start.js +70 -0
- package/dist/tools/environment/environment-statistics.d.ts +15 -0
- package/dist/tools/environment/environment-statistics.js +69 -0
- package/dist/tools/environment/environment-status.d.ts +17 -0
- package/dist/tools/environment/environment-status.js +72 -0
- package/dist/tools/environment/environment-stop.d.ts +17 -0
- package/dist/tools/environment/environment-stop.js +70 -0
- package/dist/tools/environment/environment-update.d.ts +19 -0
- package/dist/tools/environment/environment-update.js +74 -0
- package/dist/tools/environment/index.d.ts +31 -0
- package/dist/tools/environment/index.js +61 -0
- package/dist/tools/index.d.ts +20 -3
- package/dist/tools/index.js +55 -8
- package/dist/tools/job/index.d.ts +3 -1
- package/dist/tools/job/index.js +5 -1
- package/dist/tools/job/job-remove-dependency.d.ts +28 -0
- package/dist/tools/job/job-remove-dependency.js +86 -0
- package/dist/tools/registry.d.ts +21 -0
- package/dist/tools/registry.js +38 -1
- package/dist/tools/requirementPlan/requirement-plan-review.js +1 -1
- package/dist/tools/thread/thread-create-background.js +1 -1
- package/dist/tools/tool-search.d.ts +49 -0
- package/dist/tools/tool-search.js +140 -0
- package/dist/tools/toolSearch/index.d.ts +9 -0
- package/dist/tools/toolSearch/index.js +15 -0
- package/dist/tools/toolSearch/tool-search-tool.d.ts +32 -0
- package/dist/tools/toolSearch/tool-search-tool.js +110 -0
- package/dist/tools/utils/schema-validator.d.ts +1 -0
- package/dist/tools/utils/schema-validator.js +13 -1
- package/dist/types/agentDeliberation.d.ts +15 -1
- package/dist/types/agentDeliberation.js +2 -0
- package/package.json +20 -19
- package/dist/modules/codeboltEvent.d.ts +0 -57
- package/dist/modules/codeboltEvent.js +0 -217
- package/dist/tools/browser/browser-action.d.ts +0 -56
- package/dist/tools/browser/browser-action.js +0 -265
- package/dist/tools/codeboltEvent/event-add-running-agent.d.ts +0 -25
- package/dist/tools/codeboltEvent/event-add-running-agent.js +0 -69
- package/dist/tools/codeboltEvent/event-check-background-agent-completion.d.ts +0 -19
- package/dist/tools/codeboltEvent/event-check-background-agent-completion.js +0 -64
- package/dist/tools/codeboltEvent/event-get-running-agent-count.d.ts +0 -19
- package/dist/tools/codeboltEvent/event-get-running-agent-count.js +0 -55
- package/dist/tools/codeboltEvent/event-on-background-agent-completion.d.ts +0 -19
- package/dist/tools/codeboltEvent/event-on-background-agent-completion.js +0 -56
- package/dist/tools/codeboltEvent/event-wait-for-external-event.d.ts +0 -19
- package/dist/tools/codeboltEvent/event-wait-for-external-event.js +0 -55
- package/dist/tools/codeboltEvent/index.d.ts +0 -19
- package/dist/tools/codeboltEvent/index.js +0 -33
- package/dist/tools/event/event-add-running-agent.d.ts +0 -32
- package/dist/tools/event/event-add-running-agent.js +0 -77
- package/dist/tools/event/event-check-agent-event.d.ts +0 -19
- package/dist/tools/event/event-check-agent-event.js +0 -63
- package/dist/tools/event/event-check-completion.d.ts +0 -19
- package/dist/tools/event/event-check-completion.js +0 -73
- package/dist/tools/event/event-check-grouped-completion.d.ts +0 -19
- package/dist/tools/event/event-check-grouped-completion.js +0 -63
- package/dist/tools/event/event-get-running-count.d.ts +0 -19
- package/dist/tools/event/event-get-running-count.js +0 -55
- package/dist/tools/event/event-on-agent-event.d.ts +0 -19
- package/dist/tools/event/event-on-agent-event.js +0 -63
- package/dist/tools/event/event-on-completion.d.ts +0 -19
- package/dist/tools/event/event-on-completion.js +0 -73
- package/dist/tools/event/event-on-grouped-completion.d.ts +0 -19
- package/dist/tools/event/event-on-grouped-completion.js +0 -63
- package/dist/tools/event/event-wait-any.d.ts +0 -19
- package/dist/tools/event/event-wait-any.js +0 -66
- package/dist/tools/event/index.d.ts +0 -25
- package/dist/tools/event/index.js +0 -48
- package/dist/tools/git/git-action.d.ts +0 -48
- package/dist/tools/git/git-action.js +0 -279
- package/dist/tools/kvStore/kv-store-create-instance.d.ts +0 -26
- package/dist/tools/kvStore/kv-store-create-instance.js +0 -79
- package/dist/tools/kvStore/kv-store-get.d.ts +0 -30
- package/dist/tools/kvStore/kv-store-get.js +0 -80
- package/dist/tools/kvStore/kv-store-set.d.ts +0 -38
- package/dist/tools/kvStore/kv-store-set.js +0 -86
- package/dist/tools/memoryIngestion/mi-create-pipeline.d.ts +0 -44
- package/dist/tools/memoryIngestion/mi-create-pipeline.js +0 -114
- package/dist/tools/memoryIngestion/mi-list.d.ts +0 -22
- package/dist/tools/memoryIngestion/mi-list.js +0 -66
- package/dist/tools/orchestration/agent-details.d.ts +0 -15
- package/dist/tools/orchestration/agent-details.js +0 -98
- package/dist/tools/orchestration/agent-find.d.ts +0 -18
- package/dist/tools/orchestration/agent-find.js +0 -125
- package/dist/tools/orchestration/agent-list.d.ts +0 -13
- package/dist/tools/orchestration/agent-list.js +0 -106
- package/dist/tools/orchestration/agent-management.d.ts +0 -44
- package/dist/tools/orchestration/agent-management.js +0 -250
- package/dist/tools/orchestration/agent-start.d.ts +0 -18
- package/dist/tools/orchestration/agent-start.js +0 -90
- package/dist/tools/orchestration/index.d.ts +0 -49
- package/dist/tools/orchestration/index.js +0 -102
- package/dist/tools/orchestration/task-assign.d.ts +0 -18
- package/dist/tools/orchestration/task-assign.js +0 -84
- package/dist/tools/orchestration/task-create.d.ts +0 -20
- package/dist/tools/orchestration/task-create.js +0 -97
- package/dist/tools/orchestration/task-delete.d.ts +0 -16
- package/dist/tools/orchestration/task-delete.js +0 -77
- package/dist/tools/orchestration/task-execute.d.ts +0 -18
- package/dist/tools/orchestration/task-execute.js +0 -84
- package/dist/tools/orchestration/task-get.d.ts +0 -16
- package/dist/tools/orchestration/task-get.js +0 -89
- package/dist/tools/orchestration/task-list.d.ts +0 -13
- package/dist/tools/orchestration/task-list.js +0 -74
- package/dist/tools/orchestration/task-management.d.ts +0 -52
- package/dist/tools/orchestration/task-management.js +0 -231
- package/dist/tools/orchestration/task-update.d.ts +0 -22
- package/dist/tools/orchestration/task-update.js +0 -96
- package/dist/tools/orchestration/thread-create-background.d.ts +0 -18
- package/dist/tools/orchestration/thread-create-background.js +0 -94
- package/dist/tools/orchestration/thread-create-start.d.ts +0 -16
- package/dist/tools/orchestration/thread-create-start.js +0 -85
- package/dist/tools/orchestration/thread-create.d.ts +0 -16
- package/dist/tools/orchestration/thread-create.js +0 -85
- package/dist/tools/orchestration/thread-delete.d.ts +0 -16
- package/dist/tools/orchestration/thread-delete.js +0 -77
- package/dist/tools/orchestration/thread-get-messages.d.ts +0 -24
- package/dist/tools/orchestration/thread-get-messages.js +0 -122
- package/dist/tools/orchestration/thread-get.d.ts +0 -16
- package/dist/tools/orchestration/thread-get.js +0 -85
- package/dist/tools/orchestration/thread-list.d.ts +0 -16
- package/dist/tools/orchestration/thread-list.js +0 -85
- package/dist/tools/orchestration/thread-start.d.ts +0 -16
- package/dist/tools/orchestration/thread-start.js +0 -82
- package/dist/tools/orchestration/thread-update-status.d.ts +0 -18
- package/dist/tools/orchestration/thread-update-status.js +0 -89
- package/dist/tools/orchestration/thread-update.d.ts +0 -18
- package/dist/tools/orchestration/thread-update.js +0 -89
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Orchestration tools - Individual tools for task, agent, and thread management
|
|
3
|
-
*/
|
|
4
|
-
export { TaskCreateTool, type TaskCreateParams } from './task-create';
|
|
5
|
-
export { TaskUpdateTool, type TaskUpdateParams } from './task-update';
|
|
6
|
-
export { TaskDeleteTool, type TaskDeleteParams } from './task-delete';
|
|
7
|
-
export { TaskListTool, type TaskListParams } from './task-list';
|
|
8
|
-
export { TaskGetTool, type TaskGetParams } from './task-get';
|
|
9
|
-
export { TaskAssignTool, type TaskAssignParams } from './task-assign';
|
|
10
|
-
export { TaskExecuteTool, type TaskExecuteParams } from './task-execute';
|
|
11
|
-
export { AgentFindTool, type AgentFindParams } from './agent-find';
|
|
12
|
-
export { AgentStartTool, type AgentStartParams } from './agent-start';
|
|
13
|
-
export { AgentListTool, type AgentListParams } from './agent-list';
|
|
14
|
-
export { AgentDetailsTool, type AgentDetailsParams } from './agent-details';
|
|
15
|
-
export { ThreadCreateTool, type ThreadCreateParams } from './thread-create';
|
|
16
|
-
export { ThreadCreateStartTool, type ThreadCreateStartParams } from './thread-create-start';
|
|
17
|
-
export { ThreadCreateBackgroundTool, type ThreadCreateBackgroundParams } from './thread-create-background';
|
|
18
|
-
export { ThreadListTool, type ThreadListParams } from './thread-list';
|
|
19
|
-
export { ThreadGetTool, type ThreadGetParams } from './thread-get';
|
|
20
|
-
export { ThreadStartTool, type ThreadStartParams } from './thread-start';
|
|
21
|
-
export { ThreadUpdateTool, type ThreadUpdateParams } from './thread-update';
|
|
22
|
-
export { ThreadDeleteTool, type ThreadDeleteParams } from './thread-delete';
|
|
23
|
-
export { ThreadGetMessagesTool, type ThreadGetMessagesParams } from './thread-get-messages';
|
|
24
|
-
export { ThreadUpdateStatusTool, type ThreadUpdateStatusParams } from './thread-update-status';
|
|
25
|
-
import { TaskCreateTool } from './task-create';
|
|
26
|
-
import { TaskUpdateTool } from './task-update';
|
|
27
|
-
import { TaskDeleteTool } from './task-delete';
|
|
28
|
-
import { TaskListTool } from './task-list';
|
|
29
|
-
import { TaskGetTool } from './task-get';
|
|
30
|
-
import { TaskAssignTool } from './task-assign';
|
|
31
|
-
import { TaskExecuteTool } from './task-execute';
|
|
32
|
-
import { AgentFindTool } from './agent-find';
|
|
33
|
-
import { AgentStartTool } from './agent-start';
|
|
34
|
-
import { AgentListTool } from './agent-list';
|
|
35
|
-
import { AgentDetailsTool } from './agent-details';
|
|
36
|
-
import { ThreadCreateTool } from './thread-create';
|
|
37
|
-
import { ThreadCreateStartTool } from './thread-create-start';
|
|
38
|
-
import { ThreadCreateBackgroundTool } from './thread-create-background';
|
|
39
|
-
import { ThreadListTool } from './thread-list';
|
|
40
|
-
import { ThreadGetTool } from './thread-get';
|
|
41
|
-
import { ThreadStartTool } from './thread-start';
|
|
42
|
-
import { ThreadUpdateTool } from './thread-update';
|
|
43
|
-
import { ThreadDeleteTool } from './thread-delete';
|
|
44
|
-
import { ThreadGetMessagesTool } from './thread-get-messages';
|
|
45
|
-
import { ThreadUpdateStatusTool } from './thread-update-status';
|
|
46
|
-
/**
|
|
47
|
-
* All orchestration tools
|
|
48
|
-
*/
|
|
49
|
-
export declare const orchestrationTools: (TaskCreateTool | TaskUpdateTool | TaskDeleteTool | TaskListTool | TaskGetTool | TaskAssignTool | TaskExecuteTool | AgentFindTool | AgentStartTool | AgentListTool | AgentDetailsTool | ThreadCreateTool | ThreadCreateStartTool | ThreadCreateBackgroundTool | ThreadListTool | ThreadGetTool | ThreadStartTool | ThreadUpdateTool | ThreadDeleteTool | ThreadGetMessagesTool | ThreadUpdateStatusTool)[];
|
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* Orchestration tools - Individual tools for task, agent, and thread management
|
|
4
|
-
*/
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.orchestrationTools = exports.ThreadUpdateStatusTool = exports.ThreadGetMessagesTool = exports.ThreadDeleteTool = exports.ThreadUpdateTool = exports.ThreadStartTool = exports.ThreadGetTool = exports.ThreadListTool = exports.ThreadCreateBackgroundTool = exports.ThreadCreateStartTool = exports.ThreadCreateTool = exports.AgentDetailsTool = exports.AgentListTool = exports.AgentStartTool = exports.AgentFindTool = exports.TaskExecuteTool = exports.TaskAssignTool = exports.TaskGetTool = exports.TaskListTool = exports.TaskDeleteTool = exports.TaskUpdateTool = exports.TaskCreateTool = void 0;
|
|
7
|
-
// Task tools
|
|
8
|
-
var task_create_1 = require("./task-create");
|
|
9
|
-
Object.defineProperty(exports, "TaskCreateTool", { enumerable: true, get: function () { return task_create_1.TaskCreateTool; } });
|
|
10
|
-
var task_update_1 = require("./task-update");
|
|
11
|
-
Object.defineProperty(exports, "TaskUpdateTool", { enumerable: true, get: function () { return task_update_1.TaskUpdateTool; } });
|
|
12
|
-
var task_delete_1 = require("./task-delete");
|
|
13
|
-
Object.defineProperty(exports, "TaskDeleteTool", { enumerable: true, get: function () { return task_delete_1.TaskDeleteTool; } });
|
|
14
|
-
var task_list_1 = require("./task-list");
|
|
15
|
-
Object.defineProperty(exports, "TaskListTool", { enumerable: true, get: function () { return task_list_1.TaskListTool; } });
|
|
16
|
-
var task_get_1 = require("./task-get");
|
|
17
|
-
Object.defineProperty(exports, "TaskGetTool", { enumerable: true, get: function () { return task_get_1.TaskGetTool; } });
|
|
18
|
-
var task_assign_1 = require("./task-assign");
|
|
19
|
-
Object.defineProperty(exports, "TaskAssignTool", { enumerable: true, get: function () { return task_assign_1.TaskAssignTool; } });
|
|
20
|
-
var task_execute_1 = require("./task-execute");
|
|
21
|
-
Object.defineProperty(exports, "TaskExecuteTool", { enumerable: true, get: function () { return task_execute_1.TaskExecuteTool; } });
|
|
22
|
-
// Agent tools
|
|
23
|
-
var agent_find_1 = require("./agent-find");
|
|
24
|
-
Object.defineProperty(exports, "AgentFindTool", { enumerable: true, get: function () { return agent_find_1.AgentFindTool; } });
|
|
25
|
-
var agent_start_1 = require("./agent-start");
|
|
26
|
-
Object.defineProperty(exports, "AgentStartTool", { enumerable: true, get: function () { return agent_start_1.AgentStartTool; } });
|
|
27
|
-
var agent_list_1 = require("./agent-list");
|
|
28
|
-
Object.defineProperty(exports, "AgentListTool", { enumerable: true, get: function () { return agent_list_1.AgentListTool; } });
|
|
29
|
-
var agent_details_1 = require("./agent-details");
|
|
30
|
-
Object.defineProperty(exports, "AgentDetailsTool", { enumerable: true, get: function () { return agent_details_1.AgentDetailsTool; } });
|
|
31
|
-
// Thread tools
|
|
32
|
-
var thread_create_1 = require("./thread-create");
|
|
33
|
-
Object.defineProperty(exports, "ThreadCreateTool", { enumerable: true, get: function () { return thread_create_1.ThreadCreateTool; } });
|
|
34
|
-
var thread_create_start_1 = require("./thread-create-start");
|
|
35
|
-
Object.defineProperty(exports, "ThreadCreateStartTool", { enumerable: true, get: function () { return thread_create_start_1.ThreadCreateStartTool; } });
|
|
36
|
-
var thread_create_background_1 = require("./thread-create-background");
|
|
37
|
-
Object.defineProperty(exports, "ThreadCreateBackgroundTool", { enumerable: true, get: function () { return thread_create_background_1.ThreadCreateBackgroundTool; } });
|
|
38
|
-
var thread_list_1 = require("./thread-list");
|
|
39
|
-
Object.defineProperty(exports, "ThreadListTool", { enumerable: true, get: function () { return thread_list_1.ThreadListTool; } });
|
|
40
|
-
var thread_get_1 = require("./thread-get");
|
|
41
|
-
Object.defineProperty(exports, "ThreadGetTool", { enumerable: true, get: function () { return thread_get_1.ThreadGetTool; } });
|
|
42
|
-
var thread_start_1 = require("./thread-start");
|
|
43
|
-
Object.defineProperty(exports, "ThreadStartTool", { enumerable: true, get: function () { return thread_start_1.ThreadStartTool; } });
|
|
44
|
-
var thread_update_1 = require("./thread-update");
|
|
45
|
-
Object.defineProperty(exports, "ThreadUpdateTool", { enumerable: true, get: function () { return thread_update_1.ThreadUpdateTool; } });
|
|
46
|
-
var thread_delete_1 = require("./thread-delete");
|
|
47
|
-
Object.defineProperty(exports, "ThreadDeleteTool", { enumerable: true, get: function () { return thread_delete_1.ThreadDeleteTool; } });
|
|
48
|
-
var thread_get_messages_1 = require("./thread-get-messages");
|
|
49
|
-
Object.defineProperty(exports, "ThreadGetMessagesTool", { enumerable: true, get: function () { return thread_get_messages_1.ThreadGetMessagesTool; } });
|
|
50
|
-
var thread_update_status_1 = require("./thread-update-status");
|
|
51
|
-
Object.defineProperty(exports, "ThreadUpdateStatusTool", { enumerable: true, get: function () { return thread_update_status_1.ThreadUpdateStatusTool; } });
|
|
52
|
-
// Create instances for convenience
|
|
53
|
-
const task_create_2 = require("./task-create");
|
|
54
|
-
const task_update_2 = require("./task-update");
|
|
55
|
-
const task_delete_2 = require("./task-delete");
|
|
56
|
-
const task_list_2 = require("./task-list");
|
|
57
|
-
const task_get_2 = require("./task-get");
|
|
58
|
-
const task_assign_2 = require("./task-assign");
|
|
59
|
-
const task_execute_2 = require("./task-execute");
|
|
60
|
-
const agent_find_2 = require("./agent-find");
|
|
61
|
-
const agent_start_2 = require("./agent-start");
|
|
62
|
-
const agent_list_2 = require("./agent-list");
|
|
63
|
-
const agent_details_2 = require("./agent-details");
|
|
64
|
-
const thread_create_2 = require("./thread-create");
|
|
65
|
-
const thread_create_start_2 = require("./thread-create-start");
|
|
66
|
-
const thread_create_background_2 = require("./thread-create-background");
|
|
67
|
-
const thread_list_2 = require("./thread-list");
|
|
68
|
-
const thread_get_2 = require("./thread-get");
|
|
69
|
-
const thread_start_2 = require("./thread-start");
|
|
70
|
-
const thread_update_2 = require("./thread-update");
|
|
71
|
-
const thread_delete_2 = require("./thread-delete");
|
|
72
|
-
const thread_get_messages_2 = require("./thread-get-messages");
|
|
73
|
-
const thread_update_status_2 = require("./thread-update-status");
|
|
74
|
-
/**
|
|
75
|
-
* All orchestration tools
|
|
76
|
-
*/
|
|
77
|
-
exports.orchestrationTools = [
|
|
78
|
-
// Task tools
|
|
79
|
-
new task_create_2.TaskCreateTool(),
|
|
80
|
-
new task_update_2.TaskUpdateTool(),
|
|
81
|
-
new task_delete_2.TaskDeleteTool(),
|
|
82
|
-
new task_list_2.TaskListTool(),
|
|
83
|
-
new task_get_2.TaskGetTool(),
|
|
84
|
-
new task_assign_2.TaskAssignTool(),
|
|
85
|
-
new task_execute_2.TaskExecuteTool(),
|
|
86
|
-
// Agent tools
|
|
87
|
-
new agent_find_2.AgentFindTool(),
|
|
88
|
-
new agent_start_2.AgentStartTool(),
|
|
89
|
-
new agent_list_2.AgentListTool(),
|
|
90
|
-
new agent_details_2.AgentDetailsTool(),
|
|
91
|
-
// Thread tools
|
|
92
|
-
new thread_create_2.ThreadCreateTool(),
|
|
93
|
-
new thread_create_start_2.ThreadCreateStartTool(),
|
|
94
|
-
new thread_create_background_2.ThreadCreateBackgroundTool(),
|
|
95
|
-
new thread_list_2.ThreadListTool(),
|
|
96
|
-
new thread_get_2.ThreadGetTool(),
|
|
97
|
-
new thread_start_2.ThreadStartTool(),
|
|
98
|
-
new thread_update_2.ThreadUpdateTool(),
|
|
99
|
-
new thread_delete_2.ThreadDeleteTool(),
|
|
100
|
-
new thread_get_messages_2.ThreadGetMessagesTool(),
|
|
101
|
-
new thread_update_status_2.ThreadUpdateStatusTool(),
|
|
102
|
-
];
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Task Assign Tool - Assigns an agent to a task
|
|
3
|
-
* Wraps the SDK's taskService.assignAgentToTask() method
|
|
4
|
-
*/
|
|
5
|
-
import type { ToolInvocation, ToolResult } from '../types';
|
|
6
|
-
import { BaseDeclarativeTool } from '../base-tool';
|
|
7
|
-
export interface TaskAssignParams {
|
|
8
|
-
/** The task ID to assign */
|
|
9
|
-
task_id: string;
|
|
10
|
-
/** The agent ID to assign to the task */
|
|
11
|
-
agent_id: string;
|
|
12
|
-
}
|
|
13
|
-
export declare class TaskAssignTool extends BaseDeclarativeTool<TaskAssignParams, ToolResult> {
|
|
14
|
-
static readonly Name: string;
|
|
15
|
-
constructor();
|
|
16
|
-
protected validateToolParamValues(params: TaskAssignParams): string | null;
|
|
17
|
-
protected createInvocation(params: TaskAssignParams): ToolInvocation<TaskAssignParams, ToolResult>;
|
|
18
|
-
}
|
|
@@ -1,84 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* Task Assign Tool - Assigns an agent to a task
|
|
4
|
-
* Wraps the SDK's taskService.assignAgentToTask() method
|
|
5
|
-
*/
|
|
6
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
7
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
8
|
-
};
|
|
9
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.TaskAssignTool = void 0;
|
|
11
|
-
const types_1 = require("../types");
|
|
12
|
-
const base_tool_1 = require("../base-tool");
|
|
13
|
-
const task_1 = __importDefault(require("../../modules/task"));
|
|
14
|
-
class TaskAssignInvocation extends base_tool_1.BaseToolInvocation {
|
|
15
|
-
constructor(params) {
|
|
16
|
-
super(params);
|
|
17
|
-
}
|
|
18
|
-
async execute() {
|
|
19
|
-
var _a;
|
|
20
|
-
try {
|
|
21
|
-
const response = await task_1.default.assignAgentToTask(this.params.task_id, this.params.agent_id);
|
|
22
|
-
if (response && !response.success && response.success !== undefined) {
|
|
23
|
-
const errorMsg = typeof response.error === 'string'
|
|
24
|
-
? response.error
|
|
25
|
-
: ((_a = response.error) === null || _a === void 0 ? void 0 : _a.message) || 'Task assignment failed';
|
|
26
|
-
return {
|
|
27
|
-
llmContent: `Task assignment failed: ${errorMsg}`,
|
|
28
|
-
returnDisplay: `Error: ${errorMsg}`,
|
|
29
|
-
error: {
|
|
30
|
-
message: errorMsg,
|
|
31
|
-
type: types_1.ToolErrorType.TASK_NOT_FOUND,
|
|
32
|
-
},
|
|
33
|
-
};
|
|
34
|
-
}
|
|
35
|
-
return {
|
|
36
|
-
llmContent: `Assigned agent ${this.params.agent_id} to task ${this.params.task_id}`,
|
|
37
|
-
returnDisplay: `Assigned agent ${this.params.agent_id} to task ${this.params.task_id}`,
|
|
38
|
-
};
|
|
39
|
-
}
|
|
40
|
-
catch (error) {
|
|
41
|
-
const errorMessage = error instanceof Error ? error.message : 'Unknown error occurred';
|
|
42
|
-
return {
|
|
43
|
-
llmContent: `Error assigning agent to task: ${errorMessage}`,
|
|
44
|
-
returnDisplay: `Error: ${errorMessage}`,
|
|
45
|
-
error: {
|
|
46
|
-
message: errorMessage,
|
|
47
|
-
type: types_1.ToolErrorType.EXECUTION_FAILED,
|
|
48
|
-
},
|
|
49
|
-
};
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
class TaskAssignTool extends base_tool_1.BaseDeclarativeTool {
|
|
54
|
-
constructor() {
|
|
55
|
-
super(TaskAssignTool.Name, 'TaskAssign', 'Assigns an agent to a task.', types_1.Kind.Other, {
|
|
56
|
-
properties: {
|
|
57
|
-
task_id: {
|
|
58
|
-
description: 'The ID of the task.',
|
|
59
|
-
type: 'string',
|
|
60
|
-
},
|
|
61
|
-
agent_id: {
|
|
62
|
-
description: 'The ID of the agent to assign.',
|
|
63
|
-
type: 'string',
|
|
64
|
-
},
|
|
65
|
-
},
|
|
66
|
-
required: ['task_id', 'agent_id'],
|
|
67
|
-
type: 'object',
|
|
68
|
-
});
|
|
69
|
-
}
|
|
70
|
-
validateToolParamValues(params) {
|
|
71
|
-
if (!params.task_id || params.task_id.trim() === '') {
|
|
72
|
-
return "'task_id' is required for task assign";
|
|
73
|
-
}
|
|
74
|
-
if (!params.agent_id || params.agent_id.trim() === '') {
|
|
75
|
-
return "'agent_id' is required for task assign";
|
|
76
|
-
}
|
|
77
|
-
return null;
|
|
78
|
-
}
|
|
79
|
-
createInvocation(params) {
|
|
80
|
-
return new TaskAssignInvocation(params);
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
exports.TaskAssignTool = TaskAssignTool;
|
|
84
|
-
TaskAssignTool.Name = 'task_assign';
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Task Create Tool - Creates a new task
|
|
3
|
-
* Wraps the SDK's taskService.createTask() method
|
|
4
|
-
*/
|
|
5
|
-
import type { ToolInvocation, ToolResult } from '../types';
|
|
6
|
-
import { BaseDeclarativeTool } from '../base-tool';
|
|
7
|
-
export interface TaskCreateParams {
|
|
8
|
-
/** Task title/name */
|
|
9
|
-
title: string;
|
|
10
|
-
/** Task description */
|
|
11
|
-
description?: string;
|
|
12
|
-
/** Thread ID for the task */
|
|
13
|
-
thread_id?: string;
|
|
14
|
-
}
|
|
15
|
-
export declare class TaskCreateTool extends BaseDeclarativeTool<TaskCreateParams, ToolResult> {
|
|
16
|
-
static readonly Name: string;
|
|
17
|
-
constructor();
|
|
18
|
-
protected validateToolParamValues(params: TaskCreateParams): string | null;
|
|
19
|
-
protected createInvocation(params: TaskCreateParams): ToolInvocation<TaskCreateParams, ToolResult>;
|
|
20
|
-
}
|
|
@@ -1,97 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* Task Create Tool - Creates a new task
|
|
4
|
-
* Wraps the SDK's taskService.createTask() method
|
|
5
|
-
*/
|
|
6
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
7
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
8
|
-
};
|
|
9
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.TaskCreateTool = void 0;
|
|
11
|
-
const types_1 = require("../types");
|
|
12
|
-
const base_tool_1 = require("../base-tool");
|
|
13
|
-
const task_1 = __importDefault(require("../../modules/task"));
|
|
14
|
-
class TaskCreateInvocation extends base_tool_1.BaseToolInvocation {
|
|
15
|
-
constructor(params) {
|
|
16
|
-
super(params);
|
|
17
|
-
}
|
|
18
|
-
async execute() {
|
|
19
|
-
var _a;
|
|
20
|
-
try {
|
|
21
|
-
const response = await task_1.default.createTask({
|
|
22
|
-
name: this.params.title,
|
|
23
|
-
description: this.params.description,
|
|
24
|
-
threadId: this.params.thread_id || '',
|
|
25
|
-
});
|
|
26
|
-
if (response && !response.success && response.success !== undefined) {
|
|
27
|
-
const errorMsg = typeof response.error === 'string'
|
|
28
|
-
? response.error
|
|
29
|
-
: ((_a = response.error) === null || _a === void 0 ? void 0 : _a.message) || 'Task creation failed';
|
|
30
|
-
return {
|
|
31
|
-
llmContent: `Task creation failed: ${errorMsg}`,
|
|
32
|
-
returnDisplay: `Error: ${errorMsg}`,
|
|
33
|
-
error: {
|
|
34
|
-
message: errorMsg,
|
|
35
|
-
type: types_1.ToolErrorType.EXECUTION_FAILED,
|
|
36
|
-
},
|
|
37
|
-
};
|
|
38
|
-
}
|
|
39
|
-
let output = `Created task: ${this.params.title}`;
|
|
40
|
-
const resp = response;
|
|
41
|
-
if (resp.task) {
|
|
42
|
-
output += `\n\nTask ID: ${resp.task.id || resp.taskId}`;
|
|
43
|
-
}
|
|
44
|
-
else if (resp.taskId) {
|
|
45
|
-
output += `\n\nTask ID: ${resp.taskId}`;
|
|
46
|
-
}
|
|
47
|
-
return {
|
|
48
|
-
llmContent: output,
|
|
49
|
-
returnDisplay: `Created task: ${this.params.title}`,
|
|
50
|
-
};
|
|
51
|
-
}
|
|
52
|
-
catch (error) {
|
|
53
|
-
const errorMessage = error instanceof Error ? error.message : 'Unknown error occurred';
|
|
54
|
-
return {
|
|
55
|
-
llmContent: `Error creating task: ${errorMessage}`,
|
|
56
|
-
returnDisplay: `Error: ${errorMessage}`,
|
|
57
|
-
error: {
|
|
58
|
-
message: errorMessage,
|
|
59
|
-
type: types_1.ToolErrorType.EXECUTION_FAILED,
|
|
60
|
-
},
|
|
61
|
-
};
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
class TaskCreateTool extends base_tool_1.BaseDeclarativeTool {
|
|
66
|
-
constructor() {
|
|
67
|
-
super(TaskCreateTool.Name, 'TaskCreate', 'Creates a new task.', types_1.Kind.Other, {
|
|
68
|
-
properties: {
|
|
69
|
-
title: {
|
|
70
|
-
description: 'The title/name of the task.',
|
|
71
|
-
type: 'string',
|
|
72
|
-
},
|
|
73
|
-
description: {
|
|
74
|
-
description: 'The description of the task.',
|
|
75
|
-
type: 'string',
|
|
76
|
-
},
|
|
77
|
-
thread_id: {
|
|
78
|
-
description: 'The thread ID for the task.',
|
|
79
|
-
type: 'string',
|
|
80
|
-
},
|
|
81
|
-
},
|
|
82
|
-
required: ['title'],
|
|
83
|
-
type: 'object',
|
|
84
|
-
});
|
|
85
|
-
}
|
|
86
|
-
validateToolParamValues(params) {
|
|
87
|
-
if (!params.title || params.title.trim() === '') {
|
|
88
|
-
return "'title' is required for task create";
|
|
89
|
-
}
|
|
90
|
-
return null;
|
|
91
|
-
}
|
|
92
|
-
createInvocation(params) {
|
|
93
|
-
return new TaskCreateInvocation(params);
|
|
94
|
-
}
|
|
95
|
-
}
|
|
96
|
-
exports.TaskCreateTool = TaskCreateTool;
|
|
97
|
-
TaskCreateTool.Name = 'task_create';
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Task Delete Tool - Deletes a task
|
|
3
|
-
* Wraps the SDK's taskService.deleteTask() method
|
|
4
|
-
*/
|
|
5
|
-
import type { ToolInvocation, ToolResult } from '../types';
|
|
6
|
-
import { BaseDeclarativeTool } from '../base-tool';
|
|
7
|
-
export interface TaskDeleteParams {
|
|
8
|
-
/** The task ID to delete */
|
|
9
|
-
task_id: string;
|
|
10
|
-
}
|
|
11
|
-
export declare class TaskDeleteTool extends BaseDeclarativeTool<TaskDeleteParams, ToolResult> {
|
|
12
|
-
static readonly Name: string;
|
|
13
|
-
constructor();
|
|
14
|
-
protected validateToolParamValues(params: TaskDeleteParams): string | null;
|
|
15
|
-
protected createInvocation(params: TaskDeleteParams): ToolInvocation<TaskDeleteParams, ToolResult>;
|
|
16
|
-
}
|
|
@@ -1,77 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* Task Delete Tool - Deletes a task
|
|
4
|
-
* Wraps the SDK's taskService.deleteTask() method
|
|
5
|
-
*/
|
|
6
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
7
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
8
|
-
};
|
|
9
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.TaskDeleteTool = void 0;
|
|
11
|
-
const types_1 = require("../types");
|
|
12
|
-
const base_tool_1 = require("../base-tool");
|
|
13
|
-
const task_1 = __importDefault(require("../../modules/task"));
|
|
14
|
-
class TaskDeleteInvocation extends base_tool_1.BaseToolInvocation {
|
|
15
|
-
constructor(params) {
|
|
16
|
-
super(params);
|
|
17
|
-
}
|
|
18
|
-
async execute() {
|
|
19
|
-
var _a;
|
|
20
|
-
try {
|
|
21
|
-
const response = await task_1.default.deleteTask(this.params.task_id);
|
|
22
|
-
if (response && !response.success && response.success !== undefined) {
|
|
23
|
-
const errorMsg = typeof response.error === 'string'
|
|
24
|
-
? response.error
|
|
25
|
-
: ((_a = response.error) === null || _a === void 0 ? void 0 : _a.message) || 'Task deletion failed';
|
|
26
|
-
return {
|
|
27
|
-
llmContent: `Task deletion failed: ${errorMsg}`,
|
|
28
|
-
returnDisplay: `Error: ${errorMsg}`,
|
|
29
|
-
error: {
|
|
30
|
-
message: errorMsg,
|
|
31
|
-
type: types_1.ToolErrorType.TASK_NOT_FOUND,
|
|
32
|
-
},
|
|
33
|
-
};
|
|
34
|
-
}
|
|
35
|
-
return {
|
|
36
|
-
llmContent: `Deleted task: ${this.params.task_id}`,
|
|
37
|
-
returnDisplay: `Deleted task: ${this.params.task_id}`,
|
|
38
|
-
};
|
|
39
|
-
}
|
|
40
|
-
catch (error) {
|
|
41
|
-
const errorMessage = error instanceof Error ? error.message : 'Unknown error occurred';
|
|
42
|
-
return {
|
|
43
|
-
llmContent: `Error deleting task: ${errorMessage}`,
|
|
44
|
-
returnDisplay: `Error: ${errorMessage}`,
|
|
45
|
-
error: {
|
|
46
|
-
message: errorMessage,
|
|
47
|
-
type: types_1.ToolErrorType.EXECUTION_FAILED,
|
|
48
|
-
},
|
|
49
|
-
};
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
class TaskDeleteTool extends base_tool_1.BaseDeclarativeTool {
|
|
54
|
-
constructor() {
|
|
55
|
-
super(TaskDeleteTool.Name, 'TaskDelete', 'Deletes a task.', types_1.Kind.Delete, {
|
|
56
|
-
properties: {
|
|
57
|
-
task_id: {
|
|
58
|
-
description: 'The ID of the task to delete.',
|
|
59
|
-
type: 'string',
|
|
60
|
-
},
|
|
61
|
-
},
|
|
62
|
-
required: ['task_id'],
|
|
63
|
-
type: 'object',
|
|
64
|
-
});
|
|
65
|
-
}
|
|
66
|
-
validateToolParamValues(params) {
|
|
67
|
-
if (!params.task_id || params.task_id.trim() === '') {
|
|
68
|
-
return "'task_id' is required for task delete";
|
|
69
|
-
}
|
|
70
|
-
return null;
|
|
71
|
-
}
|
|
72
|
-
createInvocation(params) {
|
|
73
|
-
return new TaskDeleteInvocation(params);
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
exports.TaskDeleteTool = TaskDeleteTool;
|
|
77
|
-
TaskDeleteTool.Name = 'task_delete';
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Task Execute Tool - Executes a task with an agent
|
|
3
|
-
* Wraps the SDK's taskService.executeTaskWithAgent() method
|
|
4
|
-
*/
|
|
5
|
-
import type { ToolInvocation, ToolResult } from '../types';
|
|
6
|
-
import { BaseDeclarativeTool } from '../base-tool';
|
|
7
|
-
export interface TaskExecuteParams {
|
|
8
|
-
/** The task ID to execute */
|
|
9
|
-
task_id: string;
|
|
10
|
-
/** The agent ID to execute the task with */
|
|
11
|
-
agent_id: string;
|
|
12
|
-
}
|
|
13
|
-
export declare class TaskExecuteTool extends BaseDeclarativeTool<TaskExecuteParams, ToolResult> {
|
|
14
|
-
static readonly Name: string;
|
|
15
|
-
constructor();
|
|
16
|
-
protected validateToolParamValues(params: TaskExecuteParams): string | null;
|
|
17
|
-
protected createInvocation(params: TaskExecuteParams): ToolInvocation<TaskExecuteParams, ToolResult>;
|
|
18
|
-
}
|
|
@@ -1,84 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* Task Execute Tool - Executes a task with an agent
|
|
4
|
-
* Wraps the SDK's taskService.executeTaskWithAgent() method
|
|
5
|
-
*/
|
|
6
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
7
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
8
|
-
};
|
|
9
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.TaskExecuteTool = void 0;
|
|
11
|
-
const types_1 = require("../types");
|
|
12
|
-
const base_tool_1 = require("../base-tool");
|
|
13
|
-
const task_1 = __importDefault(require("../../modules/task"));
|
|
14
|
-
class TaskExecuteInvocation extends base_tool_1.BaseToolInvocation {
|
|
15
|
-
constructor(params) {
|
|
16
|
-
super(params);
|
|
17
|
-
}
|
|
18
|
-
async execute() {
|
|
19
|
-
var _a;
|
|
20
|
-
try {
|
|
21
|
-
const response = await task_1.default.executeTaskWithAgent(this.params.task_id, this.params.agent_id);
|
|
22
|
-
if (response && !response.success && response.success !== undefined) {
|
|
23
|
-
const errorMsg = typeof response.error === 'string'
|
|
24
|
-
? response.error
|
|
25
|
-
: ((_a = response.error) === null || _a === void 0 ? void 0 : _a.message) || 'Task execution failed';
|
|
26
|
-
return {
|
|
27
|
-
llmContent: `Task execution failed: ${errorMsg}`,
|
|
28
|
-
returnDisplay: `Error: ${errorMsg}`,
|
|
29
|
-
error: {
|
|
30
|
-
message: errorMsg,
|
|
31
|
-
type: types_1.ToolErrorType.TASK_NOT_FOUND,
|
|
32
|
-
},
|
|
33
|
-
};
|
|
34
|
-
}
|
|
35
|
-
return {
|
|
36
|
-
llmContent: `Executing task ${this.params.task_id} with agent ${this.params.agent_id}`,
|
|
37
|
-
returnDisplay: `Executing task ${this.params.task_id} with agent ${this.params.agent_id}`,
|
|
38
|
-
};
|
|
39
|
-
}
|
|
40
|
-
catch (error) {
|
|
41
|
-
const errorMessage = error instanceof Error ? error.message : 'Unknown error occurred';
|
|
42
|
-
return {
|
|
43
|
-
llmContent: `Error executing task: ${errorMessage}`,
|
|
44
|
-
returnDisplay: `Error: ${errorMessage}`,
|
|
45
|
-
error: {
|
|
46
|
-
message: errorMessage,
|
|
47
|
-
type: types_1.ToolErrorType.EXECUTION_FAILED,
|
|
48
|
-
},
|
|
49
|
-
};
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
class TaskExecuteTool extends base_tool_1.BaseDeclarativeTool {
|
|
54
|
-
constructor() {
|
|
55
|
-
super(TaskExecuteTool.Name, 'TaskExecute', 'Executes a task with a specific agent.', types_1.Kind.Execute, {
|
|
56
|
-
properties: {
|
|
57
|
-
task_id: {
|
|
58
|
-
description: 'The ID of the task to execute.',
|
|
59
|
-
type: 'string',
|
|
60
|
-
},
|
|
61
|
-
agent_id: {
|
|
62
|
-
description: 'The ID of the agent to execute the task with.',
|
|
63
|
-
type: 'string',
|
|
64
|
-
},
|
|
65
|
-
},
|
|
66
|
-
required: ['task_id', 'agent_id'],
|
|
67
|
-
type: 'object',
|
|
68
|
-
});
|
|
69
|
-
}
|
|
70
|
-
validateToolParamValues(params) {
|
|
71
|
-
if (!params.task_id || params.task_id.trim() === '') {
|
|
72
|
-
return "'task_id' is required for task execute";
|
|
73
|
-
}
|
|
74
|
-
if (!params.agent_id || params.agent_id.trim() === '') {
|
|
75
|
-
return "'agent_id' is required for task execute";
|
|
76
|
-
}
|
|
77
|
-
return null;
|
|
78
|
-
}
|
|
79
|
-
createInvocation(params) {
|
|
80
|
-
return new TaskExecuteInvocation(params);
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
exports.TaskExecuteTool = TaskExecuteTool;
|
|
84
|
-
TaskExecuteTool.Name = 'task_execute';
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Task Get Tool - Gets details of a specific task
|
|
3
|
-
* Wraps the SDK's taskService.getTaskDetail() method
|
|
4
|
-
*/
|
|
5
|
-
import type { ToolInvocation, ToolResult } from '../types';
|
|
6
|
-
import { BaseDeclarativeTool } from '../base-tool';
|
|
7
|
-
export interface TaskGetParams {
|
|
8
|
-
/** The task ID to get details for */
|
|
9
|
-
task_id: string;
|
|
10
|
-
}
|
|
11
|
-
export declare class TaskGetTool extends BaseDeclarativeTool<TaskGetParams, ToolResult> {
|
|
12
|
-
static readonly Name: string;
|
|
13
|
-
constructor();
|
|
14
|
-
protected validateToolParamValues(params: TaskGetParams): string | null;
|
|
15
|
-
protected createInvocation(params: TaskGetParams): ToolInvocation<TaskGetParams, ToolResult>;
|
|
16
|
-
}
|