@fieldwangai/agentflow 0.1.25
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/LICENSE +21 -0
- package/README.md +201 -0
- package/README.zh-CN.md +201 -0
- package/agents/agentflow-node-executor-code.md +32 -0
- package/agents/agentflow-node-executor-planning.md +32 -0
- package/agents/agentflow-node-executor-requirement.md +32 -0
- package/agents/agentflow-node-executor-test.md +32 -0
- package/agents/agentflow-node-executor-ui.md +32 -0
- package/agents/agentflow-node-executor.md +32 -0
- package/agents/agents.json +8 -0
- package/agents/en/agentflow-node-executor.md +32 -0
- package/agents/zh/agentflow-node-executor.md +32 -0
- package/bin/agentflow.mjs +52 -0
- package/bin/ensure-workspace-reference.mjs +35 -0
- package/bin/lib/agent-runners.mjs +1199 -0
- package/bin/lib/agents-path.mjs +61 -0
- package/bin/lib/api-runner.mjs +361 -0
- package/bin/lib/apply.mjs +852 -0
- package/bin/lib/catalog-agents.mjs +300 -0
- package/bin/lib/catalog-flows.mjs +532 -0
- package/bin/lib/composer-agent.mjs +884 -0
- package/bin/lib/composer-flow-instances.mjs +68 -0
- package/bin/lib/composer-flow-skeleton.mjs +334 -0
- package/bin/lib/composer-flow-validate.mjs +47 -0
- package/bin/lib/composer-log.mjs +197 -0
- package/bin/lib/composer-model-router.mjs +160 -0
- package/bin/lib/composer-node-schema.mjs +299 -0
- package/bin/lib/composer-planner.mjs +749 -0
- package/bin/lib/composer-script-ops.mjs +233 -0
- package/bin/lib/composer-skill-router.mjs +384 -0
- package/bin/lib/flow-import.mjs +305 -0
- package/bin/lib/flow-normalize.mjs +71 -0
- package/bin/lib/flow-write.mjs +395 -0
- package/bin/lib/help.mjs +139 -0
- package/bin/lib/hub-login.mjs +54 -0
- package/bin/lib/hub-publish.mjs +159 -0
- package/bin/lib/hub-remote.mjs +189 -0
- package/bin/lib/hub.mjs +299 -0
- package/bin/lib/i18n.mjs +233 -0
- package/bin/lib/locales/en.json +344 -0
- package/bin/lib/locales/zh.json +344 -0
- package/bin/lib/log.mjs +37 -0
- package/bin/lib/main.mjs +611 -0
- package/bin/lib/model-config.mjs +118 -0
- package/bin/lib/model-lists.mjs +188 -0
- package/bin/lib/node-exec-context.mjs +336 -0
- package/bin/lib/node-execute.mjs +513 -0
- package/bin/lib/normalize-node-tool-command.mjs +97 -0
- package/bin/lib/paths.mjs +216 -0
- package/bin/lib/pipeline-scripts.mjs +41 -0
- package/bin/lib/recent-runs.mjs +173 -0
- package/bin/lib/run-apply-active-lock.mjs +82 -0
- package/bin/lib/run-events.mjs +85 -0
- package/bin/lib/run-node-statuses-from-disk.mjs +85 -0
- package/bin/lib/schedule-config.mjs +227 -0
- package/bin/lib/scheduler.mjs +312 -0
- package/bin/lib/table.mjs +4 -0
- package/bin/lib/terminal.mjs +42 -0
- package/bin/lib/ui-print.mjs +94 -0
- package/bin/lib/ui-server.mjs +2113 -0
- package/bin/lib/workspace-tree.mjs +266 -0
- package/bin/lib/workspace.mjs +180 -0
- package/bin/pipeline/build-node-prompt.mjs +179 -0
- package/bin/pipeline/check-cache.mjs +191 -0
- package/bin/pipeline/check-flow.mjs +543 -0
- package/bin/pipeline/collect-nodes.mjs +212 -0
- package/bin/pipeline/compute-cache-md5.mjs +177 -0
- package/bin/pipeline/ensure-run-dir.mjs +71 -0
- package/bin/pipeline/extract-thinking.mjs +308 -0
- package/bin/pipeline/gc.mjs +129 -0
- package/bin/pipeline/get-env.mjs +83 -0
- package/bin/pipeline/get-exec-id.mjs +145 -0
- package/bin/pipeline/get-ready-nodes.mjs +435 -0
- package/bin/pipeline/get-resolved-values.mjs +337 -0
- package/bin/pipeline/load-key.mjs +62 -0
- package/bin/pipeline/parse-bool.mjs +33 -0
- package/bin/pipeline/parse-flow.mjs +698 -0
- package/bin/pipeline/post-process-control-if.mjs +23 -0
- package/bin/pipeline/post-process-node.mjs +490 -0
- package/bin/pipeline/pre-process-node.mjs +449 -0
- package/bin/pipeline/resolve-inputs.mjs +201 -0
- package/bin/pipeline/run-log.mjs +34 -0
- package/bin/pipeline/run-tool-nodejs.mjs +160 -0
- package/bin/pipeline/save-key.mjs +93 -0
- package/bin/pipeline/snapshot-prior-round.mjs +70 -0
- package/bin/pipeline/validate-flow.mjs +825 -0
- package/bin/pipeline/validate-for-ui.mjs +226 -0
- package/bin/pipeline/validate-script-output.mjs +130 -0
- package/bin/pipeline/write-result.mjs +182 -0
- package/builtin/nodes/agent_subAgent.md +14 -0
- package/builtin/nodes/control_agent_toBool.md +20 -0
- package/builtin/nodes/control_anyOne.md +17 -0
- package/builtin/nodes/control_end.md +11 -0
- package/builtin/nodes/control_if.md +20 -0
- package/builtin/nodes/control_start.md +11 -0
- package/builtin/nodes/control_toBool.md +21 -0
- package/builtin/nodes/provide_file.md +11 -0
- package/builtin/nodes/provide_str.md +11 -0
- package/builtin/nodes/tool_get_env.md +14 -0
- package/builtin/nodes/tool_load_key.md +20 -0
- package/builtin/nodes/tool_nodejs.md +40 -0
- package/builtin/nodes/tool_print.md +14 -0
- package/builtin/nodes/tool_save_key.md +20 -0
- package/builtin/nodes/tool_user_ask.md +23 -0
- package/builtin/nodes/tool_user_check.md +22 -0
- package/builtin/pipelines/module-migrate/flow.yaml +819 -0
- package/builtin/pipelines/module-migrate/scripts/check_imports.mjs +700 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/Makefile +362 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/Release/.deps/Release/obj.target/node_modules/node-addon-api/node_addon_api_except.stamp.d +1 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/Release/.deps/Release/obj.target/tree_sitter_kotlin_binding/bindings/node/binding.o.d +17 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/Release/.deps/Release/obj.target/tree_sitter_kotlin_binding/src/parser.o.d +5 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/Release/.deps/Release/obj.target/tree_sitter_kotlin_binding/src/scanner.o.d +8 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/Release/.deps/Release/tree_sitter_kotlin_binding.node.d +1 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/Release/obj.target/node_modules/node-addon-api/node_addon_api_except.stamp +0 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/Release/obj.target/tree_sitter_kotlin_binding/bindings/node/binding.o +0 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/Release/obj.target/tree_sitter_kotlin_binding/src/parser.o +0 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/Release/obj.target/tree_sitter_kotlin_binding/src/scanner.o +0 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/Release/tree_sitter_kotlin_binding.node +0 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/binding.Makefile +6 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/gyp-mac-tool +768 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/node_modules/node-addon-api/node_addon_api.Makefile +6 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/node_modules/node-addon-api/node_addon_api.target.mk +122 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/node_modules/node-addon-api/node_addon_api_except.target.mk +126 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/node_modules/node-addon-api/node_addon_api_maybe.target.mk +122 -0
- package/builtin/pipelines/module-migrate/scripts/node_modules/tree-sitter-kotlin/build/tree_sitter_kotlin_binding.target.mk +203 -0
- package/builtin/pipelines/new/flow.yaml +545 -0
- package/builtin/pipelines/new/scripts/check-flow.mjs +9 -0
- package/builtin/pipelines/new/scripts/collect-nodes.mjs +211 -0
- package/builtin/pipelines/scripts/adjust-node-positions.mjs +113 -0
- package/builtin/web-ui/dist/agentflow-icon.svg +23 -0
- package/builtin/web-ui/dist/assets/index-CZkUPcXE.css +1 -0
- package/builtin/web-ui/dist/assets/index-DkkhNESc.js +190 -0
- package/builtin/web-ui/dist/index.html +24 -0
- package/package.json +67 -0
- package/reference/flow-control-capabilities.md +274 -0
- package/reference/flow-layout.md +84 -0
- package/reference/flow-prompt-handler-check.md +12 -0
- package/reference/flow-result-semantics.md +14 -0
|
@@ -0,0 +1,819 @@
|
|
|
1
|
+
instances:
|
|
2
|
+
start:
|
|
3
|
+
definitionId: control_start
|
|
4
|
+
label: Start
|
|
5
|
+
modelType: Auto
|
|
6
|
+
input: []
|
|
7
|
+
output:
|
|
8
|
+
- type: node
|
|
9
|
+
name: next
|
|
10
|
+
value: ""
|
|
11
|
+
body: Flow entry
|
|
12
|
+
scope:
|
|
13
|
+
definitionId: agent_subAgent
|
|
14
|
+
label: Define Migration Scope
|
|
15
|
+
modelType: Auto
|
|
16
|
+
input:
|
|
17
|
+
- type: node
|
|
18
|
+
name: prev
|
|
19
|
+
value: ""
|
|
20
|
+
output:
|
|
21
|
+
- type: node
|
|
22
|
+
name: next
|
|
23
|
+
value: ""
|
|
24
|
+
- type: file
|
|
25
|
+
name: node_scope_filelist.md
|
|
26
|
+
value: ""
|
|
27
|
+
- type: text
|
|
28
|
+
name: moduleName
|
|
29
|
+
value: ""
|
|
30
|
+
body: |-
|
|
31
|
+
Based on .cursor/rules/android-module-structure.mdc and module-main-sub-dependency.mdc,
|
|
32
|
+
determine Push module migration scope (iHeima/src/main/java/com/yy/iheima/push/),
|
|
33
|
+
list files to migrate, output to {node_scope_filelist.md}.
|
|
34
|
+
Also create module name in English abbreviation, write to ${moduleName}
|
|
35
|
+
user_confirm_scope:
|
|
36
|
+
definitionId: tool_user_check
|
|
37
|
+
label: User Confirm Scope
|
|
38
|
+
modelType: Auto
|
|
39
|
+
input:
|
|
40
|
+
- type: node
|
|
41
|
+
name: prev
|
|
42
|
+
value: ""
|
|
43
|
+
output:
|
|
44
|
+
- type: node
|
|
45
|
+
name: next
|
|
46
|
+
value: ""
|
|
47
|
+
body: ""
|
|
48
|
+
migrate:
|
|
49
|
+
definitionId: agent_subAgent
|
|
50
|
+
label: Execute Migration
|
|
51
|
+
modelType: Auto
|
|
52
|
+
input:
|
|
53
|
+
- type: node
|
|
54
|
+
name: prev
|
|
55
|
+
value: ""
|
|
56
|
+
- type: file
|
|
57
|
+
name: node_scope_filelist.md
|
|
58
|
+
value: ""
|
|
59
|
+
output:
|
|
60
|
+
- type: node
|
|
61
|
+
name: next
|
|
62
|
+
value: ""
|
|
63
|
+
- type: file
|
|
64
|
+
name: result.md
|
|
65
|
+
value: ""
|
|
66
|
+
body: Based on migration scope ${node_scope_filelist.md}, execute migration (code/resource move only, no business logic changes). Can allocate multiple agents in parallel for migration only, no checks. Output migrated file list to ${result.md}
|
|
67
|
+
anyOne_static:
|
|
68
|
+
definitionId: control_anyOne
|
|
69
|
+
label: AnyOne (Static Loop Entry)
|
|
70
|
+
modelType: Auto
|
|
71
|
+
input:
|
|
72
|
+
- type: node
|
|
73
|
+
name: prev1
|
|
74
|
+
value: ""
|
|
75
|
+
- type: node
|
|
76
|
+
name: prev2
|
|
77
|
+
value: ""
|
|
78
|
+
output:
|
|
79
|
+
- type: node
|
|
80
|
+
name: next
|
|
81
|
+
value: ""
|
|
82
|
+
body: ""
|
|
83
|
+
anyOne_gradle:
|
|
84
|
+
definitionId: control_anyOne
|
|
85
|
+
label: AnyOne (Compile Loop Entry)
|
|
86
|
+
modelType: Auto
|
|
87
|
+
input:
|
|
88
|
+
- type: node
|
|
89
|
+
name: prev1
|
|
90
|
+
value: ""
|
|
91
|
+
- type: node
|
|
92
|
+
name: prev2
|
|
93
|
+
value: ""
|
|
94
|
+
output:
|
|
95
|
+
- type: node
|
|
96
|
+
name: next
|
|
97
|
+
value: ""
|
|
98
|
+
body: Enter compilation after static checks pass or spec is confirmed
|
|
99
|
+
ai_check_ref:
|
|
100
|
+
definitionId: agent_subAgent
|
|
101
|
+
label: AI Check References
|
|
102
|
+
modelType: Auto
|
|
103
|
+
input:
|
|
104
|
+
- type: node
|
|
105
|
+
name: prev
|
|
106
|
+
value: ""
|
|
107
|
+
- type: file
|
|
108
|
+
name: todo
|
|
109
|
+
value: ""
|
|
110
|
+
- type: file
|
|
111
|
+
name: done
|
|
112
|
+
value: ""
|
|
113
|
+
output:
|
|
114
|
+
- type: node
|
|
115
|
+
name: next
|
|
116
|
+
value: ""
|
|
117
|
+
- type: file
|
|
118
|
+
name: result
|
|
119
|
+
value: ""
|
|
120
|
+
body: "File list before migration ${todo}, file list after migration ${done}. Refer to .cursor/rules/module-main-sub-dependency.mdc, check if main module has direct dependencies on migrated classes. If found, list to ${result} with format: error reference module code location line number to referenced FQCN"
|
|
121
|
+
agent_sum_error:
|
|
122
|
+
definitionId: agent_subAgent
|
|
123
|
+
label: Summarize Issues
|
|
124
|
+
modelType: Auto
|
|
125
|
+
input:
|
|
126
|
+
- type: node
|
|
127
|
+
name: prev
|
|
128
|
+
value: ""
|
|
129
|
+
- type: file
|
|
130
|
+
name: err1
|
|
131
|
+
value: ""
|
|
132
|
+
- type: file
|
|
133
|
+
name: err2
|
|
134
|
+
value: ""
|
|
135
|
+
output:
|
|
136
|
+
- type: node
|
|
137
|
+
name: next
|
|
138
|
+
value: ""
|
|
139
|
+
- type: file
|
|
140
|
+
name: todo.md
|
|
141
|
+
value: ""
|
|
142
|
+
body: |
|
|
143
|
+
Merge static check results ${err1}, AI check results ${err2}.
|
|
144
|
+
Refer to .cursor/rules/module-main-sub-dependency.mdc.
|
|
145
|
+
For classes found by static and AI checks, use API relay to provide to main module.
|
|
146
|
+
Create TODO list in - [ ] format (detailed list), output to ${todo.md}
|
|
147
|
+
gradle_build:
|
|
148
|
+
definitionId: agent_subAgent
|
|
149
|
+
label: Gradle Build
|
|
150
|
+
modelType: Auto
|
|
151
|
+
input:
|
|
152
|
+
- type: node
|
|
153
|
+
name: prev
|
|
154
|
+
value: ""
|
|
155
|
+
- type: file
|
|
156
|
+
name: tasks
|
|
157
|
+
value: ""
|
|
158
|
+
output:
|
|
159
|
+
- type: node
|
|
160
|
+
name: next
|
|
161
|
+
value: ""
|
|
162
|
+
- type: file
|
|
163
|
+
name: result
|
|
164
|
+
value: ""
|
|
165
|
+
- type: file
|
|
166
|
+
name: name.md
|
|
167
|
+
value: ""
|
|
168
|
+
body: "From ${tasks}, batch get incomplete build tasks, execute compilation serially one by one, do not batch multiple tasks at once. If build passes, update ${tasks} document (check off). If build fails, write compilation error to ${result.md}, failed task name list to ${name.md}. Gradle execution time may be long (over 10min), wait for completion.\nNote: Set node status to true here, compilation issues unified handled by subsequent nodes."
|
|
169
|
+
fix_dynamic:
|
|
170
|
+
definitionId: agent_subAgent
|
|
171
|
+
label: Fix Build Issues
|
|
172
|
+
modelType: Auto
|
|
173
|
+
input:
|
|
174
|
+
- type: node
|
|
175
|
+
name: prev
|
|
176
|
+
value: ""
|
|
177
|
+
- type: file
|
|
178
|
+
name: todo.md
|
|
179
|
+
value: ""
|
|
180
|
+
- type: file
|
|
181
|
+
name: result.md
|
|
182
|
+
value: ""
|
|
183
|
+
- type: file
|
|
184
|
+
name: name.md
|
|
185
|
+
value: ""
|
|
186
|
+
output:
|
|
187
|
+
- type: node
|
|
188
|
+
name: next
|
|
189
|
+
value: ""
|
|
190
|
+
body: For failed tasks ${name.md}, fix issues recorded in ${result.md} and retry build. If fixed and passes, update task list ${todo.md} and check off
|
|
191
|
+
output_doc:
|
|
192
|
+
definitionId: agent_subAgent
|
|
193
|
+
label: Output Document
|
|
194
|
+
modelType: Auto
|
|
195
|
+
input:
|
|
196
|
+
- type: node
|
|
197
|
+
name: prev
|
|
198
|
+
value: ""
|
|
199
|
+
output:
|
|
200
|
+
- type: node
|
|
201
|
+
name: next
|
|
202
|
+
value: ""
|
|
203
|
+
body: Output migration and fix document
|
|
204
|
+
end:
|
|
205
|
+
definitionId: control_end
|
|
206
|
+
label: End
|
|
207
|
+
modelType: Auto
|
|
208
|
+
input:
|
|
209
|
+
- type: node
|
|
210
|
+
name: prev
|
|
211
|
+
value: ""
|
|
212
|
+
output: []
|
|
213
|
+
body: Flow exit
|
|
214
|
+
provide_key_ready_file:
|
|
215
|
+
definitionId: provide_str
|
|
216
|
+
label: KeyReadyFile
|
|
217
|
+
userDescription: Provides key name for migration file list in global storage (ready_file). Downstream SaveKey writes migration scope result using this key, LoadKey reads with same key.
|
|
218
|
+
modelType: Auto
|
|
219
|
+
input: []
|
|
220
|
+
output:
|
|
221
|
+
- type: text
|
|
222
|
+
name: value
|
|
223
|
+
value: ready_file
|
|
224
|
+
body: ""
|
|
225
|
+
provide_key_module_name:
|
|
226
|
+
definitionId: provide_str
|
|
227
|
+
label: KeyModuleName
|
|
228
|
+
userDescription: Provides key name for module name in global storage (moduleName). Downstream SaveKey writes new module name using this key, other nodes can LoadKey to read.
|
|
229
|
+
modelType: Auto
|
|
230
|
+
input: []
|
|
231
|
+
output:
|
|
232
|
+
- type: text
|
|
233
|
+
name: value
|
|
234
|
+
value: moduleName
|
|
235
|
+
body: ""
|
|
236
|
+
tool_save_ready_file:
|
|
237
|
+
definitionId: tool_save_key
|
|
238
|
+
label: Ready Files List
|
|
239
|
+
description: "由 agentflow apply 流程内部执行。命令:agentflow apply -ai run-tool-nodejs <workspaceRoot> <flowName> <uuid> <instanceId> <execId> -- node <path>/save-key.mjs <workspaceRoot> <flowName> <uuid> <key> <value>。返回(stdout 一行 JSON):{ \\\"err_code\\\": 0, \\\"message\\\": { \\\"result\\\": \\\"<写入的 value>\\\" } }(err_code 0=成功 1=失败)。"
|
|
240
|
+
modelType: Auto
|
|
241
|
+
input:
|
|
242
|
+
- type: node
|
|
243
|
+
name: prev
|
|
244
|
+
value: ""
|
|
245
|
+
- type: text
|
|
246
|
+
name: key
|
|
247
|
+
value: ready_file
|
|
248
|
+
- type: file
|
|
249
|
+
name: value
|
|
250
|
+
value: ""
|
|
251
|
+
output: []
|
|
252
|
+
body: ""
|
|
253
|
+
tool_save_module_name:
|
|
254
|
+
definitionId: tool_save_key
|
|
255
|
+
label: Module Name
|
|
256
|
+
description: "由 agentflow apply 流程内部执行。命令:agentflow apply -ai run-tool-nodejs <workspaceRoot> <flowName> <uuid> <instanceId> <execId> -- node <path>/save-key.mjs <workspaceRoot> <flowName> <uuid> <key> <value>。返回(stdout 一行 JSON):{ \\\"err_code\\\": 0, \\\"message\\\": { \\\"result\\\": \\\"<写入的 value>\\\" } }(err_code 0=成功 1=失败)。"
|
|
257
|
+
modelType: Auto
|
|
258
|
+
input:
|
|
259
|
+
- type: node
|
|
260
|
+
name: prev
|
|
261
|
+
value: ""
|
|
262
|
+
- type: text
|
|
263
|
+
name: key
|
|
264
|
+
value: moduleName
|
|
265
|
+
- type: text
|
|
266
|
+
name: value
|
|
267
|
+
value: ""
|
|
268
|
+
output: []
|
|
269
|
+
body: ""
|
|
270
|
+
agent_new_module:
|
|
271
|
+
definitionId: agent_subAgent
|
|
272
|
+
label: Create Module
|
|
273
|
+
modelType: Auto
|
|
274
|
+
input:
|
|
275
|
+
- type: node
|
|
276
|
+
name: prev
|
|
277
|
+
value: ""
|
|
278
|
+
- type: text
|
|
279
|
+
name: moduleName
|
|
280
|
+
value: ""
|
|
281
|
+
output:
|
|
282
|
+
- type: node
|
|
283
|
+
name: next
|
|
284
|
+
value: ""
|
|
285
|
+
body: 参考模块结构文档.cursor/rules/android-module-structure.mdc,新建模块名称为 ${moduleName},新建module和module_api。
|
|
286
|
+
tool_static_analy:
|
|
287
|
+
definitionId: tool_nodejs
|
|
288
|
+
label: Static Analysis
|
|
289
|
+
description: "|"
|
|
290
|
+
modelType: Auto
|
|
291
|
+
input:
|
|
292
|
+
- type: node
|
|
293
|
+
name: prev
|
|
294
|
+
value: ""
|
|
295
|
+
- type: file
|
|
296
|
+
name: todo
|
|
297
|
+
value: ""
|
|
298
|
+
- type: file
|
|
299
|
+
name: done
|
|
300
|
+
value: ""
|
|
301
|
+
output:
|
|
302
|
+
- type: node
|
|
303
|
+
name: next
|
|
304
|
+
value: ""
|
|
305
|
+
- type: file
|
|
306
|
+
name: result
|
|
307
|
+
value: ""
|
|
308
|
+
body: |
|
|
309
|
+
.workspace/agentflow/pipelines/live-module-migrate/scripts/check_imports.mjs
|
|
310
|
+
|
|
311
|
+
File list before migration ${todo}, file list after migration ${done}, error reference module code location line number to referenced FQCN
|
|
312
|
+
if_static:
|
|
313
|
+
definitionId: control_if
|
|
314
|
+
label: If Static Check
|
|
315
|
+
modelType: Auto
|
|
316
|
+
input:
|
|
317
|
+
- type: node
|
|
318
|
+
name: prev
|
|
319
|
+
value: ""
|
|
320
|
+
- type: bool
|
|
321
|
+
name: prediction
|
|
322
|
+
value: ""
|
|
323
|
+
output:
|
|
324
|
+
- type: node
|
|
325
|
+
name: next1
|
|
326
|
+
value: ""
|
|
327
|
+
- type: node
|
|
328
|
+
name: next2
|
|
329
|
+
value: ""
|
|
330
|
+
body: ${prediction}
|
|
331
|
+
LoadFile:
|
|
332
|
+
definitionId: tool_load_key
|
|
333
|
+
label: Migration File List
|
|
334
|
+
description: "由 agentflow apply 流程内部执行。命令:agentflow apply -ai run-tool-nodejs <workspaceRoot> <flowName> <uuid> <instanceId> <execId> -- node <path>/load-key.mjs <workspaceRoot> <flowName> <uuid> <key>。返回(stdout 一行 JSON):{ \\\"err_code\\\": 0, \\\"message\\\": { \\\"result\\\": \\\"<value>\\\" } }(err_code 0=成功 1=失败);result 写入节点的 result 槽位。"
|
|
335
|
+
modelType: Auto
|
|
336
|
+
input: []
|
|
337
|
+
output:
|
|
338
|
+
- type: file
|
|
339
|
+
name: result
|
|
340
|
+
value: ready_file
|
|
341
|
+
body: ""
|
|
342
|
+
agent_fix_todo:
|
|
343
|
+
definitionId: agent_subAgent
|
|
344
|
+
label: Fix TODO Items
|
|
345
|
+
modelType: Auto
|
|
346
|
+
input:
|
|
347
|
+
- type: node
|
|
348
|
+
name: prev
|
|
349
|
+
value: ""
|
|
350
|
+
- type: file
|
|
351
|
+
name: todo.md
|
|
352
|
+
value: ""
|
|
353
|
+
output:
|
|
354
|
+
- type: node
|
|
355
|
+
name: next
|
|
356
|
+
value: ""
|
|
357
|
+
body: |
|
|
358
|
+
Batch get TODO items from ${todo.md} and fix them.
|
|
359
|
+
Fix rule: For places directly using module classes, use SPI (corresponding API module) as relay.
|
|
360
|
+
This round try to batch process: fix multiple items in one batch when dependencies allow.
|
|
361
|
+
After fix is complete, check off the items fixed this batch in ${todo.md}.
|
|
362
|
+
control_toBool_static_bool:
|
|
363
|
+
definitionId: control_toBool
|
|
364
|
+
label: Static Check Result Conversion
|
|
365
|
+
modelType: Auto
|
|
366
|
+
input:
|
|
367
|
+
- type: node
|
|
368
|
+
name: prev
|
|
369
|
+
value: ""
|
|
370
|
+
- type: file
|
|
371
|
+
name: err1
|
|
372
|
+
value: ""
|
|
373
|
+
- type: file
|
|
374
|
+
name: err2
|
|
375
|
+
value: ""
|
|
376
|
+
output:
|
|
377
|
+
- type: node
|
|
378
|
+
name: next
|
|
379
|
+
value: ""
|
|
380
|
+
- type: bool
|
|
381
|
+
name: prediction
|
|
382
|
+
value: ""
|
|
383
|
+
body: If both ${err1} and ${err2} are OK, then true; otherwise false
|
|
384
|
+
control_if_task_gradle:
|
|
385
|
+
definitionId: control_if
|
|
386
|
+
label: If Task Complete
|
|
387
|
+
modelType: Auto
|
|
388
|
+
input:
|
|
389
|
+
- type: node
|
|
390
|
+
name: prev
|
|
391
|
+
value: ""
|
|
392
|
+
- type: bool
|
|
393
|
+
name: prediction
|
|
394
|
+
value: ""
|
|
395
|
+
output:
|
|
396
|
+
- type: node
|
|
397
|
+
name: next1
|
|
398
|
+
value: ""
|
|
399
|
+
- type: node
|
|
400
|
+
name: next2
|
|
401
|
+
value: ""
|
|
402
|
+
body: ${prediction}
|
|
403
|
+
control_toBool_gradle_bool:
|
|
404
|
+
definitionId: control_toBool
|
|
405
|
+
label: List Complete Result
|
|
406
|
+
modelType: Auto
|
|
407
|
+
input:
|
|
408
|
+
- type: node
|
|
409
|
+
name: prev
|
|
410
|
+
value: ""
|
|
411
|
+
- type: file
|
|
412
|
+
name: tasks
|
|
413
|
+
value: ""
|
|
414
|
+
output:
|
|
415
|
+
- type: node
|
|
416
|
+
name: next
|
|
417
|
+
value: ""
|
|
418
|
+
- type: bool
|
|
419
|
+
name: prediction
|
|
420
|
+
value: ""
|
|
421
|
+
body: ${tasks} 全部打勾完成,则为true。存在 - [ ]则为false
|
|
422
|
+
control_if_fixed:
|
|
423
|
+
definitionId: control_if
|
|
424
|
+
label: If Fix Complete
|
|
425
|
+
modelType: Auto
|
|
426
|
+
input:
|
|
427
|
+
- type: node
|
|
428
|
+
name: prev
|
|
429
|
+
value: ""
|
|
430
|
+
- type: bool
|
|
431
|
+
name: prediction
|
|
432
|
+
value: ""
|
|
433
|
+
output:
|
|
434
|
+
- type: node
|
|
435
|
+
name: next1
|
|
436
|
+
value: ""
|
|
437
|
+
- type: node
|
|
438
|
+
name: next2
|
|
439
|
+
value: ""
|
|
440
|
+
body: ""
|
|
441
|
+
to_bool_fix_all:
|
|
442
|
+
definitionId: control_toBool
|
|
443
|
+
label: Check If All Fixed
|
|
444
|
+
modelType: Auto
|
|
445
|
+
input:
|
|
446
|
+
- type: node
|
|
447
|
+
name: prev
|
|
448
|
+
value: ""
|
|
449
|
+
- type: file
|
|
450
|
+
name: todo.md
|
|
451
|
+
value: ""
|
|
452
|
+
output:
|
|
453
|
+
- type: node
|
|
454
|
+
name: next
|
|
455
|
+
value: ""
|
|
456
|
+
- type: bool
|
|
457
|
+
name: prediction
|
|
458
|
+
value: ""
|
|
459
|
+
body: |
|
|
460
|
+
Check ${todo.md} for - [ ] items. If all completed, then true; if any - [ ] exists, then false
|
|
461
|
+
control_anyOne_start_fix:
|
|
462
|
+
definitionId: control_anyOne
|
|
463
|
+
label: Fix Entry
|
|
464
|
+
modelType: Auto
|
|
465
|
+
input:
|
|
466
|
+
- type: node
|
|
467
|
+
name: prev1
|
|
468
|
+
value: ""
|
|
469
|
+
- type: node
|
|
470
|
+
name: prev2
|
|
471
|
+
value: ""
|
|
472
|
+
output:
|
|
473
|
+
- type: node
|
|
474
|
+
name: next
|
|
475
|
+
value: ""
|
|
476
|
+
body: ""
|
|
477
|
+
tool_print_module:
|
|
478
|
+
definitionId: tool_print
|
|
479
|
+
label: Print Summary
|
|
480
|
+
modelType: Auto
|
|
481
|
+
input:
|
|
482
|
+
- type: node
|
|
483
|
+
name: prev
|
|
484
|
+
value: ""
|
|
485
|
+
- type: file
|
|
486
|
+
name: move.md
|
|
487
|
+
value: ""
|
|
488
|
+
- type: text
|
|
489
|
+
name: moduleName
|
|
490
|
+
value: ""
|
|
491
|
+
output: []
|
|
492
|
+
body: Show confirmation, module name ${moduleName}, migration scope ${move.md}
|
|
493
|
+
gradle_tasks:
|
|
494
|
+
definitionId: agent_subAgent
|
|
495
|
+
label: Get Java/Kotlin Build Tasks
|
|
496
|
+
modelType: Auto
|
|
497
|
+
input:
|
|
498
|
+
- type: node
|
|
499
|
+
name: prev
|
|
500
|
+
value: ""
|
|
501
|
+
output:
|
|
502
|
+
- type: node
|
|
503
|
+
name: next
|
|
504
|
+
value: ""
|
|
505
|
+
- type: file
|
|
506
|
+
name: gradletask.md
|
|
507
|
+
value: ""
|
|
508
|
+
body: Use gradle task to get build tasks, filter Java and Kotlin compile tasks, only need debug tasks. Record to ${gradletask.md} as - [ ] list
|
|
509
|
+
edges:
|
|
510
|
+
- source: start
|
|
511
|
+
target: scope
|
|
512
|
+
sourceHandle: output-0
|
|
513
|
+
targetHandle: input-0
|
|
514
|
+
- source: scope
|
|
515
|
+
target: user_confirm_scope
|
|
516
|
+
sourceHandle: output-0
|
|
517
|
+
targetHandle: input-0
|
|
518
|
+
- source: migrate
|
|
519
|
+
target: anyOne_static
|
|
520
|
+
sourceHandle: output-0
|
|
521
|
+
targetHandle: input-0
|
|
522
|
+
- source: output_doc
|
|
523
|
+
target: end
|
|
524
|
+
sourceHandle: output-0
|
|
525
|
+
targetHandle: input-0
|
|
526
|
+
- source: scope
|
|
527
|
+
target: migrate
|
|
528
|
+
sourceHandle: output-1
|
|
529
|
+
targetHandle: input-1
|
|
530
|
+
- source: provide_key_ready_file
|
|
531
|
+
target: tool_save_ready_file
|
|
532
|
+
sourceHandle: output-0
|
|
533
|
+
targetHandle: input-1
|
|
534
|
+
- source: provide_key_module_name
|
|
535
|
+
target: tool_save_module_name
|
|
536
|
+
sourceHandle: output-0
|
|
537
|
+
targetHandle: input-1
|
|
538
|
+
- source: scope
|
|
539
|
+
target: tool_save_ready_file
|
|
540
|
+
sourceHandle: output-1
|
|
541
|
+
targetHandle: input-2
|
|
542
|
+
- source: scope
|
|
543
|
+
target: tool_save_module_name
|
|
544
|
+
sourceHandle: output-2
|
|
545
|
+
targetHandle: input-2
|
|
546
|
+
- source: scope
|
|
547
|
+
target: agent_new_module
|
|
548
|
+
sourceHandle: output-2
|
|
549
|
+
targetHandle: input-1
|
|
550
|
+
- source: user_confirm_scope
|
|
551
|
+
target: agent_new_module
|
|
552
|
+
sourceHandle: output-0
|
|
553
|
+
targetHandle: input-0
|
|
554
|
+
- source: agent_new_module
|
|
555
|
+
target: migrate
|
|
556
|
+
sourceHandle: output-0
|
|
557
|
+
targetHandle: input-0
|
|
558
|
+
- source: anyOne_static
|
|
559
|
+
target: tool_static_analy
|
|
560
|
+
sourceHandle: output-0
|
|
561
|
+
targetHandle: input-0
|
|
562
|
+
- source: if_static
|
|
563
|
+
target: agent_sum_error
|
|
564
|
+
sourceHandle: output-1
|
|
565
|
+
targetHandle: input-0
|
|
566
|
+
- source: anyOne_static
|
|
567
|
+
target: ai_check_ref
|
|
568
|
+
sourceHandle: output-0
|
|
569
|
+
targetHandle: input-0
|
|
570
|
+
- source: migrate
|
|
571
|
+
target: tool_static_analy
|
|
572
|
+
sourceHandle: output-1
|
|
573
|
+
targetHandle: input-2
|
|
574
|
+
- source: migrate
|
|
575
|
+
target: ai_check_ref
|
|
576
|
+
sourceHandle: output-1
|
|
577
|
+
targetHandle: input-2
|
|
578
|
+
- source: LoadFile
|
|
579
|
+
target: tool_static_analy
|
|
580
|
+
sourceHandle: output-0
|
|
581
|
+
targetHandle: input-1
|
|
582
|
+
- source: LoadFile
|
|
583
|
+
target: ai_check_ref
|
|
584
|
+
sourceHandle: output-0
|
|
585
|
+
targetHandle: input-1
|
|
586
|
+
- source: tool_static_analy
|
|
587
|
+
target: agent_sum_error
|
|
588
|
+
sourceHandle: output-1
|
|
589
|
+
targetHandle: input-1
|
|
590
|
+
- source: ai_check_ref
|
|
591
|
+
target: agent_sum_error
|
|
592
|
+
sourceHandle: output-1
|
|
593
|
+
targetHandle: input-2
|
|
594
|
+
- source: fix_dynamic
|
|
595
|
+
target: anyOne_gradle
|
|
596
|
+
sourceHandle: output-0
|
|
597
|
+
targetHandle: input-1
|
|
598
|
+
- source: agent_sum_error
|
|
599
|
+
target: agent_fix_todo
|
|
600
|
+
sourceHandle: output-1
|
|
601
|
+
targetHandle: input-1
|
|
602
|
+
- source: tool_static_analy
|
|
603
|
+
target: control_toBool_static_bool
|
|
604
|
+
sourceHandle: output-1
|
|
605
|
+
targetHandle: input-1
|
|
606
|
+
- source: ai_check_ref
|
|
607
|
+
target: control_toBool_static_bool
|
|
608
|
+
sourceHandle: output-1
|
|
609
|
+
targetHandle: input-2
|
|
610
|
+
- source: control_toBool_static_bool
|
|
611
|
+
target: if_static
|
|
612
|
+
sourceHandle: output-0
|
|
613
|
+
targetHandle: input-0
|
|
614
|
+
- source: control_toBool_static_bool
|
|
615
|
+
target: if_static
|
|
616
|
+
sourceHandle: output-1
|
|
617
|
+
targetHandle: input-1
|
|
618
|
+
- source: control_toBool_gradle_bool
|
|
619
|
+
target: control_if_task_gradle
|
|
620
|
+
sourceHandle: output-0
|
|
621
|
+
targetHandle: input-0
|
|
622
|
+
- source: control_toBool_gradle_bool
|
|
623
|
+
target: control_if_task_gradle
|
|
624
|
+
sourceHandle: output-1
|
|
625
|
+
targetHandle: input-1
|
|
626
|
+
- source: control_if_task_gradle
|
|
627
|
+
target: output_doc
|
|
628
|
+
sourceHandle: output-0
|
|
629
|
+
targetHandle: input-0
|
|
630
|
+
- source: tool_static_analy
|
|
631
|
+
target: control_toBool_static_bool
|
|
632
|
+
sourceHandle: output-0
|
|
633
|
+
targetHandle: input-0
|
|
634
|
+
- source: ai_check_ref
|
|
635
|
+
target: control_toBool_static_bool
|
|
636
|
+
sourceHandle: output-0
|
|
637
|
+
targetHandle: input-0
|
|
638
|
+
- source: agent_sum_error
|
|
639
|
+
target: to_bool_fix_all
|
|
640
|
+
sourceHandle: output-1
|
|
641
|
+
targetHandle: input-1
|
|
642
|
+
- source: to_bool_fix_all
|
|
643
|
+
target: control_if_fixed
|
|
644
|
+
sourceHandle: output-0
|
|
645
|
+
targetHandle: input-0
|
|
646
|
+
- source: to_bool_fix_all
|
|
647
|
+
target: control_if_fixed
|
|
648
|
+
sourceHandle: output-1
|
|
649
|
+
targetHandle: input-1
|
|
650
|
+
- source: control_if_fixed
|
|
651
|
+
target: anyOne_static
|
|
652
|
+
sourceHandle: output-0
|
|
653
|
+
targetHandle: input-1
|
|
654
|
+
- source: control_if_fixed
|
|
655
|
+
target: agent_fix_todo
|
|
656
|
+
sourceHandle: output-1
|
|
657
|
+
targetHandle: input-0
|
|
658
|
+
- source: agent_sum_error
|
|
659
|
+
target: control_anyOne_start_fix
|
|
660
|
+
sourceHandle: output-0
|
|
661
|
+
targetHandle: input-0
|
|
662
|
+
- source: control_anyOne_start_fix
|
|
663
|
+
target: to_bool_fix_all
|
|
664
|
+
sourceHandle: output-0
|
|
665
|
+
targetHandle: input-0
|
|
666
|
+
- source: agent_fix_todo
|
|
667
|
+
target: control_anyOne_start_fix
|
|
668
|
+
sourceHandle: output-0
|
|
669
|
+
targetHandle: input-1
|
|
670
|
+
- source: user_confirm_scope
|
|
671
|
+
target: tool_save_ready_file
|
|
672
|
+
sourceHandle: output-0
|
|
673
|
+
targetHandle: input-0
|
|
674
|
+
- source: user_confirm_scope
|
|
675
|
+
target: tool_save_module_name
|
|
676
|
+
sourceHandle: output-0
|
|
677
|
+
targetHandle: input-0
|
|
678
|
+
- source: scope
|
|
679
|
+
target: tool_print_module
|
|
680
|
+
sourceHandle: output-0
|
|
681
|
+
targetHandle: input-0
|
|
682
|
+
- source: scope
|
|
683
|
+
target: tool_print_module
|
|
684
|
+
sourceHandle: output-1
|
|
685
|
+
targetHandle: input-1
|
|
686
|
+
- source: scope
|
|
687
|
+
target: tool_print_module
|
|
688
|
+
sourceHandle: output-2
|
|
689
|
+
targetHandle: input-2
|
|
690
|
+
- source: if_static
|
|
691
|
+
target: gradle_tasks
|
|
692
|
+
sourceHandle: output-0
|
|
693
|
+
targetHandle: input-0
|
|
694
|
+
- source: gradle_tasks
|
|
695
|
+
target: control_toBool_gradle_bool
|
|
696
|
+
sourceHandle: output-1
|
|
697
|
+
targetHandle: input-1
|
|
698
|
+
- source: control_if_task_gradle
|
|
699
|
+
target: gradle_build
|
|
700
|
+
sourceHandle: output-1
|
|
701
|
+
targetHandle: input-0
|
|
702
|
+
- source: gradle_tasks
|
|
703
|
+
target: gradle_build
|
|
704
|
+
sourceHandle: output-1
|
|
705
|
+
targetHandle: input-1
|
|
706
|
+
- source: gradle_tasks
|
|
707
|
+
target: anyOne_gradle
|
|
708
|
+
sourceHandle: output-0
|
|
709
|
+
targetHandle: input-0
|
|
710
|
+
- source: anyOne_gradle
|
|
711
|
+
target: control_toBool_gradle_bool
|
|
712
|
+
sourceHandle: output-0
|
|
713
|
+
targetHandle: input-0
|
|
714
|
+
- source: gradle_build
|
|
715
|
+
target: fix_dynamic
|
|
716
|
+
sourceHandle: output-0
|
|
717
|
+
targetHandle: input-0
|
|
718
|
+
- source: gradle_tasks
|
|
719
|
+
target: fix_dynamic
|
|
720
|
+
sourceHandle: output-1
|
|
721
|
+
targetHandle: input-1
|
|
722
|
+
- source: gradle_build
|
|
723
|
+
target: fix_dynamic
|
|
724
|
+
sourceHandle: output-1
|
|
725
|
+
targetHandle: input-2
|
|
726
|
+
- source: gradle_build
|
|
727
|
+
target: fix_dynamic
|
|
728
|
+
sourceHandle: output-2
|
|
729
|
+
targetHandle: input-3
|
|
730
|
+
ui:
|
|
731
|
+
nodePositions:
|
|
732
|
+
start:
|
|
733
|
+
x: -311.3935985808113
|
|
734
|
+
"y": 189.33364422573482
|
|
735
|
+
scope:
|
|
736
|
+
x: -135.59616803985895
|
|
737
|
+
"y": 211.03635446635394
|
|
738
|
+
user_confirm_scope:
|
|
739
|
+
x: 118.68285057110319
|
|
740
|
+
"y": 142.67635535924276
|
|
741
|
+
migrate:
|
|
742
|
+
x: 454.43850887412776
|
|
743
|
+
"y": 293.0722303284743
|
|
744
|
+
anyOne_static:
|
|
745
|
+
x: 636.3356270792144
|
|
746
|
+
"y": 179.57780273715775
|
|
747
|
+
anyOne_gradle:
|
|
748
|
+
x: 1570.44781075025
|
|
749
|
+
"y": 36.43514363175286
|
|
750
|
+
ai_check_ref:
|
|
751
|
+
x: 854.0561083522535
|
|
752
|
+
"y": 230.27105761112705
|
|
753
|
+
agent_sum_error:
|
|
754
|
+
x: 1160.1179147475261
|
|
755
|
+
"y": 283.6990353598391
|
|
756
|
+
gradle_build:
|
|
757
|
+
x: 1697.6091606175742
|
|
758
|
+
"y": 240.16117248977295
|
|
759
|
+
fix_dynamic:
|
|
760
|
+
x: 1921.9082328859263
|
|
761
|
+
"y": 222.03164153416796
|
|
762
|
+
output_doc:
|
|
763
|
+
x: 2281.6461618332573
|
|
764
|
+
"y": 76.22938367968048
|
|
765
|
+
end:
|
|
766
|
+
x: 2438.643154035482
|
|
767
|
+
"y": 73.16499995993682
|
|
768
|
+
provide_key_ready_file:
|
|
769
|
+
x: 50
|
|
770
|
+
"y": 345.1735104800173
|
|
771
|
+
provide_key_module_name:
|
|
772
|
+
x: 50
|
|
773
|
+
"y": 451.2111504138263
|
|
774
|
+
tool_save_ready_file:
|
|
775
|
+
x: 243.14605812665633
|
|
776
|
+
"y": 345.1735104800173
|
|
777
|
+
tool_save_module_name:
|
|
778
|
+
x: 181.79122152352866
|
|
779
|
+
"y": 451.2111504138263
|
|
780
|
+
agent_new_module:
|
|
781
|
+
x: 311.615164633856
|
|
782
|
+
"y": 167.5175115653564
|
|
783
|
+
tool_static_analy:
|
|
784
|
+
x: 864.4439310076101
|
|
785
|
+
"y": 102.57258522623499
|
|
786
|
+
if_static:
|
|
787
|
+
x: 1187.5325527060475
|
|
788
|
+
"y": 158.54100448104072
|
|
789
|
+
LoadFile:
|
|
790
|
+
x: 668.4525351443111
|
|
791
|
+
"y": 101.68838590400665
|
|
792
|
+
agent_fix_todo:
|
|
793
|
+
x: 1270.1528621363257
|
|
794
|
+
"y": 473.19951644552344
|
|
795
|
+
control_toBool_static_bool:
|
|
796
|
+
x: 1025.1588449783735
|
|
797
|
+
"y": 150.89465569823832
|
|
798
|
+
control_if_task_gradle:
|
|
799
|
+
x: 2003.5050788426774
|
|
800
|
+
"y": 26.562359179592278
|
|
801
|
+
control_toBool_gradle_bool:
|
|
802
|
+
x: 1793.9521181579876
|
|
803
|
+
"y": 41.97357430969002
|
|
804
|
+
control_if_fixed:
|
|
805
|
+
x: 1044.724858760418
|
|
806
|
+
"y": 464.20322884129985
|
|
807
|
+
to_bool_fix_all:
|
|
808
|
+
x: 846.1471441912821
|
|
809
|
+
"y": 470.79934246403053
|
|
810
|
+
control_anyOne_start_fix:
|
|
811
|
+
x: 646.160998442873
|
|
812
|
+
"y": 452.63622882218414
|
|
813
|
+
tool_print_module:
|
|
814
|
+
x: 114.54056509849403
|
|
815
|
+
"y": -3.3121144881721563
|
|
816
|
+
gradle_tasks:
|
|
817
|
+
x: 1358.5325209278358
|
|
818
|
+
"y": 121.93084682740528
|
|
819
|
+
description: Module migration pipeline (Define scope -> Confirm -> Migrate -> Static loop -> Compile loop -> Output document)
|