@botpress/adk-cli 1.13.14 → 1.13.15

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/cli.js CHANGED
@@ -735516,7 +735516,7 @@ class AgentProjectGenerator {
735516
735516
  deploy: "adk deploy"
735517
735517
  },
735518
735518
  dependencies: {
735519
- "@botpress/runtime": "^1.13.14"
735519
+ "@botpress/runtime": "^1.13.15"
735520
735520
  },
735521
735521
  devDependencies: {
735522
735522
  typescript: "^5.9.3"
@@ -735924,7 +735924,7 @@ Description: ${action.description || "No description"}`)}
735924
735924
  const comment = toMultilineComment(`Title: ${tag?.title}
735925
735925
  Description: ${tag.description}`);
735926
735926
  acc += `${comment}
735927
- ["${integration.ref.fullName}:${t6}"]?: string,
735927
+ ["${integration.alias}:${t6}"]?: string,
735928
735928
  `;
735929
735929
  return acc;
735930
735930
  }, "") + "}";
@@ -735933,7 +735933,7 @@ Description: ${tag.description}`);
735933
735933
  const comment = toMultilineComment(`Title: ${tag?.title}
735934
735934
  Description: ${tag.description}`);
735935
735935
  acc += `${comment}
735936
- ["${integration.ref.fullName}:${t6}"]?: string,
735936
+ ["${integration.alias}:${t6}"]?: string,
735937
735937
  `;
735938
735938
  return acc;
735939
735939
  }, "") + "}";
@@ -736008,7 +736008,7 @@ Description: ${event2.description || "No description"}${attributesComment}`)}
736008
736008
  const comment = toMultilineComment(`Title: ${tag?.title}
736009
736009
  Description: ${tag?.description}`);
736010
736010
  return `${comment}
736011
- "${integration.ref.fullName}:${t6}"
736011
+ "${integration.alias}:${t6}"
736012
736012
  `;
736013
736013
  }).join(" | ") : "never";
736014
736014
  tUsers += `
@@ -740213,7 +740213,7 @@ var import_debug, import_debug2, import_ts_morph, __defProp11, __commonJS8 = (cb
740213
740213
  `));
740214
740214
  return code;
740215
740215
  }
740216
- }, ADK_VERSION = "1.13.14", relative22 = (from, to2) => {
740216
+ }, ADK_VERSION = "1.13.15", relative22 = (from, to2) => {
740217
740217
  const fromDir = path102.dirname(from);
740218
740218
  const relative32 = path102.relative(fromDir, to2);
740219
740219
  return relative32.startsWith(".") ? relative32 : `./${relative32}`;
@@ -741760,7 +741760,7 @@ var init_dist15 = __esm(() => {
741760
741760
  require_package3 = __commonJS8((exports7, module) => {
741761
741761
  module.exports = {
741762
741762
  name: "@botpress/adk",
741763
- version: "1.13.14",
741763
+ version: "1.13.15",
741764
741764
  description: "Core ADK library for building AI agents on Botpress",
741765
741765
  type: "module",
741766
741766
  main: "dist/index.js",
@@ -741807,7 +741807,7 @@ var init_dist15 = __esm(() => {
741807
741807
  "@botpress/cli": "^5.2.0",
741808
741808
  "@botpress/client": "^1.28.0",
741809
741809
  "@botpress/cognitive": "^0.3.3",
741810
- "@botpress/runtime": "^1.13.14",
741810
+ "@botpress/runtime": "^1.13.15",
741811
741811
  "@botpress/sdk": "^5.1.0",
741812
741812
  "@bpinternal/jex": "^1.2.4",
741813
741813
  "@bpinternal/yargs-extra": "^0.0.21",
@@ -748413,7 +748413,7 @@ var init_Separator = __esm(async () => {
748413
748413
  var require_package4 = __commonJS((exports7, module) => {
748414
748414
  module.exports = {
748415
748415
  name: "@botpress/adk",
748416
- version: "1.13.14",
748416
+ version: "1.13.15",
748417
748417
  description: "Core ADK library for building AI agents on Botpress",
748418
748418
  type: "module",
748419
748419
  main: "dist/index.js",
@@ -748460,7 +748460,7 @@ var require_package4 = __commonJS((exports7, module) => {
748460
748460
  "@botpress/cli": "^5.2.0",
748461
748461
  "@botpress/client": "^1.28.0",
748462
748462
  "@botpress/cognitive": "^0.3.3",
748463
- "@botpress/runtime": "^1.13.14",
748463
+ "@botpress/runtime": "^1.13.15",
748464
748464
  "@botpress/sdk": "^5.1.0",
748465
748465
  "@bpinternal/jex": "^1.2.4",
748466
748466
  "@bpinternal/yargs-extra": "^0.0.21",
@@ -750402,7 +750402,7 @@ function checkRuntimeVersion(agentRoot) {
750402
750402
  `));
