@thinkingai/ae-cli 6.0.61 → 6.0.63

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.
Files changed (184) hide show
  1. package/README.md +2 -0
  2. package/README.zh.md +2 -0
  3. package/dist/{ai-monitor-NUKSJPLE.js → ai-monitor-X5GL44JT.js} +5 -5
  4. package/dist/ai-monitor.js +7 -7
  5. package/dist/{auth-MVAEBGBP.js → auth-SPQ46XQ3.js} +3 -3
  6. package/dist/{automation-6L6IAYRK.js → automation-7XC3VBZI.js} +85 -9
  7. package/dist/{capability-74N7AN5X.js → capability-JZP4KXZC.js} +3 -3
  8. package/dist/{chunk-SVNED423.js → chunk-2VKMHNUU.js} +4 -4
  9. package/dist/{chunk-JZY6WWAP.js → chunk-6HOM2FOJ.js} +10 -1
  10. package/dist/{chunk-COOMXFUG.js → chunk-AAN6KBUK.js} +2 -2
  11. package/dist/{chunk-H35VDOAE.js → chunk-E457FREE.js} +2 -2
  12. package/dist/{chunk-VLOGOM7N.js → chunk-ETQXIZFP.js} +2 -1
  13. package/dist/{chunk-XZDKAR4N.js → chunk-F36ORPI6.js} +3 -28
  14. package/dist/{chunk-7WBCSJL6.js → chunk-F7TCQPQX.js} +1 -1
  15. package/dist/{chunk-HRFYYEXR.js → chunk-FGGEF7MI.js} +2 -2
  16. package/dist/chunk-N2MAYIRU.js +32 -0
  17. package/dist/{chunk-RB26WNLM.js → chunk-PRCHMOWT.js} +1 -1
  18. package/dist/{chunk-LPKIMGIU.js → chunk-RYY5NJK3.js} +2 -2
  19. package/dist/{chunk-OTZ4JQDU.js → chunk-VR2D54AA.js} +1 -1
  20. package/dist/{chunk-THTROEGD.js → chunk-YIG3L4RC.js} +1 -1
  21. package/dist/{chunk-XPARQSYS.js → chunk-YJYC5PLL.js} +2 -3
  22. package/dist/{chunk-HIMOBNEY.js → chunk-ZVUXAHEV.js} +1 -1
  23. package/dist/{compat-check-W4XC27RG.js → compat-check-JD5D77ET.js} +1 -1
  24. package/dist/{config-264GB6C7.js → config-IIMRATTP.js} +3 -3
  25. package/dist/{context-SOQDFZIB.js → context-BXHIPIIX.js} +1 -1
  26. package/dist/{data-integration-UNJ7EPW2.js → data-integration-VRJQ3HVK.js} +2 -1
  27. package/dist/index.js +33 -31
  28. package/dist/{memory-ZLTTULZK.js → memory-B44LY27L.js} +3 -3
  29. package/dist/{metadata-EN2IWCDI.js → metadata-ZVPG2MIA.js} +5 -5
  30. package/dist/{model-NAKQWK4W.js → model-ANZBYVST.js} +1 -1
  31. package/dist/{personal-semantic-preference-UGN67KTN.js → personal-semantic-preference-YNCV4QG3.js} +4 -4
  32. package/dist/{project-semantic-5OP3YPZD.js → project-semantic-E7ZAQL5S.js} +4 -4
  33. package/dist/{sync-LDJQZRQH.js → sync-Y4OZRQAY.js} +3 -3
  34. package/dist/{te-agent-WNNAD4AJ.js → te-agent-RKAUTYJZ.js} +4 -4
  35. package/dist/{te-analysis-KIMH6AGU.js → te-analysis-7N5VC4JB.js} +5 -5
  36. package/dist/{te-community-P7NNBVCS.js → te-community-SIA2UHTS.js} +4 -4
  37. package/dist/{te-dataops-ZRKSG4R7.js → te-dataops-5MJQCODU.js} +2 -2
  38. package/dist/{te-engage-PVBVNRSU.js → te-engage-ZTLOMKO3.js} +68 -16
  39. package/dist/{te-kb-W7PRC7QN.js → te-kb-LDL3MF2Y.js} +44 -13
  40. package/dist/{te-system-F4ZU2HRQ.js → te-system-473I5O53.js} +1 -1
  41. package/dist/{te-team-5ONMRGKF.js → te-team-JOWHCMZA.js} +87 -6
  42. package/dist/{things-PFENSIF4.js → things-DOQ2L3O2.js} +4 -4
  43. package/dist/{update-EUZ4GNND.js → update-KUS6TCPB.js} +2 -2
  44. package/dist/{workspace-Z7L33OBQ.js → workspace-MJFPIV7C.js} +3 -3
  45. package/package.json +3 -3
  46. package/skills/ae-automation/SKILL.md +6 -2
  47. package/skills/ae-automation/references/cli.md +9 -3
  48. package/skills/ae-engage/SKILL.md +6 -1
  49. package/skills/ae-engage/references/common-metric.md +47 -1
  50. package/skills/ae-engage/references/flow-metric-update.md +1 -1
  51. package/skills/ae-engage/references/task-metric-update.md +1 -1
  52. package/skills/ae-kb/SKILL.md +8 -6
  53. package/skills/ae-kb/references/query-workflow.md +5 -1
  54. package/skills/ae-team/SKILL.md +7 -3
  55. package/skills/ae-team/references/copy-to-personal.md +7 -0
  56. package/skills/ae-team/references/promote.md +7 -0
  57. package/skills/ae-team/references/update.md +3 -3
  58. package/skills/ae-tracking-matrix/SKILL.md +0 -170
  59. package/skills/ae-tracking-matrix/assets//345/237/213/347/202/271/346/250/241/347/211/210.xlsx +0 -0
  60. package/skills/ae-tracking-matrix/i18n.yaml +0 -12
  61. package/skills/ae-tracking-matrix/references/ae-capabilities.md +0 -93
  62. package/skills/ae-tracking-matrix/references/business-semantic-checks.md +0 -30
  63. package/skills/ae-tracking-matrix/references/categories/acquaintance_social_tracking_plan_template.md +0 -256
  64. package/skills/ae-tracking-matrix/references/categories/blockchain_game_tracking_plan_template.md +0 -213
  65. package/skills/ae-tracking-matrix/references/categories/card_game_tracking_plan_template.md +0 -407
  66. package/skills/ae-tracking-matrix/references/categories/casual_game_tracking_plan_template.md +0 -218
  67. package/skills/ae-tracking-matrix/references/categories/casual_music.md +0 -112
  68. package/skills/ae-tracking-matrix/references/categories/chess_cards_tracking_plan_template.md +0 -301
  69. package/skills/ae-tracking-matrix/references/categories/ecommerce_tracking_plan_template.md +0 -356
  70. package/skills/ae-tracking-matrix/references/categories/fishing.md +0 -775
  71. package/skills/ae-tracking-matrix/references/categories/game_basic_module_tracking_plan.md +0 -89
  72. package/skills/ae-tracking-matrix/references/categories/idle_card.md +0 -27
  73. package/skills/ae-tracking-matrix/references/categories/idle_game_tracking_plan_template.md +0 -415
  74. package/skills/ae-tracking-matrix/references/categories/interactive_video.md +0 -133
  75. package/skills/ae-tracking-matrix/references/categories/merge.md +0 -639
  76. package/skills/ae-tracking-matrix/references/categories/mmo_mobile_tracking_plan_template.md +0 -406
  77. package/skills/ae-tracking-matrix/references/categories/mmo_web.md +0 -230
  78. package/skills/ae-tracking-matrix/references/categories/music.md +0 -137
  79. package/skills/ae-tracking-matrix/references/categories/online_education_tracking_plan_template.md +0 -414
  80. package/skills/ae-tracking-matrix/references/categories/qipai_mj.md +0 -199
  81. package/skills/ae-tracking-matrix/references/categories/reading_tracking_plan_template.md +0 -158
  82. package/skills/ae-tracking-matrix/references/categories/roguelike_tracking_plan_template.md +0 -546
  83. package/skills/ae-tracking-matrix/references/categories/rpg.md +0 -195
  84. package/skills/ae-tracking-matrix/references/categories/short_drama_tracking_plan_template.md +0 -115
  85. package/skills/ae-tracking-matrix/references/categories/simulation_business_tracking_plan_template.md +0 -151
  86. package/skills/ae-tracking-matrix/references/categories/slg_tracking_plan_template.md +0 -260
  87. package/skills/ae-tracking-matrix/references/categories/slots_tracking_plan_template.md +0 -232
  88. package/skills/ae-tracking-matrix/references/categories/stranger_social_tracking_plan_template.md +0 -359
  89. package/skills/ae-tracking-matrix/references/categories/tower_defense.md +0 -365
  90. package/skills/ae-tracking-matrix/references/categories/video_editor_tracking_plan_template.md +0 -211
  91. package/skills/ae-tracking-matrix/references/categories/wechat_minigame.md +0 -132
  92. package/skills/ae-tracking-matrix/references/category-registry.md +0 -77
  93. package/skills/ae-tracking-matrix/references/data-verification/diagnosis_kb.md +0 -230
  94. package/skills/ae-tracking-matrix/references/data-verification/sql_checks.md +0 -406
  95. package/skills/ae-tracking-matrix/references/data-verification/tracking_plan_comparison.md +0 -128
  96. package/skills/ae-tracking-matrix/references/eval-cases.md +0 -74
  97. package/skills/ae-tracking-matrix/references/naming-dict.md +0 -238
  98. package/skills/ae-tracking-matrix/references/optimization-checklist.md +0 -85
  99. package/skills/ae-tracking-matrix/references/plan-generation/export-schema.md +0 -142
  100. package/skills/ae-tracking-matrix/references/plan-generation/module-baseline.md +0 -47
  101. package/skills/ae-tracking-matrix/references/plan-generation/reference.md +0 -794
  102. package/skills/ae-tracking-matrix/references/plan-generation/template-catalog.md +0 -94
  103. package/skills/ae-tracking-matrix/references/scene-routing.md +0 -80
  104. package/skills/ae-tracking-matrix/references/sdk/client-sdk/android.md +0 -3787
  105. package/skills/ae-tracking-matrix/references/sdk/client-sdk/c.md +0 -827
  106. package/skills/ae-tracking-matrix/references/sdk/client-sdk/cocos2d-lua.md +0 -655
  107. package/skills/ae-tracking-matrix/references/sdk/client-sdk/cocos2d-x.md +0 -953
  108. package/skills/ae-tracking-matrix/references/sdk/client-sdk/cocoscreator.md +0 -1128
  109. package/skills/ae-tracking-matrix/references/sdk/client-sdk/corona.md +0 -714
  110. package/skills/ae-tracking-matrix/references/sdk/client-sdk/egret.md +0 -1268
  111. package/skills/ae-tracking-matrix/references/sdk/client-sdk/flutter.md +0 -776
  112. package/skills/ae-tracking-matrix/references/sdk/client-sdk/h5-and-app-sdk-integration.md +0 -182
  113. package/skills/ae-tracking-matrix/references/sdk/client-sdk/ios.md +0 -2755
  114. package/skills/ae-tracking-matrix/references/sdk/client-sdk/javascript.md +0 -1182
  115. package/skills/ae-tracking-matrix/references/sdk/client-sdk/layaair.md +0 -1300
  116. package/skills/ae-tracking-matrix/references/sdk/client-sdk/macos.md +0 -1369
  117. package/skills/ae-tracking-matrix/references/sdk/client-sdk/mini-program-mini-game.md +0 -1692
  118. package/skills/ae-tracking-matrix/references/sdk/client-sdk/openharmony.md +0 -902
  119. package/skills/ae-tracking-matrix/references/sdk/client-sdk/react-native.md +0 -763
  120. package/skills/ae-tracking-matrix/references/sdk/client-sdk/uni-app.md +0 -1107
  121. package/skills/ae-tracking-matrix/references/sdk/client-sdk/unity.md +0 -1532
  122. package/skills/ae-tracking-matrix/references/sdk/client-sdk/unreal.md +0 -845
  123. package/skills/ae-tracking-matrix/references/sdk/faq/android_sdk_faq.md +0 -228
  124. package/skills/ae-tracking-matrix/references/sdk/faq/ios_sdk_faq.md +0 -149
  125. package/skills/ae-tracking-matrix/references/sdk/faq/java_sdk_faq.md +0 -407
  126. package/skills/ae-tracking-matrix/references/sdk/faq/javascript_sdk_faq.md +0 -163
  127. package/skills/ae-tracking-matrix/references/sdk/faq/minigame_sdk_faq.md +0 -149
  128. package/skills/ae-tracking-matrix/references/sdk/faq/miniprogram_sdk_faq.md +0 -153
  129. package/skills/ae-tracking-matrix/references/sdk/faq/python_sdk_faq.md +0 -232
  130. package/skills/ae-tracking-matrix/references/sdk/faq/sdk_log_guide.md +0 -314
  131. package/skills/ae-tracking-matrix/references/sdk/faq/sdk_usage_notes.md +0 -117
  132. package/skills/ae-tracking-matrix/references/sdk/faq/unity_sdk_faq.md +0 -148
  133. package/skills/ae-tracking-matrix/references/sdk/integration-tools/filebeat-logstash-guide.md +0 -645
  134. package/skills/ae-tracking-matrix/references/sdk/integration-tools/logbus2_guide.md +0 -307
  135. package/skills/ae-tracking-matrix/references/sdk/integration-tools/logbus2_parser_plugin.md +0 -347
  136. package/skills/ae-tracking-matrix/references/sdk/integration-tools/restful_api_notes.md +0 -72
  137. package/skills/ae-tracking-matrix/references/sdk/integration-tools/ta-datax-writer-guide.md +0 -264
  138. package/skills/ae-tracking-matrix/references/sdk/server-sdk/c.md +0 -566
  139. package/skills/ae-tracking-matrix/references/sdk/server-sdk/erlang.md +0 -409
  140. package/skills/ae-tracking-matrix/references/sdk/server-sdk/golang.md +0 -446
  141. package/skills/ae-tracking-matrix/references/sdk/server-sdk/java.md +0 -557
  142. package/skills/ae-tracking-matrix/references/sdk/server-sdk/lua.md +0 -457
  143. package/skills/ae-tracking-matrix/references/sdk/server-sdk/nodejs.md +0 -490
  144. package/skills/ae-tracking-matrix/references/sdk/server-sdk/php.md +0 -523
  145. package/skills/ae-tracking-matrix/references/sdk/server-sdk/python.md +0 -484
  146. package/skills/ae-tracking-matrix/references/sdk/server-sdk/ruby.md +0 -442
  147. package/skills/ae-tracking-matrix/references/sdk/te-data-rules/data-rules.md +0 -391
  148. package/skills/ae-tracking-matrix/references/sdk/te-data-rules/first-event-validation.md +0 -91
  149. package/skills/ae-tracking-matrix/references/sdk/te-data-rules/preset-properties-system-fields.md +0 -635
  150. package/skills/ae-tracking-matrix/references/sdk/te-data-rules/updatable-events.md +0 -113
  151. package/skills/ae-tracking-matrix/references/sdk/te-data-rules/user-identification-rules.md +0 -466
  152. package/skills/ae-tracking-matrix/references/standard-base/README.md +0 -22
  153. package/skills/ae-tracking-matrix/references/standard-base/basic_event_data.md +0 -174
  154. package/skills/ae-tracking-matrix/references/standard-base/common_event_properties.md +0 -20
  155. package/skills/ae-tracking-matrix/references/standard-base/common_event_properties_setup.md +0 -7
  156. package/skills/ae-tracking-matrix/references/standard-base/data_type_design_principles.md +0 -14
  157. package/skills/ae-tracking-matrix/references/standard-base/gameplay_event_data.md +0 -370
  158. package/skills/ae-tracking-matrix/references/standard-base/id_system_faq.md +0 -47
  159. package/skills/ae-tracking-matrix/references/standard-base/integration_must_know.md +0 -37
  160. package/skills/ae-tracking-matrix/references/standard-base/multi_platform_integration_notes.md +0 -27
  161. package/skills/ae-tracking-matrix/references/standard-base/multi_user_id_system_recommendations.md +0 -23
  162. package/skills/ae-tracking-matrix/references/standard-base/tracking_notes.md +0 -14
  163. package/skills/ae-tracking-matrix/references/standard-base/user_data.md +0 -46
  164. package/skills/ae-tracking-matrix/references/standard-base/user_id_system.md +0 -13
  165. package/skills/ae-tracking-matrix/references/system-fields.md +0 -297
  166. package/skills/ae-tracking-matrix/references/te-field-translations.md +0 -1791
  167. package/skills/ae-tracking-matrix/references/workflows/data-verification.md +0 -232
  168. package/skills/ae-tracking-matrix/references/workflows/feasibility-analysis.md +0 -829
  169. package/skills/ae-tracking-matrix/references/workflows/integration-qna.md +0 -355
  170. package/skills/ae-tracking-matrix/references/workflows/plan-generation.md +0 -283
  171. package/skills/ae-tracking-matrix/references/workflows/plan-lint.md +0 -168
  172. package/skills/ae-tracking-matrix/references/workflows/plan-review-optimize.md +0 -205
  173. package/skills/ae-tracking-matrix/references/workflows/prd-to-suggestions.md +0 -75
  174. package/skills/ae-tracking-matrix/references/workflows/troubleshooting.md +0 -36
  175. package/skills/ae-tracking-matrix/references/workflows/validated-upload.md +0 -107
  176. package/skills/ae-tracking-matrix/scripts/build_template_catalog.py +0 -114
  177. package/skills/ae-tracking-matrix/scripts/export_tracking_plan.py +0 -53
  178. package/skills/ae-tracking-matrix/scripts/finalize_plan.py +0 -166
  179. package/skills/ae-tracking-matrix/scripts/lint_tracking_plan.py +0 -674
  180. package/skills/ae-tracking-matrix/scripts/plan_contract.py +0 -200
  181. package/skills/ae-tracking-matrix/scripts/plan_types.py +0 -60
  182. package/skills/ae-tracking-matrix/scripts/prepare_delivery.py +0 -169
  183. package/skills/ae-tracking-matrix/scripts/sync_plan.py +0 -296
  184. package/skills/ae-tracking-matrix/scripts/upload_plan.py +0 -340
