@aigne/cli 1.48.0 → 1.48.2

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,35 @@
1
1
  # Changelog
2
2
 
3
+ ## [1.48.2](https://github.com/AIGNE-io/aigne-framework/compare/cli-v1.48.1...cli-v1.48.2) (2025-09-18)
4
+
5
+
6
+ ### Dependencies
7
+
8
+ * The following workspace dependencies were updated
9
+ * dependencies
10
+ * @aigne/aigne-hub bumped to 0.9.6
11
+
12
+ ## [1.48.1](https://github.com/AIGNE-io/aigne-framework/compare/cli-v1.48.0...cli-v1.48.1) (2025-09-18)
13
+
14
+
15
+ ### Bug Fixes
16
+
17
+ * use aigne hub model when aigne hub connected ([#516](https://github.com/AIGNE-io/aigne-framework/issues/516)) ([a0493d0](https://github.com/AIGNE-io/aigne-framework/commit/a0493d0ad453afd3c3734ee2730636c6bd1e08ce))
18
+
19
+
20
+ ### Dependencies
21
+
22
+ * The following workspace dependencies were updated
23
+ * dependencies
24
+ * @aigne/agent-library bumped to 1.21.45
25
+ * @aigne/agentic-memory bumped to 1.0.45
26
+ * @aigne/aigne-hub bumped to 0.9.5
27
+ * @aigne/core bumped to 1.60.3
28
+ * @aigne/default-memory bumped to 1.2.8
29
+ * @aigne/openai bumped to 0.15.4
30
+ * devDependencies
31
+ * @aigne/test-utils bumped to 0.5.52
32
+
3
33
  ## [1.48.0](https://github.com/AIGNE-io/aigne-framework/compare/cli-v1.47.1...cli-v1.48.0) (2025-09-16)
4
34
 
5
35
 
@@ -7,7 +7,7 @@ const DEFAULT_PORT = () => tryOrThrow(() => {
7
7
  const { PORT } = process.env;
8
8
  if (!PORT)
9
9
  return 7890;
10
- const port = Number.parseInt(PORT);
10
+ const port = Number.parseInt(PORT, 10);
11
11
  if (!port || !Number.isInteger(port))
12
12
  throw new Error(`Invalid PORT: ${PORT}`);
13
13
  return port;
@@ -6,7 +6,7 @@ export const DEFAULT_PORT = () => tryOrThrow(() => {
6
6
  const { PORT } = process.env;
7
7
  if (!PORT)
8
8
  return 3000;
9
- const port = Number.parseInt(PORT);
9
+ const port = Number.parseInt(PORT, 10);
10
10
  if (!port || !Number.isInteger(port))
11
11
  throw new Error(`Invalid PORT: ${PORT}`);
12
12
  return port;
@@ -1,8 +1,10 @@
1
+ import { readFile } from "node:fs/promises";
1
2
  import { AIGNE_HUB_DEFAULT_MODEL, findModel } from "@aigne/aigne-hub";
2
3
  import { flat, pick } from "@aigne/core/utils/type-utils.js";
3
4
  import chalk from "chalk";
4
5
  import inquirer from "inquirer";
5
- import { AIGNE_HUB_PROVIDER } from "./constants.js";
6
+ import { parse, stringify } from "yaml";
7
+ import { AIGNE_ENV_FILE, AIGNE_HUB_PROVIDER } from "./constants.js";
6
8
  import { loadAIGNEHubCredential } from "./credential.js";
7
9
  export function maskApiKey(apiKey) {
8
10
  if (!apiKey || apiKey.length <= 8)
@@ -20,8 +22,9 @@ export const formatModelName = async (model, inquirerPrompt) => {
20
22
  let { provider, model: name } = parseModelOption(model);
21
23
  provider ||= AIGNE_HUB_PROVIDER;
22
24
  const { match, all } = findModel(provider);
23
- if (!match)
25
+ if (!match) {
24
26
  throw new Error(`Unsupported model: ${provider}/${name}, available providers: ${all.map((m) => m.name).join(", ")}`);
27
+ }
25
28
  if (provider.includes(AIGNE_HUB_PROVIDER)) {
26
29
  return { provider, model: name || AIGNE_HUB_DEFAULT_MODEL };
27
30
  }
@@ -29,6 +32,10 @@ export const formatModelName = async (model, inquirerPrompt) => {
29
32
  if (requireEnvs.some((name) => name && process.env[name])) {
30
33
  return { provider, model: name };
31
34
  }
35
+ const envs = parse(await readFile(AIGNE_ENV_FILE, "utf8").catch(() => stringify({})));
36
+ if (envs?.default?.AIGNE_HUB_API_URL) {
37
+ return { provider: AIGNE_HUB_PROVIDER, model: `${provider}/${name}` };
38
+ }
32
39
  const result = await inquirerPrompt({
33
40
  type: "list",
34
41
  name: "useAigneHub",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aigne/cli",
3
- "version": "1.48.0",
3
+ "version": "1.48.2",
4
4
  "description": "Your command center for agent development",
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -47,17 +47,17 @@
47
47
  "dependencies": {
48
48
  "@aigne/listr2": "^1.0.10",
49
49
  "@aigne/marked-terminal": "^7.3.2",
50
- "@inquirer/core": "^10.2.0",
50
+ "@inquirer/core": "^10.2.2",
51
51
  "@inquirer/figures": "^1.0.13",
52
- "@inquirer/prompts": "^7.8.4",
52
+ "@inquirer/prompts": "^7.8.6",
53
53
  "@inquirer/type": "^3.0.8",
54
- "@listr2/prompt-adapter-inquirer": "^3.0.2",
55
- "@modelcontextprotocol/sdk": "^1.15.0",
56
- "@ocap/mcrypto": "^1.21.0",
57
- "@smithy/node-http-handler": "^4.1.0",
58
- "ansi-escapes": "^7.0.0",
54
+ "@listr2/prompt-adapter-inquirer": "^3.0.4",
55
+ "@modelcontextprotocol/sdk": "^1.18.0",
56
+ "@ocap/mcrypto": "^1.25.1",
57
+ "@smithy/node-http-handler": "^4.2.1",
58
+ "ansi-escapes": "^7.1.0",
59
59
  "boxen": "^8.0.1",
60
- "chalk": "^5.4.1",
60
+ "chalk": "^5.6.2",
61
61
  "cli-table3": "^0.6.5",
62
62
  "detect-port": "^2.1.0",
63
63
  "dotenv-flow": "^4.1.0",
@@ -65,46 +65,46 @@
65
65
  "glob": "^11.0.3",
66
66
  "gradient-string": "^3.0.0",
67
67
  "https-proxy-agent": "^7.0.6",
68
- "inquirer": "^12.9.4",
69
- "log-update": "^6.1.0",
70
- "marked": "^16.0.0",
68
+ "inquirer": "^12.9.6",
69
+ "log-update": "^7.0.0",
70
+ "marked": "^16.3.0",
71
71
  "nunjucks": "^3.2.4",
72
72
  "open": "^10.2.0",
73
- "openai": "^5.8.3",
73
+ "openai": "^5.20.3",
74
74
  "p-wait-for": "^5.0.2",
75
75
  "prettier": "^3.6.2",
76
76
  "tar": "^7.4.3",
77
- "terminal-image": "^3.1.1",
78
- "terminal-link": "^4.0.0",
79
- "wrap-ansi": "^9.0.0",
80
- "yaml": "^2.8.0",
77
+ "terminal-image": "^4.0.0",
78
+ "terminal-link": "^5.0.0",
79
+ "wrap-ansi": "^9.0.2",
80
+ "yaml": "^2.8.1",
81
81
  "yargs": "^18.0.0",
82
82
  "yoctocolors-cjs": "^2.1.3",
83
83
  "zod": "^3.25.67",
84
- "@aigne/agent-library": "^1.21.44",
85
- "@aigne/agentic-memory": "^1.0.44",
86
- "@aigne/core": "^1.60.2",
87
- "@aigne/default-memory": "^1.2.7",
88
- "@aigne/aigne-hub": "^0.9.4",
84
+ "@aigne/agentic-memory": "^1.0.45",
85
+ "@aigne/agent-library": "^1.21.45",
86
+ "@aigne/default-memory": "^1.2.8",
87
+ "@aigne/core": "^1.60.3",
89
88
  "@aigne/observability-api": "^0.10.4",
90
- "@aigne/openai": "^0.15.3"
89
+ "@aigne/openai": "^0.15.4",
90
+ "@aigne/aigne-hub": "^0.9.6"
91
91
  },
92
92
  "devDependencies": {
93
- "@inquirer/testing": "^2.1.49",
93
+ "@inquirer/testing": "^2.1.50",
94
94
  "@types/archiver": "^6.0.3",
95
- "@types/bun": "^1.2.18",
95
+ "@types/bun": "^1.2.22",
96
96
  "@types/express": "^5.0.3",
97
97
  "@types/glob": "^9.0.0",
98
98
  "@types/gradient-string": "^1.1.6",
99
- "@types/node": "^24.0.12",
99
+ "@types/node": "^24.5.1",
100
100
  "@types/yargs": "^17.0.33",
101
101
  "archiver": "^7.0.1",
102
102
  "hono": "4.8.4",
103
103
  "npm-run-all": "^4.1.5",
104
104
  "rimraf": "^6.0.1",
105
- "typescript": "^5.8.3",
105
+ "typescript": "^5.9.2",
106
106
  "ufo": "^1.6.1",
107
- "@aigne/test-utils": "^0.5.51"
107
+ "@aigne/test-utils": "^0.5.52"
108
108
  },
109
109
  "scripts": {
110
110
  "lint": "tsc --noEmit",