@signetai/signet-memory-openclaw 0.154.6 → 0.154.7
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/index.js +19 -19
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -25,11 +25,11 @@ import { createRequire as createRequire2 } from "node:module";
|
|
|
25
25
|
import { dirname, join } from "node:path";
|
|
26
26
|
import { fileURLToPath } from "node:url";
|
|
27
27
|
import { createRequire as createRequire22 } from "node:module";
|
|
28
|
-
import { homedir as
|
|
29
|
-
import { basename, dirname as
|
|
30
|
-
import { existsSync as
|
|
31
|
-
import { dirname as
|
|
32
|
-
import { homedir as
|
|
28
|
+
import { homedir as homedir4, platform as platform2 } from "node:os";
|
|
29
|
+
import { basename, dirname as dirname4, resolve as resolve4 } from "node:path";
|
|
30
|
+
import { existsSync as existsSync11, readFileSync as readFileSync9, readdirSync as readdirSync4, realpathSync, statSync as statSync5 } from "node:fs";
|
|
31
|
+
import { dirname as dirname7, join as join11 } from "node:path";
|
|
32
|
+
import { homedir as homedir8 } from "node:os";
|
|
33
33
|
var __create = Object.create;
|
|
34
34
|
var __getProtoOf = Object.getPrototypeOf;
|
|
35
35
|
var __defProp2 = Object.defineProperty;
|
|
@@ -11032,11 +11032,11 @@ var VALID_GITHUB_RESOURCE_TYPES = new Set(DEFAULT_GITHUB_RESOURCE_TYPES);
|
|
|
11032
11032
|
function defaultDiscordDesktopCachePath() {
|
|
11033
11033
|
switch (platform2()) {
|
|
11034
11034
|
case "darwin":
|
|
11035
|
-
return
|
|
11035
|
+
return resolve4(homedir4(), "Library", "Application Support", "discord");
|
|
11036
11036
|
case "win32":
|
|
11037
|
-
return
|
|
11037
|
+
return resolve4(process.env.APPDATA || resolve4(homedir4(), "AppData", "Roaming"), "discord");
|
|
11038
11038
|
default:
|
|
11039
|
-
return
|
|
11039
|
+
return resolve4(process.env.XDG_CONFIG_HOME || resolve4(homedir4(), ".config"), "discord");
|
|
11040
11040
|
}
|
|
11041
11041
|
}
|
|
11042
11042
|
var IDENTITY_MODES = ["managed", "passthrough", "off"];
|
|
@@ -11176,11 +11176,11 @@ function resolveIdentityModeFromConfig(config) {
|
|
|
11176
11176
|
return "managed";
|
|
11177
11177
|
}
|
|
11178
11178
|
function loadIdentityMode(agentsDir) {
|
|
11179
|
-
const agentYaml =
|
|
11180
|
-
if (!
|
|
11179
|
+
const agentYaml = join11(agentsDir, "agent.yaml");
|
|
11180
|
+
if (!existsSync11(agentYaml))
|
|
11181
11181
|
return "managed";
|
|
11182
11182
|
try {
|
|
11183
|
-
return resolveIdentityModeFromConfig(parseSimpleYaml(
|
|
11183
|
+
return resolveIdentityModeFromConfig(parseSimpleYaml(readFileSync9(agentYaml, "utf-8")));
|
|
11184
11184
|
} catch {
|
|
11185
11185
|
return "managed";
|
|
11186
11186
|
}
|
|
@@ -11213,11 +11213,11 @@ function identityHeaderFor(path, role) {
|
|
|
11213
11213
|
return STATIC_HEADER_BY_FILE[filename] ?? role ?? filename.replace(/\.md$/i, "");
|
|
11214
11214
|
}
|
|
11215
11215
|
function resolveStartupIdentityFiles(agentsDir) {
|
|
11216
|
-
const agentYaml =
|
|
11217
|
-
if (!
|
|
11216
|
+
const agentYaml = join11(agentsDir, "agent.yaml");
|
|
11217
|
+
if (!existsSync11(agentYaml))
|
|
11218
11218
|
return STATIC_BUDGETS.map(({ file, budget }) => ({ path: file, budget }));
|
|
11219
11219
|
try {
|
|
11220
|
-
const config = parseSimpleYaml(
|
|
11220
|
+
const config = parseSimpleYaml(readFileSync9(agentYaml, "utf-8"));
|
|
11221
11221
|
if (!identityModeReadsFiles(resolveIdentityModeFromConfig(config)))
|
|
11222
11222
|
return [];
|
|
11223
11223
|
const identity = readRecord(config.identity);
|
|
@@ -11245,17 +11245,17 @@ function resolveSessionStartTimeoutMs(raw) {
|
|
|
11245
11245
|
return ms;
|
|
11246
11246
|
}
|
|
11247
11247
|
function readStaticIdentity(agentsDir, status = STATIC_IDENTITY_OFFLINE_STATUS) {
|
|
11248
|
-
if (!
|
|
11248
|
+
if (!existsSync11(agentsDir))
|
|
11249
11249
|
return null;
|
|
11250
11250
|
if (!identityModeReadsFiles(loadIdentityMode(agentsDir)))
|
|
11251
11251
|
return null;
|
|
11252
11252
|
const parts = [];
|
|
11253
11253
|
for (const entry of resolveStartupIdentityFiles(agentsDir)) {
|
|
11254
|
-
const path =
|
|
11255
|
-
if (!
|
|
11254
|
+
const path = join11(agentsDir, entry.path);
|
|
11255
|
+
if (!existsSync11(path))
|
|
11256
11256
|
continue;
|
|
11257
11257
|
try {
|
|
11258
|
-
const raw =
|
|
11258
|
+
const raw = readFileSync9(path, "utf-8").trim();
|
|
11259
11259
|
if (!raw)
|
|
11260
11260
|
continue;
|
|
11261
11261
|
const budget = entry.budget ?? STATIC_BUDGETS.find((candidate) => candidate.file === entry.path)?.budget ?? 4000;
|
|
@@ -11274,7 +11274,7 @@ ${parts.join(`
|
|
|
11274
11274
|
|
|
11275
11275
|
`)}`;
|
|
11276
11276
|
}
|
|
11277
|
-
var home =
|
|
11277
|
+
var home = homedir8();
|
|
11278
11278
|
var SKIP_SUBTYPES = new Set([
|
|
11279
11279
|
"channel_join",
|
|
11280
11280
|
"channel_leave",
|