@agentvault/claude-bridge 0.8.14 → 0.8.15
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/bridge.d.ts +3 -0
- package/dist/index.js +22 -11
- package/package.json +1 -1
package/dist/bridge.d.ts
CHANGED
|
@@ -3,6 +3,9 @@ export interface RoomMessage {
|
|
|
3
3
|
roomId: string;
|
|
4
4
|
senderName: string;
|
|
5
5
|
plaintext: string;
|
|
6
|
+
/** #1223 — the text the sender typed, before any attachment was folded into
|
|
7
|
+
* `plaintext`. The @ gate reads this; absent on emitters < 0.23.42. */
|
|
8
|
+
caption?: string;
|
|
6
9
|
/** True when the sender is another agent (SecureChannel derives this from the
|
|
7
10
|
* room roster). Used to decide reply expectation: a human/owner speaking in a
|
|
8
11
|
* room always expects a reply; agent-authored traffic does not (the agent may
|
package/dist/index.js
CHANGED
|
@@ -64664,11 +64664,11 @@ var init_mls_kp_pool = __esm2({
|
|
|
64664
64664
|
}
|
|
64665
64665
|
});
|
|
64666
64666
|
function ownIdentity() {
|
|
64667
|
-
const v22 = true ? "0.23.
|
|
64667
|
+
const v22 = true ? "0.23.42" : FALLBACK;
|
|
64668
64668
|
return `${PACKAGE}@${v22}`;
|
|
64669
64669
|
}
|
|
64670
64670
|
function buildSha() {
|
|
64671
|
-
const raw = true ? "
|
|
64671
|
+
const raw = true ? "d9d53a0-dirty" : "";
|
|
64672
64672
|
const cleaned = (raw ?? "").trim();
|
|
64673
64673
|
return !cleaned || cleaned === "unknown" ? null : cleaned;
|
|
64674
64674
|
}
|
|
@@ -66919,7 +66919,7 @@ ${text}`;
|
|
|
66919
66919
|
*/
|
|
66920
66920
|
sendActivitySpan(spanData) {
|
|
66921
66921
|
if (!this._ws || this._ws.readyState !== WebSocket2.OPEN) return;
|
|
66922
|
-
const pluginVersion = true ? "0.23.
|
|
66922
|
+
const pluginVersion = true ? "0.23.42" : "0.0.0-dev";
|
|
66923
66923
|
const agentName = this.config.agentName ?? "Agent";
|
|
66924
66924
|
const resource = {
|
|
66925
66925
|
"service.name": "agentvault-agent",
|
|
@@ -68857,7 +68857,7 @@ ${text}`;
|
|
|
68857
68857
|
agentVersion: this.config.agentVersion ?? "0.0.0",
|
|
68858
68858
|
// __AV_VERSION__ is injected by esbuild from package.json at build time.
|
|
68859
68859
|
// Falls back to "0.0.0-dev" in non-bundled contexts (tests).
|
|
68860
|
-
pluginVersion: true ? "0.23.
|
|
68860
|
+
pluginVersion: true ? "0.23.42" : "0.0.0-dev"
|
|
68861
68861
|
});
|
|
68862
68862
|
this._telemetryReporter.startAutoFlush(3e4);
|
|
68863
68863
|
}
|
|
@@ -69181,7 +69181,7 @@ ${text}`;
|
|
|
69181
69181
|
agentVersion: this.config.agentVersion ?? "0.0.0",
|
|
69182
69182
|
// __AV_VERSION__ is injected by esbuild from package.json at build time.
|
|
69183
69183
|
// Falls back to "0.0.0-dev" in non-bundled contexts (tests).
|
|
69184
|
-
pluginVersion: true ? "0.23.
|
|
69184
|
+
pluginVersion: true ? "0.23.42" : "0.0.0-dev"
|
|
69185
69185
|
});
|
|
69186
69186
|
this._telemetryReporter.startAutoFlush(3e4);
|
|
69187
69187
|
}
|
|
@@ -69944,7 +69944,13 @@ ${messageText}`;
|
|
|
69944
69944
|
messageType: msgData.message_type ?? "text",
|
|
69945
69945
|
priority: msgData.priority ?? "normal",
|
|
69946
69946
|
envelopeVersion: msgData.envelope_version ?? "1.0.0",
|
|
69947
|
-
roomId
|
|
69947
|
+
roomId,
|
|
69948
|
+
// #1223 — the pre-fold text. This DR `message` path also sets `roomId`
|
|
69949
|
+
// and folds an attachment into `emitText`, so without this a room
|
|
69950
|
+
// message that reaches the gate here would fall back to the folded
|
|
69951
|
+
// text (the same bug the MLS room path fixes). `messageText` is the
|
|
69952
|
+
// envelope text before the fold; `emitText` is the folded copy.
|
|
69953
|
+
caption: messageText
|
|
69948
69954
|
};
|
|
69949
69955
|
this.emit("message", emitText, metadata);
|
|
69950
69956
|
Promise.resolve(this.config.onMessage?.(emitText, metadata)).catch((err) => {
|
|
@@ -70623,6 +70629,7 @@ ${baseText}`;
|
|
|
70623
70629
|
await this._refreshRoomRoster(resolvedRoomId);
|
|
70624
70630
|
}
|
|
70625
70631
|
}
|
|
70632
|
+
const caption = messageText;
|
|
70626
70633
|
const addressed = parseMentions(messageText).length > 0;
|
|
70627
70634
|
if (roomAttachment && !addressed) {
|
|
70628
70635
|
this._deferRoomAttachment(resolvedRoomId, roomAttachment);
|
|
@@ -70649,7 +70656,8 @@ ${baseText}`;
|
|
|
70649
70656
|
senderDeviceId,
|
|
70650
70657
|
senderIsAgent,
|
|
70651
70658
|
senderName: senderMember?.displayName || "unknown",
|
|
70652
|
-
roomName: this._persisted?.rooms?.[resolvedRoomId]?.name
|
|
70659
|
+
roomName: this._persisted?.rooms?.[resolvedRoomId]?.name,
|
|
70660
|
+
caption
|
|
70653
70661
|
};
|
|
70654
70662
|
const senderLabel = senderMember?.displayName || "someone";
|
|
70655
70663
|
this._appendHistory("owner", messageText, `room:${resolvedRoomId}`);
|
|
@@ -70658,6 +70666,9 @@ ${baseText}`;
|
|
|
70658
70666
|
senderDeviceId,
|
|
70659
70667
|
senderName: senderLabel,
|
|
70660
70668
|
plaintext: messageText,
|
|
70669
|
+
// #1223 — what the sender typed, before the attachment fold. The
|
|
70670
|
+
// bridges gate on this (falling back to `plaintext` when absent).
|
|
70671
|
+
caption,
|
|
70661
70672
|
messageType,
|
|
70662
70673
|
timestamp: data.created_at ?? (/* @__PURE__ */ new Date()).toISOString(),
|
|
70663
70674
|
// Native bridge (claude-room-bridge) consumes this to decide reply
|
|
@@ -100154,7 +100165,7 @@ var init_index = __esm2({
|
|
|
100154
100165
|
await init_skill_telemetry();
|
|
100155
100166
|
await init_policy_enforcer();
|
|
100156
100167
|
init_room_protocol();
|
|
100157
|
-
VERSION = true ? "0.23.
|
|
100168
|
+
VERSION = true ? "0.23.42" : "0.0.0-dev";
|
|
100158
100169
|
}
|
|
100159
100170
|
});
|
|
100160
100171
|
await init_index();
|
|
@@ -136346,7 +136357,7 @@ function _makeOwesReply(agentName, channel, log) {
|
|
|
136346
136357
|
);
|
|
136347
136358
|
}
|
|
136348
136359
|
return owesRoomReply(
|
|
136349
|
-
e7.plaintext,
|
|
136360
|
+
e7.caption ?? e7.plaintext,
|
|
136350
136361
|
own,
|
|
136351
136362
|
own,
|
|
136352
136363
|
e7.senderIsAgent,
|
|
@@ -136570,7 +136581,7 @@ async function main() {
|
|
|
136570
136581
|
"[bridge] warning: passing the invite token on the command line is visible to other local users via 'ps'. Prefer: AV_INVITE_TOKEN=\u2026 npx @agentvault/claude-bridge"
|
|
136571
136582
|
);
|
|
136572
136583
|
}
|
|
136573
|
-
logLine(`[bridge] version: ${true ? "0.8.
|
|
136584
|
+
logLine(`[bridge] version: ${true ? "0.8.15" : "dev"}`);
|
|
136574
136585
|
logLine(`[bridge] data dir: ${cfg.dataDir} (${cfg.dataDirSource})`);
|
|
136575
136586
|
logLine(`[bridge] workspace: ${cfg.workspaceDir} \xB7 permissions: ${cfg.permissionMode} \xB7 enclave dir fenced`);
|
|
136576
136587
|
if (cfg.armRoom) {
|
|
@@ -136602,7 +136613,7 @@ async function main() {
|
|
|
136602
136613
|
// its default would render "@agentvault/agentvault@0.7.x" — the wrong
|
|
136603
136614
|
// package name attached to the bridge's version number, which is worse
|
|
136604
136615
|
// than either alone.
|
|
136605
|
-
clientVersion: `@agentvault/claude-bridge@${true ? "0.8.
|
|
136616
|
+
clientVersion: `@agentvault/claude-bridge@${true ? "0.8.15" : "dev"}`
|
|
136606
136617
|
});
|
|
136607
136618
|
const agentSystemPrompt = cfg.systemPrompt ?? `You are ${cfg.agentName}, an AI agent on AgentVault. You talk with your owner in 1:1 direct messages and collaborate with other agents in shared rooms. That is your identity \u2014 introduce yourself by that name and do not claim to be any other agent. To speak, call the say tool. In a 1:1 with your owner, reply to what they say. In a room you see every message \u2014 call say only when you have something worth adding, and otherwise stay silent. Keep messages concise.`;
|
|
136608
136619
|
const deviceJwt = () => {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agentvault/claude-bridge",
|
|
3
|
-
"version": "0.8.
|
|
3
|
+
"version": "0.8.15",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "AgentVault Claude Bridge — daemon for bridging a Claude agent into secure E2E-encrypted AgentVault 1:1 direct messages and rooms.",
|
|
6
6
|
"main": "dist/index.js",
|