Conversation
Redesigned tool set around Nowledge Mem's v0.6 architecture. Tools: - Add nowledge_mem_save: structured capture with 8 unit_types - Add nowledge_mem_context: Working Memory daily briefing - Add nowledge_mem_connections: graph exploration with EVOLVES chains, entity discovery, cross-topic synthesis, and SOURCED_FROM provenance for Library documents/URLs - Add nowledge_mem_forget: delete by ID or query with confirmation - Remove nowledge_mem_search (redundant with memory_search) - Remove nowledge_mem_store (replaced by nowledge_mem_save) - Remove nowledge_mem_working_memory (replaced by nowledge_mem_context) Tool descriptions sharpened based on live testing: - connections: explicit cross-topic synthesis and provenance use cases - save: proactive signal — don't wait to be asked - memory_search: temporal query guidance Hooks: - recall: updated tool guidance to map user intents to right tools - capture: multi-layer quality gate (questions, injection, triggers) - after_compaction hook added for thread continuity Slash commands: add /forget Co-authored-by: Cursor <cursoragent@cursor.com>
- Add nowledge_mem_timeline: wraps /agent/feed/events with day-grouped output for temporal questions (last_n_days, event_type, tier1_only) - Update memory_search description to reflect multi-signal scoring: embedding + BM25 + labels + graph/community + recency decay - Update recall hook: route temporal queries to timeline, topic queries to memory_search/connections - Update nowledge_mem_context: clarify WM is read-only from plugin side - Document WM full-overwrite API and backend gaps in CLAUDE.md Co-authored-by: Cursor <cursoragent@cursor.com>
- Add event_date_from/to and recorded_date_from/to params to memory_search Two time dimensions: when fact HAPPENED vs when it was SAVED Uses client.searchTemporal() via API directly (works with any CLI version) - Results include eventStart, eventEnd, temporalContext from backend - CLAUDE.md: document all API signatures with params Co-authored-by: Cursor <cursoragent@cursor.com>
…meline chaining
- connections: rewrite output to JOIN edges→nodes; show CRYSTALLIZED_FROM,
EVOLVES (with sub-relation labels), SOURCED_FROM, MENTIONS each as typed
sections with relationship strength and memoryIds for follow-up
- memory_search: switch to searchRich (API-direct) — surface relevanceReason
("Text Match 100% + Semantic 69% | decay[imp:high]") and importance per result
- timeline: embed memoryId hints in entries so agent can chain to connections
- timeline: document event_type values in description for model discoverability
- recall hook: use searchRich — show scoring breakdown in injected context
- client: add searchRich() convenience wrapper
Co-authored-by: Cursor <cursoragent@cursor.com>
Aligns with nmem-cli v0.4 which adds graph expand (g) and feed (f) commands. Every feature now works in remote mode via NMEM_API_URL + NMEM_API_KEY without any plugin changes. - client: graphExpand() uses `nmem g expand`, feedEvents() uses `nmem f` - client: search() now gets rich fields (relevance_reason, importance, labels, temporal) from the enriched CLI JSON — searchRich() is now an alias - client: searchTemporal() uses CLI --event-from/--recorded-from args - client: _normalizeMemory() canonical shape across all search paths - connections: uses client.graphExpand() instead of client.apiJson() - timeline: uses client.feedEvents() instead of client.apiJson() - All API fallbacks retained for graceful degradation on older CLI versions Co-authored-by: Cursor <cursoragent@cursor.com>
…giene Exposes Nowledge Mem remote access in plugin configuration: - apiUrl: server URL (empty = local, supports remote deployment) - apiKey: API key, marked secret=true in uiHints for masked UI input Credential handling rules: - apiKey injected ONLY as NMEM_API_KEY env var into child processes - Never passed as a CLI arg (avoids ps aux exposure) - Never logged at any level - Config values win over NMEM_API_URL / NMEM_API_KEY env vars - Initialization log shows mode=remote → URL vs mode=local NowledgeMemClient now accepts credentials at construction; _spawnEnv() and _apiUrlArgs() build per-spawn env and args cleanly. Co-authored-by: Cursor <cursoragent@cursor.com>
Destructure error from both useCachedPromise calls and display a Toast.Style.Failure when searchMemories or listMemories fails, so users see "Connection failed" instead of a silent empty list. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…_type fixed nowledge_mem_save now exposes the full save contract: - unit_type: works end-to-end (API model fix in backend) - labels[]: array of topic/project tags, passed as repeated -l args - event_start / event_end: bi-temporal "when it happened" fields - temporal_context: past | present | future | timeless - importance: clamped to [0, 1] Confirmation message shows all non-default fields: "Saved: DB choice [decision] (id: ...) · labels: backend · event: 2024-03" CLAUDE.md: full rewrite reflecting current architecture - CLI-first table, remote config rules, tool surface, known gaps README.md: remote mode config section with secure apiKey example Co-authored-by: Cursor <cursoragent@cursor.com>
Gap 1 — Feed date range:
- nowledge_mem_timeline: add date_from/date_to (YYYY-MM-DD) params for exact
temporal queries ("what was I doing last Tuesday?")
- client.feedEvents(): pass --from/--to to `nmem f`; API fallback uses
?date_from=&date_to= query params
- Range label in timeline output: "Activity 2026-02-17 → 2026-02-17:"
Gap 2 — EVOLVES version chain via CLI:
- client.graphEvolves(): new method using `nmem g evolves <id>`; falls back
to GET /agent/evolves?memory_id=<id> (newly supported by backend)
- connections.js: switch from raw apiJson() to client.graphEvolves(); edge
direction now shown relative to the queried memory (→ newer / ← older)
Gap 3 — Working Memory section-level edit:
- client.patchWorkingMemory(heading, { content, append }): new method using
`nmem wm patch`; falls back to JS patchWmSection() + full PUT
- nowledge_mem_context: now accepts patch_section + patch_content/patch_append
params; agents can update one WM section without overwriting the rest
- patchWmSection() JS helper mirrors the Python _wm_patch_content() logic
Bump to v0.2.7
Co-authored-by: Cursor <cursoragent@cursor.com>
Bug: buildAgentEndCaptureHandler gated the thread append behind shouldCaptureAsMemory(), which checks for memory-trigger patterns in the last user message. Sessions ending with a question or a command were silently skipped — the thread was never saved to Nowledge Mem. The before_reset handler was already correct (unconditional). Fix: move appendOrCreateThread() before the shouldCaptureAsMemory check. Thread capture now always runs on successful agent_end when messages exist. The memory note remains gated — it's an additional signal, not the prerequisite for saving the session thread. Verified end-to-end: - thread create --id + append --idempotency-key both work in installed CLI - second append with same idempotency-key returns messages_added=0 - sessions ending with questions now get thread-captured correctly Co-authored-by: Cursor <cursoragent@cursor.com>
Expand Hooks section in README to explain: - autoRecall and autoCapture are plugin lifecycle hooks, not LLM decisions - autoCapture does two independent things: unconditional thread transcript append and conditional memory note extraction - Thread deduplication by external_id prevents duplicates across hook fires - Quality gates apply only to memory notes, not thread transcripts - What "context compaction" is and why capture happens at that point Co-authored-by: Cursor <cursoragent@cursor.com>
|
Caution Review failedThe pull request is closed. 📝 WalkthroughWalkthroughThe PR advances the Nowledge Mem OpenClaw plugin from version 0.1.4 to 0.2.7, introducing date range filtering for feed events, EVOLVES CLI graph integration, Working Memory section patching, graph exploration tools (connections, timeline), memory deletion (forget), bi-temporal search capabilities, and remote mode support with API configuration. Changes
Sequence Diagram(s)sequenceDiagram
participant U as User
participant C as Client
participant CLI as Nmem CLI
participant API as API Backend
U->>C: patchWorkingMemory(heading, {content})
C->>CLI: spawn with --patch --heading
alt CLI supports patch
CLI->>CLI: apply patch
CLI-->>C: success
C-->>U: confirmation
else CLI lacks patch support
C->>C: fallback to read-modify-write
C->>API: GET /agent/working-memory
API-->>C: document content
C->>C: patchWmSection(content, heading, {content})
C->>API: PUT /agent/working-memory
API-->>C: updated document
C-->>U: confirmation
end
sequenceDiagram
participant U as User
participant C as Client
participant CLI as Nmem CLI
participant API as API Backend
U->>C: searchTemporal(query, {dateFrom, dateTo})
C->>CLI: spawn temporal search with date filters
alt CLI temporal search available
CLI->>CLI: filter by event/recorded dates
CLI-->>C: results with temporal context
C->>U: enriched results (scores, event window)
else CLI lacks temporal support
C->>API: GET /search?temporal filters
API-->>C: bi-temporal filtered results
C->>U: enriched results (matchedVia, context)
end
Estimated code review effort🎯 4 (Complex) | ⏱️ ~65 minutes Poem
✨ Finishing Touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary by CodeRabbit
New Features
Bug Fixes
Documentation