@@ -2,18 +2,18 @@ import { createRequire as __createRequire } from 'node:module'; const require =
2
2
  import {
3
3
  kbApi,
4
4
  kbUpload
5
- } from "./chunk-7WBCSJL6.js";
5
+ } from "./chunk-F7TCQPQX.js";
6
6
  import {
7
7
  TeAgentApiError
8
- } from "./chunk-VLOGOM7N.js";
8
+ } from "./chunk-ETQXIZFP.js";
9
9
  import {
10
10
  printError
11
- } from "./chunk-OTZ4JQDU.js";
11
+ } from "./chunk-VR2D54AA.js";
12
12
  import {
13
13
  CapabilityGatewayError
14
- } from "./chunk-JZY6WWAP.js";
14
+ } from "./chunk-6HOM2FOJ.js";
15
15
  import "./chunk-NNK3JBH4.js";
16
- import "./chunk-XPARQSYS.js";
16
+ import "./chunk-YJYC5PLL.js";
17
17
  import "./chunk-PUSFEC6B.js";
18
18
  import "./chunk-PLNS5J33.js";
19
19
  import "./chunk-AMURHMS3.js";
@@ -1112,6 +1112,29 @@ var add = {
1112
1112
  }
1113
1113
  };
1114
1114
 
1115
+ // src/commands/te-kb/content-language.ts
1116
+ function requestedContentLanguage(ctx) {
1117
+ const value = ctx.str("content-language");
1118
+ if (!value) return void 0;
1119
+ if (!/^[A-Za-z]{2,8}$/.test(value.trim())) {
1120
+ throw new Error("--content-language must be a BCP-47 primary language subtag, such as ko.");
1121
+ }
1122
+ return value.trim().toLowerCase();
1123
+ }
1124
+ async function requestWithContentLanguage(ctx, path9, body4, api = kbApi, preserveBusinessErrorCode = false) {
1125
+ try {
1126
+ if (preserveBusinessErrorCode) {
1127
+ return await api(ctx, "POST", path9, {}, body4, { preserveBusinessErrorCode: true });
1128
+ }
1129
+ return await api(ctx, "POST", path9, {}, body4);
1130
+ } catch (error) {
1131
+ if (body4.contentLanguage && error instanceof Error && /^body:\s/.test(error.message)) {
1132
+ throw new Error("The server does not support the requested knowledge-base language option.", { cause: error });
1133
+ }
1134
+ throw error;
1135
+ }
1136
+ }
1137
+
1115
1138
  // src/commands/te-kb/compile.ts
