@ai-setting/roy-agent-core 1.7.66 → 1.7.68
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/env/agent/agent-component.d.ts +29 -0
- package/dist/env/agent/agent-component.js +1 -1
- package/dist/env/agent/index.js +1 -1
- package/dist/env/agent/types.d.ts +16 -0
- package/dist/env/environment.d.ts +13 -0
- package/dist/env/event-source/event-source-handlers.js +6 -5
- package/dist/env/event-source/index.js +7 -6
- package/dist/env/event-source/timer-handler.d.ts +93 -1
- package/dist/env/index.js +12 -11
- package/dist/env/prompt/index.js +3 -2
- package/dist/env/prompt/prompts-index.d.ts +2 -7
- package/dist/env/task/delegate/delegate-tool.d.ts +21 -1
- package/dist/env/task/delegate/delegate-tool.js +3 -2
- package/dist/env/task/delegate/index.js +3 -2
- package/dist/env/task/index.js +5 -4
- package/dist/env/task/mcp/index.js +2 -1
- package/dist/env/task/plugins/__e2e__/laya-completion-e2e.d.ts +16 -0
- package/dist/env/task/plugins/index.js +4 -3
- package/dist/env/task/plugins/lark-card-patch-notifier.d.ts +77 -0
- package/dist/env/task/plugins/lark-card-patch-notifier.js +7 -1
- package/dist/env/task/plugins/laya-completion-plugin.d.ts +133 -0
- package/dist/env/task/plugins/laya-port.d.ts +23 -0
- package/dist/env/task/task-component.d.ts +43 -0
- package/dist/env/task/tools/completion-copy.d.ts +27 -0
- package/dist/env/task/tools/index.js +2 -1
- package/dist/env/workflow/plugins/index.js +2 -2
- package/dist/index.js +13 -12
- package/dist/shared/@ai-setting/{roy-agent-core-8nksrtnf.js → roy-agent-core-19na22cc.js} +203 -18
- package/dist/shared/@ai-setting/{roy-agent-core-nr2m4xw1.js → roy-agent-core-1k83dq3a.js} +13 -3
- package/dist/shared/@ai-setting/roy-agent-core-43r4bxey.js +1083 -0
- package/dist/shared/@ai-setting/roy-agent-core-6m4bw8jy.js +6 -0
- package/dist/shared/@ai-setting/{roy-agent-core-0ys85x46.js → roy-agent-core-8bjj3d1b.js} +1 -1
- package/dist/shared/@ai-setting/{roy-agent-core-2wxbx36p.js → roy-agent-core-dnjm17sa.js} +21 -2
- package/dist/shared/@ai-setting/{roy-agent-core-t0ktaevq.js → roy-agent-core-h5vmff8w.js} +60 -4
- package/dist/shared/@ai-setting/{roy-agent-core-j1kksatb.js → roy-agent-core-hfr6bzts.js} +67 -10
- package/dist/shared/@ai-setting/{roy-agent-core-v8bz7d8x.js → roy-agent-core-keyb45z3.js} +26 -11
- package/dist/shared/@ai-setting/{roy-agent-core-vs5gxgwh.js → roy-agent-core-ma35jyd9.js} +14 -3
- package/dist/shared/@ai-setting/{roy-agent-core-zk2jg0v7.js → roy-agent-core-tadj19vp.js} +106 -22
- package/dist/shared/@ai-setting/{roy-agent-core-cvm1xgmg.js → roy-agent-core-wksgtqf9.js} +1 -1
- package/dist/shared/@ai-setting/{roy-agent-core-4882qsjx.js → roy-agent-core-x0ddc2cr.js} +1 -1
- package/package.json +1 -1
- package/dist/shared/@ai-setting/roy-agent-core-8mjnb7xc.js +0 -654
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
import {
|
|
8
8
|
BackgroundTaskManager,
|
|
9
9
|
createDelegateTool
|
|
10
|
-
} from "./roy-agent-core-
|
|
10
|
+
} from "./roy-agent-core-dnjm17sa.js";
|
|
11
11
|
import {
|
|
12
12
|
TaskEntityEventTypes
|
|
13
13
|
} from "./roy-agent-core-8gxth0eh.js";
|
|
@@ -22,7 +22,7 @@ import {
|
|
|
22
22
|
searchTasksTool,
|
|
23
23
|
treeTasksTool,
|
|
24
24
|
updateTaskTool
|
|
25
|
-
} from "./roy-agent-core-
|
|
25
|
+
} from "./roy-agent-core-h5vmff8w.js";
|
|
26
26
|
import {
|
|
27
27
|
createOperationTool,
|
|
28
28
|
deleteOperationTool,
|
|
@@ -198,6 +198,8 @@ class TaskComponent extends BaseComponent {
|
|
|
198
198
|
config;
|
|
199
199
|
toolComponent;
|
|
200
200
|
backgroundTaskManager;
|
|
201
|
+
skipAbortRunningTasksOnDispose = false;
|
|
202
|
+
waitForRunningTasksOnDispose = false;
|
|
201
203
|
configComponent;
|
|
202
204
|
tagService;
|
|
203
205
|
plugins = new Map;
|
|
@@ -227,6 +229,8 @@ class TaskComponent extends BaseComponent {
|
|
|
227
229
|
throw new Error("ConfigComponent is required for TaskComponent initialization");
|
|
228
230
|
}
|
|
229
231
|
this.configComponent = options.configComponent;
|
|
232
|
+
this.skipAbortRunningTasksOnDispose = options.skipAbortRunningTasksOnDispose === true;
|
|
233
|
+
this.waitForRunningTasksOnDispose = options.waitForRunningTasksOnDispose === true;
|
|
230
234
|
await this.registerConfig(options);
|
|
231
235
|
this.setStatus("running");
|
|
232
236
|
logger2.info("[TaskComponent] Initialized");
|
|
@@ -350,7 +354,10 @@ class TaskComponent extends BaseComponent {
|
|
|
350
354
|
}
|
|
351
355
|
}
|
|
352
356
|
if (this.backgroundTaskManager) {
|
|
353
|
-
this.backgroundTaskManager.dispose(
|
|
357
|
+
await this.backgroundTaskManager.dispose(this.skipAbortRunningTasksOnDispose ? {
|
|
358
|
+
skipAbortRunningTasks: true,
|
|
359
|
+
waitForRunningTasks: this.waitForRunningTasksOnDispose
|
|
360
|
+
} : undefined);
|
|
354
361
|
this.backgroundTaskManager = undefined;
|
|
355
362
|
}
|
|
356
363
|
if (this.store) {
|
|
@@ -539,6 +546,9 @@ class TaskComponent extends BaseComponent {
|
|
|
539
546
|
}
|
|
540
547
|
return task;
|
|
541
548
|
}
|
|
549
|
+
async updateTaskContext(id, context) {
|
|
550
|
+
return this.store.updateTask(id, { context });
|
|
551
|
+
}
|
|
542
552
|
async createOperation(options) {
|
|
543
553
|
const createCtx = {
|
|
544
554
|
options: { ...options }
|