Tools
Gist Memory
Scoped gist-based dialog memory plugin for OpenClaw
Configuration Example
{
"plugins": {
"entries": {
"gist-memory": {
"enabled": true,
"config": {
"workspaceDir": "/home/charles/.openclaw/workspace",
"scriptPath": "dialog_memory.py",
"dbPath": "state/dialog_memory.sqlite3",
"pythonCommand": "python3",
"autoRemember": true,
"autoPrepareReplyContext": true,
"defaultLimit": 8,
"minAutoRememberChars": 80
}
}
}
}
}
README
# Gist Memory Plugin
Installable OpenClaw companion plugin for `memory-core`, wrapping the scoped gist-based dialog memory system in `dialog_memory.py`.
## What it is
This plugin packages the existing local dialog memory system as an installable OpenClaw plugin instead of leaving it as a loose script.
It is intended to run alongside OpenClaw's bundled `memory-core`, not `memory-lancedb`.
It provides:
- install/uninstall friendly plugin identity
- agent tools for remember/search/status
- automatic retrieval before memory-relevant replies
- automatic high-signal gist capture on inbound messages
- clean config surface for paths and toggles
## What it is not yet
This is still a **wrapper plugin** around the current Python implementation.
It does **not** yet replace `dialog_memory.py` with a native JS memory runtime.
That means:
- plugin lifecycle is installable now
- memory logic still lives in `dialog_memory.py`
- the automatic ingest/retrieve loop now works through plugin hooks
- uninstall is easy because the plugin is separable
- it behaves as a companion to `memory-core`, not a replacement for it
- future migration to a full native memory capability remains possible
## Files
- `openclaw.plugin.json` - plugin manifest
- `package.json` - package metadata
- `index.js` - plugin entrypoint
## Config
Example config shape:
```json
{
"plugins": {
"entries": {
"gist-memory": {
"enabled": true,
"config": {
"workspaceDir": "/home/charles/.openclaw/workspace",
"scriptPath": "dialog_memory.py",
"dbPath": "state/dialog_memory.sqlite3",
"pythonCommand": "python3",
"autoRemember": true,
"autoPrepareReplyContext": true,
"defaultLimit": 8,
"minAutoRememberChars": 80
}
}
}
}
}
```
## Tools
- `gist_memory_status`
- `gist_memory_remember`
- `gist_memory_search`
## Admin command
- `/gistmem status`
- `/gistmem init`
- `/gistmem prune --max-salience 2 --max-sources 1 --max-retrievals 0`
- `/gistmem test`
## Install / uninstall model
### Install
Package this plugin and install it through OpenClaw's plugin system.
For local development, point OpenClaw at this plugin root or publish it as an npm/ClawHub package.
Recommended host setup:
- keep bundled `memory-core` enabled
- do not depend on `memory-lancedb`
- install `gist-memory` as a separate companion plugin
### Soft uninstall
Disable the plugin entry in config.
This stops hooks and tools, but leaves the SQLite database intact.
### Hard uninstall
1. disable/remove plugin from config
2. uninstall package
3. optionally delete `state/dialog_memory.sqlite3`
## Automatic loop behavior
### Automatic ingest
The plugin listens on `inbound_claim` and stores only higher-signal messages through `dialog_memory.py auto-remember`.
### Automatic retrieve
The plugin listens on `before_prompt_build` and calls `dialog_memory.py prepare-reply-context` for queries that look memory-relevant.
Returned gists are injected as compact prompt context.
## Recommended next step
If we keep going, the next pass should:
- integrate more cleanly with `memory-core`-style memory surfaces where useful
- refine retrieval ranking so scoped relevant memories beat generic global hits more reliably
- move more of the Python shell wrapper behavior into native plugin code
- add better high-signal classification and redaction
- add formal install docs for `openclaw plugins install`
tools
Comments
Sign in to leave a comment