1116
1139
  var API_PATH5 = "/agent/api/external/knowledge-bases/compile";
1117
1140
  var VALID_MODES = /* @__PURE__ */ new Set(["incremental", "full"]);
@@ -1131,6 +1154,8 @@ function buildBody(ctx) {
1131
1154
  if (scope) body4.scope = scope;
1132
1155
  const model = ctx.str("model");
1133
1156
  if (model) body4.model = model;
1157
+ const contentLanguage = requestedContentLanguage(ctx);
1158
+ if (contentLanguage) body4.contentLanguage = contentLanguage;
1134
1159
  return body4;
1135
1160
  }
1136
1161
  var compile = {
@@ -1138,6 +1163,7 @@ var compile = {
1138
1163
  command: "+compile",
1139
1164
  description: "Compile a knowledge.",
1140
1165
  flags: [
1166
+ { name: "content-language", type: "string", required: false, desc: "Require the working guidelines to declare this language before compilation." },
1141
1167
  { name: "name", type: "string", required: true, desc: "Knowledge base name" },
1142
1168
  { name: "mode", type: "string", required: false, default: "incremental", desc: "Compile mode: incremental | full (default: incremental)" },
1143
1169
  { name: "scope", type: "string", required: false, desc: "Exact knowledge base scope: personal | company (omit for personal \u2192 company fallback)" },
@@ -1145,15 +1171,14 @@ var compile = {
1145
1171
  ],
1146
1172
  risk: "write",
1147
1173
  validate: (ctx) => {
1148
- getMode(ctx);
1149
- getExternalKnowledgeBaseTargetScope(ctx);
1174
+ buildBody(ctx);
1150
1175
  },
1151
1176
  dryRun: (ctx) => ({
1152
1177
  method: "POST",
1153
1178
  url: `${ctx.host().replace(/\/$/, "")}${API_PATH5}`,
1154
1179
  body: buildBody(ctx)
1155
1180
  }),
1156
- execute: async (ctx) => kbApi(ctx, "POST", API_PATH5, {}, buildBody(ctx))
1181
+ execute: async (ctx) => requestWithContentLanguage(ctx, API_PATH5, buildBody(ctx))
1157
1182
  };
1158
1183
 
1159
1184
  // src/commands/te-kb/remove.ts
@@ -1339,18 +1364,24 @@ function buildBody5(ctx) {
1339
1364
  if (model) body4.model = model;
1340
1365
  const customInstructions = getCustomInstructions(ctx);
1341
1366
  if (customInstructions) body4.customInstructions = customInstructions;
1367
+ const contentLanguage = requestedContentLanguage(ctx);
1368
+ if (contentLanguage) body4.contentLanguage = contentLanguage;
1369
+ if (ctx.bool("rewrite-language")) {
1370
+ if (!contentLanguage) throw new Error("--rewrite-language requires --content-language.");
1371
+ body4.schemaMode = "rewrite-language";
1372
+ }
1342
1373
  return body4;
1343
1374
  }
1344
1375
  async function executeSchema(ctx, api = kbApi) {
1345
- return api(ctx, "POST", API_PATH9, {}, buildBody5(ctx), {
1346
- preserveBusinessErrorCode: true
1347
- });
1376
+ return requestWithContentLanguage(ctx, API_PATH9, buildBody5(ctx), api, true);
1348
1377
  }
1349
1378
  var schema = {
1350
1379
  service: "kb",
1351
1380
  command: "+schema",
1352
1381
  description: "Generate the compile schema for a knowledge base via POST /agent/api/external/knowledge-bases/schema.",
1353
1382
  flags: [
1383
+ { name: "content-language", type: "string", required: false, desc: "Set the knowledge-base content language while generating the guidelines." },
1384
+ { name: "rewrite-language", type: "boolean", required: false, desc: "Rewrite the language of the existing guidelines while preserving their rules." },
1354
1385
  { name: "name", type: "string", required: true, desc: "Knowledge base name (looked up personal \u2192 company)" },
1355
1386
  { name: "scope", type: "string", required: false, desc: "Exact knowledge base scope: personal | company (omit for personal \u2192 company fallback)" },
1356
1387
  { name: "force", type: "boolean", required: false, desc: "Preempt generation even when status is `generating` (use only for stuck recovery)" },
@@ -1373,7 +1404,7 @@ var schema = {
1373
1404
  risk: "write",
1374
1405
  validate: (ctx) => {
1375
1406
  getExternalKnowledgeBaseTargetScope(ctx);
1376
- getCustomInstructions(ctx);
1407
+ buildBody5(ctx);
1377
1408
  },
1378
1409
  dryRun: (ctx) => ({
1379
1410
  method: "POST",
@@ -1683,7 +1714,7 @@ var kbGrep = {
1683
1714
  name: "paths",
1684
1715
  type: "json",
1685
1716
  required: true,
1686
- desc: 'JSON array of wiki pages or subdirectories copied from +index, e.g. ["wiki/sandbox.md"] or ["wiki/guides"]'
1717
+ desc: 'JSON array of files or subdirectories strictly under wiki/, copied from returned navigation, e.g. ["wiki/sandbox.md"] or ["wiki/guides"]. The roots "wiki" and "wiki/", index.md, raw/, absolute paths and paths escaping wiki/ are invalid. If navigation provides no usable paths, skip +grep; never use the wiki root as a fallback.'
1687
1718
  },
1688
1719
  { name: "top-k", type: "number", required: false, min: 1, max: 50, desc: "Max number of pages to return (1-50, default 10)" },
1689
1720
  { name: "locale", type: "string", required: false, desc: "Optional locale: zh | en | ja | ko" }
@@ -12,7 +12,7 @@ import {
12
12
  postToMainApp,
13
13
  putToMainApp,
14
14
  uploadToMainApp
15
- } from "./chunk-VLOGOM7N.js";
15
+ } from "./chunk-ETQXIZFP.js";
16
16
  import "./chunk-PLNS5J33.js";
17
17
  import {
18
18
  isAeSandboxRuntime,
@@ -2,14 +2,17 @@ import { createRequire as __createRequire } from 'node:module'; const require =
2
2
  import {
3
3
  getAuthHeaders,
4
4
  kbApi
5
- } from "./chunk-7WBCSJL6.js";
5
+ } from "./chunk-F7TCQPQX.js";
6
+ import {
7
+ detectCliLocale
8
+ } from "./chunk-N2MAYIRU.js";
6
9
  import {
7
10
  printError,
8
11
  printOutput
9
- } from "./chunk-OTZ4JQDU.js";
10
- import "./chunk-JZY6WWAP.js";
12
+ } from "./chunk-VR2D54AA.js";
13
+ import "./chunk-6HOM2FOJ.js";
11
14
  import "./chunk-NNK3JBH4.js";
12
- import "./chunk-XPARQSYS.js";
15
+ import "./chunk-YJYC5PLL.js";
13
16
  import "./chunk-PUSFEC6B.js";
14
17
  import "./chunk-PLNS5J33.js";
15
18
  import "./chunk-AMURHMS3.js";
@@ -77,6 +80,12 @@ var createTeam = {
77
80
  };
78
81
 
79
82
  // src/commands/te-team/team/update-team.ts
83
+ var scopeHelp = {
84
+ en: "For compatibility, pass the current scope only. Use +promote or +copy-to-personal to change ownership.",
85
+ zh: "\u4EC5\u7528\u4E8E\u517C\u5BB9\u539F\u6837\u4F20\u56DE\u5F53\u524D\u8303\u56F4\u3002\u8981\u66F4\u6539\u5F52\u5C5E\uFF0C\u8BF7\u4F7F\u7528 +promote \u6216 +copy-to-personal\u3002",
86
+ ja: "\u4E92\u63DB\u6027\u306E\u305F\u3081\u73FE\u5728\u306E\u516C\u958B\u7BC4\u56F2\u306E\u307F\u6307\u5B9A\u3067\u304D\u307E\u3059\u3002\u6240\u6709\u7BC4\u56F2\u306E\u5909\u66F4\u306F +promote \u307E\u305F\u306F +copy-to-personal \u3092\u4F7F\u7528\u3057\u3066\u304F\u3060\u3055\u3044\u3002",
87
+ ko: "\uD638\uD658\uC131\uC744 \uC704\uD574 \uD604\uC7AC \uACF5\uAC1C \uBC94\uC704\uB9CC \uC804\uB2EC\uD560 \uC218 \uC788\uC2B5\uB2C8\uB2E4. \uC18C\uC720 \uBC94\uC704\uB97C \uBCC0\uACBD\uD558\uB824\uBA74 +promote \uB610\uB294 +copy-to-personal\uC744 \uC0AC\uC6A9\uD558\uC138\uC694."
88
+ };
80
89
  var VALID_SCOPES2 = /* @__PURE__ */ new Set(["personal", "company"]);
81
90
  function buildBody2(ctx) {
82
91
  const body = {};
@@ -101,7 +110,7 @@ var updateTeam = {
101
110
  { name: "name", type: "string", required: false, desc: "New team name" },
102
111
  { name: "config", type: "json", required: false, desc: "New TeamConfig JSON" },
103
112
  { name: "description", type: "string", required: false, desc: "New description" },
104
- { name: "scope", type: "string", required: false, desc: "personal | company" },
113
+ { name: "scope", type: "string", required: false, desc: scopeHelp[detectCliLocale()] },
105
114
  { name: "enabled", type: "boolean", required: false, desc: "Whether enabled" }
106
115
  ],
107
116
  risk: "write",
@@ -116,7 +125,7 @@ var updateTeam = {
116
125
  url: `${ctx.host().replace(/\/$/, "")}${BASE_TEAM_PATH}/${ctx.str("id")}`,
117
126
  body: buildBody2(ctx)
118
127
  }),
119
- execute: async (ctx) => kbApi(ctx, "PATCH", `${BASE_TEAM_PATH}/${ctx.str("id")}`, {}, buildBody2(ctx))
128
+ execute: async (ctx) => kbApi(ctx, "PATCH", `${BASE_TEAM_PATH}/${ctx.str("id")}`, { lang: detectCliLocale() }, buildBody2(ctx))
120
129
  };
121
130
 
122
131
  // src/commands/te-team/team/delete-team.ts
@@ -201,10 +210,82 @@ var listProjects = {
201
210
  }
202
211
  };
203
212
 
213
+ // src/commands/te-team/team/scope-command.ts
214
+ var scopeText = {
215
+ en: {
216
+ id: "Team ID",
217
+ revision: "Use expectedRevision from the preview",
218
+ required: "Preview this Team with --dry-run, then pass its --expected-revision.",
219
+ promote: "Convert your personal Team to a company Team after reviewing the preview.",
220
+ copy: "Create an independent personal copy of a company Team."
221
+ },
222
+ zh: {
223
+ id: "Team ID",
224
+ revision: "\u4F7F\u7528\u9884\u89C8\u8FD4\u56DE\u7684 expectedRevision",
225
+ required: "\u8BF7\u5148\u8FD0\u884C --dry-run \u9884\u89C8\uFF0C\u518D\u4F20\u5165\u5BF9\u5E94\u7684 --expected-revision\u3002",
226
+ promote: "\u786E\u8BA4\u9884\u89C8\u540E\uFF0C\u5C06\u672C\u4EBA\u7684\u4E2A\u4EBA Team \u8F6C\u4E3A\u516C\u53F8 Team\u3002",
227
+ copy: "\u628A\u516C\u53F8 Team \u590D\u5236\u4E3A\u72EC\u7ACB\u7684\u4E2A\u4EBA Team\u3002"
228
+ },
229
+ ja: {
230
+ id: "Team ID",
231
+ revision: "\u30D7\u30EC\u30D3\u30E5\u30FC\u3067\u53D6\u5F97\u3057\u305F expectedRevision",
232
+ required: "--dry-run \u3067\u78BA\u8A8D\u3057\u3066\u304B\u3089 --expected-revision \u3092\u6307\u5B9A\u3057\u3066\u304F\u3060\u3055\u3044\u3002",
233
+ promote: "\u78BA\u8A8D\u3057\u305F\u500B\u4EBA\u7528 Team \u3092\u4F1A\u793E\u306E Team \u306B\u5909\u66F4\u3057\u307E\u3059\u3002",
234
+ copy: "\u4F1A\u793E\u306E Team \u306E\u72EC\u7ACB\u3057\u305F\u500B\u4EBA\u7528\u30B3\u30D4\u30FC\u3092\u4F5C\u6210\u3057\u307E\u3059\u3002"
235
+ },
236
+ ko: {
237
+ id: "Team ID",
238
+ revision: "\uBBF8\uB9AC \uBCF4\uAE30\uC5D0\uC11C \uBC1B\uC740 expectedRevision",
239
+ required: "\uBA3C\uC800 --dry-run\uC73C\uB85C \uD655\uC778\uD55C \uD6C4 --expected-revision\uC744 \uC804\uB2EC\uD558\uC138\uC694.",
240
+ promote: "\uBBF8\uB9AC \uBCF4\uAE30 \uD655\uC778 \uD6C4 \uAC1C\uC778 Team\uC744 \uD68C\uC0AC Team\uC73C\uB85C \uC804\uD658\uD569\uB2C8\uB2E4.",
241
+ copy: "\uD68C\uC0AC Team\uC758 \uB3C5\uB9BD\uC801\uC778 \uAC1C\uC778 \uBCF5\uC0AC\uBCF8\uC744 \uB9CC\uB4ED\uB2C8\uB2E4."
242
+ }
243
+ };
244
+ function teamScopeCommand(action) {
245
+ const txt = scopeText[detectCliLocale()];
246
+ const endpoint = (ctx) => BASE_TEAM_PATH + "/" + encodeURIComponent(ctx.str("id")) + "/" + action;
247
+ return {
248
+ service: "team",
249
+ description: txt[action],
250
+ risk: "write",
251
+ flags: [
252
+ { name: "id", type: "string", required: true, desc: txt.id },
253
+ { name: "expected-revision", type: "string", desc: txt.revision }
254
+ ],
255
+ dryRun: (ctx) => kbApi(ctx, "GET", endpoint(ctx), { lang: detectCliLocale() }),
256
+ execute: (ctx) => {
257
+ const expectedRevision = ctx.str("expected-revision");
258
+ if (!expectedRevision) throw new Error(txt.required);
259
+ return kbApi(
260
+ ctx,
261
+ "POST",
262
+ endpoint(ctx),
263
+ { lang: detectCliLocale() },
264
+ { expectedRevision },
265
+ { preserveBusinessErrorCode: true }
266
+ );
267
+ }
268
+ };
269
+ }
270
+
271
+ // src/commands/te-team/team/promote-team.ts
272
+ var promoteTeam = {
273
+ command: "+promote",
274
+ ...teamScopeCommand("promote")
275
+ };
276
+
277
+ // src/commands/te-team/team/copy-team.ts
278
+ var copyTeam = {
279
+ command: "+copy-to-personal",
280
+ ...teamScopeCommand("copy")
281
+ };
282
+
204
283
  // src/commands/te-team/team/index.ts
205
284
  var commands = [
206
285
  listTeams,
207
286
  createTeam,
287
+ promoteTeam,
288
+ copyTeam,
208
289
  updateTeam,
209
290
  deleteTeam,
210
291
  aiGenerate,
@@ -1,14 +1,14 @@
1
1
  import { createRequire as __createRequire } from 'node:module'; const require = __createRequire(import.meta.url);
2
2
  import {
3
3
  resolveMemoryApiBaseUrl
4
- } from "./chunk-THTROEGD.js";
5
- import "./chunk-HIMOBNEY.js";
6
- import "./chunk-VLOGOM7N.js";
4
+ } from "./chunk-YIG3L4RC.js";
5
+ import "./chunk-ZVUXAHEV.js";
6
+ import "./chunk-ETQXIZFP.js";
7
7
  import {
8
8
  CapabilityGatewayError,
9
9
  buildCapabilityGatewayUrl,
10
10
  callCapabilityApi
11
- } from "./chunk-JZY6WWAP.js";
11
+ } from "./chunk-6HOM2FOJ.js";
12
12
  import "./chunk-NNK3JBH4.js";
13
13
  import "./chunk-PUSFEC6B.js";
14
14
  import "./chunk-PLNS5J33.js";
@@ -5,7 +5,7 @@ import {
5
5
  import {
6
6
  printError,
7
7
  printOutput
8
- } from "./chunk-OTZ4JQDU.js";
8
+ } from "./chunk-VR2D54AA.js";
9
9
  import {
10
10
  buildVersionInstallPlan,
11
11
  exactVersion,
@@ -16,7 +16,7 @@ import {
16
16
  installVersion,
17
17
  recordVersionSyncResult,
18
18
  rememberBusinessConfig
19
- } from "./chunk-XPARQSYS.js";
19
+ } from "./chunk-YJYC5PLL.js";
20
20
  import {
21
21
  getLocalCliPackageInfo
22
22
  } from "./chunk-PUSFEC6B.js";
@@ -13,12 +13,12 @@ import {
13
13
  workspaceResourcePath,
14
14
  workspaceTargetFlags,
15
15
  workspaceTargetPath
16
- } from "./chunk-COOMXFUG.js";
16
+ } from "./chunk-AAN6KBUK.js";
17
17
  import "./chunk-RK6GLDGI.js";
18
18
  import {
19
19
  getAgentBuffer
20
- } from "./chunk-HIMOBNEY.js";
21
- import "./chunk-VLOGOM7N.js";
20
+ } from "./chunk-ZVUXAHEV.js";
21
+ import "./chunk-ETQXIZFP.js";
22
22
  import "./chunk-PLNS5J33.js";
