Community-run site. Not operated by the official OpenClaw team.

← All skill packs

Soul and Memory Pack for OpenClaw

Five workspace templates, a config patch for bootstrap caps, compaction and memory search, and a memory-maintenance skill with two read-only Python scripts. The scripts report file sizes against OpenClaw's prompt caps and look for reasons a saved fact is not reaching your agent. Install steps back up first and keep an existing USER.md and MEMORY.md; rollback restores your previous files and config.

One pack: pay once on Stripe, no account needed. All packs: a subscription you can cancel any time. Refund Policy.

What you get

  • 5 workspace templates: SOUL.md, AGENTS.md, USER.md, IDENTITY.md, MEMORY.md
  • Config patch (37 settings) for bootstrap caps, compaction, pre-compaction memory flush, tool-result pruning, memory search and dreaming
  • 2 memory search presets: keyword-only, or local hybrid search through Ollama
  • memory-maintenance skill with trimming steps and an 8-cause checklist for forgotten facts
  • memory_audit.py: file sizes against caps, hygiene findings and a trim plan
  • forget_diagnose.py: finds a keyword in memory files and flags likely causes, including over-cap omissions
  • Backup, install and rollback commands

Test results

Run on 2026-11-26 with OpenClaw 2026.11.10 (6ea542f). macOS 15.7.4 (Apple M3 Max), Node v24.22.3, a fresh OpenClaw profile, local Ollama model gemma4:31b. Commands ran in a sandbox without system service control. Paths are shortened and long output is cut. The output below is what those runs printed, shortened.

  1. Back up the config, workspace files and OpenClaw state before changing anything

    $ WS="$HOME/.openclaw/workspace"; echo "- My own rule written before the pack." >> "$WS/SOUL.md"; (cd "$WS" && shasum SOUL.md AGENTS.md USER.md IDENTITY.md > "$HOME/before-install.sha"); B="$(mktemp -d "$HOME/openclaw-soul-memory-backup.XXXXXX")" && mkdir -p "$B/workspace" && CFG="$(openclaw config file)" && CFG="${CFG/#\~/$HOME}" && cp -p "$CFG" "$B/config.json" && for f in SOUL.md AGENTS.md USER.md IDENTITY.md MEMORY.md; do if [ -f "$WS/$f" ]; then cp -p "$WS/$f" "$B/workspace/$f"; fi; done && if [ -f "$WS/BOOTSTRAP.md" ]; then mv "$WS/BOOTSTRAP.md" "$B/workspace/BOOTSTRAP.md"; fi && openclaw backup create --verify --output "$B" && touch "$B/complete" && echo "Backup folder: $B" && ls "$B/workspace"
    Backup progress: stage=plan phase=start
    Backup progress: stage=sqlite-source-integrity phase=start sourceBytes=1413120
    Backup progress: stage=sqlite-online-copy phase=start sourceBytes=1413120
    Backup progress: stage=sqlite-vacuum phase=start sourceBytes=1413120
    Backup progress: stage=sqlite-hash phase=start sourceBytes=1413120
    …
    Archive verification: passed
    …
    Backup folder: ~/openclaw-soul-memory-backup.SVXVDM
    AGENTS.md
    BOOTSTRAP.md
    IDENTITY.md
    SOUL.md
    USER.md
  2. Copy the templates without overwriting USER.md, sync IDENTITY.md, and apply the config patch and keyword-only preset

    $ WS="$HOME/.openclaw/workspace"; B="$(ls -d "$HOME"/openclaw-soul-memory-backup.*)"; test -f "$B/complete" && mkdir -p "$WS/memory" && for f in SOUL.md AGENTS.md IDENTITY.md; do cp "./packs/soul-memory/workspace/$f" "$WS/$f"; done && for f in USER.md MEMORY.md; do if [ -f "$WS/$f" ]; then echo "kept your $f"; else cp "./packs/soul-memory/workspace/$f" "$WS/$f" && echo "added $f"; fi; done && openclaw agents set-identity --workspace "$WS" --from-identity --json && openclaw config patch --file ./packs/soul-memory/config/compaction-memory.json5 --dry-run && openclaw config patch --file ./packs/soul-memory/config/compaction-memory.json5 && openclaw config patch --file ./packs/soul-memory/config/memory-search-fts-only.json5 && openclaw config validate && echo "bootstrapMaxChars=$(openclaw config get agents.defaults.bootstrapMaxChars)" && echo "contextPruning.mode=$(openclaw config get agents.defaults.contextPruning.mode)" && echo "search.provider=$(openclaw config get memory.search.provider)"
    kept your USER.md
    added MEMORY.md
    {
      "agentId": "main",
      "identity": {
        "name": "Atlas",
    …
        "theme": "Systems familiar"
    …
    Dry run successful: 37 update(s) validated against ~/.openclaw/openclaw.json.
    Applied 37 config update(s). Restart the gateway to apply.
    Applied 2 config update(s). Restart the gateway to apply.
    Config valid: ~/.openclaw/openclaw.json
    bootstrapMaxChars=16000
    contextPruning.mode=cache-ttl
    search.provider=none
  3. Install the memory-maintenance skill and confirm it is eligible

    $ openclaw skills install ./packs/soul-memory/skills/memory-maintenance --force && openclaw skills info memory-maintenance --json
    Installing to ~/.openclaw/workspace/skills/memory-maintenance…
    Skill files changed, but local Gateway refresh failed: Gateway not reachable at ws://127.0.0.1:19790 (ECONNREFUSED).
    Start it with `openclaw gateway run` or check `openclaw gateway status`.
    Gateway target: ws://127.0.0.1:19790
    Source: local loopback
    …
    Installed memory-maintenance from path -> ~/.openclaw/workspace/skills/memory-maintenance
    …
      "eligible": true,
    …
        "config": [],
        "os": []
      },
      "install": []
    }
  4. Audit the workspace against the configured caps, locate a topic and check provenance

    $ WS="$HOME/.openclaw/workspace"; D="$WS/skills/memory-maintenance/scripts"; python3 "$D/memory_audit.py" --workspace "$WS" --config "$(openclaw config file)" --plan-trim && python3 "$D/forget_diagnose.py" --workspace "$WS" --topic "safeguard" && openclaw doctor --lint --only core/doctor/memory-provenance --json
    Workspace Memory Audit: ~/.openclaw/workspace
    Limits (config): per-file=16000 chars | total=48000 chars | USER.md=4000 chars | MEMORY.md target=8000 chars
    Total bootstrap size: 10694 / 48000 chars (22.3%)
    Bootstrap files:
      - AGENTS.md: OK | 5616 / 16000 chars (35.1%, 77 lines)
    …
      - MEMORY.md: OK | 1711 / 16000 chars (10.7%, 20 lines)
    …
    Trim plan (recommended=False, excess=0 chars over target 8000):
    …
      - MEMORY.md:L11 (Standing Decisions) [has-trigger]
    …
      $ openclaw doctor --lint --only core/doctor/memory-provenance --json
      $ openclaw memory status --deep --json  # run while Gateway is stopped
      $ openclaw memory promote-explain safeguard --json
      $ openclaw sessions --json
    {"schemaVersion":1,"ok":true,"checksRun":1,"checksSkipped":76,"findings":[],"recoveryCopies":{"scope":"local","measurement":"logical","incomplete":false,"incompleteReasons":[],"total":{"count":0,"logi
  5. Scripts catch an over-cap USER.md and a topic that was never saved (on a throwaway folder)

    $ WS="$HOME/.openclaw/workspace"; D="$WS/skills/memory-maintenance/scripts"; mkdir -p demo-workspace && python3 -c "print('- Prefer short answers.\n' * 200 + '- Prefer the staging server called heron.\n' + '- Prefer short answers.\n' * 200)" > demo-workspace/USER.md && { python3 "$D/memory_audit.py" --workspace demo-workspace; echo "audit exit code: $?"; } && python3 "$D/forget_diagnose.py" --workspace demo-workspace --topic heron && python3 "$D/forget_diagnose.py" --workspace demo-workspace --topic pelican && rm -rf demo-workspace
    Workspace Memory Audit: demo-workspace
    Limits (defaults): per-file=20000 chars | total=60000 chars | USER.md=4000 chars | MEMORY.md target=8000 chars
    Total bootstrap size: 9643 / 60000 chars (16.1%)
    Bootstrap files:
      - AGENTS.md: absent
    …
      [ERROR] user_md_over_cap: USER.md is 9643 chars, exceeding its 4000-char cap (shared USER.md is truncated from the middle; personal USER.md is omitted).
    audit exit code: 2
    …
      [HIGH] match_in_truncation_zone: 1 match(es) sit in the part of an over-cap file that is likely omitted (estimated from the file's own cap, not the total budget). Compact the file; confirm with /con
    …
      - USER.md:L201 (no heading) [TRUNCATED]
    …
      [HIGH] not_on_disk: No literal match for 'pelican' in MEMORY.md, USER.md, AGENTS.md, SOUL.md, DREAMS.md, or memory/*.md. Either it was never written to disk, pre-compaction flush was skipped, or it 
    Recommended OpenClaw CLI checks:
      $ openclaw doctor --lint --only core/doctor/memory-provenance --json
      $ openclaw memory status --deep --json  # run while Gateway is stopped
      $ openclaw memory promote-explain pelican --json
      $ openclaw sessions --json
  6. Build the keyword memory index and search it

    $ openclaw memory index --force && openclaw memory search "safeguard" --json
    Memory index updated (main): 2 files indexed.
    [state/agent-db] agent database clean-close receipt: written; agent=main
    {
      "results": [
        {
          "path": "MEMORY.md",
    …
          "snippet": "## Standing Decisions\n\n- Keep compaction in `safeguard` mode with `notifyUser: true` and pre-compaction `memoryFlush` enabled so long sessions persist key notes before summarizing.
    …
          }
        }
      ]
    }
    [state/agent-db] agent database clean-close receipt: written; agent=main
  7. One local-model agent turn runs the audit through the skill

    $ openclaw agent exec --cwd "$HOME/.openclaw/workspace" --model "$OLLAMA_MODEL" --timeout 1400 --json "Use the memory-maintenance skill. Run its memory_audit.py on this workspace and report the character counts of MEMORY.md and USER.md as plain integers without commas. Do not edit any file."
    [agent/embedded] [context-pressure-diagnostic] admitted provider attempt for ollama/gemma4:31b route=compact_only estimatedPromptTokens=26012 promptBudgetBeforeReserve=24576
    [agent/embedded] [context-pressure-diagnostic] admitted provider attempt for ollama/gemma4:31b route=compact_only estimatedPromptTokens=26414 promptBudgetBeforeReserve=24576
    [agents/agent-command] [agent] run 737795e8-7f82-413a-b0a4-5ab8a07b7681 ended with stopReason=stop
    [state/agent-db] agent database clean-close receipt: written; agent=main
    {
    …
      "status": "ok",
      "final": "MEMORY.md: 1711\nUSER.md: 1077",
    …
          "text": "MEMORY.md: 1711\nUSER.md: 1077",
    …
          "exec"
    …
      },
      "model": "gemma4:31b",
      "provider": "ollama",
      "sessionId": "737795e8-7f82-413a-b0a4-5ab8a07b7681"
    }
  8. Roll back and confirm the config and workspace files match what was there before

    $ WS="$HOME/.openclaw/workspace"; B="$(ls -d "$HOME"/openclaw-soul-memory-backup.*)"; R="$(mktemp -d "$B/removed.XXXXXX")" && CFG="$(openclaw config file)" && CFG="${CFG/#\~/$HOME}" && cp -p "$CFG" "$R/config.json" && cp -p "$B/config.json" "$CFG" && for f in SOUL.md AGENTS.md IDENTITY.md BOOTSTRAP.md; do if [ -f "$WS/$f" ]; then mv "$WS/$f" "$R/$f"; fi; if [ -f "$B/workspace/$f" ]; then cp -p "$B/workspace/$f" "$WS/$f"; fi; done; for f in USER.md MEMORY.md; do if [ ! -f "$B/workspace/$f" ] && [ -f "$WS/$f" ]; then if cmp -s "$WS/$f" "./packs/soul-memory/workspace/$f"; then mv "$WS/$f" "$R/$f"; else echo "kept $f: it changed after install"; fi; fi; done; if [ -d "$WS/skills/memory-maintenance" ]; then mv "$WS/skills/memory-maintenance" "$R/skill"; fi; openclaw config validate && echo "Rollback done" && (cd "$WS" && shasum -c "$HOME/before-install.sha") && cmp "$B/config.json" "$CFG" && echo "config file identical to backup" && test ! -e "$WS/MEMORY.md" && test ! -e "$WS/skills/memory-maintenance" && echo "pack MEMORY.md and skill removed" && { openclaw config get agents.defaults.bootstrapMaxChars || true; }
    Config valid: ~/.openclaw/openclaw.json
    Rollback done
    SOUL.md: OK
    AGENTS.md: OK
    USER.md: OK
    IDENTITY.md: OK
    config file identical to backup
    pack MEMORY.md and skill removed
    Config path is valid but unset: agents.defaults.bootstrapMaxChars. The runtime default applies until you set an authored value with openclaw config set agents.defaults.bootstrapMaxChars <value>.

Requirements

  • OpenClaw 2026.11.10
  • Python 3
  • A configured model provider (tested with a local Ollama model)
  • A macOS or Linux shell (tested on macOS)

Not included

  • Models or API keys
  • Chat channel setup
  • Third-party memory plugins
  • Automatic repair: the scripts only report
  • Testing of Ollama embedding indexing, live compaction, memory flush, dreaming runs or Gateway restarts

Files in the zip

packs/soul-memory/LICENSE.txt
packs/soul-memory/README.md
packs/soul-memory/TESTED.md
packs/soul-memory/config/compaction-memory.json5
packs/soul-memory/config/memory-search-fts-only.json5
packs/soul-memory/config/memory-search-ollama.json5
packs/soul-memory/skills/memory-maintenance/SKILL.md
packs/soul-memory/skills/memory-maintenance/scripts/forget_diagnose.py
packs/soul-memory/skills/memory-maintenance/scripts/memory_audit.py
packs/soul-memory/workspace/AGENTS.md
packs/soul-memory/workspace/IDENTITY.md
packs/soul-memory/workspace/MEMORY.md
packs/soul-memory/workspace/SOUL.md
packs/soul-memory/workspace/USER.md

34 KB · SHA-256 5ff7a52b9d9d5bc3bf294bc3517bf98ae7f8e875f83d4a4ec41ca2ca995dae09

Licence: for your own use and your own team. No resale or republishing. Not an official OpenClaw product.

Other packs

  • Gateway Fix Kit: Diagnose and fix OpenClaw gateway startup, auth, update, config, and channel issues.
  • Secure Setup Pack: Hardened config patches, audit checklist, and approval-gated security triage skill.
  • Token Saver Pack: Cost-control configs, cheaper fallback routing, and local usage reports for OpenClaw.
  • Heartbeat and Cron Pack: A checklist monitor plus morning, evening, and weekly review jobs for OpenClaw.
  • Skill Safety Checker: Scan third-party OpenClaw skills for red flags before they get installed.
  • Spreadsheet Analyst Skill: Profile CSV/TSV files, group metrics, and write Markdown reports from computed numbers.