agent-lookout 0.2.8 → 0.2.9
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 +18 -0
- package/PRIVACY.md +24 -10
- package/SECURITY.md +7 -3
- package/dist/assets/{HistoryPanel-CQ7zovsM.js → HistoryPanel-Cr6VQlz-.js} +1 -1
- package/dist/assets/SessionPanel-YVGY4vbo.js +1 -0
- package/dist/assets/index-BRNSMV9A.css +1 -0
- package/dist/assets/index-DlDz48ci.js +9 -0
- package/dist/cli/agent-lookout.js +4 -4
- package/dist/cli/{chunk-LZ62RW3N.js → chunk-AHCLJEYU.js} +1 -1
- package/dist/cli/{chunk-JSBQMY3Q.js → chunk-CMDNRNYP.js} +1 -1
- package/dist/cli/{chunk-I6Q35DHC.js → chunk-XV7BYWVY.js} +17 -0
- package/dist/cli/{mcpServer-BMSF2TXC.js → mcpServer-33QB6COH.js} +3 -3
- package/dist/cli/{startCommand-ANC7NVAO.js → startCommand-XUZHHWZG.js} +538 -241
- package/dist/index.html +2 -2
- package/docs/API.md +56 -29
- package/docs/GUIDE.md +54 -50
- package/package.json +1 -1
- package/dist/assets/SessionPanel-DS29Z04P.js +0 -1
- package/dist/assets/index-BWFkRW4g.js +0 -3
- package/dist/assets/index-B_1Its0R.css +0 -1
|
@@ -3,13 +3,13 @@ import {
|
|
|
3
3
|
statusJson,
|
|
4
4
|
statusReport,
|
|
5
5
|
statusText
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-AHCLJEYU.js";
|
|
7
7
|
import {
|
|
8
8
|
addressesToTry,
|
|
9
9
|
findSnapshot,
|
|
10
10
|
readAppVersion,
|
|
11
11
|
readSessions
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-XV7BYWVY.js";
|
|
13
13
|
|
|
14
14
|
// src/cli/agentLookout.ts
|
|
15
15
|
import { isatty } from "node:tty";
|
|
@@ -167,7 +167,7 @@ async function runCommand(options) {
|
|
|
167
167
|
return EXIT.notKnown;
|
|
168
168
|
}
|
|
169
169
|
if (parsed.kind === "start") {
|
|
170
|
-
const { startCommand } = await import("./startCommand-
|
|
170
|
+
const { startCommand } = await import("./startCommand-XUZHHWZG.js");
|
|
171
171
|
const url = await startCommand({
|
|
172
172
|
...parsed.options,
|
|
173
173
|
distDir: options.distDir ?? fileURLToPath(new URL("../../dist/", import.meta.url)),
|
|
@@ -187,7 +187,7 @@ async function runCommand(options) {
|
|
|
187
187
|
const read = options.read ?? ((address) => readSessions(address));
|
|
188
188
|
const now = options.now ?? Date.now;
|
|
189
189
|
if (parsed.kind === "mcp") {
|
|
190
|
-
const { serveMcp } = await import("./mcpServer-
|
|
190
|
+
const { serveMcp } = await import("./mcpServer-33QB6COH.js");
|
|
191
191
|
await serveMcp({
|
|
192
192
|
addresses: toTry,
|
|
193
193
|
read,
|
|
@@ -429,6 +429,10 @@ var MAX_NAME_LENGTH = 200;
|
|
|
429
429
|
var MAX_LINE_LENGTH = 80;
|
|
430
430
|
var MAX_WAITING_TEXT_LENGTH = 200;
|
|
431
431
|
var MAX_NOTICE_TEXT_LENGTH = 240;
|
|
432
|
+
var MAX_MESSAGE_LENGTH = 2e3;
|
|
433
|
+
var MESSAGE_START_REACH = 200;
|
|
434
|
+
var CONTROL_BUT_LINE_BREAK = /[^\P{Cc}\n]/gu;
|
|
435
|
+
var REORDERING = new RegExp(`[${REORDERING_MARKS}]`, "gu");
|
|
432
436
|
function clean(value) {
|
|
433
437
|
if (typeof value !== "string") return void 0;
|
|
434
438
|
const text = value.replace(UNWANTED, " ").trim();
|
|
@@ -454,6 +458,18 @@ function oneLine(text, max = MAX_LINE_LENGTH) {
|
|
|
454
458
|
if (characters.length <= max) return flat;
|
|
455
459
|
return `${characters.slice(0, max - 1).join("").trimEnd()}\u2026`;
|
|
456
460
|
}
|
|
461
|
+
function messageText(value) {
|
|
462
|
+
if (typeof value !== "string") return void 0;
|
|
463
|
+
const lines = value.replace(/\r\n?|[\u2028\u2029]/g, "\n").replace(/\t/g, " ").replace(CONTROL_BUT_LINE_BREAK, " ").replace(REORDERING, "").split("\n");
|
|
464
|
+
const text = lines.map((line) => line.trimEnd()).join("\n").replace(/\n{3,}/g, "\n\n").trim();
|
|
465
|
+
if (text === "") return void 0;
|
|
466
|
+
const characters = Array.from(text);
|
|
467
|
+
if (characters.length <= MAX_MESSAGE_LENGTH) return { text, cut: false };
|
|
468
|
+
const kept = characters.slice(-MAX_MESSAGE_LENGTH);
|
|
469
|
+
const lineBreak = kept.indexOf("\n");
|
|
470
|
+
const start = lineBreak !== -1 && lineBreak < MESSAGE_START_REACH ? lineBreak + 1 : 0;
|
|
471
|
+
return { text: kept.slice(start).join("").trimStart(), cut: true };
|
|
472
|
+
}
|
|
457
473
|
|
|
458
474
|
// src/core/waits/answeredWaits.ts
|
|
459
475
|
var ANSWER_HOLDS_MS = 1e4;
|
|
@@ -540,6 +556,7 @@ export {
|
|
|
540
556
|
sessionName,
|
|
541
557
|
waitingText,
|
|
542
558
|
oneLine,
|
|
559
|
+
messageText,
|
|
543
560
|
needsYou,
|
|
544
561
|
inAnsweredWait,
|
|
545
562
|
answeredNow
|
|
@@ -2,11 +2,11 @@ import {
|
|
|
2
2
|
machineOf,
|
|
3
3
|
statusReport,
|
|
4
4
|
terminalText
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-AHCLJEYU.js";
|
|
6
6
|
import {
|
|
7
7
|
STATUS_ORDER,
|
|
8
8
|
sortSessions
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-CMDNRNYP.js";
|
|
10
10
|
import {
|
|
11
11
|
CAPABILITIES,
|
|
12
12
|
CAPABILITY_LABEL,
|
|
@@ -27,7 +27,7 @@ import {
|
|
|
27
27
|
readAppVersion,
|
|
28
28
|
sessionTitle,
|
|
29
29
|
surfaceLabel
|
|
30
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-XV7BYWVY.js";
|
|
31
31
|
|
|
32
32
|
// node_modules/@modelcontextprotocol/sdk/node_modules/ajv/dist/compile/codegen/code.js
|
|
33
33
|
var require_code = __commonJS({
|