Clone and link locally for plugin development:
git clone https://github.com/basicmachines-co/openclaw-basic-memory.git
cd openclaw-basic-memory
bun install
openclaw plugins install -l "$PWD"
openclaw plugins enable openclaw-basic-memory --slot memory
openclaw gateway restartOr load directly from a path in your OpenClaw config:
{
plugins: {
load: {
paths: ["~/dev/openclaw-basic-memory"]
},
entries: {
"openclaw-basic-memory": {
enabled: true
}
},
slots: {
memory: "openclaw-basic-memory"
}
}
}bun run check-types # Type checking
bun run lint # Linting
bun test # Run tests (156 tests)
bun run test:int # Real BM MCP integration testsReal end-to-end tests for BmClient in integration/bm-client.integration.test.ts. These launch a real bm mcp --transport stdio process and assert actual filesystem/index results.
bun run test:intBy default this uses ./scripts/bm-local.sh, which runs BM from a sibling ../basic-memory checkout via uv run --project ... when present, and falls back to bm on PATH otherwise.
Optional overrides:
BM_BIN=/absolute/path/to/bm bun run test:int
BASIC_MEMORY_REPO=/absolute/path/to/basic-memory bun run test:intThis package is published as @basicmemory/openclaw-basic-memory.
# Verify release readiness (types + tests + npm pack dry run)
just release-check
# Inspect publish payload
just release-pack
# Authenticate once (if needed)
npm login
# Publish current version from package.json
just release-publishFor a full release (version bump + publish + push tag):
just release patch # or: minor, major, 0.2.0, etc.- CI workflow:
.github/workflows/ci.ymlruns on PRs andmainpushes - Release workflow:
.github/workflows/release.ymlruns manually (workflow_dispatch)- Runs release checks
- Bumps version and creates a git tag
- Pushes commit + tag
- Publishes to npm
- Creates a GitHub release
Publishing uses npm OIDC trusted publishing — no secrets required.
openclaw-basic-memory/
├── index.ts # Plugin entry — manages MCP lifecycle, registers tools
├── config.ts # Configuration parsing
├── bm-client.ts # Persistent Basic Memory MCP stdio client
├── tools/ # Agent tools
│ ├── search-notes.ts # search_notes
│ ├── read-note.ts # read_note
│ ├── write-note.ts # write_note
│ ├── edit-note.ts # edit_note
│ ├── delete-note.ts # delete_note
│ ├── move-note.ts # move_note
│ ├── build-context.ts # build_context
│ ├── list-memory-projects.ts # list_memory_projects
│ ├── list-workspaces.ts # list_workspaces
│ ├── schema-validate.ts # schema_validate
│ ├── schema-infer.ts # schema_infer
│ ├── schema-diff.ts # schema_diff
│ └── memory-provider.ts # Composited memory_search + memory_get
├── commands/
│ ├── slash.ts # /remember, /recall
│ ├── skills.ts # /tasks, /reflect, /defrag, /schema
│ └── cli.ts # openclaw basic-memory CLI
└── hooks/
├── capture.ts # Auto-capture conversations
└── recall.ts # Auto-recall (active tasks + recent activity)