@contextableai/openclaw-memory-rebac 0.3.6 → 0.3.7

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/cli.js CHANGED
@@ -347,9 +347,9 @@ export function registerCommands(cmd, ctx) {
347
347
  .map((b) => b.text)
348
348
  .join("\n");
349
349
  }
350
- if (text && text.length >= 5 &&
351
- !text.includes("<relevant-memories>") &&
352
- !text.includes("<memory-tools>")) {
350
+ text = text.replace(/<relevant-memories>[\s\S]*?<\/relevant-memories>/g, "").trim();
351
+ text = text.replace(/<memory-tools>[\s\S]*?<\/memory-tools>/g, "").trim();
352
+ if (text && text.length >= 5) {
353
353
  const roleLabel = role === "user" ? "User" : "Assistant";
354
354
  conversationLines.push(`${roleLabel}: ${text}`);
355
355
  }
package/dist/index.js CHANGED
@@ -566,10 +566,11 @@ const rebacMemoryPlugin = {
566
566
  }
567
567
  text = textParts.join("\n");
568
568
  }
569
+ // Strip injected memory/tool blocks — keep the user's actual content
570
+ text = text.replace(/<relevant-memories>[\s\S]*?<\/relevant-memories>/g, "").trim();
571
+ text = text.replace(/<memory-tools>[\s\S]*?<\/memory-tools>/g, "").trim();
569
572
  if (!text || text.length < 5)
570
573
  continue;
571
- if (text.includes("<relevant-memories>"))
572
- continue;
573
574
  const roleLabel = role === "user" ? "User" : "Assistant";
574
575
  conversationLines.unshift(`${roleLabel}: ${text}`);
575
576
  messageCount++;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@contextableai/openclaw-memory-rebac",
3
- "version": "0.3.6",
3
+ "version": "0.3.7",
4
4
  "description": "OpenClaw two-layer memory plugin: SpiceDB ReBAC authorization + Graphiti knowledge graph",
5
5
  "type": "module",
6
6
  "license": "MIT",