open-agents-ai 0.186.19 → 0.186.21
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 +39 -1
- package/package.json +8 -8
package/dist/index.js
CHANGED
|
@@ -5343,12 +5343,50 @@ var init_nexus = __esm({
|
|
|
5343
5343
|
* Usage: node nexus-daemon.mjs <nexus-dir> <agent-name> [agent-type]
|
|
5344
5344
|
*/
|
|
5345
5345
|
|
|
5346
|
-
import { NexusClient
|
|
5346
|
+
import { NexusClient } from 'open-agents-nexus';
|
|
5347
5347
|
import { readFileSync, writeFileSync, existsSync, mkdirSync, unlinkSync, readdirSync, appendFileSync, watch as fsWatch } from 'node:fs';
|
|
5348
5348
|
import { join } from 'node:path';
|
|
5349
5349
|
import { homedir, hostname } from 'node:os';
|
|
5350
5350
|
import { createHash, createHmac } from 'node:crypto';
|
|
5351
5351
|
|
|
5352
|
+
// NKN utilities \u2014 imported dynamically to avoid crash on older open-agents-nexus versions.
|
|
5353
|
+
// Falls back to inline implementations if the package doesn't export them yet.
|
|
5354
|
+
var buildNknEnvelope, parseNknEnvelope, deriveNknSeed;
|
|
5355
|
+
try {
|
|
5356
|
+
var _nknMod = await import('open-agents-nexus');
|
|
5357
|
+
buildNknEnvelope = _nknMod.buildNknEnvelope;
|
|
5358
|
+
parseNknEnvelope = _nknMod.parseNknEnvelope;
|
|
5359
|
+
deriveNknSeed = _nknMod.deriveNknSeed;
|
|
5360
|
+
} catch {}
|
|
5361
|
+
if (!deriveNknSeed) {
|
|
5362
|
+
deriveNknSeed = function(keyData) { return createHash('sha256').update(keyData).update('nkn-seed-v1').digest('hex'); };
|
|
5363
|
+
}
|
|
5364
|
+
if (!buildNknEnvelope) {
|
|
5365
|
+
buildNknEnvelope = function(senderAddr, receiverAddr, agentName, content, libp2pPeerId) {
|
|
5366
|
+
var ts = Date.now();
|
|
5367
|
+
var secret = createHash('sha256').update(senderAddr).update(receiverAddr).update('oa-nkn-v1').digest('hex');
|
|
5368
|
+
var hmac = createHmac('sha256', secret).update(agentName + content + String(ts)).digest('hex').slice(0, 16);
|
|
5369
|
+
return JSON.stringify({ _agentName: agentName, content: content, timestamp: ts, libp2pPeerId: libp2pPeerId || null, _hmac: hmac });
|
|
5370
|
+
};
|
|
5371
|
+
}
|
|
5372
|
+
if (!parseNknEnvelope) {
|
|
5373
|
+
parseNknEnvelope = function(senderAddr, receiverAddr, raw) {
|
|
5374
|
+
var entry = { sender: senderAddr, raw: raw, receivedAt: Date.now(), verified: false };
|
|
5375
|
+
try {
|
|
5376
|
+
var parsed = JSON.parse(raw);
|
|
5377
|
+
if (parsed._hmac && parsed._agentName && parsed.content) {
|
|
5378
|
+
var secret = createHash('sha256').update(senderAddr).update(receiverAddr).update('oa-nkn-v1').digest('hex');
|
|
5379
|
+
var expected = createHmac('sha256', secret).update(parsed._agentName + parsed.content + String(parsed.timestamp || 0)).digest('hex').slice(0, 16);
|
|
5380
|
+
entry.verified = (parsed._hmac === expected);
|
|
5381
|
+
entry.agentName = parsed._agentName;
|
|
5382
|
+
entry.content = parsed.content;
|
|
5383
|
+
entry.timestamp = parsed.timestamp;
|
|
5384
|
+
}
|
|
5385
|
+
} catch {}
|
|
5386
|
+
return entry;
|
|
5387
|
+
};
|
|
5388
|
+
}
|
|
5389
|
+
|
|
5352
5390
|
const nexusDir = process.argv[2];
|
|
5353
5391
|
const agentName = process.argv[3] || ('oa-node-' + process.pid);
|
|
5354
5392
|
const agentType = process.argv[4] || 'general';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "open-agents-ai",
|
|
3
|
-
"version": "0.186.
|
|
3
|
+
"version": "0.186.21",
|
|
4
4
|
"description": "AI coding agent powered by open-source models (Ollama/vLLM) — interactive TUI with agentic tool-calling loop",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -76,19 +76,19 @@
|
|
|
76
76
|
"node": ">=22.0.0"
|
|
77
77
|
},
|
|
78
78
|
"dependencies": {
|
|
79
|
-
"aiwg": "^2026.3.
|
|
79
|
+
"aiwg": "^2026.3.3",
|
|
80
80
|
"glob": "^11.0.0",
|
|
81
81
|
"ignore": "^6.0.2",
|
|
82
82
|
"nats.ws": "^1.30.3",
|
|
83
|
-
"open-agents-nexus": "^1.17.
|
|
84
|
-
"ws": "^8.
|
|
83
|
+
"open-agents-nexus": "^1.17.3",
|
|
84
|
+
"ws": "^8.20.0",
|
|
85
85
|
"zod": "^3.24.1"
|
|
86
86
|
},
|
|
87
87
|
"optionalDependencies": {
|
|
88
|
-
"better-sqlite3": "^
|
|
88
|
+
"better-sqlite3": "^12.8.0",
|
|
89
89
|
"moondream": "^0.2.0",
|
|
90
|
-
"neovim": "^5.
|
|
91
|
-
"node-pty": "^1.
|
|
92
|
-
"viem": "^2.47.
|
|
90
|
+
"neovim": "^5.4.0",
|
|
91
|
+
"node-pty": "^1.1.0",
|
|
92
|
+
"viem": "^2.47.6"
|
|
93
93
|
}
|
|
94
94
|
}
|