@memoryrelay/plugin-memoryrelay-ai 0.12.5 → 0.12.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.
package/index.ts CHANGED
@@ -1,10 +1,11 @@
1
1
  /**
2
2
  * OpenClaw Memory Plugin - MemoryRelay
3
- * Version: 0.12.3 (Phase 1 - Adoption Framework)
3
+ * Version: 0.12.6 (Session Context Integration)
4
4
  *
5
5
  * Long-term memory with vector search using MemoryRelay API.
6
6
  * Provides auto-recall and auto-capture via lifecycle hooks.
7
7
  * Includes: memories, entities, agents, sessions, decisions, patterns, projects.
8
+ * New in v0.12.6: OpenClaw session context integration for session tracking
8
9
  * New in v0.12.3: Smart auto-capture, daily stats, CLI commands, onboarding
9
10
  *
10
11
  * API: https://api.memoryrelay.net
@@ -1536,11 +1537,25 @@ export default async function plugin(api: OpenClawPluginApi): Promise<void> {
1536
1537
  importance?: number;
1537
1538
  tier?: string;
1538
1539
  },
1540
+ context?: {
1541
+ sessionId?: string;
1542
+ agentId?: string;
1543
+ sessionKey?: string;
1544
+ workspaceDir?: string;
1545
+ config?: any;
1546
+ },
1539
1547
  ) => {
1540
1548
  try {
1541
1549
  const { content, metadata, ...opts } = args;
1550
+
1551
+ // Inject sessionId from OpenClaw context into metadata
1552
+ const enrichedMetadata = {
1553
+ ...metadata,
1554
+ ...(context?.sessionId && { session_id: context.sessionId }),
1555
+ };
1556
+
1542
1557
  if (!opts.project && defaultProject) opts.project = defaultProject;
1543
- const memory = await client.store(content, metadata, opts);
1558
+ const memory = await client.store(content, enrichedMetadata, opts);
1544
1559
  return {
1545
1560
  content: [
1546
1561
  {
@@ -3856,7 +3871,7 @@ export default async function plugin(api: OpenClawPluginApi): Promise<void> {
3856
3871
  }
3857
3872
 
3858
3873
  api.logger.info?.(
3859
- `memory-memoryrelay: plugin v0.12.5 loaded (39 tools, autoRecall: ${cfg?.autoRecall}, autoCapture: ${autoCaptureConfig.enabled ? autoCaptureConfig.tier : 'off'}, debug: ${debugEnabled})`,
3874
+ `memory-memoryrelay: plugin v0.12.6 loaded (39 tools, autoRecall: ${cfg?.autoRecall}, autoCapture: ${autoCaptureConfig.enabled ? autoCaptureConfig.tier : 'off'}, debug: ${debugEnabled})`,
3860
3875
  );
3861
3876
 
3862
3877
  // ========================================================================
@@ -2,8 +2,8 @@
2
2
  "id": "plugin-memoryrelay-ai",
3
3
  "kind": "memory",
4
4
  "name": "MemoryRelay AI",
5
- "description": "MemoryRelay v0.12.3 - Long-term memory with sessions, decisions, patterns & projects (api.memoryrelay.net)",
6
- "version": "0.12.3",
5
+ "description": "MemoryRelay v0.12.6 - Long-term memory with sessions, decisions, patterns & projects (api.memoryrelay.net)",
6
+ "version": "0.12.6",
7
7
  "uiHints": {
8
8
  "apiKey": {
9
9
  "label": "MemoryRelay API Key",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@memoryrelay/plugin-memoryrelay-ai",
3
- "version": "0.12.5",
3
+ "version": "0.12.6",
4
4
  "description": "OpenClaw memory plugin for MemoryRelay API - sessions, decisions, patterns, projects & semantic search",
5
5
  "type": "module",
6
6
  "main": "index.ts",