@sym-bot/mesh-channel 0.1.5 → 0.1.6

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.
Files changed (3) hide show
  1. package/CHANGELOG.md +26 -0
  2. package/package.json +2 -2
  3. package/server.js +15 -12
package/CHANGELOG.md CHANGED
@@ -1,5 +1,31 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.1.6
4
+
5
+ ### Fixed
6
+
7
+ - `sym_send` no longer double-delivers. Previously called both
8
+ `node.send()` (broadcast as `event_type=message`) AND `node.remember()`
9
+ (persist as CMB which gets gossiped as `event_type=cmb`), causing
10
+ the same payload to arrive twice on receivers and double the
11
+ context-window cost. Now broadcasts the message frame only. Hosts
12
+ that want CMB persistence should call `sym_observe` separately
13
+ with proper CAT7 fields.
14
+ - `sym_send` now reports the actual delivered count, not
15
+ `peers().length`. Requires `@sym-bot/sym >= 0.3.70` where `send()`
16
+ returns the count of peer transports that successfully accepted
17
+ the broadcast. The two can disagree when peers are tracked but
18
+ have broken transports — the delivered count is the truth about
19
+ what was actually sent.
20
+
21
+ ### Changed
22
+
23
+ - Bumped `@sym-bot/sym` dep `^0.3.69` → `^0.3.70`. 0.3.70 ships the
24
+ identity lockfile that prevents two SymNode processes from
25
+ claiming the same nodeId on a host (the cliHostMode-vs-MCP
26
+ collision that broke real-time push on Windows during the
27
+ 2026-04-09 round-trip test).
28
+
3
29
  ## 0.1.5
4
30
 
5
31
  ### Changed
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sym-bot/mesh-channel",
3
- "version": "0.1.5",
3
+ "version": "0.1.6",
4
4
  "description": "MCP server — Claude Code as a peer node on the SYM mesh",
5
5
  "main": "server.js",
6
6
  "bin": {
@@ -13,7 +13,7 @@
13
13
  "LICENSE"
14
14
  ],
15
15
  "dependencies": {
16
- "@sym-bot/sym": "^0.3.69",
16
+ "@sym-bot/sym": "^0.3.70",
17
17
  "@modelcontextprotocol/sdk": "^1.12.1"
18
18
  },
19
19
  "engines": {
package/server.js CHANGED
@@ -145,19 +145,22 @@ mcp.setRequestHandler(CallToolRequestSchema, async (request) => {
145
145
 
146
146
  switch (name) {
147
147
  case 'sym_send': {
148
+ // Direct inter-node message — broadcast as type:'message' frame only.
149
+ // Do NOT also persist as a CMB via node.remember(): that caused
150
+ // double-delivery on receivers, who saw the same payload arrive once
151
+ // as event_type='message' (from this broadcast) and again as
152
+ // event_type='cmb' (from CMB gossip replication). One tool, one job:
153
+ // sym_send is for ephemeral inter-node messages; sym_observe is for
154
+ // structured CAT7 CMBs. Hosts that want both should call both.
155
+ //
156
+ // Report the actual delivered count (the number of peer transports
157
+ // that successfully accepted the broadcast), not peers().length.
158
+ // The two can disagree when peers are in _peers but their transports
159
+ // are broken — counting peers().length would lie about delivery.
160
+ // Requires @sym-bot/sym >= 0.3.70 where send() returns the count.
148
161
  const msg = args.message;
149
- node.send(msg);
150
- node.remember({
151
- focus: msg,
152
- issue: 'none',
153
- intent: 'inter-node message',
154
- motivation: 'mesh communication',
155
- commitment: msg.slice(0, 120),
156
- perspective: `${NODE_NAME}, direct message`,
157
- mood: { text: 'neutral', valence: 0, arousal: 0 },
158
- });
159
- const peers = node.peers();
160
- return { content: [{ type: 'text', text: `Message sent to ${peers.length} peer(s).` }] };
162
+ const delivered = node.send(msg);
163
+ return { content: [{ type: 'text', text: `Message delivered to ${delivered} peer(s).` }] };
161
164
  }
162
165
 
163
166
  case 'sym_observe': {