@ai-setting/roy-agent-core 1.5.37 → 1.5.41
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/config/index.js +4 -3
- package/dist/env/agent/index.js +10 -9
- package/dist/env/commands/index.js +7 -6
- package/dist/env/context/index.js +21 -0
- package/dist/env/debug/index.js +4 -3
- package/dist/env/event-source/index.js +12 -6
- package/dist/env/hook/index.js +2 -1
- package/dist/env/index.js +41 -18
- package/dist/env/llm/index.js +8 -7
- package/dist/env/log-trace/index.js +10 -9
- package/dist/env/mcp/index.js +8 -7
- package/dist/env/mcp/tool/index.js +4 -4
- package/dist/env/memory/index.js +12 -11
- package/dist/env/memory/plugin/index.js +4 -4
- package/dist/env/plugin/index.js +18 -0
- package/dist/env/prompt/index.js +7 -6
- package/dist/env/session/index.js +11 -10
- package/dist/env/session/storage/index.js +2 -6
- package/dist/env/skill/index.js +7 -6
- package/dist/env/task/delegate/index.js +6 -5
- package/dist/env/task/index.js +10 -8
- package/dist/env/task/plugins/index.js +13 -6
- package/dist/env/task/storage/index.js +4 -4
- package/dist/env/tool/built-in/index.js +3 -3
- package/dist/env/tool/index.js +8 -7
- package/dist/env/workflow/engine/index.js +5 -5
- package/dist/env/workflow/index.js +9 -8
- package/dist/env/workflow/storage/index.js +5 -5
- package/dist/env/workflow/tools/index.js +3 -3
- package/dist/env/workflow/utils/index.js +4 -4
- package/dist/index.js +67 -60
- package/dist/shared/@ai-setting/{roy-agent-core-44hnfb02.js → roy-agent-core-10n2jh7p.js} +1 -1
- package/dist/shared/@ai-setting/{roy-agent-core-xt3fx7m1.js → roy-agent-core-15x8fe5h.js} +38 -56
- package/dist/shared/@ai-setting/{roy-agent-core-1akcqxj9.js → roy-agent-core-1bfmxx89.js} +1 -1
- package/dist/shared/@ai-setting/{roy-agent-core-ty94k28r.js → roy-agent-core-2jnzv9at.js} +2 -2
- package/dist/shared/@ai-setting/{roy-agent-core-cefh9hjv.js → roy-agent-core-4jqq077c.js} +1 -1
- package/dist/shared/@ai-setting/{roy-agent-core-xs5rsgat.js → roy-agent-core-58k274fg.js} +108 -23
- package/dist/shared/@ai-setting/{roy-agent-core-jfh9q2qh.js → roy-agent-core-7b35emr7.js} +0 -15
- package/dist/shared/@ai-setting/{roy-agent-core-3rr5k71j.js → roy-agent-core-8n4bz6y3.js} +1 -1
- package/dist/shared/@ai-setting/{roy-agent-core-zpn0bqa8.js → roy-agent-core-9ffsvvcf.js} +1 -1
- package/dist/shared/@ai-setting/roy-agent-core-az13yzmc.js +11 -0
- package/dist/shared/@ai-setting/{roy-agent-core-0wdjp769.js → roy-agent-core-b4wd9tn6.js} +2 -2
- package/dist/shared/@ai-setting/{roy-agent-core-6kvtahqv.js → roy-agent-core-c3ct1346.js} +1 -1
- package/dist/shared/@ai-setting/{roy-agent-core-psv4v63c.js → roy-agent-core-c6592r3c.js} +19 -2
- package/dist/shared/@ai-setting/{roy-agent-core-c2wjwx16.js → roy-agent-core-c8f2hync.js} +305 -287
- package/dist/shared/@ai-setting/roy-agent-core-cevpwnq7.js +147 -0
- package/dist/shared/@ai-setting/{roy-agent-core-hkb529dw.js → roy-agent-core-dxbsc1zy.js} +7 -7
- package/dist/shared/@ai-setting/{roy-agent-core-vqspcspb.js → roy-agent-core-e130w7mv.js} +3 -3
- package/dist/shared/@ai-setting/{roy-agent-core-3jywqmdd.js → roy-agent-core-e9fdm13a.js} +319 -65
- package/dist/shared/@ai-setting/{roy-agent-core-j0ke54vy.js → roy-agent-core-ee6nnnqw.js} +5 -5
- package/dist/shared/@ai-setting/{roy-agent-core-qdmt6nz7.js → roy-agent-core-eg6nv09z.js} +2 -2
- package/dist/shared/@ai-setting/{roy-agent-core-hd1z20yq.js → roy-agent-core-frx4p6d1.js} +1 -1
- package/dist/shared/@ai-setting/{roy-agent-core-bvr1761x.js → roy-agent-core-hsxn8m1j.js} +1 -1
- package/dist/shared/@ai-setting/{roy-agent-core-86gphny5.js → roy-agent-core-jqy2mdyq.js} +15 -1
- package/dist/shared/@ai-setting/{roy-agent-core-c0d3dtjd.js → roy-agent-core-kajktp3d.js} +7 -7
- package/dist/shared/@ai-setting/{roy-agent-core-eajcvp4e.js → roy-agent-core-kwhv9dcd.js} +2 -2
- package/dist/shared/@ai-setting/{roy-agent-core-r9ezzemr.js → roy-agent-core-m0wp34r4.js} +1 -1
- package/dist/shared/@ai-setting/{roy-agent-core-fg1kxf70.js → roy-agent-core-nqgrjja0.js} +5 -5
- package/dist/shared/@ai-setting/{roy-agent-core-mx489p7f.js → roy-agent-core-psvwzdhj.js} +263 -33
- package/dist/shared/@ai-setting/{roy-agent-core-d7cyjkf7.js → roy-agent-core-pwkk12p4.js} +1 -1
- package/dist/shared/@ai-setting/{roy-agent-core-97ma0pr5.js → roy-agent-core-pxcrzyv9.js} +2 -2
- package/dist/shared/@ai-setting/{roy-agent-core-zgypchmt.js → roy-agent-core-q5qj0fes.js} +19 -11
- package/dist/shared/@ai-setting/{roy-agent-core-sx7wsvnn.js → roy-agent-core-qakqwbbh.js} +2 -2
- package/dist/shared/@ai-setting/{roy-agent-core-qfdp3pvq.js → roy-agent-core-rsybkb38.js} +1 -1
- package/dist/shared/@ai-setting/roy-agent-core-ty33mnr7.js +14 -0
- package/dist/shared/@ai-setting/{roy-agent-core-3prpabp8.js → roy-agent-core-v53rfk99.js} +2 -2
- package/dist/shared/@ai-setting/{roy-agent-core-wjd5kars.js → roy-agent-core-wb43x8hd.js} +3 -3
- package/dist/shared/@ai-setting/{roy-agent-core-e2vk2qh7.js → roy-agent-core-yc543gnq.js} +6 -6
- package/dist/shared/@ai-setting/{roy-agent-core-gf2c2pxr.js → roy-agent-core-ycg9rk6z.js} +3 -3
- package/dist/shared/@ai-setting/roy-agent-core-z33en0cz.js +44 -0
- package/dist/shared/@ai-setting/{roy-agent-core-by55z88t.js → roy-agent-core-zrja5v78.js} +11 -11
- package/dist/shared/@ai-setting/{roy-agent-core-wft9ra24.js → roy-agent-core-zwp3jp02.js} +4 -4
- package/package.json +1 -1
- package/dist/shared/@ai-setting/roy-agent-core-bcbqy27c.js +0 -14
|
@@ -3,11 +3,11 @@ import {
|
|
|
3
3
|
} from "./roy-agent-core-92z6t4he.js";
|
|
4
4
|
import {
|
|
5
5
|
globalHookManager
|
|
6
|
-
} from "./roy-agent-core-
|
|
6
|
+
} from "./roy-agent-core-jqy2mdyq.js";
|
|
7
7
|
import {
|
|
8
8
|
createLogger,
|
|
9
9
|
init_logger
|
|
10
|
-
} from "./roy-agent-core-
|
|
10
|
+
} from "./roy-agent-core-10n2jh7p.js";
|
|
11
11
|
|
|
12
12
|
// src/env/task/delegate/delegate-tool.ts
|
|
13
13
|
init_logger();
|
|
@@ -4,17 +4,17 @@ import {
|
|
|
4
4
|
} from "./roy-agent-core-qxhq8ven.js";
|
|
5
5
|
import {
|
|
6
6
|
BaseComponent
|
|
7
|
-
} from "./roy-agent-core-
|
|
7
|
+
} from "./roy-agent-core-4jqq077c.js";
|
|
8
8
|
import {
|
|
9
9
|
createHook
|
|
10
10
|
} from "./roy-agent-core-2dhd60aw.js";
|
|
11
11
|
import {
|
|
12
12
|
globalHookManager
|
|
13
|
-
} from "./roy-agent-core-
|
|
13
|
+
} from "./roy-agent-core-jqy2mdyq.js";
|
|
14
14
|
import {
|
|
15
15
|
createLogger,
|
|
16
16
|
init_logger
|
|
17
|
-
} from "./roy-agent-core-
|
|
17
|
+
} from "./roy-agent-core-10n2jh7p.js";
|
|
18
18
|
|
|
19
19
|
// src/env/prompt/types.ts
|
|
20
20
|
import { z } from "zod";
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
WorkflowEngine,
|
|
7
7
|
exports_engine,
|
|
8
8
|
init_engine
|
|
9
|
-
} from "./roy-agent-core-
|
|
9
|
+
} from "./roy-agent-core-2jnzv9at.js";
|
|
10
10
|
import {
|
|
11
11
|
WorkflowService
|
|
12
12
|
} from "./roy-agent-core-4t40mkpv.js";
|
|
@@ -15,11 +15,11 @@ import {
|
|
|
15
15
|
} from "./roy-agent-core-0vbdz0x7.js";
|
|
16
16
|
import {
|
|
17
17
|
BaseComponent
|
|
18
|
-
} from "./roy-agent-core-
|
|
18
|
+
} from "./roy-agent-core-4jqq077c.js";
|
|
19
19
|
import {
|
|
20
20
|
createLogger,
|
|
21
21
|
init_logger
|
|
22
|
-
} from "./roy-agent-core-
|
|
22
|
+
} from "./roy-agent-core-10n2jh7p.js";
|
|
23
23
|
import {
|
|
24
24
|
__require,
|
|
25
25
|
__toCommonJS
|
|
@@ -156,7 +156,7 @@ class WorkflowComponent extends BaseComponent {
|
|
|
156
156
|
if (this.workflowService) {
|
|
157
157
|
this.workflowService = null;
|
|
158
158
|
try {
|
|
159
|
-
const { closeDatabase } = await import("./roy-agent-core-
|
|
159
|
+
const { closeDatabase } = await import("./roy-agent-core-zwp3jp02.js");
|
|
160
160
|
closeDatabase();
|
|
161
161
|
componentLogger.info("[WorkflowComponent] SQLite database closed");
|
|
162
162
|
} catch (error) {
|
|
@@ -193,8 +193,8 @@ class WorkflowComponent extends BaseComponent {
|
|
|
193
193
|
}
|
|
194
194
|
async initSqliteService() {
|
|
195
195
|
try {
|
|
196
|
-
const { getDatabase, initializeTables } = await import("./roy-agent-core-
|
|
197
|
-
const { WorkflowRepository } = await import("./roy-agent-core-
|
|
196
|
+
const { getDatabase, initializeTables } = await import("./roy-agent-core-zwp3jp02.js");
|
|
197
|
+
const { WorkflowRepository } = await import("./roy-agent-core-ty33mnr7.js");
|
|
198
198
|
const db = getDatabase();
|
|
199
199
|
initializeTables();
|
|
200
200
|
const workflowRepository = new WorkflowRepository(db);
|
|
@@ -4,17 +4,17 @@ import {
|
|
|
4
4
|
} from "./roy-agent-core-ctdhjv68.js";
|
|
5
5
|
import {
|
|
6
6
|
adaptMcpTool
|
|
7
|
-
} from "./roy-agent-core-
|
|
7
|
+
} from "./roy-agent-core-1bfmxx89.js";
|
|
8
8
|
import {
|
|
9
9
|
toEnvKey
|
|
10
10
|
} from "./roy-agent-core-qxhq8ven.js";
|
|
11
11
|
import {
|
|
12
12
|
BaseComponent
|
|
13
|
-
} from "./roy-agent-core-
|
|
13
|
+
} from "./roy-agent-core-4jqq077c.js";
|
|
14
14
|
import {
|
|
15
15
|
createLogger,
|
|
16
16
|
init_logger
|
|
17
|
-
} from "./roy-agent-core-
|
|
17
|
+
} from "./roy-agent-core-10n2jh7p.js";
|
|
18
18
|
|
|
19
19
|
// src/env/mcp/types.ts
|
|
20
20
|
import { z } from "zod";
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
// src/env/context/env-context.ts
|
|
2
|
+
import { AsyncLocalStorage } from "async_hooks";
|
|
3
|
+
var envContextStorage = new AsyncLocalStorage;
|
|
4
|
+
function getEnvContext() {
|
|
5
|
+
return envContextStorage.getStore();
|
|
6
|
+
}
|
|
7
|
+
function getEnvContextOrEmpty() {
|
|
8
|
+
return envContextStorage.getStore() || {};
|
|
9
|
+
}
|
|
10
|
+
function hasEnvContext() {
|
|
11
|
+
return envContextStorage.getStore() !== undefined;
|
|
12
|
+
}
|
|
13
|
+
function runWithEnvContext(context, fn) {
|
|
14
|
+
if (context) {
|
|
15
|
+
return envContextStorage.run(context, fn);
|
|
16
|
+
}
|
|
17
|
+
return fn();
|
|
18
|
+
}
|
|
19
|
+
async function runWithEnvContextAsync(context, fn) {
|
|
20
|
+
if (context) {
|
|
21
|
+
return envContextStorage.run(context, fn);
|
|
22
|
+
}
|
|
23
|
+
return fn();
|
|
24
|
+
}
|
|
25
|
+
function createEnvContext(options) {
|
|
26
|
+
return {
|
|
27
|
+
envEvent: options.envEvent,
|
|
28
|
+
sourceId: options.sourceId,
|
|
29
|
+
userId: options.userId,
|
|
30
|
+
traceId: options.traceId ?? crypto.randomUUID(),
|
|
31
|
+
requestId: options.requestId ?? crypto.randomUUID(),
|
|
32
|
+
replyChannel: options.replyChannel,
|
|
33
|
+
pluginEnabled: options.pluginEnabled,
|
|
34
|
+
plugins: options.plugins,
|
|
35
|
+
timestamp: options.timestamp ?? Date.now()
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
function mergeEnvContext(partial) {
|
|
39
|
+
const current = envContextStorage.getStore();
|
|
40
|
+
if (current) {
|
|
41
|
+
Object.assign(current, partial);
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
export { envContextStorage, getEnvContext, getEnvContextOrEmpty, hasEnvContext, runWithEnvContext, runWithEnvContextAsync, createEnvContext, mergeEnvContext };
|
|
@@ -5,25 +5,25 @@ import {
|
|
|
5
5
|
} from "./roy-agent-core-rvxg1wps.js";
|
|
6
6
|
import {
|
|
7
7
|
SummaryAgent
|
|
8
|
-
} from "./roy-agent-core-
|
|
8
|
+
} from "./roy-agent-core-kwhv9dcd.js";
|
|
9
|
+
import {
|
|
10
|
+
TracedAs,
|
|
11
|
+
init_decorator
|
|
12
|
+
} from "./roy-agent-core-q5qj0fes.js";
|
|
9
13
|
import {
|
|
10
14
|
envKeyToConfigKey
|
|
11
15
|
} from "./roy-agent-core-qxhq8ven.js";
|
|
12
16
|
import {
|
|
13
17
|
BaseComponent
|
|
14
|
-
} from "./roy-agent-core-
|
|
15
|
-
import {
|
|
16
|
-
MemorySessionStore,
|
|
17
|
-
SQLiteSessionStore
|
|
18
|
-
} from "./roy-agent-core-d7cyjkf7.js";
|
|
19
|
-
import {
|
|
20
|
-
TracedAs,
|
|
21
|
-
init_decorator
|
|
22
|
-
} from "./roy-agent-core-zgypchmt.js";
|
|
18
|
+
} from "./roy-agent-core-4jqq077c.js";
|
|
23
19
|
import {
|
|
24
20
|
createLogger,
|
|
25
21
|
init_logger
|
|
26
|
-
} from "./roy-agent-core-
|
|
22
|
+
} from "./roy-agent-core-10n2jh7p.js";
|
|
23
|
+
import {
|
|
24
|
+
MemorySessionStore,
|
|
25
|
+
SQLiteSessionStore
|
|
26
|
+
} from "./roy-agent-core-pwkk12p4.js";
|
|
27
27
|
import {
|
|
28
28
|
__legacyDecorateClassTS
|
|
29
29
|
} from "./roy-agent-core-fs0mn2jk.js";
|
|
@@ -5,10 +5,10 @@ import {
|
|
|
5
5
|
initDatabase,
|
|
6
6
|
initializeTables,
|
|
7
7
|
resetDatabase
|
|
8
|
-
} from "./roy-agent-core-
|
|
9
|
-
import"./roy-agent-core-
|
|
10
|
-
import"./roy-agent-core-
|
|
11
|
-
import"./roy-agent-core-
|
|
8
|
+
} from "./roy-agent-core-9ffsvvcf.js";
|
|
9
|
+
import"./roy-agent-core-10n2jh7p.js";
|
|
10
|
+
import"./roy-agent-core-58k274fg.js";
|
|
11
|
+
import"./roy-agent-core-c6592r3c.js";
|
|
12
12
|
import"./roy-agent-core-fs0mn2jk.js";
|
|
13
13
|
export {
|
|
14
14
|
resetDatabase,
|
package/package.json
CHANGED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
WorkflowRepository,
|
|
3
|
-
rowToWorkflow
|
|
4
|
-
} from "./roy-agent-core-3rr5k71j.js";
|
|
5
|
-
import"./roy-agent-core-zpn0bqa8.js";
|
|
6
|
-
import"./roy-agent-core-rvxg1wps.js";
|
|
7
|
-
import"./roy-agent-core-44hnfb02.js";
|
|
8
|
-
import"./roy-agent-core-xs5rsgat.js";
|
|
9
|
-
import"./roy-agent-core-psv4v63c.js";
|
|
10
|
-
import"./roy-agent-core-fs0mn2jk.js";
|
|
11
|
-
export {
|
|
12
|
-
rowToWorkflow,
|
|
13
|
-
WorkflowRepository
|
|
14
|
-
};
|