750403
750403
  }
750404
750404
  }
750405
- var semver2, EXPECTED_RUNTIME_VERSION = "1.13.14", SUPPORTED_RUNTIME_RANGE = ">=1.13.0";
750405
+ var semver2, EXPECTED_RUNTIME_VERSION = "1.13.15", SUPPORTED_RUNTIME_RANGE = ">=1.13.0";
750406
750406
  var init_runtime_version_check = __esm(() => {
750407
750407
  init_source();
750408
750408
  semver2 = __toESM(require_semver2(), 1);
@@ -774353,7 +774353,7 @@ var init_internal2 = __esm(() => {
774353
774353
  });
774354
774354
  init_define_PACKAGE_VERSIONS4 = __esm7({
774355
774355
  "<define:__PACKAGE_VERSIONS__>"() {
774356
- define_PACKAGE_VERSIONS_default4 = { runtime: "1.13.14", adk: "1.13.14", sdk: "5.0.2", llmz: "0.0.37", zai: "2.5.6", cognitive: "0.3.3" };
774356
+ define_PACKAGE_VERSIONS_default4 = { runtime: "1.13.15", adk: "1.13.15", sdk: "5.0.2", llmz: "0.0.37", zai: "2.5.6", cognitive: "0.3.3" };
774357
774357
  }
774358
774358
  });
774359
774359
  init_asset4 = __esm7({
@@ -805643,10 +805643,15 @@ ${iteration.status.execution_error.stack}`;
805643
805643
  if (typeof propertyName !== "string") {
805644
805644
  return;
805645
805645
  }
805646
+ let client22;
805647
+ client22 ??= context6.get("client", { optional: true });
805646
805648
  const botAction = adk4.project.actions.find((a2) => a2.name === propertyName);
805647
805649
  if (botAction) {
805648
805650
  const handler2 = async (input) => {
805649
- return await botAction.handler(input);
805651
+ return await botAction.handler({
805652
+ input,
805653
+ client: client22
805654
+ });
805650
805655
  };
805651
805656
  handler2.asTool = () => new Autonomous4.Tool({
805652
805657
  name: botAction.name,
@@ -805658,9 +805663,7 @@ ${iteration.status.execution_error.stack}`;
805658
805663
  return handler2;
805659
805664
  }
805660
805665
  let integrations;
805661
- let client22;
805662
805666
  integrations ??= context6.get("integrations", { optional: true });
805663
- client22 ??= context6.get("client", { optional: true });
805664
805667
  const integrationName = propertyName.replace("__", "/");
805665
805668
  return new Proxy({}, {
805666
805669
  get(_3, actionName) {
@@ -806647,7 +806650,8 @@ ${iteration.status.execution_error.stack}`;
806647
806650
  } else {
806648
806651
  this.value = value2;
806649
806652
  }
806650
- if (this.value == null || this.value === undefined) {
806653
+ const needsDefaults = this.value == null || this.value === undefined;
806654
+ if (needsDefaults) {
806651
806655
  if (this.state && "parse" in this.state) {
806652
806656
  try {
806653
806657
  this.value = this.state.parse({});
@@ -806815,6 +806819,7 @@ ${iteration.status.execution_error.stack}`;
806815
806819
  init_define_PACKAGE_VERSIONS4();
806816
806820
  init_context6();
806817
806821
  init_tracing4();
806822
+ init_adk4();
806818
806823
  TrackedTags4 = class _TrackedTags {
806819
806824
  type;
806820
806825
  id;
@@ -807027,13 +807032,43 @@ ${iteration.status.execution_error.stack}`;
807027
807032
  }
807028
807033
  return {};
807029
807034
  }
807035
+ getValidTagKeys() {
807036
+ const validKeys = /* @__PURE__ */ new Set;
807037
+ try {
807038
+ const config3 = adk4.project.config;
807039
+ if (this.type === "bot" && config3.bot?.tags) {
807040
+ Object.keys(config3.bot.tags).forEach((key) => validKeys.add(key));
807041
+ } else if (this.type === "user" && config3.user?.tags) {
807042
+ Object.keys(config3.user.tags).forEach((key) => validKeys.add(key));
807043
+ } else if (this.type === "conversation" && config3.conversation?.tags) {
807044
+ Object.keys(config3.conversation.tags).forEach((key) => validKeys.add(key));
807045
+ } else if (this.type === "workflow" && config3.workflow?.tags) {
807046
+ Object.keys(config3.workflow.tags).forEach((key) => validKeys.add(key));
807047
+ }
807048
+ } catch (err) {
807049
+ console.warn(`[TrackedTags] Could not load tag definitions from config: ${err}`);
807050
+ }
807051
+ return validKeys;
807052
+ }
807030
807053
  async persistTags(tags) {
807054
+ const validKeys = this.getValidTagKeys();
807031
807055
  const tagsForApi = {};
807056
+ const skippedTags = [];
807032
807057
  for (const [key, value2] of Object.entries(tags)) {
807033
- if (value2 !== undefined && !isSystemTag4(key)) {
807058
+ if (value2 === undefined || isSystemTag4(key)) {
807059
+ continue;
807060
+ }
807061
+ if (validKeys.size === 0 || validKeys.has(key)) {
807034
807062
  tagsForApi[key] = value2;
807063
+ } else {
807064
+ skippedTags.push(key);
807065
+ delete this._tags[key];
807066
+ delete this._initialTags[key];
807035
807067
  }
807036
807068
  }
807069
+ if (skippedTags.length > 0) {
807070
+ console.warn(`[TrackedTags] Skipping tags not defined in agent.config.ts for ${this.type}/${this.id}: ${skippedTags.join(", ")}`);
807071
+ }
807037
807072
  try {
807038
807073
  if (this.type === "bot") {
807039
807074
  await this.client.updateBot({ id: this.id, tags: tagsForApi });
@@ -807855,9 +807890,13 @@ yield <Message>
807855
807890
  }
807856
807891
  const stateProxy = new Proxy(conversationInstance.TrackedState.value, {
807857
807892
  set(target, prop, value2) {
807858
- const result = Reflect.set(target, prop, value2);
807859
- conversationInstance.TrackedState.markDirty();
807860
- return result;
807893
+ const oldValue = target[prop];
807894
+ if (oldValue !== value2) {
807895
+ const result = Reflect.set(target, prop, value2);
807896
+ conversationInstance.TrackedState.markDirty();
807897
+ return result;
807898
+ }
807899
+ return true;
807861
807900
  }
807862
807901
  });
807863
807902
  await this.#handler({
@@ -808474,9 +808513,13 @@ yield <Message>
808474
808513
  const trackedState = this.TrackedState;
808475
808514
  const stateProxy = new Proxy(this.TrackedState.value, {
808476
808515
  set(target, prop, value2) {
808477
- const result = Reflect.set(target, prop, value2);
808478
- trackedState.markDirty();
808479
- return result;
808516
+ const oldValue = target[prop];
808517
+ if (oldValue !== value2) {
808518
+ const result = Reflect.set(target, prop, value2);
808519
+ trackedState.markDirty();
808520
+ return result;
808521
+ }
808522
+ return true;
808480
808523
  }
808481
808524
  });
808482
808525
  if (this.workflow.status === "pending") {
@@ -988890,7 +988933,7 @@ if (!checkNodeVersion(true)) {
988890
988933
  checkNodeVersion(false);
988891
988934
  process.exit(1);
988892
988935
  }
988893
- var CLI_VERSION = "1.13.14";
988936
+ var CLI_VERSION = "1.13.15";
988894
988937
  if (CLI_VERSION.startsWith("<<") && CLI_VERSION.endsWith(">>")) {
988895
988938
  try {
988896
988939
  const __filename2 = fileURLToPath16(import.meta.url);
@@ -1,6 +1,6 @@
1
1
  {
2
- "version": "1.13.14",
3
- "generatedAt": "2026-01-05T14:28:22.170Z",
2
+ "version": "1.13.15",
3
+ "generatedAt": "2026-01-12T20:33:58.134Z",
4
4
  "cliName": "adk",
5
5
  "globalOptions": [
6
6
  {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@botpress/adk-cli",
3
- "version": "1.13.14",
3
+ "version": "1.13.15",
4
4
  "description": "Command-line interface for the Botpress Agent Development Kit (ADK)",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -41,10 +41,10 @@
41
41
  "url": "https://github.com/botpress/adk"
42
42
  },
43
43
  "dependencies": {
44
- "@botpress/adk": "^1.13.14",
44
+ "@botpress/adk": "^1.13.15",
45
45
  "@botpress/cli": "^5.2.0",
46
46
  "@botpress/client": "^1.28.0",
47
- "@botpress/runtime": "^1.13.14",
47
+ "@botpress/runtime": "^1.13.15",
48
48
  "@botpress/sdk": "^5.1.0",
49
49
  "@botpress/webchat-client": "^0.4.0",
50
50
  "@modelcontextprotocol/sdk": "^1.25.1",