neoagent 1.0.0 → 1.0.1
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "neoagent",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.1",
|
|
4
4
|
"description": "Proactive personal AI agent with no limits",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"main": "server/index.js",
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
"@anthropic-ai/sdk": "^0.39.0",
|
|
36
36
|
"@google/generative-ai": "^0.24.0",
|
|
37
37
|
"@modelcontextprotocol/sdk": "^1.12.1",
|
|
38
|
-
"
|
|
38
|
+
"baileys": "^6.7.1",
|
|
39
39
|
"bcrypt": "^5.1.1",
|
|
40
40
|
"better-sqlite3": "^11.8.1",
|
|
41
41
|
"connect-sqlite3": "^0.9.15",
|
|
@@ -58,4 +58,4 @@
|
|
|
58
58
|
"telnyx": "^5.51.0",
|
|
59
59
|
"uuid": "^11.1.0"
|
|
60
60
|
}
|
|
61
|
-
}
|
|
61
|
+
}
|
|
@@ -26,14 +26,14 @@ class WhatsAppPlatform extends BasePlatform {
|
|
|
26
26
|
makeCacheableSignalKeyStore,
|
|
27
27
|
fetchLatestBaileysVersion,
|
|
28
28
|
Browsers
|
|
29
|
-
} = require('
|
|
29
|
+
} = require('baileys');
|
|
30
30
|
const pino = require('pino');
|
|
31
31
|
|
|
32
32
|
let logger;
|
|
33
33
|
try {
|
|
34
34
|
logger = pino({ level: 'silent' });
|
|
35
35
|
} catch {
|
|
36
|
-
logger = { level: 'silent', info: () => {}, error: () => {}, warn: () => {}, debug: () => {}, trace: () => {}, child: () => logger };
|
|
36
|
+
logger = { level: 'silent', info: () => { }, error: () => { }, warn: () => { }, debug: () => { }, trace: () => { }, child: () => logger };
|
|
37
37
|
}
|
|
38
38
|
|
|
39
39
|
const { version, isLatest } = await fetchLatestBaileysVersion();
|
|
@@ -135,7 +135,7 @@ class WhatsAppPlatform extends BasePlatform {
|
|
|
135
135
|
let localMediaPath = null;
|
|
136
136
|
if (mediaType && mediaType !== 'sticker') {
|
|
137
137
|
try {
|
|
138
|
-
const { downloadMediaMessage } = require('
|
|
138
|
+
const { downloadMediaMessage } = require('baileys');
|
|
139
139
|
const MEDIA_DIR = path.join(__dirname, '..', '..', '..', 'data', 'media');
|
|
140
140
|
if (!fs.existsSync(MEDIA_DIR)) fs.mkdirSync(MEDIA_DIR, { recursive: true });
|
|
141
141
|
const buffer = await downloadMediaMessage(msg, 'buffer', {}, {
|
|
@@ -247,14 +247,14 @@ class WhatsAppPlatform extends BasePlatform {
|
|
|
247
247
|
let jid = chatId;
|
|
248
248
|
if (!jid.includes('@')) jid = jid + '@s.whatsapp.net';
|
|
249
249
|
// readMessages expects full message keys; we do a best-effort read
|
|
250
|
-
await this.sock.sendReadReceipt(jid, null, [messageId]).catch(() => {});
|
|
250
|
+
await this.sock.sendReadReceipt(jid, null, [messageId]).catch(() => { });
|
|
251
251
|
}
|
|
252
252
|
|
|
253
253
|
async sendTyping(chatId, isTyping) {
|
|
254
254
|
if (!this.sock || this.status !== 'connected') return;
|
|
255
255
|
let jid = chatId;
|
|
256
256
|
if (!jid.includes('@')) jid = jid + '@s.whatsapp.net';
|
|
257
|
-
await this.sock.sendPresenceUpdate(isTyping ? 'composing' : 'paused', jid).catch(() => {});
|
|
257
|
+
await this.sock.sendPresenceUpdate(isTyping ? 'composing' : 'paused', jid).catch(() => { });
|
|
258
258
|
}
|
|
259
259
|
|
|
260
260
|
async getContacts() {
|