@integrity-labs/agt-cli 0.27.170 → 0.28.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/dist/bin/agt.js +4 -4
- package/dist/bin/agt.js.map +1 -1
- package/dist/{chunk-YX35EONG.js → chunk-I6QV3IE7.js} +8 -1
- package/dist/{chunk-YX35EONG.js.map → chunk-I6QV3IE7.js.map} +1 -1
- package/dist/{chunk-BMQQ63W2.js → chunk-K2HIV5DB.js} +2 -2
- package/dist/{chunk-U6LHLWWG.js → chunk-ZBMZTL7G.js} +2 -2
- package/dist/{claude-pair-runtime-IDCPU7YT.js → claude-pair-runtime-H73LQ5AR.js} +2 -2
- package/dist/lib/manager-worker.js +81 -9
- package/dist/lib/manager-worker.js.map +1 -1
- package/dist/mcp/slack-channel.js +215 -53
- package/dist/mcp/telegram-channel.js +91 -27
- package/dist/{persistent-session-YQTDRXSB.js → persistent-session-QXLGGGO2.js} +3 -3
- package/dist/{responsiveness-probe-IGQQFMSC.js → responsiveness-probe-3BUUOZZO.js} +56 -5
- package/dist/responsiveness-probe-3BUUOZZO.js.map +1 -0
- package/package.json +1 -1
- package/dist/responsiveness-probe-IGQQFMSC.js.map +0 -1
- /package/dist/{chunk-BMQQ63W2.js.map → chunk-K2HIV5DB.js.map} +0 -0
- /package/dist/{chunk-U6LHLWWG.js.map → chunk-ZBMZTL7G.js.map} +0 -0
- /package/dist/{claude-pair-runtime-IDCPU7YT.js.map → claude-pair-runtime-H73LQ5AR.js.map} +0 -0
- /package/dist/{persistent-session-YQTDRXSB.js.map → persistent-session-QXLGGGO2.js.map} +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
claudeModelAlias,
|
|
3
3
|
isClaudeFastMode
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-I6QV3IE7.js";
|
|
5
5
|
import {
|
|
6
6
|
reapOrphanChannelMcps
|
|
7
7
|
} from "./chunk-XWVM4KPK.js";
|
|
@@ -1466,4 +1466,4 @@ export {
|
|
|
1466
1466
|
stopAllSessionsAndWait,
|
|
1467
1467
|
getProjectDir
|
|
1468
1468
|
};
|
|
1469
|
-
//# sourceMappingURL=chunk-
|
|
1469
|
+
//# sourceMappingURL=chunk-K2HIV5DB.js.map
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
registerFramework,
|
|
15
15
|
resolveAvatarEnvUrl,
|
|
16
16
|
wrapScheduledTaskPrompt
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-I6QV3IE7.js";
|
|
18
18
|
|
|
19
19
|
// ../../packages/core/dist/integrations/registry.js
|
|
20
20
|
var INTEGRATION_REGISTRY = [
|
|
@@ -8237,4 +8237,4 @@ export {
|
|
|
8237
8237
|
managerInstallSystemUnitCommand,
|
|
8238
8238
|
managerUninstallSystemUnitCommand
|
|
8239
8239
|
};
|
|
8240
|
-
//# sourceMappingURL=chunk-
|
|
8240
|
+
//# sourceMappingURL=chunk-ZBMZTL7G.js.map
|
|
@@ -100,7 +100,7 @@ async function spawnPairSession(session) {
|
|
|
100
100
|
return { ok: true };
|
|
101
101
|
} catch {
|
|
102
102
|
}
|
|
103
|
-
const { resolveClaudeBinary } = await import("./persistent-session-
|
|
103
|
+
const { resolveClaudeBinary } = await import("./persistent-session-QXLGGGO2.js");
|
|
104
104
|
const claudeBin = resolveClaudeBinary();
|
|
105
105
|
const pairEnv = {
|
|
106
106
|
...process.env,
|
|
@@ -373,4 +373,4 @@ export {
|
|
|
373
373
|
startClaudePair,
|
|
374
374
|
submitClaudePairCode
|
|
375
375
|
};
|
|
376
|
-
//# sourceMappingURL=claude-pair-runtime-
|
|
376
|
+
//# sourceMappingURL=claude-pair-runtime-H73LQ5AR.js.map
|
|
@@ -22,7 +22,7 @@ import {
|
|
|
22
22
|
provisionStopHook,
|
|
23
23
|
requireHost,
|
|
24
24
|
safeWriteJsonAtomic
|
|
25
|
-
} from "../chunk-
|
|
25
|
+
} from "../chunk-ZBMZTL7G.js";
|
|
26
26
|
import {
|
|
27
27
|
getProjectDir as getProjectDir2,
|
|
28
28
|
getReadyTasks,
|
|
@@ -64,7 +64,7 @@ import {
|
|
|
64
64
|
takeWatchdogGiveUpCount,
|
|
65
65
|
takeZombieDetection,
|
|
66
66
|
transcriptActivityAgeSeconds
|
|
67
|
-
} from "../chunk-
|
|
67
|
+
} from "../chunk-K2HIV5DB.js";
|
|
68
68
|
import {
|
|
69
69
|
FLAGS_SCHEMA_VERSION,
|
|
70
70
|
KANBAN_CHECK_COMMAND,
|
|
@@ -96,7 +96,7 @@ import {
|
|
|
96
96
|
sumTranscriptUsageInWindow,
|
|
97
97
|
worseConnectivityOutcome,
|
|
98
98
|
wrapScheduledTaskPrompt
|
|
99
|
-
} from "../chunk-
|
|
99
|
+
} from "../chunk-I6QV3IE7.js";
|
|
100
100
|
import {
|
|
101
101
|
parsePsRows,
|
|
102
102
|
reapOrphanChannelMcps
|
|
@@ -3599,7 +3599,22 @@ var agentState = {
|
|
|
3599
3599
|
// compound-keyed (`agentId:<suffix>`)
|
|
3600
3600
|
// ---------------------------------------------------------------------------
|
|
3601
3601
|
knownChannelConfigHashes: /* @__PURE__ */ new Map(),
|
|
3602
|
-
knownSkillHashes: /* @__PURE__ */ new Map()
|
|
3602
|
+
knownSkillHashes: /* @__PURE__ */ new Map(),
|
|
3603
|
+
// ---------------------------------------------------------------------------
|
|
3604
|
+
// agentId-keyed (global skills, ENG-6349)
|
|
3605
|
+
// ---------------------------------------------------------------------------
|
|
3606
|
+
/**
|
|
3607
|
+
* ENG-6349 (ADR-0023): per-agent set of global-skill ids (bare code_names)
|
|
3608
|
+
* this worker installed on the previous refresh. Global skills have no folder
|
|
3609
|
+
* prefix (they're written as `.claude/skills/<code_name>/` so `/<code_name>`
|
|
3610
|
+
* resolves), so the integration orphan sweep — which scans for `integration-`/
|
|
3611
|
+
* `plugin-` prefixes — can't see them. We track the delivered set here instead
|
|
3612
|
+
* and remove only the ids that drop out (an unpublished global), never the
|
|
3613
|
+
* agent's own or integration skills. In-memory only: a manager restart resets
|
|
3614
|
+
* it, so an unpublish during a restart window leaves the folder until the next
|
|
3615
|
+
* unpublish — acceptable for a platform-staff-rare action.
|
|
3616
|
+
*/
|
|
3617
|
+
knownGlobalSkillIds: /* @__PURE__ */ new Map()
|
|
3603
3618
|
};
|
|
3604
3619
|
function clearAgentState(agentId, codeName) {
|
|
3605
3620
|
agentState.knownVersions.delete(agentId);
|
|
@@ -3615,6 +3630,7 @@ function clearAgentState(agentId, codeName) {
|
|
|
3615
3630
|
agentState.knownSenderPolicyHashes.delete(agentId);
|
|
3616
3631
|
agentState.knownMsTeamsBehaviourHashes.delete(agentId);
|
|
3617
3632
|
agentState.knownSlackBehaviourHashes.delete(agentId);
|
|
3633
|
+
agentState.knownGlobalSkillIds.delete(agentId);
|
|
3618
3634
|
agentState.agentDisplayNames.delete(codeName);
|
|
3619
3635
|
agentState.codeNameToAgentId.delete(codeName);
|
|
3620
3636
|
let channelCacheMutated = false;
|
|
@@ -3632,6 +3648,28 @@ function clearAgentState(agentId, codeName) {
|
|
|
3632
3648
|
return channelCacheMutated;
|
|
3633
3649
|
}
|
|
3634
3650
|
|
|
3651
|
+
// src/lib/manager/global-skills.ts
|
|
3652
|
+
function sanitizeGlobalSkillId(codeName) {
|
|
3653
|
+
return codeName.trim().replace(/[^a-z0-9-]/g, "-").replace(/-+/g, "-").replace(/^-|-$/g, "");
|
|
3654
|
+
}
|
|
3655
|
+
function planGlobalSkillSync(globalSkills, prevIds, hashOf, knownHash) {
|
|
3656
|
+
const currentIds = /* @__PURE__ */ new Set();
|
|
3657
|
+
const installs = [];
|
|
3658
|
+
for (const gs of globalSkills ?? []) {
|
|
3659
|
+
const codeName = (gs?.code_name ?? "").trim();
|
|
3660
|
+
const content = gs?.content ?? "";
|
|
3661
|
+
if (!codeName || !content.trim()) continue;
|
|
3662
|
+
const skillId = sanitizeGlobalSkillId(codeName);
|
|
3663
|
+
if (!skillId) continue;
|
|
3664
|
+
currentIds.add(skillId);
|
|
3665
|
+
const hash = hashOf(content);
|
|
3666
|
+
if (knownHash(skillId) === hash) continue;
|
|
3667
|
+
installs.push({ skillId, content, hash });
|
|
3668
|
+
}
|
|
3669
|
+
const removes = [...prevIds].filter((id) => !currentIds.has(id));
|
|
3670
|
+
return { installs, removes, currentIds };
|
|
3671
|
+
}
|
|
3672
|
+
|
|
3635
3673
|
// src/lib/wedge-detection.ts
|
|
3636
3674
|
var DEFAULTS = {
|
|
3637
3675
|
inboundWaitSeconds: 120,
|
|
@@ -5041,7 +5079,7 @@ var cachedMaintenanceWindow = null;
|
|
|
5041
5079
|
var lastVersionCheckAt = 0;
|
|
5042
5080
|
var VERSION_CHECK_INTERVAL_MS = 5 * 60 * 1e3;
|
|
5043
5081
|
var lastResponsivenessProbeAt = 0;
|
|
5044
|
-
var agtCliVersion = true ? "0.
|
|
5082
|
+
var agtCliVersion = true ? "0.28.2" : "dev";
|
|
5045
5083
|
function resolveBrewPath(execFileSync4) {
|
|
5046
5084
|
try {
|
|
5047
5085
|
const out = execFileSync4("which", ["brew"], { timeout: 5e3 }).toString().trim();
|
|
@@ -6244,7 +6282,7 @@ async function pollCycle() {
|
|
|
6244
6282
|
}
|
|
6245
6283
|
try {
|
|
6246
6284
|
const { detectHostSecurity } = await import("../host-security-6PDFG7F5.js");
|
|
6247
|
-
const { collectDiagnostics } = await import("../persistent-session-
|
|
6285
|
+
const { collectDiagnostics } = await import("../persistent-session-QXLGGGO2.js");
|
|
6248
6286
|
const diagCodeNames = [...agentState.persistentSessionAgents];
|
|
6249
6287
|
const agentDiagnostics = diagCodeNames.length > 0 ? collectDiagnostics(diagCodeNames) : void 0;
|
|
6250
6288
|
let tailscaleHostname;
|
|
@@ -6338,7 +6376,7 @@ async function pollCycle() {
|
|
|
6338
6376
|
const {
|
|
6339
6377
|
collectResponsivenessProbes,
|
|
6340
6378
|
getResponsivenessIntervalMs
|
|
6341
|
-
} = await import("../responsiveness-probe-
|
|
6379
|
+
} = await import("../responsiveness-probe-3BUUOZZO.js");
|
|
6342
6380
|
const probeIntervalMs = getResponsivenessIntervalMs();
|
|
6343
6381
|
if (now - lastResponsivenessProbeAt > probeIntervalMs) {
|
|
6344
6382
|
const probeCodeNames = [...agentState.persistentSessionAgents];
|
|
@@ -6370,7 +6408,7 @@ async function pollCycle() {
|
|
|
6370
6408
|
collectResponsivenessProbes,
|
|
6371
6409
|
livePendingInboundOldestAgeSeconds,
|
|
6372
6410
|
parkPendingInbound
|
|
6373
|
-
} = await import("../responsiveness-probe-
|
|
6411
|
+
} = await import("../responsiveness-probe-3BUUOZZO.js");
|
|
6374
6412
|
const { getProjectDir: wedgeProjectDir } = await import("../claude-scheduler-FATCLHDM.js");
|
|
6375
6413
|
const wedgeNow = /* @__PURE__ */ new Date();
|
|
6376
6414
|
const liveAgents = agentState.persistentSessionAgents;
|
|
@@ -8018,6 +8056,40 @@ async function processAgent(agent, agentStates) {
|
|
|
8018
8056
|
} catch (err) {
|
|
8019
8057
|
log(`Integration skill cleanup failed for '${agent.code_name}': ${err.message}`);
|
|
8020
8058
|
}
|
|
8059
|
+
try {
|
|
8060
|
+
const plan = planGlobalSkillSync(
|
|
8061
|
+
refreshAny.global_skills ?? [],
|
|
8062
|
+
agentState.knownGlobalSkillIds.get(agent.agent_id) ?? /* @__PURE__ */ new Set(),
|
|
8063
|
+
(content) => createHash4("sha256").update(content).digest("hex").slice(0, 12),
|
|
8064
|
+
(skillId) => agentState.knownSkillHashes.get(`global-skill:${agent.agent_id}:${skillId}`)
|
|
8065
|
+
);
|
|
8066
|
+
for (const { skillId, content, hash } of plan.installs) {
|
|
8067
|
+
frameworkAdapter.installSkillFiles(agent.code_name, skillId, [{ relativePath: "SKILL.md", content }]);
|
|
8068
|
+
agentState.knownSkillHashes.set(`global-skill:${agent.agent_id}:${skillId}`, hash);
|
|
8069
|
+
log(`Installed global skill '${skillId}' for '${agent.code_name}'`);
|
|
8070
|
+
}
|
|
8071
|
+
if (plan.removes.length) {
|
|
8072
|
+
const { rmSync: rmSync3 } = await import("fs");
|
|
8073
|
+
const { homedir: homedir6 } = await import("os");
|
|
8074
|
+
const globalSkillDirs = [
|
|
8075
|
+
join10(homedir6(), ".augmented", agent.code_name, "skills"),
|
|
8076
|
+
join10(homedir6(), ".augmented", agent.code_name, "project", ".claude", "skills"),
|
|
8077
|
+
join10(homedir6(), `.openclaw-${agent.code_name}`, "skills"),
|
|
8078
|
+
join10(agentDir, ".claude", "skills")
|
|
8079
|
+
];
|
|
8080
|
+
for (const id of plan.removes) {
|
|
8081
|
+
for (const dir of globalSkillDirs) {
|
|
8082
|
+
const p = join10(dir, id);
|
|
8083
|
+
if (existsSync5(p)) rmSync3(p, { recursive: true, force: true });
|
|
8084
|
+
}
|
|
8085
|
+
agentState.knownSkillHashes.delete(`global-skill:${agent.agent_id}:${id}`);
|
|
8086
|
+
log(`Removed unpublished global skill '${id}' for '${agent.code_name}'`);
|
|
8087
|
+
}
|
|
8088
|
+
}
|
|
8089
|
+
agentState.knownGlobalSkillIds.set(agent.agent_id, plan.currentIds);
|
|
8090
|
+
} catch (err) {
|
|
8091
|
+
log(`Global skill install failed for '${agent.code_name}': ${err.message}`);
|
|
8092
|
+
}
|
|
8021
8093
|
try {
|
|
8022
8094
|
const agentFwForIndex = agentFrameworkCache.get(agent.code_name) ?? "openclaw";
|
|
8023
8095
|
if (agentFwForIndex === "claude-code") {
|
|
@@ -10966,7 +11038,7 @@ async function processClaudePairSessions(agents) {
|
|
|
10966
11038
|
killPairSession,
|
|
10967
11039
|
pairTmuxSession,
|
|
10968
11040
|
finalizeClaudePairOnboarding
|
|
10969
|
-
} = await import("../claude-pair-runtime-
|
|
11041
|
+
} = await import("../claude-pair-runtime-H73LQ5AR.js");
|
|
10970
11042
|
for (const pairId of pendingResp.cancelled_pair_ids ?? []) {
|
|
10971
11043
|
log(`[claude-pair] sweeping orphan tmux session for pair ${pairId.slice(0, 8)}`);
|
|
10972
11044
|
const killed = await killPairSession(pairTmuxSession(pairId));
|