@synergenius/flow-weaver-pack-weaver 0.9.62 → 0.9.78
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/ai-chat-provider.d.ts +12 -0
- package/dist/ai-chat-provider.d.ts.map +1 -1
- package/dist/ai-chat-provider.js +173 -19
- package/dist/ai-chat-provider.js.map +1 -1
- package/dist/bot/agent-loop.d.ts +20 -0
- package/dist/bot/agent-loop.d.ts.map +1 -0
- package/dist/bot/agent-loop.js +331 -0
- package/dist/bot/agent-loop.js.map +1 -0
- package/dist/bot/ai-router.d.ts +19 -0
- package/dist/bot/ai-router.d.ts.map +1 -0
- package/dist/bot/ai-router.js +104 -0
- package/dist/bot/ai-router.js.map +1 -0
- package/dist/bot/bot-registry.js +2 -2
- package/dist/bot/bot-registry.js.map +1 -1
- package/dist/bot/conversation-store.d.ts +1 -0
- package/dist/bot/conversation-store.d.ts.map +1 -1
- package/dist/bot/conversation-store.js.map +1 -1
- package/dist/bot/improve-loop.js.map +1 -1
- package/dist/bot/instance-manager.d.ts +31 -0
- package/dist/bot/instance-manager.d.ts.map +1 -0
- package/dist/bot/instance-manager.js +115 -0
- package/dist/bot/instance-manager.js.map +1 -0
- package/dist/bot/orchestrator.d.ts +36 -0
- package/dist/bot/orchestrator.d.ts.map +1 -0
- package/dist/bot/orchestrator.js +176 -0
- package/dist/bot/orchestrator.js.map +1 -0
- package/dist/bot/profile-store.d.ts +36 -0
- package/dist/bot/profile-store.d.ts.map +1 -0
- package/dist/bot/profile-store.js +208 -0
- package/dist/bot/profile-store.js.map +1 -0
- package/dist/bot/profile-types.d.ts +126 -0
- package/dist/bot/profile-types.d.ts.map +1 -0
- package/dist/bot/profile-types.js +7 -0
- package/dist/bot/profile-types.js.map +1 -0
- package/dist/bot/session-state.d.ts +25 -0
- package/dist/bot/session-state.d.ts.map +1 -0
- package/dist/bot/session-state.js +110 -0
- package/dist/bot/session-state.js.map +1 -0
- package/dist/bot/swarm-controller.d.ts +37 -21
- package/dist/bot/swarm-controller.d.ts.map +1 -1
- package/dist/bot/swarm-controller.js +344 -163
- package/dist/bot/swarm-controller.js.map +1 -1
- package/dist/bot/task-prompt-builder.d.ts +2 -1
- package/dist/bot/task-prompt-builder.d.ts.map +1 -1
- package/dist/bot/task-prompt-builder.js +33 -10
- package/dist/bot/task-prompt-builder.js.map +1 -1
- package/dist/bot/task-queue.d.ts +46 -0
- package/dist/bot/task-queue.d.ts.map +1 -0
- package/dist/bot/task-queue.js +237 -0
- package/dist/bot/task-queue.js.map +1 -0
- package/dist/bot/task-store.d.ts +1 -6
- package/dist/bot/task-store.d.ts.map +1 -1
- package/dist/bot/task-store.js +27 -78
- package/dist/bot/task-store.js.map +1 -1
- package/dist/bot/task-types.d.ts +8 -4
- package/dist/bot/task-types.d.ts.map +1 -1
- package/dist/cli-handlers.d.ts.map +1 -1
- package/dist/cli-handlers.js +2 -3
- package/dist/cli-handlers.js.map +1 -1
- package/dist/cli.d.ts +3 -0
- package/dist/cli.d.ts.map +1 -0
- package/dist/cli.js +749 -0
- package/dist/cli.js.map +1 -0
- package/dist/docs/docs/weaver-bot-usage.md +35 -18
- package/dist/docs/docs/weaver-config.md +20 -0
- package/dist/docs/docs/weaver-task-queue.md +31 -19
- package/dist/docs/weaver-config.md +15 -9
- package/dist/mcp-tools.d.ts +17 -0
- package/dist/mcp-tools.d.ts.map +1 -1
- package/dist/mcp-tools.js +98 -232
- package/dist/mcp-tools.js.map +1 -1
- package/dist/node-types/orchestrator-dispatch.d.ts +17 -0
- package/dist/node-types/orchestrator-dispatch.d.ts.map +1 -0
- package/dist/node-types/orchestrator-dispatch.js +63 -0
- package/dist/node-types/orchestrator-dispatch.js.map +1 -0
- package/dist/node-types/orchestrator-load-state.d.ts +16 -0
- package/dist/node-types/orchestrator-load-state.d.ts.map +1 -0
- package/dist/node-types/orchestrator-load-state.js +60 -0
- package/dist/node-types/orchestrator-load-state.js.map +1 -0
- package/dist/node-types/orchestrator-route.d.ts +16 -0
- package/dist/node-types/orchestrator-route.d.ts.map +1 -0
- package/dist/node-types/orchestrator-route.js +28 -0
- package/dist/node-types/orchestrator-route.js.map +1 -0
- package/dist/node-types/receive-task.d.ts +2 -3
- package/dist/node-types/receive-task.d.ts.map +1 -1
- package/dist/node-types/receive-task.js +3 -28
- package/dist/node-types/receive-task.js.map +1 -1
- package/dist/templates/weaver-template.d.ts +11 -0
- package/dist/templates/weaver-template.d.ts.map +1 -0
- package/dist/templates/weaver-template.js +53 -0
- package/dist/templates/weaver-template.js.map +1 -0
- package/dist/ui/bot-constants.d.ts +14 -0
- package/dist/ui/bot-constants.d.ts.map +1 -0
- package/dist/ui/bot-constants.js +189 -0
- package/dist/ui/bot-constants.js.map +1 -0
- package/dist/ui/bot-panel.js +51 -90
- package/dist/ui/bot-slot-card.js +87 -122
- package/dist/ui/budget-bar.js +5 -3
- package/dist/ui/chat-task-result.js +4 -7
- package/dist/ui/decision-log.js +136 -0
- package/dist/ui/profile-card.js +158 -0
- package/dist/ui/profile-editor.js +597 -0
- package/dist/ui/swarm-controls.js +36 -27
- package/dist/ui/swarm-dashboard.js +2034 -736
- package/dist/ui/task-create-form.js +39 -116
- package/dist/ui/task-detail-view.js +490 -239
- package/dist/ui/task-pool-list.js +69 -94
- package/dist/workflows/orchestrator.d.ts +21 -0
- package/dist/workflows/orchestrator.d.ts.map +1 -0
- package/dist/workflows/orchestrator.js +281 -0
- package/dist/workflows/orchestrator.js.map +1 -0
- package/dist/workflows/weaver-bot-session.d.ts +65 -0
- package/dist/workflows/weaver-bot-session.d.ts.map +1 -0
- package/dist/workflows/weaver-bot-session.js +68 -0
- package/dist/workflows/weaver-bot-session.js.map +1 -0
- package/dist/workflows/weaver.d.ts +24 -0
- package/dist/workflows/weaver.d.ts.map +1 -0
- package/dist/workflows/weaver.js +28 -0
- package/dist/workflows/weaver.js.map +1 -0
- package/flowweaver.manifest.json +253 -66
- package/package.json +1 -1
- package/src/ai-chat-provider.ts +184 -18
- package/src/bot/ai-router.ts +132 -0
- package/src/bot/bot-registry.ts +2 -2
- package/src/bot/conversation-store.ts +2 -1
- package/src/bot/improve-loop.ts +6 -6
- package/src/bot/instance-manager.ts +128 -0
- package/src/bot/orchestrator.ts +244 -0
- package/src/bot/profile-store.ts +225 -0
- package/src/bot/profile-types.ts +141 -0
- package/src/bot/swarm-controller.ts +385 -186
- package/src/bot/task-prompt-builder.ts +37 -6
- package/src/bot/task-store.ts +28 -89
- package/src/bot/task-types.ts +10 -4
- package/src/cli-handlers.ts +2 -3
- package/src/docs/weaver-bot-usage.md +35 -18
- package/src/docs/weaver-config.md +20 -0
- package/src/docs/weaver-task-queue.md +31 -19
- package/src/mcp-tools.ts +129 -320
- package/src/node-types/orchestrator-dispatch.ts +71 -0
- package/src/node-types/orchestrator-load-state.ts +66 -0
- package/src/node-types/orchestrator-route.ts +33 -0
- package/src/node-types/receive-task.ts +3 -26
- package/src/ui/bot-constants.ts +192 -0
- package/src/ui/bot-panel.tsx +55 -79
- package/src/ui/bot-slot-card.tsx +69 -117
- package/src/ui/budget-bar.tsx +5 -3
- package/src/ui/chat-task-result.tsx +6 -9
- package/src/ui/decision-log.tsx +148 -0
- package/src/ui/profile-card.tsx +157 -0
- package/src/ui/profile-editor.tsx +384 -0
- package/src/ui/swarm-controls.tsx +35 -31
- package/src/ui/swarm-dashboard.tsx +409 -80
- package/src/ui/task-create-form.tsx +29 -119
- package/src/ui/task-detail-view.tsx +461 -215
- package/src/ui/task-pool-list.tsx +74 -95
- package/src/workflows/orchestrator.ts +302 -0
- package/dist/docs/weaver-bot-usage.md +0 -34
- package/dist/docs/weaver-genesis.md +0 -32
- package/dist/docs/weaver-task-queue.md +0 -34
- package/src/bot/error-guide.ts +0 -4
- package/src/bot/retry-utils.ts +0 -4
|
@@ -25,8 +25,8 @@ __export(task_pool_list_exports, {
|
|
|
25
25
|
});
|
|
26
26
|
module.exports = __toCommonJS(task_pool_list_exports);
|
|
27
27
|
var React = require("react");
|
|
28
|
-
var {
|
|
29
|
-
var {
|
|
28
|
+
var { useState } = React;
|
|
29
|
+
var { Flex, Typography, Icon, StatusIcon, Tag, ScrollArea, Badge, EmptyState } = require("@fw/plugin-ui-kit");
|
|
30
30
|
var statusToIcon = {
|
|
31
31
|
"pending": "pending",
|
|
32
32
|
"in-progress": "running",
|
|
@@ -35,50 +35,15 @@ var statusToIcon = {
|
|
|
35
35
|
"blocked": "pending",
|
|
36
36
|
"cancelled": "failed"
|
|
37
37
|
};
|
|
38
|
-
var
|
|
39
|
-
"pending": "color-text-subtle",
|
|
40
|
-
"in-progress": "color-status-info",
|
|
41
|
-
"done": "color-status-positive",
|
|
42
|
-
"failed": "color-status-negative",
|
|
43
|
-
"blocked": "color-status-caution",
|
|
44
|
-
"cancelled": "color-text-subtle"
|
|
45
|
-
};
|
|
46
|
-
var Container = styled.div({
|
|
47
|
-
display: "flex",
|
|
48
|
-
flexDirection: "column",
|
|
49
|
-
height: "100%",
|
|
50
|
-
overflow: "hidden"
|
|
51
|
-
});
|
|
52
|
-
var TaskRow = styled.div({
|
|
53
|
-
display: "flex",
|
|
54
|
-
alignItems: "center",
|
|
55
|
-
gap: "8px",
|
|
38
|
+
var rowBaseStyle = {
|
|
56
39
|
padding: "8px 12px",
|
|
57
40
|
cursor: "pointer",
|
|
58
|
-
borderBottom: "1px solid
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
textOverflow: "ellipsis",
|
|
65
|
-
whiteSpace: "nowrap",
|
|
66
|
-
minWidth: 0
|
|
67
|
-
});
|
|
68
|
-
var BotTags = styled.div({
|
|
69
|
-
display: "flex",
|
|
70
|
-
gap: "4px",
|
|
71
|
-
flexShrink: 0
|
|
72
|
-
});
|
|
73
|
-
var EmptyState = styled.div({
|
|
74
|
-
display: "flex",
|
|
75
|
-
flexDirection: "column",
|
|
76
|
-
alignItems: "center",
|
|
77
|
-
justifyContent: "center",
|
|
78
|
-
gap: "8px",
|
|
79
|
-
padding: "24px 16px",
|
|
80
|
-
flex: 1
|
|
81
|
-
});
|
|
41
|
+
borderBottom: "1px solid var(--color-border-default)"
|
|
42
|
+
};
|
|
43
|
+
var indentedRowStyle = {
|
|
44
|
+
...rowBaseStyle,
|
|
45
|
+
paddingLeft: "32px"
|
|
46
|
+
};
|
|
82
47
|
function sortTasks(tasks) {
|
|
83
48
|
return [...tasks].sort((a, b) => {
|
|
84
49
|
if (b.priority !== a.priority) return b.priority - a.priority;
|
|
@@ -114,65 +79,75 @@ function buildHierarchy(tasks) {
|
|
|
114
79
|
}
|
|
115
80
|
return result;
|
|
116
81
|
}
|
|
117
|
-
function
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
82
|
+
function TaskRowItem({ task, indent, onClick }) {
|
|
83
|
+
const [hovered, setHovered] = useState(false);
|
|
84
|
+
const style = {
|
|
85
|
+
...indent ? indentedRowStyle : rowBaseStyle,
|
|
86
|
+
...hovered ? { backgroundColor: "var(--color-surface-elevated)" } : void 0
|
|
87
|
+
};
|
|
88
|
+
return React.createElement(
|
|
89
|
+
Flex,
|
|
90
|
+
{
|
|
91
|
+
variant: "row-center-start-nowrap-8",
|
|
92
|
+
style,
|
|
93
|
+
onClick,
|
|
94
|
+
onMouseEnter: () => setHovered(true),
|
|
95
|
+
onMouseLeave: () => setHovered(false)
|
|
96
|
+
},
|
|
97
|
+
// Status icon
|
|
98
|
+
React.createElement(StatusIcon, {
|
|
99
|
+
status: statusToIcon[task.status] || "pending",
|
|
100
|
+
size: "sm"
|
|
101
|
+
}),
|
|
102
|
+
// Title
|
|
103
|
+
React.createElement(
|
|
104
|
+
Flex,
|
|
105
|
+
{
|
|
106
|
+
variant: "row-center-start-nowrap-0",
|
|
107
|
+
style: { flex: 1, minWidth: 0 }
|
|
108
|
+
},
|
|
123
109
|
React.createElement(Typography, {
|
|
124
110
|
variant: "caption-regular",
|
|
125
|
-
color: "color-text-subtle"
|
|
126
|
-
|
|
127
|
-
|
|
111
|
+
color: task.status === "cancelled" ? "color-text-subtle" : "color-text-high",
|
|
112
|
+
truncate: true,
|
|
113
|
+
style: task.status === "cancelled" ? { textDecoration: "line-through", opacity: 0.6 } : void 0
|
|
114
|
+
}, task.title)
|
|
115
|
+
),
|
|
116
|
+
// Assigned profile as Tag
|
|
117
|
+
task.assignedProfile && React.createElement(Tag, {
|
|
118
|
+
size: "small",
|
|
119
|
+
color: "info"
|
|
120
|
+
}, task.assignedProfile),
|
|
121
|
+
// Priority badge (only if > 0)
|
|
122
|
+
task.priority > 0 && React.createElement(Badge, {
|
|
123
|
+
variant: task.priority >= 3 ? "warning" : "info"
|
|
124
|
+
}, `P${task.priority}`)
|
|
125
|
+
);
|
|
126
|
+
}
|
|
127
|
+
function TaskPoolList({ tasks, onTaskClick }) {
|
|
128
|
+
if (!tasks || tasks.length === 0) {
|
|
129
|
+
return React.createElement(EmptyState, {
|
|
130
|
+
icon: "inbox",
|
|
131
|
+
message: "No tasks in the pool."
|
|
132
|
+
});
|
|
128
133
|
}
|
|
129
134
|
const rows = buildHierarchy(tasks);
|
|
130
135
|
return React.createElement(
|
|
131
|
-
|
|
132
|
-
|
|
136
|
+
Flex,
|
|
137
|
+
{
|
|
138
|
+
variant: "column-stretch-start-nowrap-0",
|
|
139
|
+
style: { height: "100%", overflow: "hidden" }
|
|
140
|
+
},
|
|
133
141
|
React.createElement(
|
|
134
142
|
ScrollArea,
|
|
135
143
|
{ style: { flex: 1 } },
|
|
136
144
|
rows.map(
|
|
137
|
-
({ task, indent }) => React.createElement(
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
},
|
|
144
|
-
// Status icon
|
|
145
|
-
React.createElement(StatusIcon, {
|
|
146
|
-
status: statusToIcon[task.status] || "pending",
|
|
147
|
-
size: "sm"
|
|
148
|
-
}),
|
|
149
|
-
// Title
|
|
150
|
-
React.createElement(
|
|
151
|
-
TitleText,
|
|
152
|
-
null,
|
|
153
|
-
React.createElement(Typography, {
|
|
154
|
-
variant: "caption-regular",
|
|
155
|
-
color: statusToColor[task.status] === "color-text-subtle" && task.status === "cancelled" ? "color-text-subtle" : "color-text-high",
|
|
156
|
-
style: task.status === "cancelled" ? { textDecoration: "line-through", opacity: 0.6 } : void 0
|
|
157
|
-
}, task.title)
|
|
158
|
-
),
|
|
159
|
-
// Assigned bots as Tags
|
|
160
|
-
task.assignedBots.length > 0 && React.createElement(
|
|
161
|
-
BotTags,
|
|
162
|
-
null,
|
|
163
|
-
task.assignedBots.map(
|
|
164
|
-
(botId) => React.createElement(Tag, {
|
|
165
|
-
key: botId,
|
|
166
|
-
size: "small",
|
|
167
|
-
color: "info"
|
|
168
|
-
}, botId)
|
|
169
|
-
)
|
|
170
|
-
),
|
|
171
|
-
// Priority badge (only if > 0)
|
|
172
|
-
task.priority > 0 && React.createElement(Badge, {
|
|
173
|
-
variant: task.priority >= 3 ? "warning" : "info"
|
|
174
|
-
}, `P${task.priority}`)
|
|
175
|
-
)
|
|
145
|
+
({ task, indent }) => React.createElement(TaskRowItem, {
|
|
146
|
+
key: task.id,
|
|
147
|
+
task,
|
|
148
|
+
indent,
|
|
149
|
+
onClick: () => onTaskClick(task.id)
|
|
150
|
+
})
|
|
176
151
|
)
|
|
177
152
|
)
|
|
178
153
|
);
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @flowWeaver workflow
|
|
3
|
+
* @node load orchestratorLoadState [position: 200 300]
|
|
4
|
+
* @node route orchestratorRoute [position: 450 300]
|
|
5
|
+
* @node dispatch orchestratorDispatch [position: 700 300]
|
|
6
|
+
* @path Start -> load -> route -> dispatch -> Exit
|
|
7
|
+
* @position Start 0 0
|
|
8
|
+
* @position Exit 1080 0
|
|
9
|
+
* @connect dispatch.results -> Exit.results
|
|
10
|
+
* @param execute [order:-1] - Execute
|
|
11
|
+
* @param projectDir [order:0] - ProjectDir
|
|
12
|
+
* @returns onSuccess [order:-1] - On Success
|
|
13
|
+
* @returns results [order:0] - Results
|
|
14
|
+
*/
|
|
15
|
+
export declare function orchestratorWorkflow(execute: boolean, params: {
|
|
16
|
+
projectDir: string;
|
|
17
|
+
}, __abortSignal__?: AbortSignal): Promise<{
|
|
18
|
+
onSuccess: boolean;
|
|
19
|
+
results: string | null;
|
|
20
|
+
}>;
|
|
21
|
+
//# sourceMappingURL=orchestrator.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"orchestrator.d.ts","sourceRoot":"","sources":["../../src/workflows/orchestrator.ts"],"names":[],"mappings":"AAcA;;;;;;;;;;;;;GAaG;AACH,wBAAsB,oBAAoB,CACxC,OAAO,EAAE,OAAO,EAChB,MAAM,EAAE;IAAE,UAAU,EAAE,MAAM,CAAA;CAAE,EAC9B,eAAe,CAAC,EAAE,WAAW,GAC5B,OAAO,CAAC;IAAE,SAAS,EAAE,OAAO,CAAC;IAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAA;CAAE,CAAC,CA6QzD"}
|
|
@@ -0,0 +1,281 @@
|
|
|
1
|
+
import { orchestratorLoadState } from '../node-types/orchestrator-load-state.js';
|
|
2
|
+
import { orchestratorRoute } from '../node-types/orchestrator-route.js';
|
|
3
|
+
import { orchestratorDispatch } from '../node-types/orchestrator-dispatch.js';
|
|
4
|
+
// @flow-weaver-runtime-start
|
|
5
|
+
// ============================================================================
|
|
6
|
+
// DO NOT EDIT - This section is auto-generated by Flow Weaver
|
|
7
|
+
// ============================================================================
|
|
8
|
+
import { GeneratedExecutionContext, CancellationError } from '@synergenius/flow-weaver/runtime';
|
|
9
|
+
// @flow-weaver-runtime-end
|
|
10
|
+
/**
|
|
11
|
+
* @flowWeaver workflow
|
|
12
|
+
* @node load orchestratorLoadState [position: 200 300]
|
|
13
|
+
* @node route orchestratorRoute [position: 450 300]
|
|
14
|
+
* @node dispatch orchestratorDispatch [position: 700 300]
|
|
15
|
+
* @path Start -> load -> route -> dispatch -> Exit
|
|
16
|
+
* @position Start 0 0
|
|
17
|
+
* @position Exit 1080 0
|
|
18
|
+
* @connect dispatch.results -> Exit.results
|
|
19
|
+
* @param execute [order:-1] - Execute
|
|
20
|
+
* @param projectDir [order:0] - ProjectDir
|
|
21
|
+
* @returns onSuccess [order:-1] - On Success
|
|
22
|
+
* @returns results [order:0] - Results
|
|
23
|
+
*/
|
|
24
|
+
export async function orchestratorWorkflow(execute, params, __abortSignal__) {
|
|
25
|
+
// @flow-weaver-body-start
|
|
26
|
+
// ============================================================================
|
|
27
|
+
// DO NOT EDIT - This section is auto-generated by Flow Weaver
|
|
28
|
+
// Edit the @flowWeaver annotations above to modify workflow behavior
|
|
29
|
+
// ============================================================================
|
|
30
|
+
const __effectiveDebugger__ = typeof __flowWeaverDebugger__ !== 'undefined' ? __flowWeaverDebugger__ : undefined;
|
|
31
|
+
// Recursion depth protection
|
|
32
|
+
const __rd__ = params.__rd__ ?? 0;
|
|
33
|
+
if (__rd__ >= 1000) {
|
|
34
|
+
throw new Error('Max recursion depth exceeded (1000) in workflow "orchestratorWorkflow"');
|
|
35
|
+
}
|
|
36
|
+
const ctx = new GeneratedExecutionContext(true, __effectiveDebugger__, __abortSignal__);
|
|
37
|
+
// Debug controller for step-through debugging and checkpoint/resume
|
|
38
|
+
const __ctrl__ = (typeof globalThis !== 'undefined' && globalThis.__fw_debug_controller__
|
|
39
|
+
? globalThis.__fw_debug_controller__
|
|
40
|
+
: { beforeNode: () => true, afterNode: () => { } });
|
|
41
|
+
const startIdx = ctx.addExecution('Start');
|
|
42
|
+
await ctx.setVariable({ id: 'Start', portName: 'execute', executionIndex: startIdx, nodeTypeName: 'Start' }, execute);
|
|
43
|
+
await ctx.setVariable({ id: 'Start', portName: 'projectDir', executionIndex: startIdx, nodeTypeName: 'Start' }, params.projectDir);
|
|
44
|
+
await ctx.sendStatusChangedEvent({
|
|
45
|
+
nodeTypeName: 'Start',
|
|
46
|
+
id: 'Start',
|
|
47
|
+
executionIndex: startIdx,
|
|
48
|
+
status: 'SUCCEEDED',
|
|
49
|
+
});
|
|
50
|
+
let loadIdx;
|
|
51
|
+
let routeIdx;
|
|
52
|
+
let dispatchIdx;
|
|
53
|
+
let load_success = false;
|
|
54
|
+
let route_success = false;
|
|
55
|
+
if (await __ctrl__.beforeNode('load', ctx)) {
|
|
56
|
+
// ── load (orchestratorLoadState) ──
|
|
57
|
+
ctx.checkAborted('load');
|
|
58
|
+
loadIdx = ctx.addExecution('load');
|
|
59
|
+
if (typeof globalThis !== 'undefined')
|
|
60
|
+
globalThis.__fw_current_node_id__ = 'load';
|
|
61
|
+
await ctx.sendStatusChangedEvent({
|
|
62
|
+
nodeTypeName: 'orchestratorLoadState',
|
|
63
|
+
id: 'load',
|
|
64
|
+
executionIndex: loadIdx,
|
|
65
|
+
status: 'RUNNING',
|
|
66
|
+
});
|
|
67
|
+
load_success = false;
|
|
68
|
+
try {
|
|
69
|
+
const load_execute = await ctx.getVariable({ id: 'Start', portName: 'execute', executionIndex: startIdx });
|
|
70
|
+
await ctx.setVariable({ id: 'load', portName: 'execute', executionIndex: loadIdx, nodeTypeName: 'orchestratorLoadState' }, load_execute);
|
|
71
|
+
const load_projectDir = await ctx.getVariable({ id: 'Start', portName: 'projectDir', executionIndex: startIdx });
|
|
72
|
+
await ctx.setVariable({ id: 'load', portName: 'projectDir', executionIndex: loadIdx, nodeTypeName: 'orchestratorLoadState' }, load_projectDir);
|
|
73
|
+
const loadResult = await orchestratorLoadState(load_execute, load_projectDir);
|
|
74
|
+
await ctx.setVariable({ id: 'load', portName: 'state', executionIndex: loadIdx, nodeTypeName: 'orchestratorLoadState' }, loadResult.state);
|
|
75
|
+
await ctx.setVariable({ id: 'load', portName: 'onSuccess', executionIndex: loadIdx, nodeTypeName: 'orchestratorLoadState' }, loadResult.onSuccess);
|
|
76
|
+
await ctx.setVariable({ id: 'load', portName: 'onFailure', executionIndex: loadIdx, nodeTypeName: 'orchestratorLoadState' }, loadResult.onFailure);
|
|
77
|
+
await ctx.sendStatusChangedEvent({
|
|
78
|
+
nodeTypeName: 'orchestratorLoadState',
|
|
79
|
+
id: 'load',
|
|
80
|
+
executionIndex: loadIdx,
|
|
81
|
+
status: 'SUCCEEDED',
|
|
82
|
+
});
|
|
83
|
+
await __ctrl__.afterNode('load', ctx);
|
|
84
|
+
load_success = loadResult.onSuccess;
|
|
85
|
+
}
|
|
86
|
+
catch (error) {
|
|
87
|
+
const isCancellation = CancellationError.isCancellationError(error);
|
|
88
|
+
await ctx.sendStatusChangedEvent({
|
|
89
|
+
nodeTypeName: 'orchestratorLoadState',
|
|
90
|
+
id: 'load',
|
|
91
|
+
executionIndex: loadIdx,
|
|
92
|
+
status: isCancellation ? 'CANCELLED' : 'FAILED',
|
|
93
|
+
});
|
|
94
|
+
if (!isCancellation) {
|
|
95
|
+
ctx.sendLogErrorEvent({
|
|
96
|
+
nodeTypeName: 'orchestratorLoadState',
|
|
97
|
+
id: 'load',
|
|
98
|
+
executionIndex: loadIdx,
|
|
99
|
+
error: error instanceof Error ? error.message : String(error),
|
|
100
|
+
});
|
|
101
|
+
await ctx.setVariable({ id: 'load', portName: 'onSuccess', executionIndex: loadIdx, nodeTypeName: 'orchestratorLoadState' }, false);
|
|
102
|
+
await ctx.setVariable({ id: 'load', portName: 'onFailure', executionIndex: loadIdx, nodeTypeName: 'orchestratorLoadState' }, true);
|
|
103
|
+
load_success = false;
|
|
104
|
+
}
|
|
105
|
+
throw error;
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
else {
|
|
109
|
+
loadIdx = ctx.addExecution('load');
|
|
110
|
+
load_success = true;
|
|
111
|
+
}
|
|
112
|
+
if (load_success) {
|
|
113
|
+
if (await __ctrl__.beforeNode('route', ctx)) {
|
|
114
|
+
// ── route (orchestratorRoute) ──
|
|
115
|
+
ctx.checkAborted('route');
|
|
116
|
+
routeIdx = ctx.addExecution('route');
|
|
117
|
+
if (typeof globalThis !== 'undefined')
|
|
118
|
+
globalThis.__fw_current_node_id__ = 'route';
|
|
119
|
+
await ctx.sendStatusChangedEvent({
|
|
120
|
+
nodeTypeName: 'orchestratorRoute',
|
|
121
|
+
id: 'route',
|
|
122
|
+
executionIndex: routeIdx,
|
|
123
|
+
status: 'RUNNING',
|
|
124
|
+
});
|
|
125
|
+
route_success = false;
|
|
126
|
+
try {
|
|
127
|
+
const route_execute = loadIdx !== undefined ? await ctx.getVariable({ id: 'load', portName: 'onSuccess', executionIndex: loadIdx }) : false;
|
|
128
|
+
await ctx.setVariable({ id: 'route', portName: 'execute', executionIndex: routeIdx, nodeTypeName: 'orchestratorRoute' }, route_execute);
|
|
129
|
+
const route_state = await ctx.getVariable({ id: 'load', portName: 'state', executionIndex: loadIdx });
|
|
130
|
+
await ctx.setVariable({ id: 'route', portName: 'state', executionIndex: routeIdx, nodeTypeName: 'orchestratorRoute' }, route_state);
|
|
131
|
+
const routeResult = await orchestratorRoute(route_execute, route_state);
|
|
132
|
+
await ctx.setVariable({ id: 'route', portName: 'decisions', executionIndex: routeIdx, nodeTypeName: 'orchestratorRoute' }, routeResult.decisions);
|
|
133
|
+
await ctx.setVariable({ id: 'route', portName: 'onSuccess', executionIndex: routeIdx, nodeTypeName: 'orchestratorRoute' }, routeResult.onSuccess);
|
|
134
|
+
await ctx.setVariable({ id: 'route', portName: 'onFailure', executionIndex: routeIdx, nodeTypeName: 'orchestratorRoute' }, routeResult.onFailure);
|
|
135
|
+
await ctx.sendStatusChangedEvent({
|
|
136
|
+
nodeTypeName: 'orchestratorRoute',
|
|
137
|
+
id: 'route',
|
|
138
|
+
executionIndex: routeIdx,
|
|
139
|
+
status: 'SUCCEEDED',
|
|
140
|
+
});
|
|
141
|
+
await __ctrl__.afterNode('route', ctx);
|
|
142
|
+
route_success = routeResult.onSuccess;
|
|
143
|
+
}
|
|
144
|
+
catch (error) {
|
|
145
|
+
const isCancellation = CancellationError.isCancellationError(error);
|
|
146
|
+
await ctx.sendStatusChangedEvent({
|
|
147
|
+
nodeTypeName: 'orchestratorRoute',
|
|
148
|
+
id: 'route',
|
|
149
|
+
executionIndex: routeIdx,
|
|
150
|
+
status: isCancellation ? 'CANCELLED' : 'FAILED',
|
|
151
|
+
});
|
|
152
|
+
if (!isCancellation) {
|
|
153
|
+
ctx.sendLogErrorEvent({
|
|
154
|
+
nodeTypeName: 'orchestratorRoute',
|
|
155
|
+
id: 'route',
|
|
156
|
+
executionIndex: routeIdx,
|
|
157
|
+
error: error instanceof Error ? error.message : String(error),
|
|
158
|
+
});
|
|
159
|
+
await ctx.setVariable({ id: 'route', portName: 'onSuccess', executionIndex: routeIdx, nodeTypeName: 'orchestratorRoute' }, false);
|
|
160
|
+
await ctx.setVariable({ id: 'route', portName: 'onFailure', executionIndex: routeIdx, nodeTypeName: 'orchestratorRoute' }, true);
|
|
161
|
+
route_success = false;
|
|
162
|
+
}
|
|
163
|
+
throw error;
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
else {
|
|
167
|
+
routeIdx = ctx.addExecution('route');
|
|
168
|
+
route_success = true;
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
else {
|
|
172
|
+
const routeIdx = ctx.addExecution('route');
|
|
173
|
+
await ctx.setVariable({ id: 'route', portName: 'onSuccess', executionIndex: routeIdx, nodeTypeName: 'orchestratorRoute' }, false);
|
|
174
|
+
await ctx.setVariable({ id: 'route', portName: 'onFailure', executionIndex: routeIdx, nodeTypeName: 'orchestratorRoute' }, false);
|
|
175
|
+
await ctx.sendStatusChangedEvent({
|
|
176
|
+
nodeTypeName: 'orchestratorRoute',
|
|
177
|
+
id: 'route',
|
|
178
|
+
executionIndex: routeIdx,
|
|
179
|
+
status: 'CANCELLED',
|
|
180
|
+
});
|
|
181
|
+
const dispatchIdx = ctx.addExecution('dispatch');
|
|
182
|
+
await ctx.setVariable({ id: 'dispatch', portName: 'onSuccess', executionIndex: dispatchIdx, nodeTypeName: 'orchestratorDispatch' }, false);
|
|
183
|
+
await ctx.setVariable({ id: 'dispatch', portName: 'onFailure', executionIndex: dispatchIdx, nodeTypeName: 'orchestratorDispatch' }, false);
|
|
184
|
+
await ctx.sendStatusChangedEvent({
|
|
185
|
+
nodeTypeName: 'orchestratorDispatch',
|
|
186
|
+
id: 'dispatch',
|
|
187
|
+
executionIndex: dispatchIdx,
|
|
188
|
+
status: 'CANCELLED',
|
|
189
|
+
});
|
|
190
|
+
}
|
|
191
|
+
if (load_success && route_success) {
|
|
192
|
+
if (await __ctrl__.beforeNode('dispatch', ctx)) {
|
|
193
|
+
// ── dispatch (orchestratorDispatch) ──
|
|
194
|
+
ctx.checkAborted('dispatch');
|
|
195
|
+
dispatchIdx = ctx.addExecution('dispatch');
|
|
196
|
+
if (typeof globalThis !== 'undefined')
|
|
197
|
+
globalThis.__fw_current_node_id__ = 'dispatch';
|
|
198
|
+
await ctx.sendStatusChangedEvent({
|
|
199
|
+
nodeTypeName: 'orchestratorDispatch',
|
|
200
|
+
id: 'dispatch',
|
|
201
|
+
executionIndex: dispatchIdx,
|
|
202
|
+
status: 'RUNNING',
|
|
203
|
+
});
|
|
204
|
+
try {
|
|
205
|
+
const dispatch_execute = routeIdx !== undefined ? await ctx.getVariable({ id: 'route', portName: 'onSuccess', executionIndex: routeIdx }) : false;
|
|
206
|
+
await ctx.setVariable({ id: 'dispatch', portName: 'execute', executionIndex: dispatchIdx, nodeTypeName: 'orchestratorDispatch' }, dispatch_execute);
|
|
207
|
+
const dispatch_decisions = await ctx.getVariable({ id: 'route', portName: 'decisions', executionIndex: routeIdx });
|
|
208
|
+
await ctx.setVariable({ id: 'dispatch', portName: 'decisions', executionIndex: dispatchIdx, nodeTypeName: 'orchestratorDispatch' }, dispatch_decisions);
|
|
209
|
+
const dispatch_projectDir = await ctx.getVariable({ id: 'Start', portName: 'projectDir', executionIndex: startIdx });
|
|
210
|
+
await ctx.setVariable({ id: 'dispatch', portName: 'projectDir', executionIndex: dispatchIdx, nodeTypeName: 'orchestratorDispatch' }, dispatch_projectDir);
|
|
211
|
+
const dispatchResult = await orchestratorDispatch(dispatch_execute, dispatch_decisions, dispatch_projectDir);
|
|
212
|
+
await ctx.setVariable({ id: 'dispatch', portName: 'results', executionIndex: dispatchIdx, nodeTypeName: 'orchestratorDispatch' }, dispatchResult.results);
|
|
213
|
+
await ctx.setVariable({ id: 'dispatch', portName: 'onSuccess', executionIndex: dispatchIdx, nodeTypeName: 'orchestratorDispatch' }, dispatchResult.onSuccess);
|
|
214
|
+
await ctx.setVariable({ id: 'dispatch', portName: 'onFailure', executionIndex: dispatchIdx, nodeTypeName: 'orchestratorDispatch' }, dispatchResult.onFailure);
|
|
215
|
+
await ctx.sendStatusChangedEvent({
|
|
216
|
+
nodeTypeName: 'orchestratorDispatch',
|
|
217
|
+
id: 'dispatch',
|
|
218
|
+
executionIndex: dispatchIdx,
|
|
219
|
+
status: 'SUCCEEDED',
|
|
220
|
+
});
|
|
221
|
+
await __ctrl__.afterNode('dispatch', ctx);
|
|
222
|
+
}
|
|
223
|
+
catch (error) {
|
|
224
|
+
const isCancellation = CancellationError.isCancellationError(error);
|
|
225
|
+
await ctx.sendStatusChangedEvent({
|
|
226
|
+
nodeTypeName: 'orchestratorDispatch',
|
|
227
|
+
id: 'dispatch',
|
|
228
|
+
executionIndex: dispatchIdx,
|
|
229
|
+
status: isCancellation ? 'CANCELLED' : 'FAILED',
|
|
230
|
+
});
|
|
231
|
+
if (!isCancellation) {
|
|
232
|
+
ctx.sendLogErrorEvent({
|
|
233
|
+
nodeTypeName: 'orchestratorDispatch',
|
|
234
|
+
id: 'dispatch',
|
|
235
|
+
executionIndex: dispatchIdx,
|
|
236
|
+
error: error instanceof Error ? error.message : String(error),
|
|
237
|
+
});
|
|
238
|
+
await ctx.setVariable({ id: 'dispatch', portName: 'onSuccess', executionIndex: dispatchIdx, nodeTypeName: 'orchestratorDispatch' }, false);
|
|
239
|
+
await ctx.setVariable({ id: 'dispatch', portName: 'onFailure', executionIndex: dispatchIdx, nodeTypeName: 'orchestratorDispatch' }, true);
|
|
240
|
+
}
|
|
241
|
+
throw error;
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
else {
|
|
245
|
+
dispatchIdx = ctx.addExecution('dispatch');
|
|
246
|
+
}
|
|
247
|
+
}
|
|
248
|
+
else {
|
|
249
|
+
const dispatchIdx = ctx.addExecution('dispatch');
|
|
250
|
+
await ctx.setVariable({ id: 'dispatch', portName: 'onSuccess', executionIndex: dispatchIdx, nodeTypeName: 'orchestratorDispatch' }, false);
|
|
251
|
+
await ctx.setVariable({ id: 'dispatch', portName: 'onFailure', executionIndex: dispatchIdx, nodeTypeName: 'orchestratorDispatch' }, false);
|
|
252
|
+
await ctx.sendStatusChangedEvent({
|
|
253
|
+
nodeTypeName: 'orchestratorDispatch',
|
|
254
|
+
id: 'dispatch',
|
|
255
|
+
executionIndex: dispatchIdx,
|
|
256
|
+
status: 'CANCELLED',
|
|
257
|
+
});
|
|
258
|
+
}
|
|
259
|
+
const exitIdx = ctx.addExecution('Exit');
|
|
260
|
+
const exit_results = dispatchIdx !== undefined ? await ctx.getVariable({ id: 'dispatch', portName: 'results', executionIndex: dispatchIdx }) : undefined;
|
|
261
|
+
await ctx.setVariable({ id: 'Exit', portName: 'results', executionIndex: exitIdx, nodeTypeName: 'Exit' }, exit_results);
|
|
262
|
+
const exit_onSuccess = dispatchIdx !== undefined ? await ctx.getVariable({ id: 'dispatch', portName: 'onSuccess', executionIndex: dispatchIdx }) : false;
|
|
263
|
+
await ctx.setVariable({ id: 'Exit', portName: 'onSuccess', executionIndex: exitIdx, nodeTypeName: 'Exit' }, exit_onSuccess);
|
|
264
|
+
await ctx.setVariable({ id: 'Exit', portName: 'onFailure', executionIndex: exitIdx, nodeTypeName: 'Exit' }, false);
|
|
265
|
+
const finalResult = { onFailure: false, results: exit_results, onSuccess: exit_onSuccess };
|
|
266
|
+
await ctx.sendStatusChangedEvent({
|
|
267
|
+
nodeTypeName: 'Exit',
|
|
268
|
+
id: 'Exit',
|
|
269
|
+
executionIndex: exitIdx,
|
|
270
|
+
status: 'SUCCEEDED',
|
|
271
|
+
});
|
|
272
|
+
ctx.sendWorkflowCompletedEvent({
|
|
273
|
+
executionIndex: exitIdx,
|
|
274
|
+
status: 'SUCCEEDED',
|
|
275
|
+
result: finalResult,
|
|
276
|
+
});
|
|
277
|
+
return finalResult;
|
|
278
|
+
// @flow-weaver-body-end
|
|
279
|
+
return { onSuccess: false, results: null };
|
|
280
|
+
}
|
|
281
|
+
//# sourceMappingURL=orchestrator.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"orchestrator.js","sourceRoot":"","sources":["../../src/workflows/orchestrator.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,qBAAqB,EAAE,MAAM,0CAA0C,CAAC;AACjF,OAAO,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AACxE,OAAO,EAAE,oBAAoB,EAAE,MAAM,wCAAwC,CAAC;AAE9E,6BAA6B;AAC7B,+EAA+E;AAC/E,8DAA8D;AAC9D,+EAA+E;AAE/E,OAAO,EAAE,yBAAyB,EAAE,iBAAiB,EAAE,MAAM,kCAAkC,CAAC;AAGhG,2BAA2B;AAE3B;;;;;;;;;;;;;GAaG;AACH,MAAM,CAAC,KAAK,UAAU,oBAAoB,CACxC,OAAgB,EAChB,MAA8B,EAC9B,eAA6B;IAE7B,0BAA0B;IAC1B,+EAA+E;IAC/E,8DAA8D;IAC9D,qEAAqE;IACrE,+EAA+E;IAE7E,MAAM,qBAAqB,GAAG,OAAO,sBAAsB,KAAK,WAAW,CAAC,CAAC,CAAC,sBAAsB,CAAC,CAAC,CAAC,SAAS,CAAC;IAEjH,6BAA6B;IAC7B,MAAM,MAAM,GAAI,MAA8B,CAAC,MAAM,IAAI,CAAC,CAAC;IAC3D,IAAI,MAAM,IAAI,IAAI,EAAE,CAAC;QACnB,MAAM,IAAI,KAAK,CAAC,wEAAwE,CAAC,CAAC;IAC5F,CAAC;IAED,MAAM,GAAG,GAAG,IAAI,yBAAyB,CAAC,IAAI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Ac,EAAE,OAAO,EAAE,YAAY,EAAE,MAAM,EAAE,EAAE,KAAK,CAAC,CAAC;IACnH,MAAM,WAAW,GAAG,EAAE,SAAS,EAAE,KAAK,EAAE,OAAO,EAAE,YAAsB,EAAE,SAAS,EAAE,cAAyB,EAAE,CAAC;IAEhH,MAAM,GAAG,CAAC,sBAAsB,CAAC;QAC/B,YAAY,EAAE,MAAM;QACpB,EAAE,EAAE,MAAM;QACV,cAAc,EAAE,OAAO;QACvB,MAAM,EAAE,WAAW;KACpB,CAAC,CAAC;IACH,GAAG,CAAC,0BAA0B,CAAC;QAC7B,cAAc,EAAE,OAAO;QACvB,MAAM,EAAE,WAAW;QACnB,MAAM,EAAE,WAAW;KACpB,CAAC,CAAC;IAEH,OAAO,WAAW,CAAC;IACrB,wBAAwB;IACxB,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;AAC7C,CAAC"}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Session mode bot. Continuously polls the task queue and processes
|
|
3
|
+
* tasks through the full bot pipeline.
|
|
4
|
+
*
|
|
5
|
+
* @flowWeaver workflow
|
|
6
|
+
*
|
|
7
|
+
* @node cfg weaverLoadConfig [color: "teal"] [icon: "settings"] [position: 80 200]
|
|
8
|
+
* @node detect weaverDetectProvider [color: "cyan"] [icon: "search"] [position: 230 200]
|
|
9
|
+
* @node receive weaverReceiveTask [color: "blue"] [icon: "send"] [position: 400 200]
|
|
10
|
+
* @node route weaverRouteTask [color: "purple"] [icon: "flow"] [position: 570 200]
|
|
11
|
+
* @node readWf weaverReadWorkflow [color: "cyan"] [icon: "description"] [position: 740 450]
|
|
12
|
+
* @node context weaverBuildContext [color: "teal"] [icon: "code"] [position: 740 200]
|
|
13
|
+
* @node plan weaverPlanTask [color: "blue"] [icon: "psychology"] [position: 910 200]
|
|
14
|
+
* @node approve weaverApprovalGate [color: "orange"] [icon: "send"] [position: 1080 200]
|
|
15
|
+
* @node abort weaverAbortTask [color: "red"] [icon: "code"] [position: 1250 450]
|
|
16
|
+
* @node execRetry weaverExecValidateRetry [color: "purple"] [icon: "code"] [position: 1250 200]
|
|
17
|
+
* @node gitOps weaverGitOps [color: "green"] [icon: "code"] [position: 1420 100]
|
|
18
|
+
* @node notify weaverSendNotify [color: "yellow"] [icon: "send"] [position: 1420 300]
|
|
19
|
+
* @node report weaverBotReport [color: "green"] [icon: "description"] [position: 1600 200]
|
|
20
|
+
*
|
|
21
|
+
* @path Start -> cfg -> detect -> receive -> route -> context -> plan -> approve -> execRetry -> gitOps -> report -> Exit
|
|
22
|
+
* @path execRetry -> notify
|
|
23
|
+
* @path route:fail -> readWf
|
|
24
|
+
* @path approve:fail -> abort
|
|
25
|
+
*
|
|
26
|
+
* @connect readWf.onSuccess -> report.execute
|
|
27
|
+
* @connect abort.onSuccess -> report.execute
|
|
28
|
+
* @connect notify.onSuccess -> report.execute
|
|
29
|
+
*
|
|
30
|
+
* @connect route.taskJson -> readWf.taskJson
|
|
31
|
+
* @connect route.projectDir -> readWf.projectDir
|
|
32
|
+
* @connect readWf.resultJson -> report.readResult
|
|
33
|
+
*
|
|
34
|
+
* @connect context.contextBundle -> plan.contextBundle
|
|
35
|
+
*
|
|
36
|
+
* @connect approve.rejectionReason -> abort.rejectionReason
|
|
37
|
+
* @connect approve.taskJson -> abort.taskJson
|
|
38
|
+
* @connect approve.projectDir -> abort.projectDir
|
|
39
|
+
* @connect abort.resultJson -> report.abortResult
|
|
40
|
+
*
|
|
41
|
+
* @connect execRetry.resultJson -> notify.resultJson
|
|
42
|
+
* @connect execRetry.projectDir -> notify.targetPath
|
|
43
|
+
*
|
|
44
|
+
* @connect execRetry.resultJson -> report.mainResult
|
|
45
|
+
* @connect execRetry.filesModified -> report.filesModified
|
|
46
|
+
* @connect gitOps.gitResultJson -> report.gitResultJson
|
|
47
|
+
*
|
|
48
|
+
* @connect report.summary -> Exit.summary
|
|
49
|
+
*
|
|
50
|
+
* @position Start 0 200
|
|
51
|
+
* @position Exit 1750 200
|
|
52
|
+
*
|
|
53
|
+
* @param execute [order:-1] - Execute
|
|
54
|
+
* @param taskJson [order:0] [optional] - Task instruction (JSON)
|
|
55
|
+
* @param projectDir [order:1] [optional] - Project directory
|
|
56
|
+
* @returns onSuccess [order:-2] - On Success
|
|
57
|
+
* @returns onFailure [order:-1] - On Failure
|
|
58
|
+
* @returns summary [order:0] - Summary text
|
|
59
|
+
*/
|
|
60
|
+
export declare function weaverBotSession(execute: boolean, taskJson?: string, projectDir?: string, __abortSignal__?: AbortSignal): Promise<{
|
|
61
|
+
onSuccess: boolean;
|
|
62
|
+
onFailure: boolean;
|
|
63
|
+
summary: string | null;
|
|
64
|
+
}>;
|
|
65
|
+
//# sourceMappingURL=weaver-bot-session.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"weaver-bot-session.d.ts","sourceRoot":"","sources":["../../src/workflows/weaver-bot-session.ts"],"names":[],"mappings":"AAiBA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0DG;AACH,wBAAsB,gBAAgB,CACpC,OAAO,EAAE,OAAO,EAChB,QAAQ,CAAC,EAAE,MAAM,EACjB,UAAU,CAAC,EAAE,MAAM,EACnB,eAAe,CAAC,EAAE,WAAW,GAC5B,OAAO,CAAC;IAAE,SAAS,EAAE,OAAO,CAAC;IAAC,SAAS,EAAE,OAAO,CAAC;IAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAA;CAAE,CAAC,CAK7E"}
|