@ai-setting/roy-agent-core 1.6.17 → 1.6.18
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/index.js +1 -1
- package/dist/env/event-source/index.js +3 -3
- package/dist/env/index.js +10 -10
- package/dist/env/prompt/index.js +2 -2
- package/dist/env/task/delegate/index.js +2 -2
- package/dist/env/task/index.js +4 -4
- package/dist/env/task/plugins/index.js +2 -2
- package/dist/env/task/tools/index.js +1 -1
- package/dist/env/workflow/index.js +2 -2
- package/dist/env/workflow/tools/index.js +1 -1
- package/dist/index.js +11 -11
- package/dist/shared/@ai-setting/{roy-agent-core-pq1q854s.js → roy-agent-core-65vpkh7x.js} +8 -0
- package/dist/shared/@ai-setting/{roy-agent-core-bsxgrqzq.js → roy-agent-core-6mz26khm.js} +1 -1
- package/dist/shared/@ai-setting/{roy-agent-core-r0t34bbh.js → roy-agent-core-c7e3htaq.js} +146 -8
- package/dist/shared/@ai-setting/{roy-agent-core-x36fsm47.js → roy-agent-core-f6x6ksz3.js} +1 -1
- package/dist/shared/@ai-setting/{roy-agent-core-cfqm5w9b.js → roy-agent-core-h07kk80k.js} +1 -1
- package/dist/shared/@ai-setting/{roy-agent-core-4z7dzcgb.js → roy-agent-core-kkt2ndpf.js} +168 -7
- package/dist/shared/@ai-setting/{roy-agent-core-m134hen4.js → roy-agent-core-mvmgy9t0.js} +2 -2
- package/dist/shared/@ai-setting/{roy-agent-core-4cgkj7v0.js → roy-agent-core-n1fx2fx4.js} +679 -32
- package/dist/shared/@ai-setting/{roy-agent-core-yqxrekhg.js → roy-agent-core-nreqmmtz.js} +1 -1
- package/dist/shared/@ai-setting/{roy-agent-core-edbhy767.js → roy-agent-core-qyb2z42s.js} +27 -1
- package/dist/shared/@ai-setting/{roy-agent-core-dnns0v64.js → roy-agent-core-vc8e968b.js} +1 -1
- package/package.json +1 -1
package/dist/env/agent/index.js
CHANGED
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
AgentComponent,
|
|
3
3
|
AgentComponentConfigSchema,
|
|
4
4
|
SummaryAgent
|
|
5
|
-
} from "../../shared/@ai-setting/roy-agent-core-
|
|
5
|
+
} from "../../shared/@ai-setting/roy-agent-core-qyb2z42s.js";
|
|
6
6
|
import"../../shared/@ai-setting/roy-agent-core-8n0e62y4.js";
|
|
7
7
|
import"../../shared/@ai-setting/roy-agent-core-eskgj8nc.js";
|
|
8
8
|
import"../../shared/@ai-setting/roy-agent-core-ataagh3a.js";
|
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
larkCliHandler,
|
|
12
12
|
resolveBountyIMSystemPrompt,
|
|
13
13
|
timerHandler
|
|
14
|
-
} from "../../shared/@ai-setting/roy-agent-core-
|
|
14
|
+
} from "../../shared/@ai-setting/roy-agent-core-6mz26khm.js";
|
|
15
15
|
import {
|
|
16
16
|
BUILT_IN_EVENT_SOURCE_TYPES,
|
|
17
17
|
BUILT_IN_EVENT_SOURCE_TYPE_LIST,
|
|
@@ -22,13 +22,13 @@ import {
|
|
|
22
22
|
validateEventSourceConfig
|
|
23
23
|
} from "../../shared/@ai-setting/roy-agent-core-ds5f75pg.js";
|
|
24
24
|
import"../../shared/@ai-setting/roy-agent-core-1qjgwjjs.js";
|
|
25
|
-
import"../../shared/@ai-setting/roy-agent-core-
|
|
25
|
+
import"../../shared/@ai-setting/roy-agent-core-nreqmmtz.js";
|
|
26
26
|
import"../../shared/@ai-setting/roy-agent-core-az13yzmc.js";
|
|
27
27
|
import"../../shared/@ai-setting/roy-agent-core-1mrc9a1r.js";
|
|
28
28
|
import"../../shared/@ai-setting/roy-agent-core-bq1gskrf.js";
|
|
29
29
|
import"../../shared/@ai-setting/roy-agent-core-jrj30vq3.js";
|
|
30
30
|
import"../../shared/@ai-setting/roy-agent-core-e25xkv53.js";
|
|
31
|
-
import"../../shared/@ai-setting/roy-agent-core-
|
|
31
|
+
import"../../shared/@ai-setting/roy-agent-core-65vpkh7x.js";
|
|
32
32
|
import"../../shared/@ai-setting/roy-agent-core-1pg0fepg.js";
|
|
33
33
|
import"../../shared/@ai-setting/roy-agent-core-7hh0brvs.js";
|
|
34
34
|
import"../../shared/@ai-setting/roy-agent-core-akb8mb9v.js";
|
package/dist/env/index.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import {
|
|
2
2
|
BaseEnvironment
|
|
3
|
-
} from "../shared/@ai-setting/roy-agent-core-
|
|
3
|
+
} from "../shared/@ai-setting/roy-agent-core-vc8e968b.js";
|
|
4
4
|
import {
|
|
5
5
|
EventSourceComponent,
|
|
6
6
|
builtInHandlers,
|
|
7
7
|
larkCliHandler
|
|
8
|
-
} from "../shared/@ai-setting/roy-agent-core-
|
|
8
|
+
} from "../shared/@ai-setting/roy-agent-core-6mz26khm.js";
|
|
9
9
|
import {
|
|
10
10
|
EventSourceInitHooks,
|
|
11
11
|
getDefaultConfigForType,
|
|
@@ -17,11 +17,11 @@ import"../shared/@ai-setting/roy-agent-core-1qjgwjjs.js";
|
|
|
17
17
|
import {
|
|
18
18
|
PluginComponent
|
|
19
19
|
} from "../shared/@ai-setting/roy-agent-core-gc75v3px.js";
|
|
20
|
-
import"../shared/@ai-setting/roy-agent-core-
|
|
20
|
+
import"../shared/@ai-setting/roy-agent-core-nreqmmtz.js";
|
|
21
21
|
import"../shared/@ai-setting/roy-agent-core-az13yzmc.js";
|
|
22
22
|
import {
|
|
23
23
|
WorkflowComponent
|
|
24
|
-
} from "../shared/@ai-setting/roy-agent-core-
|
|
24
|
+
} from "../shared/@ai-setting/roy-agent-core-f6x6ksz3.js";
|
|
25
25
|
import"../shared/@ai-setting/roy-agent-core-77wfej1h.js";
|
|
26
26
|
import"../shared/@ai-setting/roy-agent-core-yr3fp8tv.js";
|
|
27
27
|
import"../shared/@ai-setting/roy-agent-core-6atd905e.js";
|
|
@@ -30,7 +30,7 @@ import"../shared/@ai-setting/roy-agent-core-ez91vxas.js";
|
|
|
30
30
|
import"../shared/@ai-setting/roy-agent-core-ddwa0n6h.js";
|
|
31
31
|
import"../shared/@ai-setting/roy-agent-core-hhrg314p.js";
|
|
32
32
|
import"../shared/@ai-setting/roy-agent-core-7kw06e4b.js";
|
|
33
|
-
import"../shared/@ai-setting/roy-agent-core-
|
|
33
|
+
import"../shared/@ai-setting/roy-agent-core-kkt2ndpf.js";
|
|
34
34
|
import"../shared/@ai-setting/roy-agent-core-1db4vpc6.js";
|
|
35
35
|
import"../shared/@ai-setting/roy-agent-core-r15sn7ve.js";
|
|
36
36
|
import"../shared/@ai-setting/roy-agent-core-1mrc9a1r.js";
|
|
@@ -41,20 +41,20 @@ import"../shared/@ai-setting/roy-agent-core-1ce3fqrk.js";
|
|
|
41
41
|
import {
|
|
42
42
|
AgentComponent,
|
|
43
43
|
AgentComponentConfigSchema
|
|
44
|
-
} from "../shared/@ai-setting/roy-agent-core-
|
|
44
|
+
} from "../shared/@ai-setting/roy-agent-core-qyb2z42s.js";
|
|
45
45
|
import"../shared/@ai-setting/roy-agent-core-8n0e62y4.js";
|
|
46
46
|
import"../shared/@ai-setting/roy-agent-core-eskgj8nc.js";
|
|
47
47
|
import"../shared/@ai-setting/roy-agent-core-ataagh3a.js";
|
|
48
48
|
import"../shared/@ai-setting/roy-agent-core-e25xkv53.js";
|
|
49
49
|
import {
|
|
50
50
|
TaskComponent
|
|
51
|
-
} from "../shared/@ai-setting/roy-agent-core-
|
|
51
|
+
} from "../shared/@ai-setting/roy-agent-core-mvmgy9t0.js";
|
|
52
52
|
import"../shared/@ai-setting/roy-agent-core-amkqnyzy.js";
|
|
53
53
|
import"../shared/@ai-setting/roy-agent-core-8gxth0eh.js";
|
|
54
|
-
import"../shared/@ai-setting/roy-agent-core-
|
|
54
|
+
import"../shared/@ai-setting/roy-agent-core-n1fx2fx4.js";
|
|
55
55
|
import"../shared/@ai-setting/roy-agent-core-44g3synv.js";
|
|
56
56
|
import"../shared/@ai-setting/roy-agent-core-zdzkzx5g.js";
|
|
57
|
-
import"../shared/@ai-setting/roy-agent-core-
|
|
57
|
+
import"../shared/@ai-setting/roy-agent-core-65vpkh7x.js";
|
|
58
58
|
import"../shared/@ai-setting/roy-agent-core-c1v263jn.js";
|
|
59
59
|
import"../shared/@ai-setting/roy-agent-core-tycbpm17.js";
|
|
60
60
|
import {
|
|
@@ -62,7 +62,7 @@ import {
|
|
|
62
62
|
getXDGPath,
|
|
63
63
|
getXDGPaths
|
|
64
64
|
} from "../shared/@ai-setting/roy-agent-core-qxnbvgwe.js";
|
|
65
|
-
import"../shared/@ai-setting/roy-agent-core-
|
|
65
|
+
import"../shared/@ai-setting/roy-agent-core-c7e3htaq.js";
|
|
66
66
|
import"../shared/@ai-setting/roy-agent-core-rn57psp0.js";
|
|
67
67
|
import"../shared/@ai-setting/roy-agent-core-1pg0fepg.js";
|
|
68
68
|
import {
|
package/dist/env/prompt/index.js
CHANGED
|
@@ -3,8 +3,8 @@ import {
|
|
|
3
3
|
PromptConfigSchema,
|
|
4
4
|
PromptPathSchema,
|
|
5
5
|
PromptRenderer
|
|
6
|
-
} from "../../shared/@ai-setting/roy-agent-core-
|
|
7
|
-
import"../../shared/@ai-setting/roy-agent-core-
|
|
6
|
+
} from "../../shared/@ai-setting/roy-agent-core-h07kk80k.js";
|
|
7
|
+
import"../../shared/@ai-setting/roy-agent-core-65vpkh7x.js";
|
|
8
8
|
import"../../shared/@ai-setting/roy-agent-core-qxnbvgwe.js";
|
|
9
9
|
import"../../shared/@ai-setting/roy-agent-core-7hh0brvs.js";
|
|
10
10
|
import"../../shared/@ai-setting/roy-agent-core-akb8mb9v.js";
|
|
@@ -3,9 +3,9 @@ import {
|
|
|
3
3
|
BackgroundTaskManager,
|
|
4
4
|
createDelegateTool,
|
|
5
5
|
createStopTool
|
|
6
|
-
} from "../../../shared/@ai-setting/roy-agent-core-
|
|
6
|
+
} from "../../../shared/@ai-setting/roy-agent-core-n1fx2fx4.js";
|
|
7
7
|
import"../../../shared/@ai-setting/roy-agent-core-44g3synv.js";
|
|
8
|
-
import"../../../shared/@ai-setting/roy-agent-core-
|
|
8
|
+
import"../../../shared/@ai-setting/roy-agent-core-65vpkh7x.js";
|
|
9
9
|
import"../../../shared/@ai-setting/roy-agent-core-c1v263jn.js";
|
|
10
10
|
import"../../../shared/@ai-setting/roy-agent-core-tycbpm17.js";
|
|
11
11
|
import"../../../shared/@ai-setting/roy-agent-core-qxnbvgwe.js";
|
package/dist/env/task/index.js
CHANGED
|
@@ -5,22 +5,22 @@ import {
|
|
|
5
5
|
TaskPriorityEnum,
|
|
6
6
|
TaskStatusEnum,
|
|
7
7
|
TaskTypeEnum
|
|
8
|
-
} from "../../shared/@ai-setting/roy-agent-core-
|
|
8
|
+
} from "../../shared/@ai-setting/roy-agent-core-mvmgy9t0.js";
|
|
9
9
|
import"../../shared/@ai-setting/roy-agent-core-amkqnyzy.js";
|
|
10
10
|
import {
|
|
11
11
|
TaskEntityEventTypes
|
|
12
12
|
} from "../../shared/@ai-setting/roy-agent-core-8gxth0eh.js";
|
|
13
|
-
import"../../shared/@ai-setting/roy-agent-core-
|
|
13
|
+
import"../../shared/@ai-setting/roy-agent-core-n1fx2fx4.js";
|
|
14
14
|
import"../../shared/@ai-setting/roy-agent-core-44g3synv.js";
|
|
15
15
|
import {
|
|
16
16
|
SQLiteTaskStore,
|
|
17
17
|
getDefaultTaskDbPath
|
|
18
18
|
} from "../../shared/@ai-setting/roy-agent-core-zdzkzx5g.js";
|
|
19
|
-
import"../../shared/@ai-setting/roy-agent-core-
|
|
19
|
+
import"../../shared/@ai-setting/roy-agent-core-65vpkh7x.js";
|
|
20
20
|
import"../../shared/@ai-setting/roy-agent-core-c1v263jn.js";
|
|
21
21
|
import"../../shared/@ai-setting/roy-agent-core-tycbpm17.js";
|
|
22
22
|
import"../../shared/@ai-setting/roy-agent-core-qxnbvgwe.js";
|
|
23
|
-
import"../../shared/@ai-setting/roy-agent-core-
|
|
23
|
+
import"../../shared/@ai-setting/roy-agent-core-c7e3htaq.js";
|
|
24
24
|
import"../../shared/@ai-setting/roy-agent-core-rn57psp0.js";
|
|
25
25
|
import"../../shared/@ai-setting/roy-agent-core-1pg0fepg.js";
|
|
26
26
|
import"../../shared/@ai-setting/roy-agent-core-7hh0brvs.js";
|
|
@@ -8,13 +8,13 @@ import {
|
|
|
8
8
|
formatExtractorInput,
|
|
9
9
|
formatExtractorInputFromDescription,
|
|
10
10
|
parseExtractorOutput
|
|
11
|
-
} from "../../../shared/@ai-setting/roy-agent-core-
|
|
11
|
+
} from "../../../shared/@ai-setting/roy-agent-core-nreqmmtz.js";
|
|
12
12
|
import"../../../shared/@ai-setting/roy-agent-core-az13yzmc.js";
|
|
13
13
|
import"../../../shared/@ai-setting/roy-agent-core-1mrc9a1r.js";
|
|
14
14
|
import"../../../shared/@ai-setting/roy-agent-core-bq1gskrf.js";
|
|
15
15
|
import"../../../shared/@ai-setting/roy-agent-core-jrj30vq3.js";
|
|
16
16
|
import"../../../shared/@ai-setting/roy-agent-core-e25xkv53.js";
|
|
17
|
-
import"../../../shared/@ai-setting/roy-agent-core-
|
|
17
|
+
import"../../../shared/@ai-setting/roy-agent-core-65vpkh7x.js";
|
|
18
18
|
import"../../../shared/@ai-setting/roy-agent-core-1pg0fepg.js";
|
|
19
19
|
import"../../../shared/@ai-setting/roy-agent-core-sqt96sam.js";
|
|
20
20
|
import"../../../shared/@ai-setting/roy-agent-core-dtkbj8fk.js";
|
|
@@ -9,7 +9,7 @@ import {
|
|
|
9
9
|
searchTasksTool,
|
|
10
10
|
treeTasksTool,
|
|
11
11
|
updateTaskTool
|
|
12
|
-
} from "../../../shared/@ai-setting/roy-agent-core-
|
|
12
|
+
} from "../../../shared/@ai-setting/roy-agent-core-c7e3htaq.js";
|
|
13
13
|
import"../../../shared/@ai-setting/roy-agent-core-dtkbj8fk.js";
|
|
14
14
|
import"../../../shared/@ai-setting/roy-agent-core-96mj6gvc.js";
|
|
15
15
|
import"../../../shared/@ai-setting/roy-agent-core-nna4s0qs.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
WorkflowComponent
|
|
3
|
-
} from "../../shared/@ai-setting/roy-agent-core-
|
|
3
|
+
} from "../../shared/@ai-setting/roy-agent-core-f6x6ksz3.js";
|
|
4
4
|
import"../../shared/@ai-setting/roy-agent-core-77wfej1h.js";
|
|
5
5
|
import"../../shared/@ai-setting/roy-agent-core-yr3fp8tv.js";
|
|
6
6
|
import"../../shared/@ai-setting/roy-agent-core-6atd905e.js";
|
|
@@ -9,7 +9,7 @@ import"../../shared/@ai-setting/roy-agent-core-ez91vxas.js";
|
|
|
9
9
|
import"../../shared/@ai-setting/roy-agent-core-ddwa0n6h.js";
|
|
10
10
|
import"../../shared/@ai-setting/roy-agent-core-hhrg314p.js";
|
|
11
11
|
import"../../shared/@ai-setting/roy-agent-core-7kw06e4b.js";
|
|
12
|
-
import"../../shared/@ai-setting/roy-agent-core-
|
|
12
|
+
import"../../shared/@ai-setting/roy-agent-core-kkt2ndpf.js";
|
|
13
13
|
import"../../shared/@ai-setting/roy-agent-core-1db4vpc6.js";
|
|
14
14
|
import"../../shared/@ai-setting/roy-agent-core-r15sn7ve.js";
|
|
15
15
|
import"../../shared/@ai-setting/roy-agent-core-1mrc9a1r.js";
|
|
@@ -24,7 +24,7 @@ import {
|
|
|
24
24
|
getRunWorkflowTool,
|
|
25
25
|
initRunWorkflowTool,
|
|
26
26
|
resetRunWorkflowTool
|
|
27
|
-
} from "../../../shared/@ai-setting/roy-agent-core-
|
|
27
|
+
} from "../../../shared/@ai-setting/roy-agent-core-kkt2ndpf.js";
|
|
28
28
|
import {
|
|
29
29
|
WORKFLOW_SUBMIT_OUTPUT_TOOL_NAME,
|
|
30
30
|
WorkflowJsonOutputMarker,
|
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
PromptComponent,
|
|
3
3
|
PromptStore
|
|
4
|
-
} from "./shared/@ai-setting/roy-agent-core-
|
|
4
|
+
} from "./shared/@ai-setting/roy-agent-core-h07kk80k.js";
|
|
5
5
|
import {
|
|
6
6
|
LLMComponent,
|
|
7
7
|
LLMConfigSchema,
|
|
@@ -63,7 +63,7 @@ import {
|
|
|
63
63
|
BaseEnvironment,
|
|
64
64
|
generateDescendingId,
|
|
65
65
|
generateId
|
|
66
|
-
} from "./shared/@ai-setting/roy-agent-core-
|
|
66
|
+
} from "./shared/@ai-setting/roy-agent-core-vc8e968b.js";
|
|
67
67
|
import {
|
|
68
68
|
BountyIMInstance,
|
|
69
69
|
EventSourceComponent,
|
|
@@ -76,7 +76,7 @@ import {
|
|
|
76
76
|
larkCliHandler,
|
|
77
77
|
resolveBountyIMSystemPrompt,
|
|
78
78
|
timerHandler
|
|
79
|
-
} from "./shared/@ai-setting/roy-agent-core-
|
|
79
|
+
} from "./shared/@ai-setting/roy-agent-core-6mz26khm.js";
|
|
80
80
|
import {
|
|
81
81
|
BUILT_IN_EVENT_SOURCE_TYPES,
|
|
82
82
|
BUILT_IN_EVENT_SOURCE_TYPE_LIST,
|
|
@@ -96,13 +96,13 @@ import {
|
|
|
96
96
|
import {
|
|
97
97
|
TaskTagPlugin,
|
|
98
98
|
createAutoTaskPlugin
|
|
99
|
-
} from "./shared/@ai-setting/roy-agent-core-
|
|
99
|
+
} from "./shared/@ai-setting/roy-agent-core-nreqmmtz.js";
|
|
100
100
|
import {
|
|
101
101
|
BasePlugin
|
|
102
102
|
} from "./shared/@ai-setting/roy-agent-core-az13yzmc.js";
|
|
103
103
|
import {
|
|
104
104
|
WorkflowComponent
|
|
105
|
-
} from "./shared/@ai-setting/roy-agent-core-
|
|
105
|
+
} from "./shared/@ai-setting/roy-agent-core-f6x6ksz3.js";
|
|
106
106
|
import {
|
|
107
107
|
init_node_registry_helper,
|
|
108
108
|
registerDecoratorNodeType
|
|
@@ -114,7 +114,7 @@ import"./shared/@ai-setting/roy-agent-core-ez91vxas.js";
|
|
|
114
114
|
import"./shared/@ai-setting/roy-agent-core-ddwa0n6h.js";
|
|
115
115
|
import"./shared/@ai-setting/roy-agent-core-hhrg314p.js";
|
|
116
116
|
import"./shared/@ai-setting/roy-agent-core-7kw06e4b.js";
|
|
117
|
-
import"./shared/@ai-setting/roy-agent-core-
|
|
117
|
+
import"./shared/@ai-setting/roy-agent-core-kkt2ndpf.js";
|
|
118
118
|
import"./shared/@ai-setting/roy-agent-core-1db4vpc6.js";
|
|
119
119
|
import"./shared/@ai-setting/roy-agent-core-r15sn7ve.js";
|
|
120
120
|
import"./shared/@ai-setting/roy-agent-core-1mrc9a1r.js";
|
|
@@ -131,7 +131,7 @@ import"./shared/@ai-setting/roy-agent-core-1ce3fqrk.js";
|
|
|
131
131
|
import {
|
|
132
132
|
AgentComponent,
|
|
133
133
|
AgentComponentConfigSchema
|
|
134
|
-
} from "./shared/@ai-setting/roy-agent-core-
|
|
134
|
+
} from "./shared/@ai-setting/roy-agent-core-qyb2z42s.js";
|
|
135
135
|
import {
|
|
136
136
|
createInvokeConfig,
|
|
137
137
|
invoke,
|
|
@@ -150,10 +150,10 @@ import {
|
|
|
150
150
|
} from "./shared/@ai-setting/roy-agent-core-e25xkv53.js";
|
|
151
151
|
import {
|
|
152
152
|
TaskComponent
|
|
153
|
-
} from "./shared/@ai-setting/roy-agent-core-
|
|
153
|
+
} from "./shared/@ai-setting/roy-agent-core-mvmgy9t0.js";
|
|
154
154
|
import"./shared/@ai-setting/roy-agent-core-amkqnyzy.js";
|
|
155
155
|
import"./shared/@ai-setting/roy-agent-core-8gxth0eh.js";
|
|
156
|
-
import"./shared/@ai-setting/roy-agent-core-
|
|
156
|
+
import"./shared/@ai-setting/roy-agent-core-n1fx2fx4.js";
|
|
157
157
|
import"./shared/@ai-setting/roy-agent-core-44g3synv.js";
|
|
158
158
|
import {
|
|
159
159
|
SQLiteTaskStore,
|
|
@@ -162,7 +162,7 @@ import {
|
|
|
162
162
|
import {
|
|
163
163
|
getBuiltInPrompt,
|
|
164
164
|
getBuiltInPromptNames
|
|
165
|
-
} from "./shared/@ai-setting/roy-agent-core-
|
|
165
|
+
} from "./shared/@ai-setting/roy-agent-core-65vpkh7x.js";
|
|
166
166
|
import"./shared/@ai-setting/roy-agent-core-c1v263jn.js";
|
|
167
167
|
import {
|
|
168
168
|
AgentRegistry
|
|
@@ -172,7 +172,7 @@ import {
|
|
|
172
172
|
getXDGPath,
|
|
173
173
|
getXDGPaths
|
|
174
174
|
} from "./shared/@ai-setting/roy-agent-core-qxnbvgwe.js";
|
|
175
|
-
import"./shared/@ai-setting/roy-agent-core-
|
|
175
|
+
import"./shared/@ai-setting/roy-agent-core-c7e3htaq.js";
|
|
176
176
|
import"./shared/@ai-setting/roy-agent-core-rn57psp0.js";
|
|
177
177
|
import {
|
|
178
178
|
TaskHookPoints
|
|
@@ -61,6 +61,14 @@ var builtInPrompts = {
|
|
|
61
61
|
**\`delegate_task\`** — 这是你的**主要执行工具**。用于一切复杂、多步骤、需要读文件、运行命令、代码分析、搜索、实现功能等场景。**当不确定用哪个时,选 \`delegate_task\`。**
|
|
62
62
|
|
|
63
63
|
> **similar_task_ids 是必填参数**:每次调用 \`delegate_task\` 前,必须先使用 \`task_search\` 搜索与当前任务相似的历史任务,将找到的相似任务 ID 填入 \`similar_task_ids\` 参数(最多 3 个)。如果没有找到相似任务,传入空数组 \`similar_task_ids=[]\`。
|
|
64
|
+
>
|
|
65
|
+
> **Reuse Candidates auto-injected — three legal paths (Task #2395)**: even if you pass \`similar_task_ids=[]\`, \`delegate_task\` automatically injects the most recent TaskCreationRegistry entries into the sub-agent prompt as candidates. The injected section shows each candidate's **parent / children / subtree summary / project / branch / worktree** so the sub-agent can judge which path fits. Before creating any new task, the sub-agent **must** call \`task_get\` on the relevant candidate and pick exactly one of three paths:
|
|
66
|
+
>
|
|
67
|
+
> - **Path A — Continuation (reopen existing task).** The new work is the SAME logical task as a candidate (or its parent). Use \`task_update(task_id=<id>, { status: "active" })\` and append description/goals. Do **not** create a new id.
|
|
68
|
+
> - **Path B — Child task (independent sub-delivery under the same feature).** The new work is a sibling-style item — an independent bug fix, optimization, parallel delivery, or independent acceptance criterion that clearly belongs under an existing feature/parent. Use \`task_create(parent_task_id=<candidate_id>, title="<distinguishing title>", ...)\`. \`task_create\` will auto-merge the parent's safe context (project_path, worktree_path, branch, parent_branch) and strip sensitive keys (commits, tokens, secrets). Always pair with a \`task_operation_create\` (milestone_type=\`milestone\`) so the audit trail shows *why* this was a child rather than a reopen.
|
|
69
|
+
> - **Path C — New root (unrelated work).** The new work is unrelated to any candidate. Create a brand-new root task without \`parent_task_id\` — but only when no existing longterm / topic cluster fits. Root count should stay ≤ ~10 to keep the tree readable.
|
|
70
|
+
>
|
|
71
|
+
> Candidates are **suggestions**, not mandatory merges. Empty reuse is a valid outcome. Whichever path the sub-agent picks, it **must** call \`task_operation_create\` to record why the path was chosen (\`decision\` for A, \`milestone\` for B, \`create\` for C).
|
|
64
72
|
|
|
65
73
|
**\`bash\`** — 用于执行**简单的一次性 shell 命令**(1-2 行能完成的查询)。典型场景:
|
|
66
74
|
- **文件浏览 / 读取**:\`ls -la\`、\`cat file.txt\`、\`head -n 20 file.txt\`、\`tail -n 50 log.txt\`、\`grep "pattern" file.txt\`、\`find . -name "*.ts"\`
|
|
@@ -92,7 +92,101 @@ var TreeTasksToolSchema = z.object({
|
|
|
92
92
|
init_env_context();
|
|
93
93
|
init_logger();
|
|
94
94
|
import { execSync } from "child_process";
|
|
95
|
-
|
|
95
|
+
|
|
96
|
+
// src/env/task/task-child-context.ts
|
|
97
|
+
init_logger();
|
|
98
|
+
var logger = createLogger("task-child-context");
|
|
99
|
+
var STRIPPED_KEYS = ["commit", "token", "secret", "password", "api_key"];
|
|
100
|
+
function stripSensitiveKeys(obj) {
|
|
101
|
+
if (obj === null || obj === undefined)
|
|
102
|
+
return obj;
|
|
103
|
+
if (Array.isArray(obj))
|
|
104
|
+
return obj.map(stripSensitiveKeys);
|
|
105
|
+
if (typeof obj !== "object")
|
|
106
|
+
return obj;
|
|
107
|
+
const out = {};
|
|
108
|
+
for (const [k, v] of Object.entries(obj)) {
|
|
109
|
+
const lower = k.toLowerCase();
|
|
110
|
+
if (STRIPPED_KEYS.some((s) => lower.includes(s)))
|
|
111
|
+
continue;
|
|
112
|
+
out[k] = stripSensitiveKeys(v);
|
|
113
|
+
}
|
|
114
|
+
return out;
|
|
115
|
+
}
|
|
116
|
+
function inheritChildContext(args) {
|
|
117
|
+
const { parent, overrides = {} } = args;
|
|
118
|
+
const contextInherit = overrides.contextInherit !== false;
|
|
119
|
+
const inheritTags = overrides.inheritTags === true;
|
|
120
|
+
const project_path = overrides.projectPath ?? parent.projectPath ?? "unknown";
|
|
121
|
+
let parentCtx = {};
|
|
122
|
+
if (parent.contextJson && parent.contextJson.trim().length > 0) {
|
|
123
|
+
try {
|
|
124
|
+
const parsed = JSON.parse(parent.contextJson);
|
|
125
|
+
if (parsed && typeof parsed === "object" && !Array.isArray(parsed)) {
|
|
126
|
+
parentCtx = parsed;
|
|
127
|
+
}
|
|
128
|
+
} catch (err) {
|
|
129
|
+
logger.debug(`[task-child-context] parent #${parent.taskId} context is malformed JSON; ` + `continuing with empty inherited context (${err instanceof Error ? err.message : String(err)})`);
|
|
130
|
+
parentCtx = {};
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
const childCtx = {};
|
|
134
|
+
if (contextInherit) {
|
|
135
|
+
if (parentCtx.worktree_path !== undefined && overrides.worktreePath === undefined) {
|
|
136
|
+
childCtx.worktree_path = parentCtx.worktree_path;
|
|
137
|
+
}
|
|
138
|
+
if (parentCtx.branch !== undefined && overrides.branch === undefined) {
|
|
139
|
+
childCtx.branch = parentCtx.branch;
|
|
140
|
+
}
|
|
141
|
+
if (parentCtx.parent_branch !== undefined) {
|
|
142
|
+
childCtx.parent_branch = parentCtx.parent_branch;
|
|
143
|
+
}
|
|
144
|
+
if (parentCtx.type !== undefined) {
|
|
145
|
+
childCtx.type = parentCtx.type;
|
|
146
|
+
}
|
|
147
|
+
if (parentCtx.prior_context && typeof parentCtx.prior_context === "object") {
|
|
148
|
+
const pc = parentCtx.prior_context;
|
|
149
|
+
const safe = {};
|
|
150
|
+
for (const [k, v] of Object.entries(pc)) {
|
|
151
|
+
if (k.toLowerCase() === "commit")
|
|
152
|
+
continue;
|
|
153
|
+
safe[k] = v;
|
|
154
|
+
}
|
|
155
|
+
if (Object.keys(safe).length > 0) {
|
|
156
|
+
childCtx.prior_context = safe;
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
const reserved = new Set([
|
|
160
|
+
"worktree_path",
|
|
161
|
+
"branch",
|
|
162
|
+
"parent_branch",
|
|
163
|
+
"type",
|
|
164
|
+
"prior_context",
|
|
165
|
+
"created_at"
|
|
166
|
+
]);
|
|
167
|
+
for (const [k, v] of Object.entries(parentCtx)) {
|
|
168
|
+
if (reserved.has(k))
|
|
169
|
+
continue;
|
|
170
|
+
childCtx[k] = v;
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
if (overrides.worktreePath !== undefined)
|
|
174
|
+
childCtx.worktree_path = overrides.worktreePath;
|
|
175
|
+
if (overrides.branch !== undefined)
|
|
176
|
+
childCtx.branch = overrides.branch;
|
|
177
|
+
const createdAt = overrides.createdAt ?? new Date().toISOString();
|
|
178
|
+
childCtx.created_at = createdAt;
|
|
179
|
+
childCtx.child_of = parent.taskId;
|
|
180
|
+
const sanitized = stripSensitiveKeys(childCtx);
|
|
181
|
+
return {
|
|
182
|
+
project_path,
|
|
183
|
+
context: JSON.stringify(sanitized),
|
|
184
|
+
inheritedTags: inheritTags ? parent.tags ?? [] : []
|
|
185
|
+
};
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
// src/env/task/tools/create-tool.ts
|
|
189
|
+
var logger2 = createLogger("task:tools:create");
|
|
96
190
|
function detectWorktree() {
|
|
97
191
|
try {
|
|
98
192
|
const toplevel = execSync("git rev-parse --show-toplevel", {
|
|
@@ -242,9 +336,53 @@ function createTaskTool(taskComponent) {
|
|
|
242
336
|
const sessionId = ctx.session_id || "unknown";
|
|
243
337
|
const detectedWorktree = detectWorktree();
|
|
244
338
|
let enrichedContext = params.context;
|
|
339
|
+
let inheritedProjectPath = params.project_path && params.project_path.trim() !== "" ? params.project_path : undefined;
|
|
340
|
+
let inheritedTags = params.tags;
|
|
341
|
+
let inheritedContext;
|
|
342
|
+
if (params.parent_task_id !== undefined && params.parent_task_id !== null) {
|
|
343
|
+
try {
|
|
344
|
+
const parent = await taskComponent.getTask(params.parent_task_id);
|
|
345
|
+
if (parent) {
|
|
346
|
+
const inherited = inheritChildContext({
|
|
347
|
+
parent: {
|
|
348
|
+
taskId: parent.id,
|
|
349
|
+
projectPath: parent.project_path,
|
|
350
|
+
contextJson: parent.context ?? "",
|
|
351
|
+
tags: parent.tags
|
|
352
|
+
},
|
|
353
|
+
overrides: {
|
|
354
|
+
projectPath: inheritedProjectPath,
|
|
355
|
+
branch: undefined,
|
|
356
|
+
worktreePath: undefined,
|
|
357
|
+
inheritTags: params.tags === undefined,
|
|
358
|
+
contextInherit: true
|
|
359
|
+
}
|
|
360
|
+
});
|
|
361
|
+
if (inheritedProjectPath === undefined) {
|
|
362
|
+
inheritedProjectPath = inherited.project_path;
|
|
363
|
+
}
|
|
364
|
+
if (params.tags === undefined)
|
|
365
|
+
inheritedTags = inherited.inheritedTags;
|
|
366
|
+
inheritedContext = inherited.context;
|
|
367
|
+
}
|
|
368
|
+
} catch (err) {
|
|
369
|
+
logger2.debug(`[task_create] failed to pre-load parent #${params.parent_task_id} for context inheritance: ${err instanceof Error ? err.message : String(err)}`);
|
|
370
|
+
}
|
|
371
|
+
}
|
|
245
372
|
try {
|
|
246
373
|
const ctxObj = params.context ? JSON.parse(params.context) : {};
|
|
247
374
|
const obj = typeof ctxObj === "object" && ctxObj !== null && !Array.isArray(ctxObj) ? ctxObj : {};
|
|
375
|
+
if (inheritedContext) {
|
|
376
|
+
try {
|
|
377
|
+
const inheritedObj = JSON.parse(inheritedContext);
|
|
378
|
+
if (inheritedObj && typeof inheritedObj === "object" && !Array.isArray(inheritedObj)) {
|
|
379
|
+
for (const [k, v] of Object.entries(inheritedObj)) {
|
|
380
|
+
if (obj[k] === undefined)
|
|
381
|
+
obj[k] = v;
|
|
382
|
+
}
|
|
383
|
+
}
|
|
384
|
+
} catch {}
|
|
385
|
+
}
|
|
248
386
|
if (!obj.created_at) {
|
|
249
387
|
obj.created_at = new Date().toISOString();
|
|
250
388
|
}
|
|
@@ -264,13 +402,13 @@ function createTaskTool(taskComponent) {
|
|
|
264
402
|
type: params.type || "normal",
|
|
265
403
|
goals_and_expected_deliverables: params.goals_and_expected_deliverables,
|
|
266
404
|
due_date: params.due_date,
|
|
267
|
-
tags:
|
|
405
|
+
tags: inheritedTags,
|
|
268
406
|
sessionId,
|
|
269
|
-
project_path: params.project_path,
|
|
407
|
+
project_path: inheritedProjectPath ?? params.project_path,
|
|
270
408
|
context: enrichedContext
|
|
271
409
|
});
|
|
272
410
|
setCurrentTaskId(task.id);
|
|
273
|
-
|
|
411
|
+
logger2.info(`[createTask] Trace: Task #${task.id} created, currentTaskId=${task.id} set in EnvContext`);
|
|
274
412
|
return {
|
|
275
413
|
success: true,
|
|
276
414
|
output: `Task created successfully: #${task.id} - ${task.title}`,
|
|
@@ -550,7 +688,7 @@ function batchDeleteTaskTool(taskComponent) {
|
|
|
550
688
|
// src/env/task/tools/update-tool.ts
|
|
551
689
|
init_env_context();
|
|
552
690
|
init_logger();
|
|
553
|
-
var
|
|
691
|
+
var logger3 = createLogger("tool:update-task");
|
|
554
692
|
async function detectCycle(taskComponent, taskId, newParentId) {
|
|
555
693
|
const visited = new Set;
|
|
556
694
|
let currentId = newParentId;
|
|
@@ -624,7 +762,7 @@ function updateTaskTool(taskComponent) {
|
|
|
624
762
|
});
|
|
625
763
|
}
|
|
626
764
|
setCurrentTaskId(task.id);
|
|
627
|
-
|
|
765
|
+
logger3.info(`[updateTask] Trace: Task #${task.id} updated, currentTaskId=${task.id} set in EnvContext`);
|
|
628
766
|
return {
|
|
629
767
|
success: true,
|
|
630
768
|
output: `Task updated: #${task.id} - ${task.title}`,
|
|
@@ -678,7 +816,7 @@ function deleteTaskTool(taskComponent) {
|
|
|
678
816
|
// src/env/task/tools/complete-tool.ts
|
|
679
817
|
init_env_context();
|
|
680
818
|
init_logger();
|
|
681
|
-
var
|
|
819
|
+
var logger4 = createLogger("task:tools:complete");
|
|
682
820
|
function completeTaskTool(taskComponent) {
|
|
683
821
|
return {
|
|
684
822
|
name: "task_complete",
|
|
@@ -715,7 +853,7 @@ function completeTaskTool(taskComponent) {
|
|
|
715
853
|
};
|
|
716
854
|
}
|
|
717
855
|
setCurrentTaskId(undefined);
|
|
718
|
-
|
|
856
|
+
logger4.info(`[completeTask] Trace: Task #${params.task_id} completed, currentTaskId cleared from EnvContext`);
|
|
719
857
|
return {
|
|
720
858
|
success: true,
|
|
721
859
|
output: `Task completed: #${task.id} - ${task.title}`,
|