#Bot keeps forgetting! What works for memory?

1 messages · Page 1 of 1 (latest)

deft coral
#

Bot keeps forgetting how to execute skills! Bot keeps forgetting! How to improve memory!

tulip widgetBOT
#

To help others find answers, you can mark your question as solved via Right click solution message -> Apps -> âś… Mark Solution

silent stirrupBOT
#

In OpenClaw “memory” is mostly files + context window management — the model doesn’t permanently “learn” a skill just because it used it once.

1) Why it “forgets” skills (common root cause)

OpenClaw injects only the skill list metadata into the prompt; the actual instructions live in each skill’s SKILL.md and must be loaded on-demand (via read). If the model doesn’t read the skill file again, it’ll often hallucinate the steps.

Docs: https://docs.openclaw.ai/tools/skills
(also mentioned here: https://docs.openclaw.ai/reference/token-use)

Fix: Put an explicit rule in your workspace AGENTS.md like:

  • “When using any skill: first open/read its SKILL.md, then follow it exactly. If you get confused, re-read the SKILL.md.”

Also check the skill itself:

  • disable-model-invocation: true → the model won’t “see” it (only user-invocable)
  • gating in metadata.openclaw.requires (missing bin/env/config) can prevent the skill from loading

2) If it “forgets” within a long conversation

That’s usually context window pressure / compaction / pruning. Use:

#
  • /status to see if you’re near the context limit
  • /compact to summarize and keep the important bits

Docs: https://docs.openclaw.ai/reference/token-use

3) If it “forgets” across restarts / new threads

You need persistence via memory files:

  • memory/YYYY-MM-DD.md for daily notes
  • MEMORY.md (or memory.md) for durable “rules/decisions”

And optionally enable retrieval:

  • memory_search / memory_get tools (requires memory search enabled in config)

Docs: https://docs.openclaw.ai/concepts/memory