@thinkingai/ae-cli 6.1.17 → 6.1.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{auth-2WTQOP77.js → auth-GBMV6TEJ.js} +3 -3
- package/dist/{auth-77BUFLGC.js → auth-ROB2EDYV.js} +12 -13
- package/dist/{capability-72DTW5M2.js → capability-DKMYUTLC.js} +50 -13
- package/dist/{capability-PJHNI4GJ.js → capability-HYVVPG25.js} +49 -12
- package/dist/chunk-3FY3RJ26.js +293 -0
- package/dist/{chunk-PTE56QPL.js → chunk-3KWQYGYI.js} +4 -0
- package/dist/{chunk-UOUS37JQ.js → chunk-4XXOWOTA.js} +3 -3
- package/dist/{chunk-GT46FPXN.js → chunk-BYYS3ANB.js} +17 -8
- package/dist/{chunk-YA6SMTXG.js → chunk-EFH4XWYC.js} +3 -3
- package/dist/{chunk-4SGZG4XY.js → chunk-J2DEBMRF.js} +9 -7
- package/dist/{chunk-LYVNONC4.js → chunk-JHENBQ5B.js} +35 -0
- package/dist/{chunk-VR3LCBHW.js → chunk-JRJY5DMJ.js} +5 -5
- package/dist/{chunk-ILIU36SU.js → chunk-OMPRXM3V.js} +3 -3
- package/dist/{chunk-VPKZ7I72.js → chunk-QNOLN2LJ.js} +2 -2
- package/dist/{chunk-SAU3QFIQ.js → chunk-QZ3AS4KK.js} +3 -3
- package/dist/chunk-RJDU7NYP.js +1198 -0
- package/dist/{chunk-4KVPKXFX.js → chunk-RNAALWJK.js} +2 -2
- package/dist/{chunk-C4MGVGJW.js → chunk-SERWF6G5.js} +1 -1
- package/dist/{chunk-RGKJGKT7.js → chunk-Y3LOALAV.js} +5 -5
- package/dist/{chunk-P3FGXJTU.js → chunk-ZQ47LWTI.js} +4 -4
- package/dist/chunk-ZQKDZXDO.js +317 -0
- package/dist/{client-TKG4WBHN.js → client-L2YDMHQ6.js} +5 -4
- package/dist/{community-report-client-FI4LNVYS.js → community-report-client-C7WDGET3.js} +1 -2
- package/dist/{config-RE6CMGPK.js → config-BMYZX2UE.js} +7 -6
- package/dist/{data-integration-XQYB4X4F.js → data-integration-QEKDWQDY.js} +1601 -192
- package/dist/index.js +131 -1241
- package/dist/{local-data-upload-client-BWHSUQQK.js → local-data-upload-client-4YYHSYD6.js} +1 -2
- package/dist/{memory-CHRU2F7W.js → memory-3ORCR7JH.js} +6 -6
- package/dist/{memory-YK33G4T7.js → memory-I2WXDTV2.js} +5 -5
- package/dist/{metadata-XXR34N5P.js → metadata-I4C2EWUN.js} +10 -10
- package/dist/{metadata-UILXHBWF.js → metadata-VUOQJE26.js} +9 -9
- package/dist/{model-NR3JHFSJ.js → model-HLHIEFMU.js} +5 -5
- package/dist/{model-K3KLWIW6.js → model-UGRDX4MW.js} +6 -6
- package/dist/personal-semantic-preference-LIPACBDX.js +239 -0
- package/dist/personal-semantic-preference-OEISBRHM.js +239 -0
- package/dist/project-semantic-FFPWFPIW.js +1114 -0
- package/dist/project-semantic-RT3R2VQD.js +1114 -0
- package/dist/{sync-FCKOVWWS.js → sync-HKIOZXQE.js} +6 -6
- package/dist/{sync-DAVKYVMW.js → sync-TFHU2UTG.js} +7 -7
- package/dist/{te-agent-HLW4VTQK.js → te-agent-BR6VDBNX.js} +9 -8
- package/dist/{te-agent-4BKBODMF.js → te-agent-VLYOV7S4.js} +8 -7
- package/dist/{te-analysis-ZMNGOVNW.js → te-analysis-4YGQL5RC.js} +437 -38
- package/dist/{te-analysis-O6DCO6BS.js → te-analysis-7VUNUYWZ.js} +436 -37
- package/dist/{te-community-HLC43QKH.js → te-community-5DMNKJWY.js} +5 -5
- package/dist/{te-community-6HPBWJUZ.js → te-community-ISDQWJU7.js} +6 -6
- package/dist/{te-dataops-HDRUXY4K.js → te-dataops-6P5IKWNJ.js} +8 -7
- package/dist/{te-dataops-EJP56W3K.js → te-dataops-CVULXNVB.js} +7 -6
- package/dist/{te-engage-RAK5PESW.js → te-engage-KZPR5R22.js} +9 -9
- package/dist/{te-engage-FGBGQ4IY.js → te-engage-N5WI32H6.js} +8 -8
- package/dist/{te-experiment-SO5MPDMJ.js → te-experiment-6BITX4RD.js} +226 -8
- package/dist/{te-experiment-VZF7BT6G.js → te-experiment-UVR4HLND.js} +227 -9
- package/dist/{te-kb-SQCLHG6X.js → te-kb-RCLSSH2Q.js} +7 -7
- package/dist/{te-system-Z77IKZFN.js → te-system-FXITO2JG.js} +5 -5
- package/dist/{te-system-YARIK4S5.js → te-system-K2GYMCTB.js} +6 -6
- package/dist/{te-team-EFKWYKMK.js → te-team-ADOC2ROP.js} +6 -6
- package/dist/{update-OGPSZM5A.js → update-YCYCKJOO.js} +7 -6
- package/package.json +1 -1
- package/skills/ae-agent/SKILL.md +3 -4
- package/skills/ae-agent/references/edit-skill.md +3 -0
- package/skills/ae-agent/references/get-skill-content.md +1 -1
- package/skills/ae-agent/references/rescan-skills.md +15 -13
- package/skills/ae-agent/references/upload-skill.md +7 -4
- package/skills/ae-analysis/SKILL.md +45 -4
- package/skills/ae-analysis/metadata_resolution.md +38 -4
- package/skills/ae-analysis/references/analysis_data_retrieval.md +29 -0
- package/skills/ae-analysis/references/asset_authentication_export.md +22 -0
- package/skills/ae-analysis/references/asset_authentication_list.md +18 -14
- package/skills/ae-analysis/references/asset_authentication_update.md +29 -14
- package/skills/ae-analysis/references/command_index.md +17 -9
- package/skills/ae-analysis/references/dashboard_get.md +18 -1
- package/skills/ae-analysis/references/dashboard_update.md +3 -0
- package/skills/ae-analysis/references/personal_semantic_preference_add.md +23 -0
- package/skills/ae-analysis/references/personal_semantic_preference_delete.md +17 -0
- package/skills/ae-analysis/references/personal_semantic_preference_get.md +19 -0
- package/skills/ae-analysis/references/personal_semantic_preference_list.md +21 -0
- package/skills/ae-analysis/references/personal_semantic_preference_update.md +19 -0
- package/skills/ae-data-integration/SKILL.md +23 -4
- package/skills/ae-data-integration/references/custom-layer.md +93 -0
- package/skills/ae-data-integration/references/error-handling.md +92 -0
- package/skills/ae-data-integration/references/handoff.md +77 -18
- package/skills/ae-data-integration/references/local-analysis.md +1 -1
- package/skills/ae-data-integration/references/reuse.md +9 -5
- package/skills/ae-data-integration/references/sink-upload.md +1 -1
- package/skills/ae-data-integration/references/source-inspect.md +18 -12
- package/skills/ae-data-integration/references/tracking-plan.md +7 -5
- package/skills/ae-data-integration/references/transform.md +10 -10
- package/skills/ae-data-integration/references/ue-mapping.md +33 -11
- package/skills/ae-engage/references/build-task-save-guide.md +9 -0
- package/skills/ae-engage/references/save-task.md +82 -0
- package/skills/ae-experiment/SKILL.md +8 -2
- package/skills/ae-experiment/references/manage_feature_whitelist.md +66 -0
- package/skills/ae-experiment/references/manage_guardrail_metrics.md +26 -0
- package/skills/ae-experiment/references/save_experiment.md +1 -1
- package/skills/ae-kb/SKILL.md +1 -1
- package/skills/ae-project-semantic/SKILL.md +193 -0
- package/skills/ae-project-semantic/references/query-routing-v5.md +165 -0
- package/skills/ae-project-semantic/references/recommendation-quality.md +68 -0
- package/dist/chunk-QGM4M3NI.js +0 -37
- package/dist/chunk-ZZUOD757.js +0 -598
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import {
|
|
2
2
|
createCapabilityCommand
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-Y3LOALAV.js";
|
|
4
4
|
import {
|
|
5
5
|
registerCapabilityGatewayRoute
|
|
6
|
-
} from "./chunk-
|
|
7
|
-
import "./chunk-
|
|
8
|
-
import "./chunk-
|
|
9
|
-
import "./chunk-
|
|
10
|
-
import "./chunk-
|
|
11
|
-
import "./chunk-
|
|
6
|
+
} from "./chunk-3KWQYGYI.js";
|
|
7
|
+
import "./chunk-BYYS3ANB.js";
|
|
8
|
+
import "./chunk-ZQ47LWTI.js";
|
|
9
|
+
import "./chunk-SERWF6G5.js";
|
|
10
|
+
import "./chunk-J2DEBMRF.js";
|
|
11
|
+
import "./chunk-ZQKDZXDO.js";
|
|
12
|
+
import "./chunk-3FY3RJ26.js";
|
|
12
13
|
import "./chunk-UW5UN47B.js";
|
|
13
|
-
import "./chunk-
|
|
14
|
-
import "./chunk-QGM4M3NI.js";
|
|
14
|
+
import "./chunk-JHENBQ5B.js";
|
|
15
15
|
|
|
16
16
|
// src/commands/te-experiment/capability-shared.ts
|
|
17
17
|
function createExperimentCapabilityCommand(config) {
|
|
@@ -283,6 +283,54 @@ var experimentUpdateGroup = createExperimentCapabilityCommand({
|
|
|
283
283
|
})
|
|
284
284
|
});
|
|
285
285
|
|
|
286
|
+
// src/commands/te-experiment/experiment/update-metrics.ts
|
|
287
|
+
var METRIC_ROLES = /* @__PURE__ */ new Set(["primary", "secondary", "guardrail"]);
|
|
288
|
+
function readMetricBindings(ctx) {
|
|
289
|
+
const value = ctx.json("metrics");
|
|
290
|
+
if (!Array.isArray(value) || value.length === 0) {
|
|
291
|
+
throw new Error("Flag --metrics must be a non-empty JSON array");
|
|
292
|
+
}
|
|
293
|
+
for (let index = 0; index < value.length; index += 1) {
|
|
294
|
+
const item = value[index];
|
|
295
|
+
if (!item || typeof item !== "object" || Array.isArray(item)) {
|
|
296
|
+
throw new Error(`Flag --metrics[${index}] must be a JSON object`);
|
|
297
|
+
}
|
|
298
|
+
const metricId = item.metricId;
|
|
299
|
+
const metricRole = item.metricRole;
|
|
300
|
+
if (typeof metricId !== "string" || metricId.trim() === "") {
|
|
301
|
+
throw new Error(`Flag --metrics[${index}].metricId must be a non-empty string`);
|
|
302
|
+
}
|
|
303
|
+
if (typeof metricRole !== "string" || !METRIC_ROLES.has(metricRole)) {
|
|
304
|
+
throw new Error(`Flag --metrics[${index}].metricRole must be one of primary, secondary, guardrail`);
|
|
305
|
+
}
|
|
306
|
+
}
|
|
307
|
+
return value;
|
|
308
|
+
}
|
|
309
|
+
var experimentUpdateMetrics = createExperimentCapabilityCommand({
|
|
310
|
+
resource: "experiment",
|
|
311
|
+
command: "update-metrics",
|
|
312
|
+
capabilityId: "experiment.experiment.save",
|
|
313
|
+
description: "Replace experiment metric bindings and assign primary, secondary, or guardrail roles.",
|
|
314
|
+
flags: [
|
|
315
|
+
{ name: "project-id", type: "number", required: true, alias: "p", desc: "Numeric project ID." },
|
|
316
|
+
{ name: "exp-id", type: "string", required: true, desc: "Experiment draft ID." },
|
|
317
|
+
{
|
|
318
|
+
name: "metrics",
|
|
319
|
+
type: "json",
|
|
320
|
+
required: true,
|
|
321
|
+
desc: "Non-empty metric binding array with camelCase metricId and metricRole fields; replaces all saved bindings."
|
|
322
|
+
}
|
|
323
|
+
],
|
|
324
|
+
risk: "write",
|
|
325
|
+
validate: (ctx) => {
|
|
326
|
+
readMetricBindings(ctx);
|
|
327
|
+
},
|
|
328
|
+
buildInput: (ctx) => ({
|
|
329
|
+
project_id: ctx.num("project-id"),
|
|
330
|
+
req: { expId: ctx.str("exp-id"), metrics: readMetricBindings(ctx) }
|
|
331
|
+
})
|
|
332
|
+
});
|
|
333
|
+
|
|
286
334
|
// src/commands/te-experiment/feature/batch-delete.ts
|
|
287
335
|
var featureBatchDelete = createExperimentCapabilityCommand({
|
|
288
336
|
resource: "feature",
|
|
@@ -402,6 +450,166 @@ var featureOperationLogQuery = createExperimentCapabilityCommand({
|
|
|
402
450
|
})
|
|
403
451
|
});
|
|
404
452
|
|
|
453
|
+
// src/commands/te-experiment/feature-whitelist/shared.ts
|
|
454
|
+
function readRuleIds(ctx) {
|
|
455
|
+
const value = ctx.json("rule-ids");
|
|
456
|
+
if (!Array.isArray(value) || value.length === 0 || !value.every((item) => typeof item === "string" && item.trim() !== "")) {
|
|
457
|
+
throw new Error("Flag --rule-ids must be a non-empty JSON array of strings");
|
|
458
|
+
}
|
|
459
|
+
return value;
|
|
460
|
+
}
|
|
461
|
+
function readWhitelist(ctx) {
|
|
462
|
+
const value = ctx.json("whitelist");
|
|
463
|
+
if (!Array.isArray(value) || value.length === 0) {
|
|
464
|
+
throw new Error("Flag --whitelist must be a non-empty JSON array");
|
|
465
|
+
}
|
|
466
|
+
const bucketIds = /* @__PURE__ */ new Set();
|
|
467
|
+
value.forEach((bucket, bucketIndex) => {
|
|
468
|
+
if (!bucket || typeof bucket !== "object" || Array.isArray(bucket)) {
|
|
469
|
+
throw new Error(`Flag --whitelist[${bucketIndex}] must be a JSON object`);
|
|
470
|
+
}
|
|
471
|
+
const item = bucket;
|
|
472
|
+
if (typeof item.bucket_id !== "string" || item.bucket_id.trim() === "") {
|
|
473
|
+
throw new Error(`Flag --whitelist[${bucketIndex}].bucket_id must be a non-empty string`);
|
|
474
|
+
}
|
|
475
|
+
if (bucketIds.has(item.bucket_id)) {
|
|
476
|
+
throw new Error(`Flag --whitelist contains duplicate bucket_id: ${item.bucket_id}`);
|
|
477
|
+
}
|
|
478
|
+
bucketIds.add(item.bucket_id);
|
|
479
|
+
if (!Array.isArray(item.rules) || item.rules.length === 0) {
|
|
480
|
+
throw new Error(`Flag --whitelist[${bucketIndex}].rules must be a non-empty array`);
|
|
481
|
+
}
|
|
482
|
+
const bucketValueIds = /* @__PURE__ */ new Set();
|
|
483
|
+
item.rules.forEach((rule, ruleIndex) => {
|
|
484
|
+
if (!rule || typeof rule !== "object" || Array.isArray(rule)) {
|
|
485
|
+
throw new Error(`Flag --whitelist[${bucketIndex}].rules[${ruleIndex}] must be a JSON object`);
|
|
486
|
+
}
|
|
487
|
+
const row = rule;
|
|
488
|
+
if (!Array.isArray(row.ids) || row.ids.length === 0 || !row.ids.every((id) => typeof id === "string" && id.trim() !== "")) {
|
|
489
|
+
throw new Error(`Flag --whitelist[${bucketIndex}].rules[${ruleIndex}].ids must be a non-empty string array`);
|
|
490
|
+
}
|
|
491
|
+
row.ids.forEach((id) => {
|
|
492
|
+
if (bucketValueIds.has(id)) {
|
|
493
|
+
throw new Error(`Flag --whitelist bucket ${item.bucket_id} contains duplicate ID: ${id}`);
|
|
494
|
+
}
|
|
495
|
+
bucketValueIds.add(id);
|
|
496
|
+
});
|
|
497
|
+
if (typeof row.value !== "string") {
|
|
498
|
+
throw new Error(`Flag --whitelist[${bucketIndex}].rules[${ruleIndex}].value must be a string`);
|
|
499
|
+
}
|
|
500
|
+
});
|
|
501
|
+
});
|
|
502
|
+
return value;
|
|
503
|
+
}
|
|
504
|
+
|
|
505
|
+
// src/commands/te-experiment/feature-whitelist/batch-delete.ts
|
|
506
|
+
function buildBody(ctx) {
|
|
507
|
+
return { project_id: ctx.num("project-id"), rule_ids: readRuleIds(ctx) };
|
|
508
|
+
}
|
|
509
|
+
var featureWhitelistBatchDelete = createExperimentCapabilityCommand({
|
|
510
|
+
resource: "feature whitelist",
|
|
511
|
+
command: "batch-delete",
|
|
512
|
+
capabilityId: "experiment.feature_whitelist.batch_delete",
|
|
513
|
+
description: "Delete Feature whitelist rules; enabled whitelist rules are allowed and trigger RCC resync.",
|
|
514
|
+
flags: [
|
|
515
|
+
{ name: "project-id", type: "number", required: true, alias: "p", desc: "Numeric project ID." },
|
|
516
|
+
{ name: "rule-ids", type: "json", required: true, desc: "Non-empty JSON array of whitelist rule IDs." }
|
|
517
|
+
],
|
|
518
|
+
risk: "high-risk-write",
|
|
519
|
+
validate: (ctx) => {
|
|
520
|
+
buildBody(ctx);
|
|
521
|
+
},
|
|
522
|
+
buildInput: buildBody
|
|
523
|
+
});
|
|
524
|
+
|
|
525
|
+
// src/commands/te-experiment/feature-whitelist/list.ts
|
|
526
|
+
function buildInput5(ctx) {
|
|
527
|
+
return {
|
|
528
|
+
project_id: ctx.num("project-id"),
|
|
529
|
+
feature_key: ctx.str("feature-key")
|
|
530
|
+
};
|
|
531
|
+
}
|
|
532
|
+
var featureWhitelistList = createExperimentCapabilityCommand({
|
|
533
|
+
resource: "feature whitelist",
|
|
534
|
+
command: "list",
|
|
535
|
+
capabilityId: "experiment.feature_whitelist.list",
|
|
536
|
+
description: "List explicit whitelist rules for one Feature.",
|
|
537
|
+
flags: [
|
|
538
|
+
{ name: "project-id", type: "number", required: true, alias: "p", desc: "Numeric project ID." },
|
|
539
|
+
{ name: "feature-key", type: "string", required: true, desc: "Existing Feature key." }
|
|
540
|
+
],
|
|
541
|
+
risk: "read",
|
|
542
|
+
buildInput: buildInput5
|
|
543
|
+
});
|
|
544
|
+
|
|
545
|
+
// src/commands/te-experiment/feature-whitelist/save.ts
|
|
546
|
+
function buildInput6(ctx) {
|
|
547
|
+
const ruleId = ctx.str("rule-id").trim();
|
|
548
|
+
const status = ctx.str("status").trim() || "draft";
|
|
549
|
+
if (!["draft", "enable", "disable"].includes(status)) {
|
|
550
|
+
throw new Error("Flag --status must be one of draft, enable, disable");
|
|
551
|
+
}
|
|
552
|
+
const input = {
|
|
553
|
+
project_id: ctx.num("project-id"),
|
|
554
|
+
feature_key: ctx.str("feature-key"),
|
|
555
|
+
whitelist: readWhitelist(ctx),
|
|
556
|
+
status
|
|
557
|
+
};
|
|
558
|
+
if (ruleId) input.rule_id = ruleId;
|
|
559
|
+
const priority = ctx.str("priority");
|
|
560
|
+
if (priority !== "") input.priority = ctx.num("priority");
|
|
561
|
+
return input;
|
|
562
|
+
}
|
|
563
|
+
var featureWhitelistSave = createExperimentCapabilityCommand({
|
|
564
|
+
resource: "feature whitelist",
|
|
565
|
+
command: "save",
|
|
566
|
+
capabilityId: "experiment.feature_whitelist.save",
|
|
567
|
+
description: "Create or modify a Feature whitelist rule and optionally enable it.",
|
|
568
|
+
flags: [
|
|
569
|
+
{ name: "project-id", type: "number", required: true, alias: "p", desc: "Numeric project ID." },
|
|
570
|
+
{ name: "feature-key", type: "string", required: true, desc: "Existing Feature key." },
|
|
571
|
+
{ name: "rule-id", type: "string", desc: "Existing whitelist rule ID; omit to create a new rule." },
|
|
572
|
+
{ name: "priority", type: "number", desc: "Rule priority; omitted create requests use the server-assigned next priority." },
|
|
573
|
+
{ name: "status", type: "string", default: "draft", desc: "Rule status: draft, enable, or disable." },
|
|
574
|
+
{
|
|
575
|
+
name: "whitelist",
|
|
576
|
+
type: "json",
|
|
577
|
+
required: true,
|
|
578
|
+
desc: 'Whitelist bucket array: [{"bucket_id":"#user_id","rules":[{"ids":["u1"],"value":"on"}]}].'
|
|
579
|
+
}
|
|
580
|
+
],
|
|
581
|
+
risk: "write",
|
|
582
|
+
validate: (ctx) => {
|
|
583
|
+
buildInput6(ctx);
|
|
584
|
+
},
|
|
585
|
+
buildInput: buildInput6
|
|
586
|
+
});
|
|
587
|
+
|
|
588
|
+
// src/commands/te-experiment/feature-whitelist/update-status.ts
|
|
589
|
+
function buildBody2(ctx) {
|
|
590
|
+
const status = ctx.str("status");
|
|
591
|
+
if (!["enable", "disable"].includes(status)) {
|
|
592
|
+
throw new Error("Flag --status must be one of enable, disable");
|
|
593
|
+
}
|
|
594
|
+
return { project_id: ctx.num("project-id"), rule_id: ctx.str("rule-id"), status };
|
|
595
|
+
}
|
|
596
|
+
var featureWhitelistUpdateStatus = createExperimentCapabilityCommand({
|
|
597
|
+
resource: "feature whitelist",
|
|
598
|
+
command: "update-status",
|
|
599
|
+
capabilityId: "experiment.feature_whitelist.update_status",
|
|
600
|
+
description: "Enable or disable a Feature whitelist rule; enabled rules sync an online Feature to RCC.",
|
|
601
|
+
flags: [
|
|
602
|
+
{ name: "project-id", type: "number", required: true, alias: "p", desc: "Numeric project ID." },
|
|
603
|
+
{ name: "rule-id", type: "string", required: true, desc: "Whitelist rule ID." },
|
|
604
|
+
{ name: "status", type: "string", required: true, desc: "Target status: enable or disable." }
|
|
605
|
+
],
|
|
606
|
+
risk: "write",
|
|
607
|
+
validate: (ctx) => {
|
|
608
|
+
buildBody2(ctx);
|
|
609
|
+
},
|
|
610
|
+
buildInput: buildBody2
|
|
611
|
+
});
|
|
612
|
+
|
|
405
613
|
// src/commands/te-experiment/metric/delete.ts
|
|
406
614
|
var metricDelete = createExperimentCapabilityCommand({
|
|
407
615
|
resource: "metric",
|
|
@@ -709,6 +917,7 @@ var commands = [
|
|
|
709
917
|
experimentConflictCheck,
|
|
710
918
|
experimentManage,
|
|
711
919
|
experimentUpdateGroup,
|
|
920
|
+
experimentUpdateMetrics,
|
|
712
921
|
experimentBatchDelete,
|
|
713
922
|
operationLogQuery,
|
|
714
923
|
saveBuildGuide,
|
|
@@ -731,6 +940,10 @@ var commands = [
|
|
|
731
940
|
featureVersionList,
|
|
732
941
|
featureOperationLogQuery,
|
|
733
942
|
featureBatchDelete,
|
|
943
|
+
featureWhitelistList,
|
|
944
|
+
featureWhitelistSave,
|
|
945
|
+
featureWhitelistUpdateStatus,
|
|
946
|
+
featureWhitelistBatchDelete,
|
|
734
947
|
bucketList
|
|
735
948
|
];
|
|
736
949
|
var te_experiment_default = commands;
|
|
@@ -746,6 +959,7 @@ export {
|
|
|
746
959
|
experimentReadyCheck,
|
|
747
960
|
experimentSave,
|
|
748
961
|
experimentUpdateGroup,
|
|
962
|
+
experimentUpdateMetrics,
|
|
749
963
|
featureBatchDelete,
|
|
750
964
|
featureGet,
|
|
751
965
|
featureList,
|
|
@@ -753,6 +967,10 @@ export {
|
|
|
753
967
|
featureSave,
|
|
754
968
|
featureUpdateStatus,
|
|
755
969
|
featureVersionList,
|
|
970
|
+
featureWhitelistBatchDelete,
|
|
971
|
+
featureWhitelistList,
|
|
972
|
+
featureWhitelistSave,
|
|
973
|
+
featureWhitelistUpdateStatus,
|
|
756
974
|
metricDelete,
|
|
757
975
|
metricGet,
|
|
758
976
|
metricList,
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import {
|
|
2
2
|
kbApi,
|
|
3
3
|
kbUpload
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-RNAALWJK.js";
|
|
5
5
|
import {
|
|
6
6
|
printError
|
|
7
|
-
} from "./chunk-
|
|
8
|
-
import "./chunk-
|
|
9
|
-
import "./chunk-
|
|
7
|
+
} from "./chunk-BYYS3ANB.js";
|
|
8
|
+
import "./chunk-J2DEBMRF.js";
|
|
9
|
+
import "./chunk-ZQKDZXDO.js";
|
|
10
|
+
import "./chunk-3FY3RJ26.js";
|
|
10
11
|
import {
|
|
11
12
|
PermissionError
|
|
12
13
|
} from "./chunk-UW5UN47B.js";
|
|
13
|
-
import "./chunk-
|
|
14
|
-
import "./chunk-QGM4M3NI.js";
|
|
14
|
+
import "./chunk-JHENBQ5B.js";
|
|
15
15
|
|
|
16
16
|
// src/commands/te-kb/add.ts
|
|
17
17
|
import { promises as fs } from "fs";
|
|
@@ -884,7 +884,7 @@ var url = {
|
|
|
884
884
|
{ name: "name", type: "string", required: true, desc: "Knowledge base name" },
|
|
885
885
|
{ name: "url", type: "string", required: true, desc: "Source URL to upload" },
|
|
886
886
|
{ name: "display-name", type: "string", required: false, desc: "Optional display name for the URL source" },
|
|
887
|
-
{ name: "parse-instruction", type: "string", required: false, desc: "Optional parsing instruction for the URL source" }
|
|
887
|
+
{ name: "parse-instruction", type: "string", required: false, desc: "Optional parsing instruction for the URL source; ignored for Lark/Feishu doc URLs (the server applies its own Feishu parsing)" }
|
|
888
888
|
],
|
|
889
889
|
risk: "write",
|
|
890
890
|
validate: (ctx) => {
|
|
@@ -7,17 +7,17 @@ import {
|
|
|
7
7
|
putToMainApp,
|
|
8
8
|
tryLoadTeAgentSandboxCredentials,
|
|
9
9
|
uploadToMainApp
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-QNOLN2LJ.js";
|
|
11
11
|
import "./chunk-6EIJSNBD.js";
|
|
12
|
-
import "./chunk-
|
|
12
|
+
import "./chunk-J2DEBMRF.js";
|
|
13
|
+
import "./chunk-ZQKDZXDO.js";
|
|
13
14
|
import {
|
|
14
15
|
safeJsonParse
|
|
15
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-3FY3RJ26.js";
|
|
16
17
|
import {
|
|
17
18
|
CliValidationError
|
|
18
19
|
} from "./chunk-UW5UN47B.js";
|
|
19
|
-
import "./chunk-
|
|
20
|
-
import "./chunk-QGM4M3NI.js";
|
|
20
|
+
import "./chunk-JHENBQ5B.js";
|
|
21
21
|
|
|
22
22
|
// src/commands/te-system/shared.ts
|
|
23
23
|
import { readFileSync } from "fs";
|
|
@@ -7,17 +7,17 @@ import {
|
|
|
7
7
|
putToMainApp,
|
|
8
8
|
tryLoadTeAgentSandboxCredentials,
|
|
9
9
|
uploadToMainApp
|
|
10
|
-
} from "./chunk-
|
|
11
|
-
import "./chunk-
|
|
12
|
-
import "./chunk-
|
|
10
|
+
} from "./chunk-4XXOWOTA.js";
|
|
11
|
+
import "./chunk-SERWF6G5.js";
|
|
12
|
+
import "./chunk-J2DEBMRF.js";
|
|
13
|
+
import "./chunk-ZQKDZXDO.js";
|
|
13
14
|
import {
|
|
14
15
|
safeJsonParse
|
|
15
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-3FY3RJ26.js";
|
|
16
17
|
import {
|
|
17
18
|
CliValidationError
|
|
18
19
|
} from "./chunk-UW5UN47B.js";
|
|
19
|
-
import "./chunk-
|
|
20
|
-
import "./chunk-QGM4M3NI.js";
|
|
20
|
+
import "./chunk-JHENBQ5B.js";
|
|
21
21
|
|
|
22
22
|
// src/commands/te-system/shared.ts
|
|
23
23
|
import { readFileSync } from "fs";
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import {
|
|
2
2
|
getAuthHeaders,
|
|
3
3
|
kbApi
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-RNAALWJK.js";
|
|
5
5
|
import {
|
|
6
6
|
printError,
|
|
7
7
|
printOutput
|
|
8
|
-
} from "./chunk-
|
|
9
|
-
import "./chunk-
|
|
10
|
-
import "./chunk-
|
|
8
|
+
} from "./chunk-BYYS3ANB.js";
|
|
9
|
+
import "./chunk-J2DEBMRF.js";
|
|
10
|
+
import "./chunk-ZQKDZXDO.js";
|
|
11
|
+
import "./chunk-3FY3RJ26.js";
|
|
11
12
|
import "./chunk-UW5UN47B.js";
|
|
12
|
-
import "./chunk-
|
|
13
|
-
import "./chunk-QGM4M3NI.js";
|
|
13
|
+
import "./chunk-JHENBQ5B.js";
|
|
14
14
|
|
|
15
15
|
// src/commands/te-team/shared.ts
|
|
16
16
|
var API_PREFIX = process.env.AE_API_PREFIX ?? "/agent";
|
|
@@ -7,18 +7,19 @@ import {
|
|
|
7
7
|
printError,
|
|
8
8
|
printOutput,
|
|
9
9
|
recordVersionSyncResult
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-BYYS3ANB.js";
|
|
11
11
|
import {
|
|
12
12
|
peekCliToken
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-J2DEBMRF.js";
|
|
14
|
+
import {
|
|
15
|
+
missingAeHostHint
|
|
16
|
+
} from "./chunk-ZQKDZXDO.js";
|
|
14
17
|
import {
|
|
15
18
|
getActiveHost,
|
|
16
|
-
missingAeHostHint,
|
|
17
19
|
normalizeUrl
|
|
18
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-3FY3RJ26.js";
|
|
19
21
|
import "./chunk-UW5UN47B.js";
|
|
20
|
-
import "./chunk-
|
|
21
|
-
import "./chunk-QGM4M3NI.js";
|
|
22
|
+
import "./chunk-JHENBQ5B.js";
|
|
22
23
|
|
|
23
24
|
// src/commands/update.ts
|
|
24
25
|
var HOST_OPTION_DESC = "Override active AE host URL (e.g., https://ta.thinkingdata.cn)";
|
package/package.json
CHANGED
package/skills/ae-agent/SKILL.md
CHANGED
|
@@ -74,7 +74,7 @@ Use `ae-agent` for all Agent platform resource work:
|
|
|
74
74
|
|
|
75
75
|
If the user's intent is data analysis, audience management, metadata governance, TeamRuns, or knowledge bases, switch to `ae-analysis` / `ae-engage` / `ae-dataops` / `ae-team` / `ae-kb`.
|
|
76
76
|
|
|
77
|
-
## Tool Groups (
|
|
77
|
+
## Tool Groups (81 commands)
|
|
78
78
|
|
|
79
79
|
### Agents (5)
|
|
80
80
|
|
|
@@ -128,7 +128,7 @@ If the user's intent is data analysis, audience management, metadata governance,
|
|
|
128
128
|
- `+del-skill` ([doc](references/del-skill.md)) — delete a personal Skill (physical delete)
|
|
129
129
|
- `+toggle-skill` ([doc](references/toggle-skill.md)) — enable or disable a Skill
|
|
130
130
|
|
|
131
|
-
### Skill content & assets (
|
|
131
|
+
### Skill content & assets (15)
|
|
132
132
|
|
|
133
133
|
- `+edit-skill` ([doc](references/edit-skill.md)) — edit a Skill's content (name/description/instructions/category/icon)
|
|
134
134
|
- `+get-skill-content` ([doc](references/get-skill-content.md)) — read a Skill's SKILL.md source
|
|
@@ -145,7 +145,6 @@ If the user's intent is data analysis, audience management, metadata governance,
|
|
|
145
145
|
- `+read-skill-script` ([doc](references/read-skill-script.md)) — read a script file (binary-safe with `--output`)
|
|
146
146
|
- `+del-skill-script` ([doc](references/del-skill-script.md)) — delete a script file
|
|
147
147
|
- `+upload-skill` ([doc](references/upload-skill.md)) — create/replace a Skill from a ZIP package (parses SKILL.md; 5MB)
|
|
148
|
-
- `+rescan-skills` ([doc](references/rescan-skills.md)) — rescan local filesystem and sync Skills to DB (root only)
|
|
149
148
|
|
|
150
149
|
### Market (browse) (2)
|
|
151
150
|
|
|
@@ -261,7 +260,7 @@ For a local Agent, a successful `+mark-used` response means only that the dedupl
|
|
|
261
260
|
- **MCP connectivity**: `+add-mcp` does NOT validate server connectivity — an unreachable URL is accepted at create time and only fails when the agent calls the MCP at runtime. Double-check the URL.
|
|
262
261
|
- **Attachments**: upload supports files up to 50MB each, with a 1GB user quota. Batch uploads support partial success — individual file failures don't affect others.
|
|
263
262
|
- **Skill `--instructions @-`**: reads from stdin, useful for piping long instruction text.
|
|
264
|
-
- **Skill content versions**: `+add-skill` accepts optional `--version`; `+edit-skill` content changes and `+upload-skill --replace-skill-id` require a higher `major.minor` version.
|
|
263
|
+
- **Skill content versions**: `+add-skill` accepts optional `--version`; `+edit-skill` content changes and `+upload-skill --replace-skill-id` require a higher `major.minor` version. On `SKILL_VERSION_CONFLICT`, read `meta.currentVersion` and retry with a strictly higher version. On `SKILL_HISTORY_CONFLICT`, stop retrying and tell the user that the Skill cannot be safely updated right now and that they should contact their administrator. Never recommend internal maintenance commands or expose diagnostic payloads in a customer-facing response.
|
|
265
264
|
- **Skill sync push**: each selected Skill is uploaded as a ZIP to the versioned server endpoint. The server commits the canonical package before success; the CLI no longer copies it after the response.
|
|
266
265
|
- **Market category keys**: `ae_preset | dev_tool | search_tool | data_query | content_gen | enterprise | life | automation | other`. Sort options: `newest | calls | likes` (`calls` sorts MCP by call count, Skill by download count). Market scope: `all | system | company | custom` (`custom` = personal).
|
|
267
266
|
- **Meta on create/copy**: `+add-mcp` / `+add-skill` / `+copy-skill` accept optional `--category / --icon-emoji / --icon-color`; these are applied via a follow-up meta PATCH after creation. MCP creation still does NOT validate server connectivity.
|
|
@@ -68,6 +68,9 @@ ae-cli agent +edit-skill --dry-run --id <skill-cuid> --name new-name --version 2
|
|
|
68
68
|
|
|
69
69
|
- `404` / not found: re-run `+list-skills` to verify the Skill ID and scope.
|
|
70
70
|
- `409` / name conflict: use `--name` with a different name, or consider `+upload-skill` with `--auto-rename`.
|
|
71
|
+
- `SKILL_VERSION_CONFLICT`: read `meta.currentVersion`, choose a strictly higher `major.minor` value, and retry the same command with `--version`.
|
|
72
|
+
- `SKILL_HISTORY_CONFLICT`: stop retrying and tell the user, "The Skill cannot be safely updated right now. Please contact your administrator."
|
|
73
|
+
- Do not recommend internal maintenance commands or expose diagnostic payloads in a customer-facing response.
|
|
71
74
|
|
|
72
75
|
## Recommended Chaining
|
|
73
76
|
|
|
@@ -30,7 +30,7 @@ ae-cli agent +get-skill-content --dry-run --id <skill-cuid>
|
|
|
30
30
|
|
|
31
31
|
## Next Steps on Failure
|
|
32
32
|
- `404` / not found: re-run `+list-skills` to verify the Skill ID.
|
|
33
|
-
- `file_not_found`: the Skill
|
|
33
|
+
- `file_not_found`: the Skill content is unavailable. Ask the user to contact their administrator; do not recommend internal maintenance commands.
|
|
34
34
|
|
|
35
35
|
## Recommended Chaining
|
|
36
36
|
- `+list-skills` → confirm `id` → `+get-skill-content` → `+edit-skill` (if changes needed)
|
|
@@ -1,24 +1,26 @@
|
|
|
1
|
-
# agent +rescan-skills (
|
|
1
|
+
# agent +rescan-skills (Internal Compatibility Reference)
|
|
2
2
|
|
|
3
3
|
> **Prerequisite:** Follow the Global AE CLI Rules in [`../SKILL.md`](../SKILL.md).
|
|
4
4
|
|
|
5
|
-
Domain: **Skills / write**
|
|
5
|
+
Domain: **Skills / internal write**
|
|
6
6
|
|
|
7
7
|
## Use Cases
|
|
8
|
-
-
|
|
8
|
+
- Preserve compatibility for privileged administrators who already use the legacy command.
|
|
9
9
|
- Endpoint: `POST /api/sandbox/agent/skills/rescan`.
|
|
10
|
-
-
|
|
11
|
-
-
|
|
10
|
+
- The endpoint synchronizes system-scope Skills only.
|
|
11
|
+
- The command is hidden from normal `agent --help` output and public Skill routing.
|
|
12
12
|
|
|
13
13
|
## Mandatory Rules (MUST)
|
|
14
14
|
- This command takes no flags.
|
|
15
|
-
-
|
|
15
|
+
- It requires `root` or `agent_admin` privileges; other users receive a 403 response.
|
|
16
|
+
- Never use it to recover a personal or company Skill.
|
|
17
|
+
- Never expose this command or its maintenance terminology in a customer-facing response.
|
|
16
18
|
- This is an ordinary `write` operation and does not require CLI confirmation.
|
|
17
19
|
- Prefer `--dry-run` before executing — rescan has filesystem side effects.
|
|
18
20
|
|
|
19
21
|
## Command
|
|
20
22
|
```bash
|
|
21
|
-
#
|
|
23
|
+
# Internal administrator use only
|
|
22
24
|
ae-cli agent +rescan-skills
|
|
23
25
|
|
|
24
26
|
# Dry-run to inspect the request before executing
|
|
@@ -31,14 +33,14 @@ ae-cli agent +rescan-skills --dry-run
|
|
|
31
33
|
| _(none)_ | — | This command takes no flags |
|
|
32
34
|
|
|
33
35
|
## Decision Rules
|
|
34
|
-
- Use this command
|
|
35
|
-
-
|
|
36
|
-
-
|
|
36
|
+
- Use this command only for an explicitly authorized system-Skill maintenance task.
|
|
37
|
+
- Confirm the operator has `root` or `agent_admin` privileges before running it.
|
|
38
|
+
- Do not route ordinary Skill update failures to this command.
|
|
37
39
|
- Use `--dry-run` first to verify the request shape before executing.
|
|
38
40
|
|
|
39
41
|
## Next Steps on Failure
|
|
40
|
-
- `403
|
|
41
|
-
-
|
|
42
|
+
- `403`: the current operator lacks the required administrator role.
|
|
43
|
+
- Other failures: stop and inspect administrator-only service logs; do not relay diagnostic details to customers.
|
|
42
44
|
|
|
43
45
|
## Recommended Chaining
|
|
44
|
-
- `+rescan-skills` → `+list-skills` (verify
|
|
46
|
+
- `+rescan-skills` → `+list-skills` (verify system Skills only)
|
|
@@ -87,11 +87,14 @@ ae-cli agent +upload-skill --dry-run --file ./my-skill.zip
|
|
|
87
87
|
|
|
88
88
|
- `File not found`: verify the local file path.
|
|
89
89
|
- `--file must be a .zip file`: only ZIP format is supported.
|
|
90
|
-
- `
|
|
91
|
-
-
|
|
92
|
-
-
|
|
93
|
-
-
|
|
90
|
+
- Missing `SKILL.md`: ensure the ZIP contains a `SKILL.md` file.
|
|
91
|
+
- Missing name or content: add the `name` field and Skill content to `SKILL.md`.
|
|
92
|
+
- Missing description: add a description to `SKILL.md` or use `--description`.
|
|
93
|
+
- The upload could not be saved: retry once, then contact the administrator if it still fails.
|
|
94
94
|
- `409` / name conflict: use `--auto-rename` or choose a different `--name`.
|
|
95
|
+
- `SKILL_VERSION_CONFLICT`: read `meta.currentVersion`, choose a strictly higher `major.minor` value, and retry the same replacement with `--version`.
|
|
96
|
+
- `SKILL_HISTORY_CONFLICT`: stop retrying and tell the user, "The Skill cannot be safely updated right now. Please contact your administrator."
|
|
97
|
+
- Do not recommend internal maintenance commands or expose diagnostic payloads in a customer-facing response.
|
|
95
98
|
|
|
96
99
|
## Recommended Chaining
|
|
97
100
|
|