@ouro.bot/cli 0.1.0-alpha.219 → 0.1.0-alpha.220
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/changelog.json +6 -0
- package/dist/repertoire/tools-session.js +18 -1
- package/package.json +1 -1
package/changelog.json
CHANGED
|
@@ -1,6 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"_note": "This changelog is maintained as part of the PR/version-bump workflow. Agent-curated, not auto-generated. Agents read this file directly via read_file to understand what changed between versions.",
|
|
3
3
|
"versions": [
|
|
4
|
+
{
|
|
5
|
+
"version": "0.1.0-alpha.220",
|
|
6
|
+
"changes": [
|
|
7
|
+
"fix: send_message BB session key resolution — agents don't know the real BB session key (e.g. 'chat_any;-;ari@mendelow.me'), so they pass the default 'session'. buildChatRefForSessionKey failed on this fake key, returning missing_target. Now auto-resolves the real BB session key from the sessions directory when the default key is used."
|
|
8
|
+
]
|
|
9
|
+
},
|
|
4
10
|
{
|
|
5
11
|
"version": "0.1.0-alpha.219",
|
|
6
12
|
"changes": [
|
|
@@ -567,10 +567,27 @@ exports.sessionToolDefinitions = [
|
|
|
567
567
|
surfaced: "nothing yet",
|
|
568
568
|
});
|
|
569
569
|
}
|
|
570
|
+
// Resolve BB session key if using default — agents don't know the real session key
|
|
571
|
+
/* v8 ignore start -- BB session key resolution: reads real filesystem @preserve */
|
|
572
|
+
let resolvedKey = key;
|
|
573
|
+
if (channel === "bluebubbles" && key === "session") {
|
|
574
|
+
try {
|
|
575
|
+
const agentRoot = (0, identity_1.getAgentRoot)();
|
|
576
|
+
const bbDir = path.join(agentRoot, "state", "sessions", friendId, "bluebubbles");
|
|
577
|
+
if (fs.existsSync(bbDir)) {
|
|
578
|
+
const files = fs.readdirSync(bbDir).filter((f) => f.endsWith(".json"));
|
|
579
|
+
if (files.length > 0) {
|
|
580
|
+
resolvedKey = files[0].replace(/\.json$/, "");
|
|
581
|
+
}
|
|
582
|
+
}
|
|
583
|
+
}
|
|
584
|
+
catch { /* continue with default key */ }
|
|
585
|
+
}
|
|
586
|
+
/* v8 ignore stop */
|
|
570
587
|
const deliveryResult = await (0, cross_chat_delivery_1.deliverCrossChatMessage)({
|
|
571
588
|
friendId,
|
|
572
589
|
channel,
|
|
573
|
-
key,
|
|
590
|
+
key: resolvedKey,
|
|
574
591
|
content,
|
|
575
592
|
intent: ctx?.currentSession && ctx.currentSession.friendId !== "self"
|
|
576
593
|
? "explicit_cross_chat"
|