agent-communication-mcp 0.2.0 → 0.2.3
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.
|
@@ -7,7 +7,7 @@ const constants_1 = require("./constants");
|
|
|
7
7
|
exports.sendMessageSchema = zod_1.z.object({
|
|
8
8
|
agentName: zod_1.z.string().min(1).max(50),
|
|
9
9
|
roomName: zod_1.z.string().min(1).regex(/^[a-zA-Z0-9-_]+$/),
|
|
10
|
-
message: zod_1.z.string().min(1).max(
|
|
10
|
+
message: zod_1.z.string().min(1).max(2000),
|
|
11
11
|
metadata: zod_1.z.record(zod_1.z.any()).optional()
|
|
12
12
|
});
|
|
13
13
|
exports.getMessagesSchema = zod_1.z.object({
|
|
@@ -14,7 +14,7 @@ const agentNameSchema = zod_1.z
|
|
|
14
14
|
const messageContentSchema = zod_1.z
|
|
15
15
|
.string()
|
|
16
16
|
.min(1, 'Message cannot be empty')
|
|
17
|
-
.max(
|
|
17
|
+
.max(2000, 'Message cannot exceed 2000 characters');
|
|
18
18
|
exports.sendMessageInputSchema = zod_1.z.object({
|
|
19
19
|
agentName: agentNameSchema,
|
|
20
20
|
roomName: roomNameSchema,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dataDir.d.ts","sourceRoot":"","sources":["../../src/utils/dataDir.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,qBAAqB,QAA8C,CAAC;AACjF,eAAO,MAAM,eAAe,WAAW,CAAC;
|
|
1
|
+
{"version":3,"file":"dataDir.d.ts","sourceRoot":"","sources":["../../src/utils/dataDir.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,qBAAqB,QAA8C,CAAC;AACjF,eAAO,MAAM,eAAe,WAAW,CAAC;AAOxC,wBAAgB,gBAAgB,IAAI,MAAM,CAOzC"}
|
package/dist/utils/dataDir.js
CHANGED
|
@@ -4,24 +4,12 @@ exports.LEGACY_DATA_DIR = exports.DEFAULT_HOME_DATA_DIR = void 0;
|
|
|
4
4
|
exports.getDataDirectory = getDataDirectory;
|
|
5
5
|
const os_1 = require("os");
|
|
6
6
|
const path_1 = require("path");
|
|
7
|
-
const fs_1 = require("fs");
|
|
8
7
|
exports.DEFAULT_HOME_DATA_DIR = (0, path_1.join)((0, os_1.homedir)(), '.agent-communication-mcp');
|
|
9
8
|
exports.LEGACY_DATA_DIR = './data';
|
|
10
9
|
function getDataDirectory() {
|
|
11
10
|
if (process.env.AGENT_COMM_DATA_DIR) {
|
|
12
11
|
return process.env.AGENT_COMM_DATA_DIR;
|
|
13
12
|
}
|
|
14
|
-
if ((0, fs_1.existsSync)(exports.LEGACY_DATA_DIR)) {
|
|
15
|
-
try {
|
|
16
|
-
(0, fs_1.accessSync)(exports.LEGACY_DATA_DIR, fs_1.constants.W_OK);
|
|
17
|
-
console.warn(`Warning: Using legacy data directory "${exports.LEGACY_DATA_DIR}". ` +
|
|
18
|
-
`Consider setting AGENT_COMM_DATA_DIR="${exports.DEFAULT_HOME_DATA_DIR}" ` +
|
|
19
|
-
`and migrating your data.`);
|
|
20
|
-
return exports.LEGACY_DATA_DIR;
|
|
21
|
-
}
|
|
22
|
-
catch {
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
13
|
return exports.DEFAULT_HOME_DATA_DIR;
|
|
26
14
|
}
|
|
27
15
|
//# sourceMappingURL=dataDir.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dataDir.js","sourceRoot":"","sources":["../../src/utils/dataDir.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"dataDir.js","sourceRoot":"","sources":["../../src/utils/dataDir.ts"],"names":[],"mappings":";;;AAYA,4CAOC;AAnBD,2BAA6B;AAC7B,+BAA4B;AAGf,QAAA,qBAAqB,GAAG,IAAA,WAAI,EAAC,IAAA,YAAO,GAAE,EAAE,0BAA0B,CAAC,CAAC;AACpE,QAAA,eAAe,GAAG,QAAQ,CAAC;AAOxC,SAAgB,gBAAgB;IAE9B,IAAI,OAAO,CAAC,GAAG,CAAC,mBAAmB,EAAE,CAAC;QACpC,OAAO,OAAO,CAAC,GAAG,CAAC,mBAAmB,CAAC;IACzC,CAAC;IAED,OAAO,6BAAqB,CAAC;AAC/B,CAAC"}
|