@aigne/cli 1.59.0-beta.24 → 1.59.0-beta.27

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/CHANGELOG.md CHANGED
@@ -1,5 +1,79 @@
1
1
  # Changelog
2
2
 
3
+ ## [1.59.0-beta.27](https://github.com/AIGNE-io/aigne-framework/compare/cli-v1.59.0-beta.26...cli-v1.59.0-beta.27) (2026-01-15)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * **ci:** replace crypto library and simplify credential handling ([#912](https://github.com/AIGNE-io/aigne-framework/issues/912)) ([f3c3e65](https://github.com/AIGNE-io/aigne-framework/commit/f3c3e651c4776a02675e601ffa56c01c144b892d))
9
+
10
+
11
+ ### Dependencies
12
+
13
+ * The following workspace dependencies were updated
14
+ * dependencies
15
+ * @aigne/afs-local-fs bumped to 1.4.0-beta.22
16
+ * @aigne/agent-library bumped to 1.24.0-beta.23
17
+ * @aigne/agentic-memory bumped to 1.1.6-beta.21
18
+ * @aigne/aigne-hub bumped to 0.10.16-beta.27
19
+ * @aigne/core bumped to 1.72.0-beta.21
20
+ * @aigne/default-memory bumped to 1.4.0-beta.20
21
+ * @aigne/observability-api bumped to 0.11.14-beta.5
22
+ * @aigne/openai bumped to 0.16.16-beta.21
23
+ * @aigne/secrets bumped to 0.1.6-beta.21
24
+ * devDependencies
25
+ * @aigne/test-utils bumped to 0.5.69-beta.21
26
+
27
+ ## [1.59.0-beta.26](https://github.com/AIGNE-io/aigne-framework/compare/cli-v1.59.0-beta.25...cli-v1.59.0-beta.26) (2026-01-15)
28
+
29
+
30
+ ### Dependencies
31
+
32
+ * The following workspace dependencies were updated
33
+ * dependencies
34
+ * @aigne/afs-local-fs bumped to 1.4.0-beta.21
35
+ * @aigne/agent-library bumped to 1.24.0-beta.22
36
+ * @aigne/agentic-memory bumped to 1.1.6-beta.20
37
+ * @aigne/aigne-hub bumped to 0.10.16-beta.26
38
+ * @aigne/core bumped to 1.72.0-beta.20
39
+ * @aigne/default-memory bumped to 1.4.0-beta.19
40
+ * @aigne/openai bumped to 0.16.16-beta.20
41
+ * @aigne/secrets bumped to 0.1.6-beta.20
42
+ * devDependencies
43
+ * @aigne/test-utils bumped to 0.5.69-beta.20
44
+
45
+ ## [1.59.0-beta.25](https://github.com/AIGNE-io/aigne-framework/compare/cli-v1.59.0-beta.24...cli-v1.59.0-beta.25) (2026-01-14)
46
+
47
+
48
+ ### Features
49
+
50
+ * **afs:** add module access control and schema validation support ([#904](https://github.com/AIGNE-io/aigne-framework/issues/904)) ([d0b279a](https://github.com/AIGNE-io/aigne-framework/commit/d0b279aac07ebe2bcc1fd4148498fc3f6bbcd561))
51
+
52
+
53
+ ### Bug Fixes
54
+
55
+ * **cli:** default enter interactive mode ([#906](https://github.com/AIGNE-io/aigne-framework/issues/906)) ([0791040](https://github.com/AIGNE-io/aigne-framework/commit/0791040557dd135c8feb4ceb8eab66d0578382b2))
56
+ * improve test coverage tracking and reporting ([#903](https://github.com/AIGNE-io/aigne-framework/issues/903)) ([031144e](https://github.com/AIGNE-io/aigne-framework/commit/031144e74f29e882cffe52ffda8f7a18c76ace7f))
57
+
58
+
59
+ ### Dependencies
60
+
61
+ * The following workspace dependencies were updated
62
+ * dependencies
63
+ * @aigne/afs bumped to 1.4.0-beta.9
64
+ * @aigne/afs-history bumped to 1.2.0-beta.10
65
+ * @aigne/afs-local-fs bumped to 1.4.0-beta.20
66
+ * @aigne/agent-library bumped to 1.24.0-beta.21
67
+ * @aigne/agentic-memory bumped to 1.1.6-beta.19
68
+ * @aigne/aigne-hub bumped to 0.10.16-beta.25
69
+ * @aigne/core bumped to 1.72.0-beta.19
70
+ * @aigne/default-memory bumped to 1.4.0-beta.18
71
+ * @aigne/observability-api bumped to 0.11.14-beta.4
72
+ * @aigne/openai bumped to 0.16.16-beta.19
73
+ * @aigne/secrets bumped to 0.1.6-beta.19
74
+ * devDependencies
75
+ * @aigne/test-utils bumped to 0.5.69-beta.19
76
+
3
77
  ## [1.59.0-beta.24](https://github.com/AIGNE-io/aigne-framework/compare/cli-v1.59.0-beta.23...cli-v1.59.0-beta.24) (2026-01-13)
4
78
 
5
79
 
@@ -10,10 +10,10 @@ export declare const serveMcpCommandModule: ({ aigne, name, }: {
10
10
  port?: number;
11
11
  pathname: string;
12
12
  }>;
13
- export declare const agentCommandModule: ({ aigne, agent, chat, }: {
13
+ export declare const agentCommandModule: ({ aigne, agent, interactive, }: {
14
14
  aigne: AIGNE;
15
15
  agent: Agent;
16
- chat?: boolean;
16
+ interactive?: boolean;
17
17
  }) => CommandModule<unknown, AgentRunCommonOptions>;
18
18
  export declare const cliAgentCommandModule: ({ aigne, cliAgent, }: {
19
19
  aigne: AIGNE;
@@ -32,7 +32,7 @@ export const serveMcpCommandModule = ({ aigne, name, }) => ({
32
32
  });
33
33
  },
34
34
  });
35
- export const agentCommandModule = ({ aigne, agent, chat, }) => {
35
+ export const agentCommandModule = ({ aigne, agent, interactive, }) => {
36
36
  return {
37
37
  command: agent.name,
38
38
  aliases: agent.alias || [],
@@ -40,7 +40,9 @@ export const agentCommandModule = ({ aigne, agent, chat, }) => {
40
40
  builder: async (yargs) => {
41
41
  return withAgentInputSchema(yargs, {
42
42
  inputSchema: agent.inputSchema,
43
- optionalInputs: chat && "inputKey" in agent && typeof agent.inputKey === "string" ? [agent.inputKey] : [],
43
+ optionalInputs: interactive && "inputKey" in agent && typeof agent.inputKey === "string"
44
+ ? [agent.inputKey]
45
+ : [],
44
46
  });
45
47
  },
46
48
  handler: async (options) => {
@@ -49,7 +51,7 @@ export const agentCommandModule = ({ aigne, agent, chat, }) => {
49
51
  await invokeAgent({
50
52
  aigne,
51
53
  agent,
52
- input: { ...options, chat: chat ?? options.chat },
54
+ input: { ...options, interactive: interactive ?? options.interactive },
53
55
  });
54
56
  },
55
57
  };
@@ -38,7 +38,7 @@ export async function runAppCLI({ appName = process.env.AIGNE_APP_NAME, appPacka
38
38
  ...agentCommandModule({
39
39
  aigne,
40
40
  agent: aigne.cli.chat,
41
- chat: true,
41
+ interactive: true,
42
42
  }),
43
43
  command: "$0",
44
44
  });
@@ -83,14 +83,14 @@ export function createRunCommand({ aigneFilePath, } = {}) {
83
83
  const subYargs = yargs().scriptName("").usage("aigne run <path> <agent> [...options]");
84
84
  if (aigne.cli.chat) {
85
85
  subYargs.command({
86
- ...agentCommandModule({ aigne, agent: aigne.cli.chat, chat: true }),
86
+ ...agentCommandModule({ aigne, agent: aigne.cli.chat, interactive: true }),
87
87
  command: "$0",
88
88
  });
89
89
  }
90
90
  // Allow user to run all of agents in the AIGNE instances
91
91
  const allAgents = flat(aigne.agents, aigne.skills, aigne.cli.chat, aigne.mcpServer.agents);
92
92
  for (const agent of allAgents) {
93
- subYargs.command(agentCommandModule({ aigne, agent, chat: options.interactive }));
93
+ subYargs.command(agentCommandModule({ aigne, agent, interactive: options.interactive }));
94
94
  }
95
95
  for (const cliAgent of aigne.cli.agents ?? []) {
96
96
  subYargs.command(cliAgentCommandModule({
@@ -9,9 +9,6 @@ export declare function createConnect({ connectUrl, openPage, fetchInterval, ret
9
9
  export declare function connectToAIGNEHub(url: string): Promise<{
10
10
  apiKey: string;
11
11
  url: string;
12
- } | {
13
- apiKey: undefined;
14
- url: undefined;
15
12
  }>;
16
13
  export declare const checkConnectionStatus: (host: string) => Promise<{
17
14
  apiKey: any;
@@ -3,7 +3,6 @@ import { homedir } from "node:os";
3
3
  import { join } from "node:path";
4
4
  import { AIGNE_HUB_BLOCKLET_DID, AIGNE_HUB_URL, getAIGNEHubMountPoint } from "@aigne/aigne-hub";
5
5
  import { fetch } from "@aigne/core/utils/fetch.js";
6
- import { logger } from "@aigne/core/utils/logger.js";
7
6
  import inquirer from "inquirer";
8
7
  import open from "open";
9
8
  import pWaitFor from "p-wait-for";
@@ -38,7 +37,7 @@ export const fetchConfigs = async ({ connectUrl, sessionId, fetchInterval, fetch
38
37
  };
39
38
  };
40
39
  function baseWrapSpinner(_, waiting) {
41
- return Promise.resolve(waiting());
40
+ return waiting();
42
41
  }
43
42
  export async function createConnect({ connectUrl, openPage, fetchInterval = 3 * 1000, retry = 1500, source = "Blocklet CLI", connectAction = "connect-cli", wrapSpinner = baseWrapSpinner, closeOnSuccess, intervalFetchConfig, appName = "AIGNE CLI", appLogo = "https://www.aigne.io/favicon.ico?imageFilter=resize&w=32", }) {
44
43
  const startSessionURL = joinURL(connectUrl, ACCESS_KEY_SESSION_API);
@@ -68,28 +67,22 @@ export async function connectToAIGNEHub(url) {
68
67
  const { origin } = new URL(url);
69
68
  const connectUrl = joinURL(origin, WELLKNOWN_SERVICE_PATH_PREFIX);
70
69
  const apiUrl = await getAIGNEHubMountPoint(url, AIGNE_HUB_BLOCKLET_DID);
71
- try {
72
- const openFn = isTest ? () => { } : open;
73
- const result = await createConnect({
74
- connectUrl: connectUrl,
75
- connectAction: "gen-simple-access-key",
76
- source: `@aigne/cli connect to AIGNE hub`,
77
- closeOnSuccess: true,
78
- openPage: (pageUrl) => openFn(pageUrl),
79
- });
80
- const accessKeyOptions = {
81
- apiKey: result.accessKeySecret,
82
- url: apiUrl,
83
- };
84
- const secretStore = await getSecretStore();
85
- await secretStore.setKey(accessKeyOptions.url, accessKeyOptions.apiKey);
86
- await secretStore.setDefault(accessKeyOptions.url);
87
- return accessKeyOptions;
88
- }
89
- catch (error) {
90
- logger.error("Failed to connect to AIGNE Hub", error.message);
91
- return { apiKey: undefined, url: undefined };
92
- }
70
+ const openFn = isTest ? () => { } : open;
71
+ const result = await createConnect({
72
+ connectUrl: connectUrl,
73
+ connectAction: "gen-simple-access-key",
74
+ source: `@aigne/cli connect to AIGNE hub`,
75
+ closeOnSuccess: true,
76
+ openPage: (pageUrl) => openFn(pageUrl),
77
+ });
78
+ const accessKeyOptions = {
79
+ apiKey: result.accessKeySecret,
80
+ url: apiUrl,
81
+ };
82
+ const secretStore = await getSecretStore();
83
+ await secretStore.setKey(accessKeyOptions.url, accessKeyOptions.apiKey);
84
+ await secretStore.setDefault(accessKeyOptions.url);
85
+ return accessKeyOptions;
93
86
  }
94
87
  export const checkConnectionStatus = async (host) => {
95
88
  const secretStore = await getSecretStore();
@@ -1,5 +1,21 @@
1
1
  import crypto from "node:crypto";
2
- import { AesCrypter } from "@ocap/mcrypto/lib/crypter/aes-legacy.js";
2
+ import CryptoJS from "crypto-js";
3
+ const encoders = {
4
+ latin1: CryptoJS.enc.Latin1,
5
+ utf8: CryptoJS.enc.Utf8,
6
+ hex: CryptoJS.enc.Hex,
7
+ utf16: CryptoJS.enc.Utf16,
8
+ base64: CryptoJS.enc.Base64,
9
+ };
10
+ class AesCrypter {
11
+ encrypt(message, secret) {
12
+ const text = typeof message === "string" ? message : JSON.stringify(message);
13
+ return CryptoJS.AES.encrypt(text, secret).toString();
14
+ }
15
+ decrypt(cipher, secret, outputEncoding = "utf8") {
16
+ return CryptoJS.AES.decrypt(cipher, secret).toString(encoders[outputEncoding]);
17
+ }
18
+ }
3
19
  const aes = new AesCrypter();
4
20
  export const decrypt = (m, s, i) => aes.decrypt(m, crypto.pbkdf2Sync(i, s, 256, 32, "sha512").toString("hex"));
5
21
  export const encrypt = (m, s, i) => aes.encrypt(m, crypto.pbkdf2Sync(i, s, 256, 32, "sha512").toString("hex"));
@@ -55,7 +55,7 @@ export async function loadAIGNE({ path, modelOptions, imageModelOptions, skipMod
55
55
  availableModules: [
56
56
  {
57
57
  module: "history",
58
- load: (options) => import("@aigne/afs-history").then((m) => new m.AFSHistory(options.parsed)),
58
+ load: (options) => import("@aigne/afs-history").then((m) => m.AFSHistory.load(options)),
59
59
  },
60
60
  {
61
61
  module: "local-fs",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aigne/cli",
3
- "version": "1.59.0-beta.24",
3
+ "version": "1.59.0-beta.27",
4
4
  "description": "Your command center for agent development",
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -56,13 +56,13 @@
56
56
  "@inquirer/type": "^3.0.8",
57
57
  "@listr2/prompt-adapter-inquirer": "^3.0.4",
58
58
  "@modelcontextprotocol/sdk": "^1.18.0",
59
- "@ocap/mcrypto": "^1.28.5",
60
59
  "@smithy/node-http-handler": "^4.2.1",
61
60
  "ansi-escapes": "^7.1.0",
62
61
  "ansi-regex": "^6.2.2",
63
62
  "boxen": "^8.0.1",
64
63
  "chalk": "^5.6.2",
65
64
  "cli-table3": "^0.6.5",
65
+ "crypto-js": "^4.2.0",
66
66
  "detect-port": "^2.1.0",
67
67
  "dotenv-flow": "^4.1.0",
68
68
  "express": "^5.1.0",
@@ -90,22 +90,23 @@
90
90
  "yoctocolors-cjs": "^2.1.3",
91
91
  "zod": "^3.25.67",
92
92
  "zod-to-json-schema": "^3.24.6",
93
- "@aigne/afs": "^1.4.0-beta.8",
94
- "@aigne/afs-history": "^1.2.0-beta.9",
95
- "@aigne/afs-local-fs": "^1.4.0-beta.19",
96
- "@aigne/agent-library": "^1.24.0-beta.20",
97
- "@aigne/agentic-memory": "^1.1.6-beta.18",
98
- "@aigne/aigne-hub": "^0.10.16-beta.24",
99
- "@aigne/default-memory": "^1.4.0-beta.17",
100
- "@aigne/core": "^1.72.0-beta.18",
101
- "@aigne/observability-api": "^0.11.14-beta.3",
102
- "@aigne/secrets": "^0.1.6-beta.18",
103
- "@aigne/openai": "^0.16.16-beta.18"
93
+ "@aigne/afs-history": "^1.2.0-beta.10",
94
+ "@aigne/afs": "^1.4.0-beta.9",
95
+ "@aigne/afs-local-fs": "^1.4.0-beta.22",
96
+ "@aigne/agent-library": "^1.24.0-beta.23",
97
+ "@aigne/agentic-memory": "^1.1.6-beta.21",
98
+ "@aigne/aigne-hub": "^0.10.16-beta.27",
99
+ "@aigne/core": "^1.72.0-beta.21",
100
+ "@aigne/default-memory": "^1.4.0-beta.20",
101
+ "@aigne/observability-api": "^0.11.14-beta.5",
102
+ "@aigne/openai": "^0.16.16-beta.21",
103
+ "@aigne/secrets": "^0.1.6-beta.21"
104
104
  },
105
105
  "devDependencies": {
106
106
  "@inquirer/testing": "^2.1.50",
107
107
  "@types/archiver": "^6.0.3",
108
108
  "@types/bun": "^1.2.22",
109
+ "@types/crypto-js": "^4.2.2",
109
110
  "@types/express": "^5.0.3",
110
111
  "@types/gradient-string": "^1.1.6",
111
112
  "@types/node": "^24.5.1",
@@ -117,7 +118,7 @@
117
118
  "rimraf": "^6.0.1",
118
119
  "typescript": "^5.9.2",
119
120
  "ufo": "^1.6.1",
120
- "@aigne/test-utils": "^0.5.69-beta.18"
121
+ "@aigne/test-utils": "^0.5.69-beta.21"
121
122
  },
122
123
  "scripts": {
123
124
  "lint": "tsc --noEmit",