@ai-setting/roy-agent-cli 1.5.56 → 1.5.58
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/bin/roy-agent.js +52 -5
- package/dist/index.js +52 -5
- package/dist/roy-agent-linux-x64/bin/roy-agent +0 -0
- package/package.json +3 -3
package/dist/bin/roy-agent.js
CHANGED
|
@@ -7319,7 +7319,7 @@ var require_dist = __commonJS((exports) => {
|
|
|
7319
7319
|
var require_package = __commonJS((exports, module) => {
|
|
7320
7320
|
module.exports = {
|
|
7321
7321
|
name: "@ai-setting/roy-agent-cli",
|
|
7322
|
-
version: "1.5.
|
|
7322
|
+
version: "1.5.58",
|
|
7323
7323
|
type: "module",
|
|
7324
7324
|
description: "CLI for roy-agent - Non-interactive command execution",
|
|
7325
7325
|
main: "./dist/index.js",
|
|
@@ -7345,8 +7345,8 @@ var require_package = __commonJS((exports, module) => {
|
|
|
7345
7345
|
typecheck: "npx tsc --noEmit --skipLibCheck"
|
|
7346
7346
|
},
|
|
7347
7347
|
dependencies: {
|
|
7348
|
-
"@ai-setting/roy-agent-coder-harness": "^1.5.
|
|
7349
|
-
"@ai-setting/roy-agent-core": "^1.5.
|
|
7348
|
+
"@ai-setting/roy-agent-coder-harness": "^1.5.48",
|
|
7349
|
+
"@ai-setting/roy-agent-core": "^1.5.57",
|
|
7350
7350
|
"@ai-setting/roy-agent-ontology-harness": "^1.5.47",
|
|
7351
7351
|
chalk: "^5.6.2",
|
|
7352
7352
|
commander: "^14.0.3",
|
|
@@ -7414,6 +7414,11 @@ class CliQuietModeService {
|
|
|
7414
7414
|
isQuiet() {
|
|
7415
7415
|
return isCoreQuietMode();
|
|
7416
7416
|
}
|
|
7417
|
+
setQuietFromArgv(argv) {
|
|
7418
|
+
if (argv.quiet === true) {
|
|
7419
|
+
setCoreQuietMode(true);
|
|
7420
|
+
}
|
|
7421
|
+
}
|
|
7417
7422
|
reset() {
|
|
7418
7423
|
setCoreQuietMode(false);
|
|
7419
7424
|
}
|
|
@@ -8955,7 +8960,17 @@ class EventMessageFormatter {
|
|
|
8955
8960
|
const desc = payload.description || "未命名任务";
|
|
8956
8961
|
const result = payload.result;
|
|
8957
8962
|
const time = payload.executionTimeMs ? `(${this.formatDuration(payload.executionTimeMs)})` : "";
|
|
8963
|
+
const bgProcessId = payload.backgroundTaskId || "";
|
|
8964
|
+
const taskId = payload.associatedTaskId;
|
|
8958
8965
|
let message = `${this.prefix} ✅ 后台任务「${desc}」已完成 ${time}`;
|
|
8966
|
+
if (bgProcessId) {
|
|
8967
|
+
message += `
|
|
8968
|
+
bgprocess: ${bgProcessId}`;
|
|
8969
|
+
}
|
|
8970
|
+
if (taskId !== undefined) {
|
|
8971
|
+
message += `
|
|
8972
|
+
Task #${taskId}`;
|
|
8973
|
+
}
|
|
8959
8974
|
if (result) {
|
|
8960
8975
|
const truncatedResult = result.length > 1e4 ? result.substring(0, 100) + "...[TRUNCATED]" : result;
|
|
8961
8976
|
message += `
|
|
@@ -8967,7 +8982,17 @@ class EventMessageFormatter {
|
|
|
8967
8982
|
const desc = payload.description || "未命名任务";
|
|
8968
8983
|
const error = payload.error || "未知错误";
|
|
8969
8984
|
const time = payload.executionTimeMs ? `(${this.formatDuration(payload.executionTimeMs)})` : "";
|
|
8985
|
+
const bgProcessId = payload.backgroundTaskId || "";
|
|
8986
|
+
const taskId = payload.associatedTaskId;
|
|
8970
8987
|
let message = `${this.prefix} ❌ 后台任务「${desc}」失败 ${time}`;
|
|
8988
|
+
if (bgProcessId) {
|
|
8989
|
+
message += `
|
|
8990
|
+
bgprocess: ${bgProcessId}`;
|
|
8991
|
+
}
|
|
8992
|
+
if (taskId !== undefined) {
|
|
8993
|
+
message += `
|
|
8994
|
+
Task #${taskId}`;
|
|
8995
|
+
}
|
|
8971
8996
|
if (error) {
|
|
8972
8997
|
const truncatedError = error.length > 100 ? error.substring(0, 100) + "..." : error;
|
|
8973
8998
|
message += `
|
|
@@ -8978,12 +9003,34 @@ class EventMessageFormatter {
|
|
|
8978
9003
|
formatTaskTimeout(payload) {
|
|
8979
9004
|
const desc = payload.description || "未命名任务";
|
|
8980
9005
|
const time = payload.executionTimeMs ? `(${this.formatDuration(payload.executionTimeMs)})` : "";
|
|
8981
|
-
|
|
9006
|
+
const bgProcessId = payload.backgroundTaskId || "";
|
|
9007
|
+
const taskId = payload.associatedTaskId;
|
|
9008
|
+
let message = `${this.prefix} ⏱️ 后台任务「${desc}」超时 ${time}`;
|
|
9009
|
+
if (bgProcessId) {
|
|
9010
|
+
message += `
|
|
9011
|
+
bgprocess: ${bgProcessId}`;
|
|
9012
|
+
}
|
|
9013
|
+
if (taskId !== undefined) {
|
|
9014
|
+
message += `
|
|
9015
|
+
Task #${taskId}`;
|
|
9016
|
+
}
|
|
9017
|
+
return message;
|
|
8982
9018
|
}
|
|
8983
9019
|
formatTaskStopped(payload) {
|
|
8984
9020
|
const desc = payload.description || "未命名任务";
|
|
8985
9021
|
const time = payload.executionTimeMs ? `(${this.formatDuration(payload.executionTimeMs)})` : "";
|
|
8986
|
-
|
|
9022
|
+
const bgProcessId = payload.backgroundTaskId || "";
|
|
9023
|
+
const taskId = payload.associatedTaskId;
|
|
9024
|
+
let message = `${this.prefix} \uD83D\uDED1 后台任务「${desc}」已停止 ${time}`;
|
|
9025
|
+
if (bgProcessId) {
|
|
9026
|
+
message += `
|
|
9027
|
+
bgprocess: ${bgProcessId}`;
|
|
9028
|
+
}
|
|
9029
|
+
if (taskId !== undefined) {
|
|
9030
|
+
message += `
|
|
9031
|
+
Task #${taskId}`;
|
|
9032
|
+
}
|
|
9033
|
+
return message;
|
|
8987
9034
|
}
|
|
8988
9035
|
formatGeneric(event) {
|
|
8989
9036
|
return `${this.prefix} 收到事件: ${event.type}`;
|
package/dist/index.js
CHANGED
|
@@ -7318,7 +7318,7 @@ var require_dist = __commonJS((exports) => {
|
|
|
7318
7318
|
var require_package = __commonJS((exports, module) => {
|
|
7319
7319
|
module.exports = {
|
|
7320
7320
|
name: "@ai-setting/roy-agent-cli",
|
|
7321
|
-
version: "1.5.
|
|
7321
|
+
version: "1.5.58",
|
|
7322
7322
|
type: "module",
|
|
7323
7323
|
description: "CLI for roy-agent - Non-interactive command execution",
|
|
7324
7324
|
main: "./dist/index.js",
|
|
@@ -7344,8 +7344,8 @@ var require_package = __commonJS((exports, module) => {
|
|
|
7344
7344
|
typecheck: "npx tsc --noEmit --skipLibCheck"
|
|
7345
7345
|
},
|
|
7346
7346
|
dependencies: {
|
|
7347
|
-
"@ai-setting/roy-agent-coder-harness": "^1.5.
|
|
7348
|
-
"@ai-setting/roy-agent-core": "^1.5.
|
|
7347
|
+
"@ai-setting/roy-agent-coder-harness": "^1.5.48",
|
|
7348
|
+
"@ai-setting/roy-agent-core": "^1.5.57",
|
|
7349
7349
|
"@ai-setting/roy-agent-ontology-harness": "^1.5.47",
|
|
7350
7350
|
chalk: "^5.6.2",
|
|
7351
7351
|
commander: "^14.0.3",
|
|
@@ -7413,6 +7413,11 @@ class CliQuietModeService {
|
|
|
7413
7413
|
isQuiet() {
|
|
7414
7414
|
return isCoreQuietMode();
|
|
7415
7415
|
}
|
|
7416
|
+
setQuietFromArgv(argv) {
|
|
7417
|
+
if (argv.quiet === true) {
|
|
7418
|
+
setCoreQuietMode(true);
|
|
7419
|
+
}
|
|
7420
|
+
}
|
|
7416
7421
|
reset() {
|
|
7417
7422
|
setCoreQuietMode(false);
|
|
7418
7423
|
}
|
|
@@ -8954,7 +8959,17 @@ class EventMessageFormatter {
|
|
|
8954
8959
|
const desc = payload.description || "未命名任务";
|
|
8955
8960
|
const result = payload.result;
|
|
8956
8961
|
const time = payload.executionTimeMs ? `(${this.formatDuration(payload.executionTimeMs)})` : "";
|
|
8962
|
+
const bgProcessId = payload.backgroundTaskId || "";
|
|
8963
|
+
const taskId = payload.associatedTaskId;
|
|
8957
8964
|
let message = `${this.prefix} ✅ 后台任务「${desc}」已完成 ${time}`;
|
|
8965
|
+
if (bgProcessId) {
|
|
8966
|
+
message += `
|
|
8967
|
+
bgprocess: ${bgProcessId}`;
|
|
8968
|
+
}
|
|
8969
|
+
if (taskId !== undefined) {
|
|
8970
|
+
message += `
|
|
8971
|
+
Task #${taskId}`;
|
|
8972
|
+
}
|
|
8958
8973
|
if (result) {
|
|
8959
8974
|
const truncatedResult = result.length > 1e4 ? result.substring(0, 100) + "...[TRUNCATED]" : result;
|
|
8960
8975
|
message += `
|
|
@@ -8966,7 +8981,17 @@ class EventMessageFormatter {
|
|
|
8966
8981
|
const desc = payload.description || "未命名任务";
|
|
8967
8982
|
const error = payload.error || "未知错误";
|
|
8968
8983
|
const time = payload.executionTimeMs ? `(${this.formatDuration(payload.executionTimeMs)})` : "";
|
|
8984
|
+
const bgProcessId = payload.backgroundTaskId || "";
|
|
8985
|
+
const taskId = payload.associatedTaskId;
|
|
8969
8986
|
let message = `${this.prefix} ❌ 后台任务「${desc}」失败 ${time}`;
|
|
8987
|
+
if (bgProcessId) {
|
|
8988
|
+
message += `
|
|
8989
|
+
bgprocess: ${bgProcessId}`;
|
|
8990
|
+
}
|
|
8991
|
+
if (taskId !== undefined) {
|
|
8992
|
+
message += `
|
|
8993
|
+
Task #${taskId}`;
|
|
8994
|
+
}
|
|
8970
8995
|
if (error) {
|
|
8971
8996
|
const truncatedError = error.length > 100 ? error.substring(0, 100) + "..." : error;
|
|
8972
8997
|
message += `
|
|
@@ -8977,12 +9002,34 @@ class EventMessageFormatter {
|
|
|
8977
9002
|
formatTaskTimeout(payload) {
|
|
8978
9003
|
const desc = payload.description || "未命名任务";
|
|
8979
9004
|
const time = payload.executionTimeMs ? `(${this.formatDuration(payload.executionTimeMs)})` : "";
|
|
8980
|
-
|
|
9005
|
+
const bgProcessId = payload.backgroundTaskId || "";
|
|
9006
|
+
const taskId = payload.associatedTaskId;
|
|
9007
|
+
let message = `${this.prefix} ⏱️ 后台任务「${desc}」超时 ${time}`;
|
|
9008
|
+
if (bgProcessId) {
|
|
9009
|
+
message += `
|
|
9010
|
+
bgprocess: ${bgProcessId}`;
|
|
9011
|
+
}
|
|
9012
|
+
if (taskId !== undefined) {
|
|
9013
|
+
message += `
|
|
9014
|
+
Task #${taskId}`;
|
|
9015
|
+
}
|
|
9016
|
+
return message;
|
|
8981
9017
|
}
|
|
8982
9018
|
formatTaskStopped(payload) {
|
|
8983
9019
|
const desc = payload.description || "未命名任务";
|
|
8984
9020
|
const time = payload.executionTimeMs ? `(${this.formatDuration(payload.executionTimeMs)})` : "";
|
|
8985
|
-
|
|
9021
|
+
const bgProcessId = payload.backgroundTaskId || "";
|
|
9022
|
+
const taskId = payload.associatedTaskId;
|
|
9023
|
+
let message = `${this.prefix} \uD83D\uDED1 后台任务「${desc}」已停止 ${time}`;
|
|
9024
|
+
if (bgProcessId) {
|
|
9025
|
+
message += `
|
|
9026
|
+
bgprocess: ${bgProcessId}`;
|
|
9027
|
+
}
|
|
9028
|
+
if (taskId !== undefined) {
|
|
9029
|
+
message += `
|
|
9030
|
+
Task #${taskId}`;
|
|
9031
|
+
}
|
|
9032
|
+
return message;
|
|
8986
9033
|
}
|
|
8987
9034
|
formatGeneric(event) {
|
|
8988
9035
|
return `${this.prefix} 收到事件: ${event.type}`;
|
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ai-setting/roy-agent-cli",
|
|
3
|
-
"version": "1.5.
|
|
3
|
+
"version": "1.5.58",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "CLI for roy-agent - Non-interactive command execution",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -26,8 +26,8 @@
|
|
|
26
26
|
"typecheck": "npx tsc --noEmit --skipLibCheck"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@ai-setting/roy-agent-coder-harness": "^1.5.
|
|
30
|
-
"@ai-setting/roy-agent-core": "^1.5.
|
|
29
|
+
"@ai-setting/roy-agent-coder-harness": "^1.5.48",
|
|
30
|
+
"@ai-setting/roy-agent-core": "^1.5.57",
|
|
31
31
|
"@ai-setting/roy-agent-ontology-harness": "^1.5.47",
|
|
32
32
|
"chalk": "^5.6.2",
|
|
33
33
|
"commander": "^14.0.3",
|