agentbnb 8.4.1 → 8.4.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.
- package/dist/{chunk-Z5726VPY.js → chunk-EKLVNIIY.js} +1 -1
- package/dist/{chunk-6XCN62YU.js → chunk-IMLFBU3H.js} +5 -3
- package/dist/{chunk-RVBW2QXU.js → chunk-J46N2TCC.js} +5 -3
- package/dist/{chunk-XGOA5J2K.js → chunk-RJNKX347.js} +100 -3
- package/dist/{chunk-UF6R2RVN.js → chunk-SME5LJTE.js} +1 -1
- package/dist/cli/index.js +12 -12
- package/dist/{conduct-FZPUMPCI.js → conduct-2RD45QKB.js} +3 -3
- package/dist/{conduct-J2NXU6RM.js → conduct-TE4YAXKR.js} +3 -3
- package/dist/{conductor-mode-OPGQJFLA.js → conductor-mode-PXTMYGK5.js} +1 -1
- package/dist/{conductor-mode-HNNMWZIH.js → conductor-mode-TLIQMU4A.js} +2 -2
- package/dist/index.js +5 -3
- package/dist/{openclaw-setup-KA72IIEW.js → openclaw-setup-LVSGMXDF.js} +88 -14
- package/dist/{openclaw-skills-CT673RBL.js → openclaw-skills-6ZWQJ5V6.js} +130 -95
- package/dist/{request-IM3ZLAOA.js → request-XWEOIVB3.js} +1 -1
- package/dist/scanner-GP4AOCW6.js +16 -0
- package/dist/{server-MH7FTZFN.js → server-QG3FKU5Q.js} +7 -6
- package/dist/{service-coordinator-R5LZVM6A.js → service-coordinator-2HDVHDFD.js} +1 -1
- package/dist/skills/agentbnb/bootstrap.js +6 -5
- package/package.json +23 -21
- package/skills/agentbnb/install.sh +0 -0
- package/dist/scanner-F5VNV5FP.js +0 -8
- package/skills/agentbnb/bootstrap.test.ts +0 -323
- package/skills/agentbnb/openclaw-tools.test.ts +0 -328
|
@@ -37,12 +37,19 @@ function writeSkillsYaml(configDir, skills) {
|
|
|
37
37
|
function rpad(s, width) {
|
|
38
38
|
return String(s).padEnd(width);
|
|
39
39
|
}
|
|
40
|
+
function deriveAgentName(configDir) {
|
|
41
|
+
const parts = configDir.split("/");
|
|
42
|
+
const agentbnbIdx = parts.lastIndexOf(".agentbnb");
|
|
43
|
+
if (agentbnbIdx > 0) return parts[agentbnbIdx - 1] ?? "";
|
|
44
|
+
return "";
|
|
45
|
+
}
|
|
40
46
|
async function skillsList(opts) {
|
|
41
47
|
if (opts.agentDir) process.env["AGENTBNB_DIR"] = opts.agentDir;
|
|
42
48
|
const configDir = getConfigDir();
|
|
43
49
|
const skills = readSkillsYaml(configDir);
|
|
44
50
|
if (skills.length === 0) {
|
|
45
51
|
console.log("No skills configured. Run `agentbnb openclaw setup` to share skills.");
|
|
52
|
+
await showAvailableSkills(configDir, /* @__PURE__ */ new Set());
|
|
46
53
|
return;
|
|
47
54
|
}
|
|
48
55
|
const hireMap = {};
|
|
@@ -91,6 +98,60 @@ ${rpad(headers[0], 24)} ${rpad(headers[1], 8)} ${rpad(headers[2], 7)} ${rpad(hea
|
|
|
91
98
|
);
|
|
92
99
|
}
|
|
93
100
|
console.log("");
|
|
101
|
+
const sharedIds = new Set(skills.map((s) => s.id));
|
|
102
|
+
await showAvailableSkills(configDir, sharedIds);
|
|
103
|
+
}
|
|
104
|
+
async function showAvailableSkills(configDir, sharedIds) {
|
|
105
|
+
try {
|
|
106
|
+
const { scanCapabilities, scanWorkspaceSkills, findSoulMd } = await import("./scanner-GP4AOCW6.js");
|
|
107
|
+
const agentName = deriveAgentName(configDir);
|
|
108
|
+
if (!agentName) return;
|
|
109
|
+
const { homedir } = await import("os");
|
|
110
|
+
const { join: pathJoin } = await import("path");
|
|
111
|
+
const { getOpenClawWorkspaceDir } = await import("./scanner-GP4AOCW6.js");
|
|
112
|
+
const workspaceDir = getOpenClawWorkspaceDir();
|
|
113
|
+
const brainsDir = pathJoin(workspaceDir, "brains");
|
|
114
|
+
const brainDir = pathJoin(brainsDir, agentName);
|
|
115
|
+
const agentsDir = pathJoin(homedir(), ".openclaw", "agents");
|
|
116
|
+
const agentDir = pathJoin(agentsDir, agentName);
|
|
117
|
+
let effectiveBrainDir = "";
|
|
118
|
+
if (existsSync(brainDir)) {
|
|
119
|
+
effectiveBrainDir = brainDir;
|
|
120
|
+
} else {
|
|
121
|
+
const soulPath = findSoulMd(agentName);
|
|
122
|
+
if (soulPath) {
|
|
123
|
+
const { inferBrainDir } = await import("./scanner-GP4AOCW6.js");
|
|
124
|
+
effectiveBrainDir = inferBrainDir(soulPath, agentDir) || agentDir;
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
const agentCaps = effectiveBrainDir ? scanCapabilities(effectiveBrainDir) : [];
|
|
128
|
+
const workspaceCaps = scanWorkspaceSkills();
|
|
129
|
+
const seen = new Set(sharedIds);
|
|
130
|
+
const available = [];
|
|
131
|
+
for (const cap of agentCaps) {
|
|
132
|
+
if (!seen.has(cap.name)) {
|
|
133
|
+
seen.add(cap.name);
|
|
134
|
+
available.push({ name: cap.name, description: cap.description, source: "agent" });
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
for (const cap of workspaceCaps) {
|
|
138
|
+
if (!seen.has(cap.name)) {
|
|
139
|
+
seen.add(cap.name);
|
|
140
|
+
available.push({ name: cap.name, description: cap.description, source: "workspace" });
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
if (available.length === 0) return;
|
|
144
|
+
console.log("Available to share (not yet on AgentBnB):");
|
|
145
|
+
for (const cap of available) {
|
|
146
|
+
const tag = cap.source === "workspace" ? " [workspace]" : "";
|
|
147
|
+
const desc = cap.description.slice(0, 50);
|
|
148
|
+
console.log(` \u2022 ${cap.name}${tag} \u2014 ${desc}`);
|
|
149
|
+
}
|
|
150
|
+
console.log(`
|
|
151
|
+
Run 'agentbnb openclaw skills add' to share one.`);
|
|
152
|
+
console.log("");
|
|
153
|
+
} catch {
|
|
154
|
+
}
|
|
94
155
|
}
|
|
95
156
|
async function skillsAdd(opts) {
|
|
96
157
|
const configDir = getConfigDir();
|
|
@@ -124,48 +185,66 @@ async function skillsAdd(opts) {
|
|
|
124
185
|
};
|
|
125
186
|
if (newSkill.command === void 0) delete newSkill["command"];
|
|
126
187
|
} else {
|
|
127
|
-
const { scanCapabilities } = await import("./scanner-
|
|
128
|
-
const
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
);
|
|
133
|
-
const
|
|
134
|
-
const
|
|
135
|
-
const
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
188
|
+
const { scanCapabilities, scanWorkspaceSkills, findSoulMd, inferBrainDir, getOpenClawWorkspaceDir } = await import("./scanner-GP4AOCW6.js");
|
|
189
|
+
const { homedir } = await import("os");
|
|
190
|
+
const { join: pathJoin } = await import("path");
|
|
191
|
+
const agentName = deriveAgentName(configDir);
|
|
192
|
+
const workspaceDir = getOpenClawWorkspaceDir();
|
|
193
|
+
const brainsDir = pathJoin(workspaceDir, "brains");
|
|
194
|
+
const agentsDir = pathJoin(homedir(), ".openclaw", "agents");
|
|
195
|
+
const agentDir = pathJoin(agentsDir, agentName);
|
|
196
|
+
const brainDir = pathJoin(brainsDir, agentName);
|
|
197
|
+
let effectiveBrainDir = "";
|
|
198
|
+
if (existsSync(brainDir)) {
|
|
199
|
+
effectiveBrainDir = brainDir;
|
|
200
|
+
} else if (agentName) {
|
|
201
|
+
const soulPath = findSoulMd(agentName);
|
|
202
|
+
if (soulPath) {
|
|
203
|
+
effectiveBrainDir = inferBrainDir(soulPath, agentDir) || agentDir;
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
const agentCaps = effectiveBrainDir ? scanCapabilities(effectiveBrainDir) : [];
|
|
207
|
+
const workspaceCaps = scanWorkspaceSkills();
|
|
208
|
+
const unsharedAgent = agentCaps.filter((c) => !existingIds.has(c.name));
|
|
209
|
+
const unsharedWorkspace = workspaceCaps.filter(
|
|
210
|
+
(c) => !existingIds.has(c.name) && !unsharedAgent.some((a) => a.name === c.name)
|
|
140
211
|
);
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
212
|
+
if (unsharedAgent.length === 0 && unsharedWorkspace.length === 0) {
|
|
213
|
+
if (agentCaps.length === 0 && workspaceCaps.length === 0) {
|
|
214
|
+
console.log("No SOUL.md or skills found. Use --manual to add a skill directly.");
|
|
215
|
+
console.log(` Example: agentbnb openclaw skills add --manual --name my-skill --type command --price 3`);
|
|
216
|
+
} else {
|
|
217
|
+
console.log("All detected capabilities are already shared!");
|
|
218
|
+
console.log("Use --manual to add a new skill: agentbnb openclaw skills add --manual --name <id> --type command --price <n>");
|
|
219
|
+
}
|
|
149
220
|
return;
|
|
150
221
|
}
|
|
151
|
-
const
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
222
|
+
const allUnshared = [
|
|
223
|
+
...unsharedAgent.map((c) => ({ cap: c, group: effectiveBrainDir ? `From ${effectiveBrainDir}:` : "From agent:" })),
|
|
224
|
+
...unsharedWorkspace.map((c) => ({ cap: c, group: `From workspace/skills/:` }))
|
|
225
|
+
];
|
|
226
|
+
let lastGroup = "";
|
|
227
|
+
allUnshared.forEach(({ cap, group }, i) => {
|
|
228
|
+
if (group !== lastGroup) {
|
|
229
|
+
console.log(`
|
|
230
|
+
${group}`);
|
|
231
|
+
lastGroup = group;
|
|
232
|
+
}
|
|
233
|
+
console.log(` ${i + 1}. ${cap.name} \u2014 ${cap.description.slice(0, 50)} (suggested: ${cap.suggestedPrice} cr)`);
|
|
234
|
+
});
|
|
235
|
+
if (existingSkills.length > 0) {
|
|
236
|
+
console.log("\nAlready shared on AgentBnB:");
|
|
237
|
+
for (const s of existingSkills) {
|
|
238
|
+
console.log(` \u2705 ${s.id} (${s.pricing?.credits_per_call ?? "?"} cr)`);
|
|
239
|
+
}
|
|
157
240
|
}
|
|
158
|
-
console.log("\nUnshared capabilities:");
|
|
159
|
-
unshared.forEach(
|
|
160
|
-
(c, i) => console.log(` ${i + 1}. ${c.name} \u2014 ${c.description.slice(0, 50)} (suggested: ${c.suggestedPrice} cr)`)
|
|
161
|
-
);
|
|
162
241
|
const selInput = await prompt("\nSelect capability to add (default: 1): ");
|
|
163
242
|
const selIdx = selInput === "" ? 0 : parseInt(selInput, 10) - 1;
|
|
164
|
-
if (isNaN(selIdx) || selIdx < 0 || selIdx >=
|
|
243
|
+
if (isNaN(selIdx) || selIdx < 0 || selIdx >= allUnshared.length) {
|
|
165
244
|
console.error("Invalid selection.");
|
|
166
245
|
process.exit(1);
|
|
167
246
|
}
|
|
168
|
-
const selected =
|
|
247
|
+
const selected = allUnshared[selIdx].cap;
|
|
169
248
|
const typeInput = await prompt(`Skill type [command/openclaw] (default: command): `);
|
|
170
249
|
const skillType = typeInput === "" ? "command" : typeInput;
|
|
171
250
|
const priceInput = await prompt(`Price in credits (default: ${selected.suggestedPrice}): `);
|
|
@@ -189,28 +268,7 @@ async function skillsAdd(opts) {
|
|
|
189
268
|
writeSkillsYaml(configDir, updatedSkills);
|
|
190
269
|
console.log(`
|
|
191
270
|
\u2705 Added skill "${newSkill.id}" (${newSkill.pricing?.credits_per_call} cr)`);
|
|
192
|
-
|
|
193
|
-
const { updateSoulMdSkillsTable } = await import("./writer-4QJ3U3WE.js");
|
|
194
|
-
const agentsDir = join(
|
|
195
|
-
process.env["HOME"] ?? process.env["USERPROFILE"] ?? "/root",
|
|
196
|
-
".openclaw",
|
|
197
|
-
"agents"
|
|
198
|
-
);
|
|
199
|
-
const configParent = configDir.replace(/\/.agentbnb$/, "");
|
|
200
|
-
const agentName = configParent.split("/").pop() ?? "";
|
|
201
|
-
const soulPath = join(agentsDir, agentName, "SOUL.md");
|
|
202
|
-
if (existsSync(soulPath)) {
|
|
203
|
-
const skillEntries = updatedSkills.map((s) => ({
|
|
204
|
-
id: s.id,
|
|
205
|
-
name: s.name,
|
|
206
|
-
description: s.description,
|
|
207
|
-
pricing: s.pricing
|
|
208
|
-
}));
|
|
209
|
-
updateSoulMdSkillsTable(soulPath, skillEntries);
|
|
210
|
-
console.log(`\u2705 Updated SOUL.md skills table`);
|
|
211
|
-
}
|
|
212
|
-
} catch {
|
|
213
|
-
}
|
|
271
|
+
await updateSoulMdIfPresent(configDir, updatedSkills);
|
|
214
272
|
}
|
|
215
273
|
async function skillsRemove(skillId) {
|
|
216
274
|
const configDir = getConfigDir();
|
|
@@ -222,28 +280,7 @@ async function skillsRemove(skillId) {
|
|
|
222
280
|
}
|
|
223
281
|
writeSkillsYaml(configDir, filtered);
|
|
224
282
|
console.log(`\u2705 Removed skill "${skillId}"`);
|
|
225
|
-
|
|
226
|
-
const { updateSoulMdSkillsTable } = await import("./writer-4QJ3U3WE.js");
|
|
227
|
-
const agentsDir = join(
|
|
228
|
-
process.env["HOME"] ?? process.env["USERPROFILE"] ?? "/root",
|
|
229
|
-
".openclaw",
|
|
230
|
-
"agents"
|
|
231
|
-
);
|
|
232
|
-
const configParent = configDir.replace(/\/.agentbnb$/, "");
|
|
233
|
-
const agentName = configParent.split("/").pop() ?? "";
|
|
234
|
-
const soulPath = join(agentsDir, agentName, "SOUL.md");
|
|
235
|
-
if (existsSync(soulPath)) {
|
|
236
|
-
const skillEntries = filtered.map((s) => ({
|
|
237
|
-
id: s.id,
|
|
238
|
-
name: s.name,
|
|
239
|
-
description: s.description,
|
|
240
|
-
pricing: s.pricing
|
|
241
|
-
}));
|
|
242
|
-
updateSoulMdSkillsTable(soulPath, skillEntries);
|
|
243
|
-
console.log(`\u2705 Updated SOUL.md skills table`);
|
|
244
|
-
}
|
|
245
|
-
} catch {
|
|
246
|
-
}
|
|
283
|
+
await updateSoulMdIfPresent(configDir, filtered);
|
|
247
284
|
}
|
|
248
285
|
async function skillsPrice(skillId, newPrice) {
|
|
249
286
|
const configDir = getConfigDir();
|
|
@@ -257,26 +294,24 @@ async function skillsPrice(skillId, newPrice) {
|
|
|
257
294
|
skill.pricing = { ...skill.pricing ?? {}, credits_per_call: newPrice };
|
|
258
295
|
writeSkillsYaml(configDir, skills);
|
|
259
296
|
console.log(`\u2705 Updated "${skillId}" price: ${oldPrice} cr \u2192 ${newPrice} cr`);
|
|
297
|
+
await updateSoulMdIfPresent(configDir, skills);
|
|
298
|
+
}
|
|
299
|
+
async function updateSoulMdIfPresent(configDir, skills) {
|
|
260
300
|
try {
|
|
261
301
|
const { updateSoulMdSkillsTable } = await import("./writer-4QJ3U3WE.js");
|
|
262
|
-
const
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
);
|
|
267
|
-
const
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
pricing: s.pricing
|
|
276
|
-
}));
|
|
277
|
-
updateSoulMdSkillsTable(soulPath, skillEntries);
|
|
278
|
-
console.log(`\u2705 Updated SOUL.md skills table`);
|
|
279
|
-
}
|
|
302
|
+
const { findSoulMd } = await import("./scanner-GP4AOCW6.js");
|
|
303
|
+
const agentName = deriveAgentName(configDir);
|
|
304
|
+
if (!agentName) return;
|
|
305
|
+
const soulPath = findSoulMd(agentName);
|
|
306
|
+
if (!soulPath) return;
|
|
307
|
+
const skillEntries = skills.map((s) => ({
|
|
308
|
+
id: s.id,
|
|
309
|
+
name: s.name,
|
|
310
|
+
description: s.description,
|
|
311
|
+
pricing: s.pricing
|
|
312
|
+
}));
|
|
313
|
+
updateSoulMdSkillsTable(soulPath, skillEntries);
|
|
314
|
+
console.log(`\u2705 Updated SOUL.md skills table`);
|
|
280
315
|
} catch {
|
|
281
316
|
}
|
|
282
317
|
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import {
|
|
2
|
+
findSoulMd,
|
|
3
|
+
getOpenClawWorkspaceDir,
|
|
4
|
+
inferBrainDir,
|
|
5
|
+
scanAgents,
|
|
6
|
+
scanCapabilities,
|
|
7
|
+
scanWorkspaceSkills
|
|
8
|
+
} from "./chunk-RJNKX347.js";
|
|
9
|
+
export {
|
|
10
|
+
findSoulMd,
|
|
11
|
+
getOpenClawWorkspaceDir,
|
|
12
|
+
inferBrainDir,
|
|
13
|
+
scanAgents,
|
|
14
|
+
scanCapabilities,
|
|
15
|
+
scanWorkspaceSkills
|
|
16
|
+
};
|
|
@@ -110,6 +110,7 @@ var statusInputSchema = {
|
|
|
110
110
|
async function handleStatus(ctx) {
|
|
111
111
|
try {
|
|
112
112
|
let balance = 0;
|
|
113
|
+
const creditKey = ctx.identity.agent_id ?? ctx.identity.owner;
|
|
113
114
|
if (ctx.config.registry) {
|
|
114
115
|
try {
|
|
115
116
|
const keys = loadKeyPair(ctx.configDir);
|
|
@@ -118,11 +119,11 @@ async function handleStatus(ctx) {
|
|
|
118
119
|
ownerPublicKey: ctx.identity.public_key,
|
|
119
120
|
privateKey: keys.privateKey
|
|
120
121
|
});
|
|
121
|
-
balance = await ledger.getBalance(
|
|
122
|
+
balance = await ledger.getBalance(creditKey);
|
|
122
123
|
} catch {
|
|
123
124
|
const creditDb = openCreditDb(ctx.config.credit_db_path);
|
|
124
125
|
try {
|
|
125
|
-
balance = getBalance(creditDb,
|
|
126
|
+
balance = getBalance(creditDb, creditKey);
|
|
126
127
|
} finally {
|
|
127
128
|
creditDb.close();
|
|
128
129
|
}
|
|
@@ -130,7 +131,7 @@ async function handleStatus(ctx) {
|
|
|
130
131
|
} else {
|
|
131
132
|
const creditDb = openCreditDb(ctx.config.credit_db_path);
|
|
132
133
|
try {
|
|
133
|
-
balance = getBalance(creditDb,
|
|
134
|
+
balance = getBalance(creditDb, creditKey);
|
|
134
135
|
} finally {
|
|
135
136
|
creditDb.close();
|
|
136
137
|
}
|
|
@@ -250,7 +251,7 @@ function registerPublishTool(server, ctx) {
|
|
|
250
251
|
}
|
|
251
252
|
|
|
252
253
|
// src/mcp/server.ts
|
|
253
|
-
var VERSION = true ? "8.4.
|
|
254
|
+
var VERSION = true ? "8.4.3" : "0.0.0-dev";
|
|
254
255
|
async function startMcpServer() {
|
|
255
256
|
const config = loadConfig();
|
|
256
257
|
if (!config) {
|
|
@@ -271,8 +272,8 @@ async function startMcpServer() {
|
|
|
271
272
|
registerDiscoverTool(server, ctx);
|
|
272
273
|
registerStatusTool(server, ctx);
|
|
273
274
|
registerPublishTool(server, ctx);
|
|
274
|
-
const { registerRequestTool } = await import("./request-
|
|
275
|
-
const { registerConductTool } = await import("./conduct-
|
|
275
|
+
const { registerRequestTool } = await import("./request-XWEOIVB3.js");
|
|
276
|
+
const { registerConductTool } = await import("./conduct-TE4YAXKR.js");
|
|
276
277
|
const { registerServeSkillTool } = await import("./serve-skill-6RKMVDMK.js");
|
|
277
278
|
registerRequestTool(server, ctx);
|
|
278
279
|
registerConductTool(server, ctx);
|
|
@@ -1042,7 +1042,7 @@ var AgentRuntime = class {
|
|
|
1042
1042
|
}
|
|
1043
1043
|
const modes = /* @__PURE__ */ new Map();
|
|
1044
1044
|
if (this.conductorEnabled) {
|
|
1045
|
-
const { ConductorMode } = await import("./conductor-mode-
|
|
1045
|
+
const { ConductorMode } = await import("./conductor-mode-TLIQMU4A.js");
|
|
1046
1046
|
const { registerConductorCard, CONDUCTOR_OWNER } = await import("./card-HYTD2BJQ.js");
|
|
1047
1047
|
const { loadPeers } = await import("./peers-F2EWUMVQ.js");
|
|
1048
1048
|
registerConductorCard(this.registryDb);
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
orchestrate,
|
|
15
15
|
requestViaTemporaryRelay,
|
|
16
16
|
resolvePendingRequest
|
|
17
|
-
} from "../../chunk-
|
|
17
|
+
} from "../../chunk-J46N2TCC.js";
|
|
18
18
|
import {
|
|
19
19
|
generateKeyPair,
|
|
20
20
|
loadKeyPair,
|
|
@@ -1373,7 +1373,7 @@ var AgentRuntime = class {
|
|
|
1373
1373
|
}
|
|
1374
1374
|
const modes = /* @__PURE__ */ new Map();
|
|
1375
1375
|
if (this.conductorEnabled) {
|
|
1376
|
-
const { ConductorMode } = await import("../../conductor-mode-
|
|
1376
|
+
const { ConductorMode } = await import("../../conductor-mode-PXTMYGK5.js");
|
|
1377
1377
|
const { registerConductorCard, CONDUCTOR_OWNER } = await import("../../card-BN643ZOY.js");
|
|
1378
1378
|
const { loadPeers: loadPeers2 } = await import("../../peers-CJ7T4RJO.js");
|
|
1379
1379
|
registerConductorCard(this.registryDb);
|
|
@@ -7770,6 +7770,7 @@ var statusInputSchema = {
|
|
|
7770
7770
|
async function handleStatus(ctx) {
|
|
7771
7771
|
try {
|
|
7772
7772
|
let balance = 0;
|
|
7773
|
+
const creditKey = ctx.identity.agent_id ?? ctx.identity.owner;
|
|
7773
7774
|
if (ctx.config.registry) {
|
|
7774
7775
|
try {
|
|
7775
7776
|
const keys = loadKeyPair(ctx.configDir);
|
|
@@ -7778,11 +7779,11 @@ async function handleStatus(ctx) {
|
|
|
7778
7779
|
ownerPublicKey: ctx.identity.public_key,
|
|
7779
7780
|
privateKey: keys.privateKey
|
|
7780
7781
|
});
|
|
7781
|
-
balance = await ledger.getBalance(
|
|
7782
|
+
balance = await ledger.getBalance(creditKey);
|
|
7782
7783
|
} catch {
|
|
7783
7784
|
const creditDb = openCreditDb(ctx.config.credit_db_path);
|
|
7784
7785
|
try {
|
|
7785
|
-
balance = getBalance(creditDb,
|
|
7786
|
+
balance = getBalance(creditDb, creditKey);
|
|
7786
7787
|
} finally {
|
|
7787
7788
|
creditDb.close();
|
|
7788
7789
|
}
|
|
@@ -7790,7 +7791,7 @@ async function handleStatus(ctx) {
|
|
|
7790
7791
|
} else {
|
|
7791
7792
|
const creditDb = openCreditDb(ctx.config.credit_db_path);
|
|
7792
7793
|
try {
|
|
7793
|
-
balance = getBalance(creditDb,
|
|
7794
|
+
balance = getBalance(creditDb, creditKey);
|
|
7794
7795
|
} finally {
|
|
7795
7796
|
creditDb.close();
|
|
7796
7797
|
}
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"workspaces": [
|
|
4
4
|
"packages/*"
|
|
5
5
|
],
|
|
6
|
-
"version": "8.4.
|
|
6
|
+
"version": "8.4.3",
|
|
7
7
|
"description": "P2P Agent Capability Sharing Protocol — Airbnb for AI agent pipelines",
|
|
8
8
|
"type": "module",
|
|
9
9
|
"main": "dist/index.js",
|
|
@@ -15,7 +15,15 @@
|
|
|
15
15
|
"dist",
|
|
16
16
|
"README.md",
|
|
17
17
|
"LICENSE",
|
|
18
|
-
"skills/agentbnb",
|
|
18
|
+
"skills/agentbnb/auto-request.ts",
|
|
19
|
+
"skills/agentbnb/auto-share.ts",
|
|
20
|
+
"skills/agentbnb/bootstrap.ts",
|
|
21
|
+
"skills/agentbnb/credit-mgr.ts",
|
|
22
|
+
"skills/agentbnb/gateway.ts",
|
|
23
|
+
"skills/agentbnb/openclaw-tools.ts",
|
|
24
|
+
"skills/agentbnb/HEARTBEAT.rules.md",
|
|
25
|
+
"skills/agentbnb/install.sh",
|
|
26
|
+
"skills/agentbnb/SKILL.md",
|
|
19
27
|
"openclaw.plugin.json"
|
|
20
28
|
],
|
|
21
29
|
"exports": {
|
|
@@ -32,18 +40,6 @@
|
|
|
32
40
|
"import": "./dist/identity/index.js"
|
|
33
41
|
}
|
|
34
42
|
},
|
|
35
|
-
"scripts": {
|
|
36
|
-
"build": "tsup",
|
|
37
|
-
"build:hub": "cd hub && pnpm install && pnpm build",
|
|
38
|
-
"build:all": "pnpm build && pnpm build:hub",
|
|
39
|
-
"dev": "tsx watch src/cli/index.ts",
|
|
40
|
-
"test": "vitest run",
|
|
41
|
-
"test:run": "vitest run",
|
|
42
|
-
"test:watch": "vitest",
|
|
43
|
-
"lint": "eslint src/",
|
|
44
|
-
"typecheck": "tsc --noEmit",
|
|
45
|
-
"prepublishOnly": "pnpm run build && pnpm run typecheck && pnpm run test:run"
|
|
46
|
-
},
|
|
47
43
|
"keywords": [
|
|
48
44
|
"ai",
|
|
49
45
|
"agent",
|
|
@@ -74,7 +70,7 @@
|
|
|
74
70
|
"@fastify/swagger": "^9.7.0",
|
|
75
71
|
"@fastify/swagger-ui": "^5.2.5",
|
|
76
72
|
"@fastify/websocket": "^11.2.0",
|
|
77
|
-
"@modelcontextprotocol/sdk": "^1.
|
|
73
|
+
"@modelcontextprotocol/sdk": "^1.29.0",
|
|
78
74
|
"better-sqlite3": "^11.6.0",
|
|
79
75
|
"bonjour-service": "^1.3.0",
|
|
80
76
|
"commander": "^12.1.0",
|
|
@@ -92,11 +88,17 @@
|
|
|
92
88
|
]
|
|
93
89
|
},
|
|
94
90
|
"engines": {
|
|
95
|
-
"node": ">=20.0.0"
|
|
91
|
+
"node": ">=20.0.0 <25.0.0"
|
|
96
92
|
},
|
|
97
|
-
"
|
|
98
|
-
"
|
|
99
|
-
|
|
100
|
-
|
|
93
|
+
"scripts": {
|
|
94
|
+
"build": "tsup",
|
|
95
|
+
"build:hub": "cd hub && pnpm install && pnpm build",
|
|
96
|
+
"build:all": "pnpm build && pnpm build:hub",
|
|
97
|
+
"dev": "tsx watch src/cli/index.ts",
|
|
98
|
+
"test": "vitest run",
|
|
99
|
+
"test:run": "vitest run",
|
|
100
|
+
"test:watch": "vitest",
|
|
101
|
+
"lint": "eslint src/",
|
|
102
|
+
"typecheck": "tsc --noEmit"
|
|
101
103
|
}
|
|
102
|
-
}
|
|
104
|
+
}
|
|
File without changes
|