23
23
  import "./chunk-AMURHMS3.js";
24
24
  import {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thinkingai/ae-cli",
3
- "version": "6.0.61",
3
+ "version": "6.0.63",
4
4
  "description": "CLI tool for ThinkingAI (AE) analytics platform",
5
5
  "type": "module",
6
6
  "bin": {
@@ -51,7 +51,7 @@
51
51
  "verify:retired-analysis-commands": "node --test test/retired-analysis-commands.test.mjs",
52
52
  "verify:retired-api-command": "node --test test/retired-api-command.test.mjs",
53
53
  "verify:analysis-common-tools": "node scripts/verify-te-common-tools.mjs",
54
- "verify:team-tools": "node scripts/verify-te-team-tools.mjs && node --import tsx --test tests/team-run-watch.test.ts test/team-run-start-command.test.mjs",
54
+ "verify:team-tools": "node scripts/verify-te-team-tools.mjs && node --import tsx --test tests/team-run-watch.test.ts test/team-run-start-command.test.mjs test/team-scope-command.test.mjs",
55
55
  "verify:evaluation-tools": "node scripts/verify-evaluation-tools.mjs && node --import tsx tests/evaluation-client.test.ts && node --import tsx tests/evaluation-sandbox-session.test.ts && node --import tsx tests/evaluation-security.test.ts && node --import tsx tests/evaluation-command-contract.test.ts && node --import tsx --test tests/evaluation-onboarding.test.ts",
56
56
  "verify:a2a": "node --import tsx --test tests/a2a-client.test.ts",
57
57
  "verify:agent-tools": "npm run verify:a2a && node --test test/agent-command-registry.test.mjs && tsx tests/te-agent-credentials.test.ts && tsx tests/te-agent-unified-auth.test.ts && node --import tsx --test tests/te-agent-env-isolation.test.ts && tsx tests/te-agent-conversations.test.ts && tsx scripts/verify-agent-tools.mjs && npm run verify:resource-package && npm run verify:approval && npm run verify:agent-distribution && npm run verify:agent-context && npm run verify:sandbox-tools && npm run verify:notifications",
@@ -99,7 +99,7 @@
99
99
  "verify:skill-businesses": "node --test test/release-gate-skill-businesses.test.mjs",
100
100
  "verify:notifications": "tsx tests/notification-command.test.ts",
101
101
  "verify:mcp-int64-request": "npx tsx tests/mcp-int64-request.test.ts",
102
- "verify:cli-source-logging": "node --import tsx --test tests/source-logged-fetch.test.ts",
102
+ "verify:cli-source-logging": "node --import tsx --test tests/source-logged-fetch.test.ts tests/cli-agent-context-transports.test.ts",
103
103
  "verify:capability-api": "npx tsx tests/capability-api.test.ts",
104
104
  "verify:community-ux": "npm run build && npx tsx tests/community-ux.test.ts",
105
105
  "verify:community-evidence": "node --import tsx tests/community-evidence.test.ts",
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  name: ae-automation
3
+ version: 1.1.2
3
4
  description: "Schedule AE platform automations: every day/week, daily reports, recurring reminders, monitoring, or repeat this task. Use ae-cli automation for persistent Agent/Agent Team tasks in the current space, instead of session-local CronCreate or /loop. Also manage schedules, runs, and results."
4
5
  ---
5
6
 
@@ -11,8 +12,11 @@ See [command risks](references/command_index.md). Read [the command contract](re
11
12
 
12
13
  1. Resolve the host and space. A local user signs in with `ae-cli auth login`; a sandbox uses the current conversation user's injected CLI token, never a shared sandbox's user binding. Pass `--agent-space-id` when the user identifies a space. Without an explicit space, the CLI inherits the current AgentSpace from its runtime context, working directory or verified current conversation; only a local invocation without space context uses the personal default. Show the resolved space when it matters.
13
14
  2. Discover the automation with `automation list` and inspect `automation get`. Use the returned IDs; names are not unique.
14
- 3. For creation, select an Agent or team through the corresponding discovery commands. Match configuration to the target type. Use `--weekdays` or `--days-of-month` JSON arrays for multiple days with one time; skip dates absent in a month. For the actual last day of every month use `--days-of-month '["L"]'`, or combine it with dates, e.g. `'[1,15,"L"]'`; overlapping selections execute only once. Both Agent and Agent Team accept result notifications. Confirm the complete configuration before creation; save only the recurring task instructions as `--message`, never the automation-creation guide. Preview writes with `--dry-run` when useful; the CLI shows a redacted request and asks the server to validate authentication, space, permissions, target state, fields, and idempotency without applying the operation.
15
- 4. Execute the requested operation. After creation, read back the returned automation ID with `automation get` and verify the saved space and configuration before reporting success; a local schedule or a promise to run later is not a platform creation receipt. Deleting an automation or stopping an execution requires confirmation; use `--yes` only when the user already authorized that action. In a non-interactive shell, these operations fail immediately unless global `--yes` is present.
15
+ 3. For creation, select an Agent or team through the corresponding discovery commands. Match configuration to the target type. Use `--weekdays` or `--days-of-month` JSON arrays for multiple days with one time; skip dates absent in a month. For the actual last day of every month use `--days-of-month '["L"]'`, or combine it with dates, e.g. `'[1,15,"L"]'`; overlapping selections execute only once. Both Agent and Agent Team accept result notifications. Save only the recurring task instructions as `--message`.
16
+ - In a conversation, run `ae-cli automation create --dry-run` for each new task, including a second task in the same chat or one that will start paused. Show the name, space, target, task instructions, schedule, model and depth, notifications, conversation mode and initial state, including any immediate run. Ask the user to confirm this preview and wait for their reply. Use AskUserQuestion when available. Selecting a target or answering a clarification only completes the preview. A changed configuration needs a new preview and confirmation. A cancellation ends that draft. Only an explicit reply approving this task authorizes one creation.
17
+ - For a single Agent, include reasoning depth in the confirmation. If no depth was requested, use adaptive without asking or copying the current conversation's setting. For an explicit depth, pass `--effort low|medium|high|max`. If the request is ambiguous or conflicting, clarify before creating.
18
+ - In a shared workspace, select an enabled company Team. A personal Team is only a valid target in a personal workspace; do not silently switch workspace or Team. For an Agent Team, ignore any requested depth, even an unrecognized one. Use the team's own settings and continue without asking about depth. For a request to change only Team depth, use the CLI update with the supplied effort to verify permission. A successful `unchanged: true` means the override was ignored and the team still uses its own settings. With a mixed update, report the fields that were saved and the ignored depth separately.
19
+ 4. Execute the requested operation. After creation, read back the returned automation ID with `automation get` and verify the saved space and configuration, including the Agent effort (`null` means adaptive) before reporting success. Link to the returned `detailPath` including its `agentSpaceId` query. A local schedule or a promise to run later is not a platform creation receipt. Deleting an automation or stopping an execution requires confirmation; use `--yes` only when the user already authorized that action. In a non-interactive shell, these operations fail immediately unless global `--yes` is present.
16
20
  5. Read the returned run ID, then `automation runs result`. Report acceptance separately from completion. Use `--wait` only when the user needs the final outcome now.
17
21
 
18
22
  Results are read from the server and work outside the sandbox. This skill does not read complete conversations or continue a chat. Never infer an output from a different execution sharing the same conversation.
@@ -1,5 +1,7 @@
1
1
  # Automation command contract
2
2
 
3
+ Shared workspace automations require an enabled company Team. Personal Teams can be used in personal workspaces. Validate the saved workspace and target in the server dry-run.
4
+
3
5
  Transition status: transitional
4
6
  Owning module: te-claude automation and team scheduling
5
7
  Current transport: authenticated TE REST /api/cli/automation/v1
@@ -11,7 +13,7 @@ Exit condition: equivalent gateway capabilities preserve permissions, idempotenc
11
13
 
12
14
  - `ae-cli automation list [--agent-space-id ID] [--target-type agent|team] [--q NAME] [--status active|paused] [--limit 20] [--cursor CURSOR]`
13
15
  - `ae-cli automation get --id ID`
14
- - `ae-cli automation create --target-type agent --agent-id ID --name NAME --message TEXT --schedule-kind daily --time 09:00 [--model MODEL_CONFIG_ID] [--reuse-conversation true|false]`
16
+ - `ae-cli automation create --target-type agent --agent-id ID --name NAME --message TEXT --schedule-kind daily --time 09:00 [--model MODEL_CONFIG_ID] [--effort adaptive|low|medium|high|max] [--reuse-conversation true|false]`
15
17
  - `ae-cli automation create --target-type team --team-id ID --name NAME --message TEXT --trigger-type manual [--scope JSON] [--channels JSON_ARRAY]`
16
18
  - `ae-cli automation update --id ID --target-type agent|team <changed fields>`
17
19
  - `ae-cli automation enable|disable --id ID`
@@ -19,7 +21,11 @@ Exit condition: equivalent gateway capabilities preserve permissions, idempotenc
19
21
 
20
22
  Scheduled creation needs `--schedule-kind` or `--cron-expression`. Frequencies: hourly with `--minute 0..59`; daily with `--time HH:mm`; weekly also `--weekdays '[1,3,5]'` (0=Sunday through 6=Saturday); monthly also `--days-of-month '[1,15,31]'` (integers 1–31 and `"L"` for the actual last day of the month). Existing single-day flags `--weekday 0..6` and `--day-of-month 1..31` remain supported; do not combine a single-day flag with its plural array. Arrays must be non-empty; duplicates are removed and dates sorted. Dates absent in the current month are skipped, never shifted into the next month. `"L"` follows the actual month end in the server timezone (including leap years). It can be selected alone or with numeric dates; overlapping selections at the same time run only once. Any minute 00–59 is valid in `--time`. Times use the server timezone. Manual creation does not require a schedule. `--trigger-immediately` executes after creation; `--wait` then waits for that execution. Creation and immediate execution have separate results: do not create another automation if only its execution failed.
21
23
 
22
- On update, omitted fields retain their values. `--model null`, `--scope null`, destination IDs set to `null`, and `--save-to-knowledge-base-id null` clear nullable fields. `--channels '[]'` clears notifications; `--clear-message` clears instructions; `--reuse-conversation false` disables reuse. An automation's target is immutable on update. Team fields are rejected for Agent targets and vice versa.
24
+ On update, omitted fields retain their values. `--model null`, `--scope null`, destination IDs set to `null`, and `--save-to-knowledge-base-id null` clear nullable fields. `--channels '[]'` clears notifications; `--clear-message` clears instructions; `--reuse-conversation false` disables reuse. An automation's target is immutable on update. Target-specific fields are rejected on the other target, except for `--effort` on Team automations.
25
+
26
+ For a single Agent, `--effort` accepts `adaptive`, `low`, `medium`, `high`, or `max`. Omit it on create for adaptive reasoning. Omit it on update to keep the saved depth, or pass `--effort adaptive` to clear an override. Verify the saved `effort` with `automation get` (`null` means adaptive). Never infer a depth from the current chat.
27
+
28
+ For an Agent Team, ignore any `--effort` value before validating the other fields. Create or update with the remaining settings. An update containing only `--effort` verifies the existing target and update permission and returns `unchanged: true` without writing. Preflight and successful command results identify an explicit Team depth in `ignoredFields: ["effort"]`. An effort-only success means the team kept its own settings. For a mixed update, report the saved changes and the ignored depth. Report permission and validation errors from their error envelope.
23
29
 
24
30
  Team configuration supports `--scope`, `--channels`, `--feishu-chat-id`, `--lark-chat-id`, `--slack-channel-id`, `--save-to-knowledge-base-id`. Other supported notification channels use the team's existing notification configuration. Team visibility and management permissions follow the Web application.
25
31
 
@@ -58,7 +64,7 @@ Agent and Agent Team both accept `--channels '["feishu","slack"]'`, `--feishu-ch
58
64
 
59
65
  Automation requests use the current user's `cli-token`, including in a shared sandbox. They do not infer an owner from `SandboxUser` or fall back to a different member. `--agent-space-id` takes precedence over `TE_AGENT_CURRENT_AGENT_SPACE_ID` or the current AgentSpace working directory. When the shell has changed directories, `TE_AGENT_CONVERSATION_ID` resolves the space through the existing authenticated workspace target API; a resolution failure never falls back to the personal space. Membership and write permissions are enforced by the server.
60
66
 
61
- For conversational creation, keep the supplied prompt editable until the user sends it. Resolve missing or ambiguous targets, summarize the configuration and obtain confirmation before creating. Agent runs inherit its model unless explicitly overridden; Agent Team retains its own configuration. Omit `--trigger-immediately` unless the user requests an immediate run.
67
+ For conversational creation, keep the supplied prompt editable until the user sends it. Resolve missing or ambiguous targets, then run `automation create --dry-run` and present the complete draft. Wait for the user to approve that specific preview before the real create, including paused tasks. Each new task in the same chat and each revised configuration requires a fresh preview and confirmation. A clarification or an earlier approval does not authorize this write. After saving, share the complete `detailPath` returned by `automation get`, including the space query. A single Agent inherits its model unless explicitly overridden. Include its reasoning depth (adaptive by default) in the confirmation and ask only about ambiguous or conflicting depth requests. For an Agent Team, ignore any requested depth and state that the team uses its own settings. Omit `--trigger-immediately` unless the user requests an immediate run.
62
68
 
63
69
  ## Multi-date examples
64
70
 
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: ae-engage
3
- version: 1.0.1
3
+ version: 1.0.2
4
4
  description: "AE Engage capability gateway: config center, flows, push/config channels, strategies, templates, task management, operation activities, and query lifecycle. Trigger words: config center, scene config, push channel, config channel, operation strategy, operation task, operation activity, query lifecycle, template, config item, Engage, Hermes, engage-scene, engage-setting, engage-flow, engage-task, engage-activity, engage-query."
5
5
  ---
6
6
 
@@ -170,6 +170,11 @@ ae-cli engage-setting common-metric update --project-id <project_id> --metric-ty
170
170
  ae-cli engage-setting common-metric delete --project-id <project_id> --metric-name <name> --yes
171
171
  ```
172
172
 
173
+ Common metrics support rolling windows and natural day/week/month windows via
174
+ `--time-cycle-def`. Read [common-metric.md](references/common-metric.md) for the public
175
+ snake_case definition, update omission/null semantics, and required backend support.
176
+
177
+
173
178
  ### 2. task
174
179
 
175
180
  ```bash
@@ -112,4 +112,50 @@ property and percentile requirements as event metrics.
112
112
 
113
113
  Resolve every event and property through `ae-cli analysis-meta event list` and the corresponding property metadata before writing. `get` and `list` return `metric_definition`, `metric_definition_status`, and an optional unavailable reason. Raw metric QP is hidden.
114
114
 
115
- `metric_type=1` remains required for setting-page common metrics. Metric windows remain separate from the semantic definition, and their unit must be `minute` / `hour` / `day`.
115
+ ## Rolling and natural windows
116
+
117
+ `metric_type=1` remains required for setting-page common metrics. Window configuration is
118
+ separate from `metric_definition` and applies to both event and formula metrics.
119
+
120
+ - Rolling windows use `minute`, `hour`, or `day`. On create, omit `--time-cycle-def`
121
+ (or pass `null`) to keep the rolling behavior. A rolling day is not a calendar day.
122
+ - Natural windows use `day`, `week`, or `month` with `--metric-window-num 1` and a
123
+ non-null `--time-cycle-def` object. The capability input key is `time_cycle_def`;
124
+ its public nested keys are `start_time` / `start_day` (snake_case).
125
+
126
+ | Window | Unit | `--time-cycle-def` |
127
+ | --- | --- | --- |
128
+ | Calendar day | `day` | '{"start_time":"00:00"}' |
129
+ | Calendar week (Monday) | `week` | '{"start_day":1,"start_time":"00:00"}' |
130
+ | Calendar month | `month` | '{"start_day":1}' |
131
+ | Day starting at 06:30 | `day` | '{"start_time":"06:30"}' |
132
+ | Week starting Wednesday at 06:30 | `week` | '{"start_day":3,"start_time":"06:30"}' |
133
+ | Month starting on day 15 | `month` | '{"start_day":15}' |
134
+
135
+ Day/week `start_time` must use `HH:mm` (00:00-23:59). A day must omit `start_day`.
136
+ Week `start_day` is 1-7 (Monday-Sunday); month `start_day` is 1-28. A month must
137
+ omit `start_time` or set it to `00:00`. Unknown keys and invalid combinations are rejected.
138
+
139
+ For an existing verified event, add these flags to `common-metric create`:
140
+
141
+ ```bash
142
+ --metric-window-num 1 --metric-window-time-unit week \
143
+ --time-cycle-def '{"start_day":1,"start_time":"00:00"}'
144
+ ```
145
+
146
+ On **update**, omitting `--time-cycle-def` preserves the stored definition. The server
147
+ validates the new window parameters together with that definition; omission must not
148
+ silently turn a calendar day into a rolling day. Pass a new object to change the cycle,
149
+ or explicitly pass `--time-cycle-def null` and a rolling unit to clear it. For example,
150
+ switching to a rolling day uses:
151
+
152
+ ```bash
153
+ --metric-window-num 1 --metric-window-time-unit day --time-cycle-def null
154
+ ```
155
+
156
+ `get` and `list` return `time_cycle_def` (an object, or `null` for rolling windows).
157
+ After create/update, read the metric back and check that the definition matches the intent.
158
+ When binding a PRESET metric to a task or flow, reference its verified metric name using
159
+ the documented metric-update contract; the saved common metric provides the window.
160
+ Hermes with natural common-metric capability support must be deployed before using the
161
+ new flags. Older Hermes versions may reject `time_cycle_def` or week/month units.
@@ -68,7 +68,7 @@ Natural window constraints:
68
68
  - Month: require `startDay` from `1` to `28`; omit `startTime` or use `"00:00"`.
69
69
  - An empty `timeCycleDef: {}` is invalid. Without `timeCycleDef`, only rolling `minute`, `hour`, and `day` units are accepted.
70
70
  - When switching rolling to calendar, add the matching `timeCycleDef` and set the number/unit together. When switching back, remove `timeCycleDef` entirely and use a valid rolling unit. Preserve the binding's `metricSettingId` and all other desired metrics.
71
- - These options apply to custom metrics (`metricType: 2`) through `metric update`. Do not use `engage-setting common-metric create/update` to create natural windows.
71
+ - Custom metrics (`metricType: 2`) configure these options through `metric update`. PRESET natural metrics (`metricType: 1`) can be created or updated with `engage-setting common-metric create/update --time-cycle-def` when the matching Hermes capability is deployed; see [common-metric.md](common-metric.md). Reference the saved preset metric name when binding and verify its persisted cycle after saving.
72
72
  - Task support requires a backend deployment containing the task natural-window feature. Do not silently replace an unsupported calendar window with a rolling duration.
73
73
 
74
74
  ### Custom metric payload examples
@@ -59,7 +59,7 @@ Natural window constraints:
59
59
  - Month: require `startDay` from `1` to `28`; omit `startTime` or use `"00:00"`.
60
60
  - An empty `timeCycleDef: {}` is invalid. Without `timeCycleDef`, only rolling `minute`, `hour`, and `day` units are accepted.
61
61
  - When switching rolling to calendar, add the matching `timeCycleDef` and set the number/unit together. When switching back, remove `timeCycleDef` entirely and use a valid rolling unit. Preserve the binding's `metricSettingId` and all other desired metrics.
62
- - These options apply to custom metrics (`metricType: 2`) through `metric update`. Do not use `engage-setting common-metric create/update` to create natural windows.
62
+ - Custom metrics (`metricType: 2`) configure these options through `metric update`. PRESET natural metrics (`metricType: 1`) can be created or updated with `engage-setting common-metric create/update --time-cycle-def` when the matching Hermes capability is deployed; see [common-metric.md](common-metric.md). Reference the saved preset metric name when binding and verify its persisted cycle after saving.
63
63
  - Task support requires a backend deployment containing the task natural-window feature. Do not silently replace an unsupported calendar window with a rolling duration.
64
64
 
65
65
  ### Custom metric payload examples
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: ae-kb
3
- version: 1.0.13
3
+ version: 1.0.15
4
4
  description: 'AE knowledge base CLI manual for creating, importing read-only compiled snapshots, querying, LLM-powered ask, listing accessible knowledge bases and their sources, deterministic index/grep/read retrieval, checking status, ZIP source upload and directory management, raw child-file reading, revision-checked child updates and deletion, compiling, schema generation, URL sources, source deletion, ordinary text source creation, full reads and revision-checked editing, file/ZIP source draft replacement and restoration, and knowledge base deletion. Use when the user asks to manage AE (Agentic Engine) knowledge bases, import a compiled Markdown ZIP snapshot, upload documents or URLs to a knowledge base, query knowledge, ask knowledge bases with an LLM, list accessible knowledge bases or source metadata, inspect knowledge base indexes, search knowledge base pages, read a specific knowledge base page, check knowledge base status, generate schemas, compile knowledge, remove sources, create or edit text sources, or delete a knowledge base. To choose which knowledge base is worth searching, use the ae-kb-discovery skill first; this skill runs the retrieval once a target is chosen. Must use ae-cli kb commands and must not guess knowledge base names, scopes, page paths, source IDs, source display names, JSON payload shapes, or URL formats.'
5
5
  ---
6
6
 
@@ -294,7 +294,7 @@ Compile after sources and schema are ready:
294
294
  ae-cli kb +compile --name engineering-handbook --scope company --mode incremental
295
295
  ```
296
296
 
297
- Valid compile modes are `incremental` and `full`; default is `incremental`.
297
+ Valid compile modes are `incremental` and `full`; default is `incremental`. The optional `--content-language` checks the working declaration without changing it. When a server rejects a new language option, report that the server does not support it; never retry without the requested option. Verify actual index and page text with `+index` and `+read` before claiming content acceptance.
298
298
 
299
299
  ### Check Knowledge Base Status
300
300
 
@@ -500,7 +500,7 @@ ae-cli kb +grep --query "<keywords>" --sources '[{"scope":"company","name":"kb-n
500
500
 
501
501
  - `--query`, alias `-q`: required keywords to search.
502
502
  - `--sources`: required JSON array of knowledge base refs.
503
- - `--paths`: required JSON array of wiki pages or subdirectories **copied** from current `+index`, `+grep` or `+read` navigation links. Do not invent paths. A single page is still an array, e.g. `["wiki/sandbox.md"]`. Distinct from `+read --path` (one string).
503
+ - `--paths`: required JSON array of files or subdirectories strictly under `wiki/`, **copied** from current `+index`, `+grep` or `+read` navigation links. The roots `wiki` and `wiki/`, `index.md`, `raw/`, absolute paths and paths escaping `wiki/` are invalid. Do not invent paths or use the wiki root as a full-library search fallback. If navigation provides no usable paths, skip `+grep` and continue with navigation or linked pages. A single page is still an array, e.g. `["wiki/sandbox.md"]`. Distinct from `+read --path` (one string).
504
504
  - `--top-k`: optional max number of hits, 1-50, default 10.
505
505
  - `--locale`: optional locale: `zh`, `en`, `ja`, or `ko`.
506
506
  - Each page entry in results carries `hitCount` (full match count), `pageKind`, and `sections` previews with `sectionStartLine` / `sectionEndLine` — use the section range as the `+read` window.
@@ -564,9 +564,11 @@ ae-cli kb +url --name "<name>" --url "https://example.com/page" [--scope persona
564
564
  ### `+schema`
565
565
 
566
566
  ```bash
567
- ae-cli kb +schema --name "<name>" [--scope personal|company] [--force] [--model <model-ref>] [--custom-instructions "<one-time guidance>"]
567
+ ae-cli kb +schema --name "<name>" [--scope personal|company] [--force] [--model <model-ref>] [--custom-instructions "<one-time guidance>"] [--content-language <primary-tag>] [--rewrite-language]
568
568
  ```
569
569
 
570
+ - Use `--content-language` only when the user explicitly requests a knowledge-base content language. The conversation language alone does not select it. Without a flag the server keeps the existing declaration or infers the language.
571
+ - Use `--rewrite-language --content-language ko` to change language while retaining the existing compilation rules. To publish a change between declared languages, run a complete full compilation.
570
572
  - `--custom-instructions`: Optional per-run schema-generation guidance. It is not persisted; whitespace-only input is omitted. The server allows at most 10,000 Unicode characters and rejects disallowed control characters. Do not include secrets or credentials.
571
573
  - `--force`: Replace the current attempt only when schema generation is already running and the user explicitly requests the replacement. The selected model and custom instructions apply to the new attempt, which may consume additional tokens.
572
574
  - `--dry-run`: Shows the same `customInstructions` request field that execution will send.
@@ -577,7 +579,7 @@ ae-cli kb +schema --name "<name>" [--scope personal|company] [--force] [--model
577
579
  ### `+compile`
578
580
 
579
581
  ```bash
580
- ae-cli kb +compile --name "<name>" [--scope personal|company] [--mode incremental|full] [--model <model-ref>]
582
+ ae-cli kb +compile --name "<name>" [--scope personal|company] [--mode incremental|full] [--model <model-ref>] [--content-language <primary-tag>]
581
583
  ```
582
584
 
583
585
  ### `+status`
@@ -586,7 +588,7 @@ ae-cli kb +compile --name "<name>" [--scope personal|company] [--mode incrementa
586
588
  ae-cli kb +status --name "<name>" [--scope personal|company] [--run-id <compile-run-id>]
587
589
  ```
588
590
 
589
- With `--run-id`, output contains `knowledgeBase` and `compileRun` (`id`, `status`, `errorMessage`, `startedAt`, `finishedAt`) instead of the aggregate lifecycle fields. Copy the ID from `+compile`; wait only for `queued`/`running`, and stop on `succeeded`/`failed`/`cancelled`. A failed run remains failed even when an older published version is available. Exact-run diagnostics require the same compile-run permission as the KB run-detail view, and error text is redacted. The run must belong to the resolved, authorized KB; unknown and cross-KB IDs return `KB_COMPILE_RUN_NOT_FOUND`. Existing calls without `--run-id` are unchanged. Older servers may reject the optional field; do not fall back to aggregate polling for exact-run completion. Run success is separate from publication completeness and content acceptance.
591
+ With `--run-id`, output contains `knowledgeBase` and `compileRun` (`id`, `status`, `errorMessage`, `startedAt`, `finishedAt`) instead of the aggregate lifecycle fields. Copy the ID from `+compile`; wait only for `queued`/`running`, and stop on `succeeded`/`failed`/`cancelled`. A failed run remains failed even when an older published version is available. Exact-run diagnostics require the same compile-run permission as the KB run-detail view, and error text is redacted. The run must belong to the resolved, authorized KB; unknown and cross-KB IDs return `KB_COMPILE_RUN_NOT_FOUND`. Aggregate output includes working and published language declarations when available. Exact-run output can include structured `runStatus` and an original-language `contentSummary`. A legacy `summary` is a historical task status. Older servers may reject the optional field; do not fall back to aggregate polling for exact-run completion. Run success is separate from publication completeness and content acceptance.
590
592
 
591
593
  ### `+list-sources`
592
594
 
@@ -43,7 +43,11 @@ A revision or access-context change requires revalidation, not silent reuse.
43
43
 
44
44
  2. **Grep copied paths.** When no sufficiently specific page link is known,
45
45
  copy 1–3 `wiki/...` entries from the navigation already returned (a page
46
- such as `wiki/sandbox.md`, or a subdirectory such as `wiki/guides`). Call
46
+ such as `wiki/sandbox.md`, or a subdirectory such as `wiki/guides`). Each
47
+ entry must be strictly below `wiki/`: the roots `wiki` and `wiki/`,
48
+ `index.md`, `raw/`, absolute paths and paths escaping `wiki/` are invalid.
49
+ Never use the wiki root as a full-library search fallback. If navigation
50
+ provides no usable paths, skip grep as described below. Call
47
51
  `+grep` with the candidate `--sources` and the copied list as `--paths`. Search
48
52
  with the terms in the returned navigation. If the first grep misses, rewrite
49
53
  the query **once** using different terms from that navigation, still with