@thinkingai/ae-cli 1.0.24 → 1.0.28
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/README.md +17 -2
- package/README.zh.md +18 -2
- package/dist/auth-5NSDQFQB.js +454 -0
- package/dist/{auth-4OPL4YWG.js → auth-H2376DEF.js} +2 -2
- package/dist/chunk-AD5V3ZPJ.js +217 -0
- package/dist/chunk-CAQYQA4R.js +399 -0
- package/dist/{chunk-JJCRURTR.js → chunk-CLJF7MQA.js} +1 -1
- package/dist/chunk-GSJGPNKK.js +49 -0
- package/dist/chunk-IMBKVXKY.js +478 -0
- package/dist/chunk-KAEZTSXN.js +99 -0
- package/dist/{chunk-MZW6NOVS.js → chunk-LU7SXK4Q.js} +27 -8
- package/dist/chunk-OJDNO5QY.js +63 -0
- package/dist/{chunk-DC66L5AM.js → chunk-SRJIAOBN.js} +76 -91
- package/dist/{chunk-OVHL4JAC.js → chunk-WCHI7725.js} +44 -47
- package/dist/{client-TDH6MUWM.js → client-FCMK3XEK.js} +5 -3
- package/dist/config-64G36TJL.js +130 -0
- package/dist/index.js +50 -17
- package/dist/model-EZ6K7FXI.js +134 -0
- package/dist/{raw-EM7AP3RT.js → raw-VEF3D6UD.js} +11 -6
- package/dist/sync-NRODEVNH.js +385 -0
- package/dist/te-agent-7U7JLJKU.js +524 -0
- package/dist/{te-analysis-3KFSNUCJ.js → te-analysis-A2OSGHQ4.js} +136 -20
- package/dist/{te-audience-GMYJFCSC.js → te-audience-LI67PPGO.js} +5 -4
- package/dist/{te-common-YLERCMQI.js → te-common-35WVU3C5.js} +19 -8
- package/dist/{te-community-PYDN5A6B.js → te-community-LEAP6PWT.js} +4 -3
- package/dist/{te-dataops-ETWS5O3X.js → te-dataops-N2LGZBOX.js} +4 -3
- package/dist/{te-engage-ROJVZHDA.js → te-engage-H7C72Z46.js} +105 -49
- package/dist/{te-kb-VUNS2CC7.js → te-kb-I2OKTBAI.js} +225 -29
- package/dist/{te-meta-3EFWLM3A.js → te-meta-HBTIEDRO.js} +4 -3
- package/dist/te-team-EM5OWRQL.js +529 -0
- package/package.json +10 -2
- package/skills/ae-agent/SKILL.md +134 -0
- package/skills/ae-analysis/SKILL.md +1 -1
- package/skills/ae-analysis/references/drilldown_user_events.md +1 -1
- package/skills/ae-analysis/references/drilldown_users.md +2 -2
- package/skills/ae-analysis/references/list_clusters.md +4 -2
- package/skills/ae-analysis/references/query_adhoc.md +3 -2
- package/skills/ae-analysis/references/query_entity_details.md +1 -1
- package/skills/ae-analysis-global/SKILL.md +51 -0
- package/skills/ae-analysis-global/references/list_query_clusters.md +67 -0
- package/skills/ae-community/SKILL.md +2 -3
- package/skills/ae-dataops/SKILL.md +1 -2
- package/skills/ae-engage/SKILL.md +26 -2
- package/skills/ae-engage/references/add-approver.md +0 -1
- package/skills/ae-engage/references/add-channel.md +0 -1
- package/skills/ae-engage/references/approver-list.md +0 -1
- package/skills/ae-engage/references/build-task-save-guide.md +283 -0
- package/skills/ae-engage/references/cancel-query-by-request-id.md +0 -1
- package/skills/ae-engage/references/channel-detail.md +0 -1
- package/skills/ae-engage/references/channel-list.md +0 -1
- package/skills/ae-engage/references/config-channel-detail.md +0 -1
- package/skills/ae-engage/references/config-channel-list.md +0 -1
- package/skills/ae-engage/references/config-item-analysis-report.md +0 -1
- package/skills/ae-engage/references/config-item-detail.md +0 -1
- package/skills/ae-engage/references/config-item-list.md +0 -1
- package/skills/ae-engage/references/config-item-strategy-comparison.md +0 -1
- package/skills/ae-engage/references/config-item-trigger-report.md +0 -1
- package/skills/ae-engage/references/copy-config-template.md +0 -1
- package/skills/ae-engage/references/delete-channel.md +0 -1
- package/skills/ae-engage/references/delete-config-channel.md +0 -1
- package/skills/ae-engage/references/delete-config-item.md +0 -1
- package/skills/ae-engage/references/delete-flow.md +0 -1
- package/skills/ae-engage/references/flow-ab-split-node-report.md +0 -1
- package/skills/ae-engage/references/flow-detail.md +0 -1
- package/skills/ae-engage/references/flow-list.md +0 -1
- package/skills/ae-engage/references/flow-node-config-schema.md +0 -1
- package/skills/ae-engage/references/flow-node-detail-report.md +0 -1
- package/skills/ae-engage/references/flow-node-overview-report.md +0 -1
- package/skills/ae-engage/references/flow-process-report.md +0 -1
- package/skills/ae-engage/references/manage-flow.md +0 -1
- package/skills/ae-engage/references/manage-strategy.md +0 -1
- package/skills/ae-engage/references/manage-task.md +0 -1
- package/skills/ae-engage/references/modify-flow-base-info.md +0 -1
- package/skills/ae-engage/references/save-task.md +304 -0
- package/skills/ae-engage/references/strategy-detail.md +0 -1
- package/skills/ae-engage/references/strategy-list.md +0 -1
- package/skills/ae-engage/references/task-data-detail.md +0 -1
- package/skills/ae-engage/references/task-data-overview.md +0 -1
- package/skills/ae-engage/references/task-detail.md +0 -1
- package/skills/ae-engage/references/task-experiment-report.md +0 -1
- package/skills/ae-engage/references/task-list.md +0 -1
- package/skills/ae-engage/references/task-metric-detail.md +0 -1
- package/skills/ae-engage/references/task-stats.md +0 -1
- package/skills/ae-engage/references/update-channel-status.md +0 -1
- package/skills/ae-engage/references/update-config-channel-status.md +0 -1
- package/skills/ae-engage/references/validate-flow-node-config.md +0 -1
- package/skills/ae-engage/references/whitelist-list.md +0 -1
- package/skills/ae-kb/SKILL.md +284 -0
- package/skills/ae-team/SKILL.md +164 -0
- package/skills/ae-team/references/ai-generate.md +39 -0
- package/skills/ae-team/references/create.md +94 -0
- package/skills/ae-team/references/delete.md +39 -0
- package/skills/ae-team/references/list-projects.md +45 -0
- package/skills/ae-team/references/list-templates.md +38 -0
- package/skills/ae-team/references/list.md +39 -0
- package/skills/ae-team/references/run-artifacts.md +51 -0
- package/skills/ae-team/references/run-cancel.md +38 -0
- package/skills/ae-team/references/run-chat.md +57 -0
- package/skills/ae-team/references/run-reply.md +41 -0
- package/skills/ae-team/references/run-result.md +75 -0
- package/skills/ae-team/references/run-start.md +73 -0
- package/skills/ae-team/references/run-watch.md +82 -0
- package/skills/ae-team/references/update.md +47 -0
- package/dist/auth-PBPAZQWP.js +0 -168
- package/dist/chunk-47MTN54I.js +0 -285
- package/dist/config-5ELRYAIH.js +0 -257
|
@@ -0,0 +1,304 @@
|
|
|
1
|
+
# ae-engage `+save_task`
|
|
2
|
+
|
|
3
|
+
Create or update a Hermes task draft.
|
|
4
|
+
|
|
5
|
+
Mapped command: `ae-cli engage +save_task`
|
|
6
|
+
|
|
7
|
+
This command is the final write step. Do not use it as the first step in task construction.
|
|
8
|
+
|
|
9
|
+
Recommended workflow:
|
|
10
|
+
|
|
11
|
+
1. `ae-cli engage +channel_list --project_id <projectId>`
|
|
12
|
+
2. `ae-cli engage +build_task_save_guide --project_id <projectId> --req '{...}'`
|
|
13
|
+
3. If the guide indicates QP-derived fields are needed, call:
|
|
14
|
+
|
|
15
|
+
```bash
|
|
16
|
+
ae-cli analysis_audience +get_cluster_definition_schema --cluster_type condition
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
4. Build the final grouped `req`
|
|
20
|
+
5. `ae-cli engage +save_task --project_id <projectId> --req '{...}'`
|
|
21
|
+
|
|
22
|
+
The audience schema query is not a fixed preflight step. Call it only when the guide indicates that you must construct:
|
|
23
|
+
|
|
24
|
+
- `targetConfig.qp`
|
|
25
|
+
- `triggerConfig.triggerRule`
|
|
26
|
+
- `clientConfig.clientQp`
|
|
27
|
+
- `completionIndicatorDef.event`
|
|
28
|
+
|
|
29
|
+
For the full guide contract, request format, return sections, and handoff usage, read:
|
|
30
|
+
|
|
31
|
+
- `references/build-task-save-guide.md`
|
|
32
|
+
|
|
33
|
+
---
|
|
34
|
+
|
|
35
|
+
## 1. General Principles
|
|
36
|
+
|
|
37
|
+
`+save_task` accepts only the final grouped draft-save payload that Hermes can validate and persist.
|
|
38
|
+
|
|
39
|
+
The command supports two modes:
|
|
40
|
+
|
|
41
|
+
- create mode: omit `req.taskId`
|
|
42
|
+
- update mode: include `req.taskId` for an existing draft task
|
|
43
|
+
|
|
44
|
+
Regardless of mode, this tool only saves a draft:
|
|
45
|
+
|
|
46
|
+
- it does not submit approval
|
|
47
|
+
- it does not start sending
|
|
48
|
+
- it does not register or start trigger execution
|
|
49
|
+
|
|
50
|
+
The CLI call shape is:
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
ae-cli engage +save_task --project_id <projectId> --req '<req-json>'
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
Notes:
|
|
57
|
+
|
|
58
|
+
- `projectId` is injected into top-level `req` by the CLI
|
|
59
|
+
- if the caller also passes `req.projectId`, the outer `--project_id` wins
|
|
60
|
+
- the whole `req` must be a JSON object, not a stringified JSON string
|
|
61
|
+
- for update mode, Hermes only allows modifying draft tasks
|
|
62
|
+
- in update mode, omitted fields are backfilled from the existing draft before validation, so partial draft updates are allowed
|
|
63
|
+
|
|
64
|
+
---
|
|
65
|
+
|
|
66
|
+
## 2. Required Workflow
|
|
67
|
+
|
|
68
|
+
### 2.1 Query Real Channels First
|
|
69
|
+
|
|
70
|
+
Run:
|
|
71
|
+
|
|
72
|
+
```bash
|
|
73
|
+
ae-cli engage +channel_list --project_id <projectId>
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
Purpose:
|
|
77
|
+
|
|
78
|
+
- get the real project channel list
|
|
79
|
+
- resolve the real `channelId`
|
|
80
|
+
- confirm the final `channelType`
|
|
81
|
+
|
|
82
|
+
Never invent a `channelId`.
|
|
83
|
+
|
|
84
|
+
### 2.2 Build the Scenario Guide
|
|
85
|
+
|
|
86
|
+
Run:
|
|
87
|
+
|
|
88
|
+
```bash
|
|
89
|
+
ae-cli engage +build_task_save_guide --project_id <projectId> --req '{...}'
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
Use the guide to determine:
|
|
93
|
+
|
|
94
|
+
- required grouped blocks
|
|
95
|
+
- required fields for the current trigger and audience mode
|
|
96
|
+
- unsupported combinations
|
|
97
|
+
- correct content schema
|
|
98
|
+
- current handoff template
|
|
99
|
+
- whether the current payload is already close to submit-ready
|
|
100
|
+
|
|
101
|
+
### 2.3 Query Audience Condition Schema Only When Needed
|
|
102
|
+
|
|
103
|
+
If the guide indicates that QP-derived fields are needed, run:
|
|
104
|
+
|
|
105
|
+
```bash
|
|
106
|
+
ae-cli analysis_audience +get_cluster_definition_schema --cluster_type condition
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
Use the returned schema to build:
|
|
110
|
+
|
|
111
|
+
- `targetConfig.qp`
|
|
112
|
+
- `triggerConfig.triggerRule`
|
|
113
|
+
- `clientConfig.clientQp`
|
|
114
|
+
- `completionIndicatorDef.event`
|
|
115
|
+
|
|
116
|
+
Do not call this command by default for every task. It is conditional, not mandatory.
|
|
117
|
+
|
|
118
|
+
### 2.4 Build Final `req` and Save
|
|
119
|
+
|
|
120
|
+
Only after the above steps should you construct the final grouped `req` and submit it with `+save_task`.
|
|
121
|
+
|
|
122
|
+
---
|
|
123
|
+
|
|
124
|
+
## 3. Final `req` Shape
|
|
125
|
+
|
|
126
|
+
The final object passed to `--req` should have this grouped shape:
|
|
127
|
+
|
|
128
|
+
```json
|
|
129
|
+
{
|
|
130
|
+
"taskId": "<string, optional>",
|
|
131
|
+
"baseInfo": {},
|
|
132
|
+
"channelConfig": {},
|
|
133
|
+
"targetConfig": {},
|
|
134
|
+
"triggerConfig": {},
|
|
135
|
+
"controlConfig": {},
|
|
136
|
+
"expConfig": {},
|
|
137
|
+
"activityConfig": {},
|
|
138
|
+
"clientConfig": {}
|
|
139
|
+
}
|
|
140
|
+
```
|
|
141
|
+
|
|
142
|
+
Top-level notes:
|
|
143
|
+
|
|
144
|
+
- `taskId` is used only in update mode
|
|
145
|
+
- `baseInfo` / `channelConfig` / `targetConfig` / `triggerConfig` / `controlConfig` are the main blocks
|
|
146
|
+
- optional blocks should usually be omitted rather than filled with invented values
|
|
147
|
+
- use `build_task_save_guide` output as the source of truth for the current scenario
|
|
148
|
+
|
|
149
|
+
---
|
|
150
|
+
|
|
151
|
+
## 4. How To Build Major Blocks
|
|
152
|
+
|
|
153
|
+
### 4.1 `taskId`
|
|
154
|
+
|
|
155
|
+
Use `taskId` only when you are updating an existing draft task.
|
|
156
|
+
|
|
157
|
+
- create mode: omit `taskId`
|
|
158
|
+
- update mode: include `taskId`
|
|
159
|
+
- update mode can send only the fields that need changing
|
|
160
|
+
- update mode still fails if the referenced task is not in draft status
|
|
161
|
+
|
|
162
|
+
### 4.2 `channelConfig`
|
|
163
|
+
|
|
164
|
+
Core fields:
|
|
165
|
+
|
|
166
|
+
- `channelType`
|
|
167
|
+
- `channelId`
|
|
168
|
+
- `groupContentList`
|
|
169
|
+
- optional `channelTemplateId`
|
|
170
|
+
|
|
171
|
+
Rules:
|
|
172
|
+
|
|
173
|
+
- derive `channelType` and `channelId` from real channel metadata
|
|
174
|
+
- do not guess template IDs
|
|
175
|
+
- `groupContentList` maximum size is `5`
|
|
176
|
+
- `occasionKeys` are parsed from content automatically and are not accepted as input
|
|
177
|
+
|
|
178
|
+
Content guidance:
|
|
179
|
+
|
|
180
|
+
- do not invent channel-specific payload structures from memory
|
|
181
|
+
- use `fieldRules.channelContentSchema` from `build_task_save_guide`
|
|
182
|
+
- take valid keys, expected item shape, and examples from the guide
|
|
183
|
+
- when schema fields include `paramType`, copy it exactly
|
|
184
|
+
- do not use free-form content items such as `{"text":"..."}` as the primary pattern
|
|
185
|
+
|
|
186
|
+
### 4.3 `targetConfig`
|
|
187
|
+
|
|
188
|
+
Use the guide to decide which audience shape applies:
|
|
189
|
+
|
|
190
|
+
- `targetClusterType=1`: custom audience, requires `qp`
|
|
191
|
+
- `targetClusterType=2`: existing cluster, requires `clusterKey`
|
|
192
|
+
- `targetClusterType=3`: all users, forbids both `qp` and `clusterKey`
|
|
193
|
+
|
|
194
|
+
If `qp` is required, construct it from:
|
|
195
|
+
|
|
196
|
+
```bash
|
|
197
|
+
ae-cli analysis_audience +get_cluster_definition_schema --cluster_type condition
|
|
198
|
+
```
|
|
199
|
+
|
|
200
|
+
### 4.4 `triggerConfig`
|
|
201
|
+
|
|
202
|
+
Use the guide to determine the current trigger rule set:
|
|
203
|
+
|
|
204
|
+
- `triggerType=0`: requires `triggerTime`
|
|
205
|
+
- `triggerType=1`: requires `startDate`, `endDate`, `triggerCrontab`
|
|
206
|
+
- `triggerType=2`: manual, no `triggerRule`
|
|
207
|
+
- `triggerType=3/4/5`: requires `triggerRule`
|
|
208
|
+
|
|
209
|
+
Rules:
|
|
210
|
+
|
|
211
|
+
- `triggerType=6` is not supported
|
|
212
|
+
- use the guide for cron format and wrong-example checks
|
|
213
|
+
- if `triggerRule` is needed, build it from:
|
|
214
|
+
|
|
215
|
+
```bash
|
|
216
|
+
ae-cli analysis_audience +get_cluster_definition_schema --cluster_type condition
|
|
217
|
+
```
|
|
218
|
+
|
|
219
|
+
### 4.5 `controlConfig`
|
|
220
|
+
|
|
221
|
+
Minimum required field:
|
|
222
|
+
|
|
223
|
+
- `completionIndicatorDef`
|
|
224
|
+
|
|
225
|
+
When the guide points to event-based completion or experiment-driven main-goal rules, use:
|
|
226
|
+
|
|
227
|
+
```bash
|
|
228
|
+
ae-cli analysis_audience +get_cluster_definition_schema --cluster_type condition
|
|
229
|
+
```
|
|
230
|
+
|
|
231
|
+
to build `completionIndicatorDef.event`.
|
|
232
|
+
|
|
233
|
+
Important constraints that still apply:
|
|
234
|
+
|
|
235
|
+
- `doNotDisturb.enableDoNotDisturb=true` requires `startTime` and `endTime` in `HH:mm`
|
|
236
|
+
- `pushDelay.enablePushDelay=true` requires valid `delayType`, and its dependent fields must match the selected mode
|
|
237
|
+
- `pushDelay.delayType=1` is only valid for `client_push`
|
|
238
|
+
- `pushDelay.delayUnit` must stay within `week`, `day`, `hour`, `minute`, `second`
|
|
239
|
+
- `timeoutControl.enableTimeoutControl=true` requires valid `time` and `unit`
|
|
240
|
+
- `timeoutControl.unit` must stay within `day`, `hour`, `minute`
|
|
241
|
+
|
|
242
|
+
### 4.6 `clientConfig`
|
|
243
|
+
|
|
244
|
+
Use this block only when client-side conditions are needed.
|
|
245
|
+
|
|
246
|
+
If `clientConfig.clientQp` is required, build it from:
|
|
247
|
+
|
|
248
|
+
```bash
|
|
249
|
+
ae-cli analysis_audience +get_cluster_definition_schema --cluster_type condition
|
|
250
|
+
```
|
|
251
|
+
|
|
252
|
+
Only call that schema query when the guide explicitly shows that the field is needed.
|
|
253
|
+
|
|
254
|
+
---
|
|
255
|
+
|
|
256
|
+
## 5. Final Self-Check Before `+save_task`
|
|
257
|
+
|
|
258
|
+
Before submission, verify:
|
|
259
|
+
|
|
260
|
+
1. `channelId` comes from a real channel query.
|
|
261
|
+
2. `build_task_save_guide` has already been called for the current scenario or partial draft.
|
|
262
|
+
3. `fieldRules.channelContentSchema` was used as the source of truth for content structure.
|
|
263
|
+
4. Any required QP-derived fields were built from `ae-cli analysis_audience +get_cluster_definition_schema --cluster_type condition`.
|
|
264
|
+
5. `targetClusterType` matches the presence or absence of `clusterKey` / `qp`.
|
|
265
|
+
6. `triggerType` matches the provided scheduling or event fields.
|
|
266
|
+
7. `completionIndicatorDef` is present and structurally valid for the current scenario.
|
|
267
|
+
8. `taskId` is omitted for create mode and present only for updating a draft.
|
|
268
|
+
9. No unsupported `triggerType=6` is used.
|
|
269
|
+
10. No placeholder IDs or fabricated resource names remain in the request.
|
|
270
|
+
|
|
271
|
+
---
|
|
272
|
+
|
|
273
|
+
## 6. Standard Example Flow
|
|
274
|
+
|
|
275
|
+
Use this style of workflow, rather than jumping directly to `+save_task`:
|
|
276
|
+
|
|
277
|
+
```bash
|
|
278
|
+
ae-cli engage +channel_list --project_id 1
|
|
279
|
+
ae-cli engage +build_task_save_guide --project_id 1 --req '{"context":{"triggerType":2,"channelId":"channel_123"}}'
|
|
280
|
+
ae-cli engage +save_task --project_id 1 --req '{...final grouped req...}'
|
|
281
|
+
```
|
|
282
|
+
|
|
283
|
+
If the guide indicates QP-derived fields are needed, insert:
|
|
284
|
+
|
|
285
|
+
```bash
|
|
286
|
+
ae-cli analysis_audience +get_cluster_definition_schema --cluster_type condition
|
|
287
|
+
```
|
|
288
|
+
|
|
289
|
+
before building the final `req`.
|
|
290
|
+
|
|
291
|
+
---
|
|
292
|
+
|
|
293
|
+
## 7. Safety Constraints
|
|
294
|
+
|
|
295
|
+
This command is a write operation.
|
|
296
|
+
|
|
297
|
+
- Do not treat `save_task` as “submit and launch task”
|
|
298
|
+
- Do not bypass `build_task_save_guide`
|
|
299
|
+
- Do not pass the whole `req` as a JSON string
|
|
300
|
+
- Do not use `triggerType=6`
|
|
301
|
+
- Do not invent `channelId`, `clusterKey`, audience definitions, or content keys
|
|
302
|
+
- Do not use `taskId` for a non-draft task
|
|
303
|
+
- Do not pass `occasionKeys`; Hermes derives them from content
|
|
304
|
+
- Do not call the audience schema query as a reflex; call it only when guide output says QP-derived fields are needed
|