hindsight icon indicating copy to clipboard operation
hindsight copied to clipboard

openclaw: Active Memory deep recall stops working once OpenClaw gates memory-core's recall tools, because the plugin declares no recallToolNames

Open etzelm opened this issue 1 month ago • 1 comments

Bug Description

OpenClaw's Active Memory runs a child "deep recall" turn before some replies. It picks the tools for that turn in this order: the explicit plugins.entries.active-memory.config.toolsAllow list, then the selected memory plugin's recallToolNames from its registerMemoryCapability call, then a built-in fallback of memory_search and memory_get.

@vectorize-io/hindsight-openclaw registers a memory capability with providerRuntime only (src/index.ts, the api.registerMemoryCapability?.({ providerRuntime: ... }) call; dist/index.js:2759 in 1.2.0). It does not declare recallToolNames, so Active Memory has always used the fallback.

Until now the fallback worked by accident: the bundled memory-core plugin kept registering memory_search and memory_get even when Hindsight owned the memory slot, so the deep-recall turn ran against memory-core's own file index rather than Hindsight (openclaw/openclaw#141806). OpenClaw PR openclaw/openclaw#191028 (merged 2026-11-03) fixes that: memory-core registers those two tools only when it owns the slot. The PR body states the consequence for other plugins: Active Memory's fallback "records recall as unavailable (existing missing-tools path) unless the selected plugin declares recallToolNames or toolsAllow is configured."

So on the next OpenClaw release, every hindsight-openclaw user loses Active Memory deep recall unless they hand-edit the Active Memory allowlist.

This is not a request for Active Memory candidates. PR #5535 chose candidates: [] so Active Memory does not recall a second time on top of autoRecall; that stays as is. recallToolNames only names which of the plugin's own tools the deep-recall child turn may call.

Steps to Reproduce

  1. OpenClaw built from main at or after openclaw/openclaw#191028 (or the next tagged release), plugins.slots.memory: "hindsight-openclaw", memory-core left enabled, active-memory enabled with no toolsAllow.
  2. Start the gateway and open a session; let Active Memory trigger a deep recall (any prompt that references earlier work).
  3. Read the gateway log for the Active Memory recall step.

Expected Behavior

The deep-recall child turn calls hindsight_recall (and optionally hindsight_reflect) on the agent's bank, because the plugin declares recallToolNames: ["hindsight_recall", "hindsight_reflect"] next to providerRuntime.

Actual Behavior

Active Memory logs recall as unavailable (missing tools) and the reply runs without deep recall. On OpenClaw 2026.10.10 and earlier the same setup instead ran memory_search against memory-core's index, which never contained Hindsight data.

Workaround today: set plugins.entries.active-memory.config.toolsAllow: ["hindsight_recall", "hindsight_reflect"]. That works but is per-installation and undocumented for this plugin.

Version

  • @vectorize-io/hindsight-openclaw 1.2.0 (also main at src/index.ts)
  • Hindsight API 1.1.0
  • OpenClaw 2026.10.10 and main after #191028
  • macOS 27.2 arm64, Node 24

LLM Provider

Anthropic (claude-haiku-5-5 for retain), not relevant to the bug.

etzelm avatar Nov 03 '26 17:11 etzelm

For anyone who needs deep recall working before this is fixed: I published a standalone OpenClaw memory plugin for Hindsight, @etzelm/openclaw-memory-hindsight (source: https://github.com/etzelm/openclaw-memory-hindsight). It declares recallToolNames: ["hindsight_recall", "hindsight_reflect"], so Active Memory uses those tools without a toolsAllow list.

openclaw plugins install npm:@etzelm/openclaw-memory-hindsight

One limit: it only works on turns that run on OpenClaw's embedded agent runtime. On CLI-backed runtimes such as claude-cli, OpenClaw does not yet pass a memory audience to plugin hooks, so it does nothing on those turns. hindsight-openclaw does not have that limit.

It uses the same per-agent bank ids as hindsight-openclaw, so existing memory carries over. It is not a fix for this plugin. Adding recallToolNames next to providerRuntime here is still the right change, and the toolsAllow workaround above still works for hindsight-openclaw users.

etzelm avatar Nov 07 '26 03:11 etzelm