Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
41 commits
Select commit Hold shift + click to select a range
c07393f
feat(core): add harness envelope and redaction floor for bm hook fron…
phernandez Jul 15, 2026
3e3b85f
feat(core): add hook inbox WAL and harness stdin adapters
phernandez Jul 15, 2026
2d7c1c1
feat(core): add deterministic hook projector
phernandez Jul 15, 2026
af38809
feat(cli): add bm hook command group
phernandez Jul 15, 2026
6d34fe5
refactor(plugins): reduce claude and codex hooks to bm hook shims
phernandez Jul 15, 2026
a3ab49c
feat(cli): add bm hook install and remove with ownership-tagged merging
phernandez Jul 15, 2026
956a693
chore(plugins): bump the shim uvx floor from the release version updater
phernandez Jul 15, 2026
f494950
docs(plugins): document uv prerequisite, uvx floor, and captureEvents…
phernandez Jul 15, 2026
63bc6c8
fix(core): address review findings in bm hook front door
phernandez Jul 16, 2026
7fd1d03
fix(core): address PR #1070 review — hook probe, path redaction, Wind…
phernandez Jul 16, 2026
aacb9ab
fix(core): address PR #1070 round-2 review — tilde paths, shim fail-open
phernandez Jul 16, 2026
709a622
fix(core): redact envelope and checkpoint cwd (PR #1070 round-3 review)
phernandez Jul 16, 2026
e908d94
fix(core): fix projector replay-retire race and bound unmapped inbox …
phernandez Jul 16, 2026
c04e0c8
fix(core): dedup processed replay history on projector rebuild (PR #1…
phernandez Jul 16, 2026
0a39f5f
fix(core): route on project hint carried by an in-group replay (PR #1…
phernandez Jul 16, 2026
3d6e78a
fix(core): resolvable install command + flush tolerance for vanished …
phernandez Jul 16, 2026
daf3b4e
fix(core): probe PATH launchers before baking them into installed hoo…
phernandez Jul 16, 2026
14e6d3e
fix(core): recall generic session notes in the Codex brief (PR #1070 …
phernandez Jul 16, 2026
481b308
fix(core): redact Codex working-tree rows in checkpoints (PR #1070 ro…
phernandez Jul 16, 2026
a5f8798
fix(core): projector note_type, exact-dir redaction, envelope types, …
phernandez Jul 16, 2026
0f1f903
fix(core): skip CLI init for hook commands, redact roots before punct…
phernandez Jul 16, 2026
85cc94c
fix(plugins): restore uv tool run fallback for hook launchers (PR #10…
phernandez Jul 16, 2026
0cb528e
fix(core): don't prune write-failed envelopes; fail-open hook config …
phernandez Jul 16, 2026
a08ff88
fix(core): scope hook fail-open so operator verbs aren't silenced (PR…
phernandez Jul 16, 2026
a71b154
fix(core): install uvloop on the hook path before async work (PR #107…
phernandez Jul 16, 2026
d5b65a2
fix(core): catch SystemExit on the hook fail-open paths (PR #1070 rou…
phernandez Jul 16, 2026
510525e
fix(core): guard hook logging setup against config SystemExit (PR #10…
phernandez Jul 16, 2026
d9b2c20
fix(core): make pending retention session-aware (PR #1070 round-19)
phernandez Jul 16, 2026
6da90df
fix(core): create the hook inbox with owner-only permissions (PR #107…
phernandez Jul 16, 2026
a636e89
fix(core): expand user redactPaths; serialize checkpoint frontmatter …
phernandez Jul 16, 2026
56b76fd
fix(core): preserve the brief's closing fence under truncation (PR #1…
phernandez Jul 16, 2026
d883a05
fix(plugins): strip copied quotes from a multi-token BM_BIN (PR #1070…
phernandez Jul 16, 2026
93245ed
fix(core): bound the brief fence; route on full processed history (PR…
phernandez Jul 16, 2026
ac9702e
fix(core): reject negative retention; case-insensitive deny paths on …
phernandez Jul 16, 2026
5723092
fix(core): redact whole-value denied paths containing spaces (PR #107…
phernandez Jul 16, 2026
9931d5f
fix(core): redact embedded denied paths with spaced directories (PR #…
phernandez Jul 16, 2026
8ff92a7
fix(core): fix Windows deny-path redaction failures (PR #1070)
phernandez Jul 16, 2026
d6f60d8
refactor(core): value objects + Pydantic for the hooks module (PR #1070)
phernandez Jul 16, 2026
64b7f2e
fix(core): serialize projector artifact frontmatter via metadata= (PR…
phernandez Jul 17, 2026
14b07c7
fix(core): serialize concurrent projector flushes with an inbox lock …
phernandez Jul 17, 2026
d651ba2
fix(core): skip checkpoint working-tree section for denied workspaces…
phernandez Jul 17, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,20 @@
# CHANGELOG

## Unreleased

### Features

- **#997**: Added the `bm hook` harness front door (SPEC-55). Lifecycle verbs
(`session-start`, `pre-compact`) move the plugin hook logic into the package
behind per-harness stdin adapters, with the session brief fenced as reference
data. Opt-in envelope capture (`captureEvents: true`, fail-closed) records
redacted lifecycle events into a local inbox WAL, projected deterministically
by `bm hook flush`; `bm hook status` shows the surface. `bm hook install` /
`bm hook remove` wire the hooks into user-level harness config for standalone
users with ownership-tagged, surgical merging. The Claude Code and Codex
plugin hooks are now zero-logic shims that exec `basic-memory hook`; their
`uvx` fallback floor is bumped by release tooling.

## v0.22.1 (2026-06-12)

Follow-up patch to v0.22.0. Fixes project and default-project resolution on
Expand Down
8 changes: 8 additions & 0 deletions plugins/claude-code/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,14 @@ Memory's durable graph**, rather than a memory layer of its own. See

### Changed

- **Hooks are now zero-logic shims** (SPEC-55, #997). `session-start.sh` and
`pre-compact.sh` resolve the Basic Memory CLI (`BM_BIN` → `basic-memory`/`bm`
on PATH → `uvx "basic-memory>=<floor>"`, floor bumped by release tooling) and
exec `basic-memory hook <event> --harness claude` with the hook JSON on
stdin. The brief/checkpoint logic lives in the released package; opt-in
`captureEvents: true` additionally records redacted event envelopes to a
local inbox. uv is the documented prerequisite; the uvx fallback fetches from
PyPI on first run.
- **SessionStart hook now nudges toward `/basic-memory:bm-setup` on first run** — when
no `basicMemory` config block is present in either settings file. The nudge
survives a failed/empty task query (so a brand-new user with no project yet still
Expand Down
34 changes: 29 additions & 5 deletions plugins/claude-code/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,13 +45,36 @@ Plugin skills are namespaced under the plugin name:

## Requirements

- [Basic Memory](https://github.com/basicmachines-co/basic-memory) `>= 0.19.0`
connected as an MCP server. `uv tool install basic-memory` is recommended (it puts
a `basic-memory` binary on PATH, which the hooks call directly). A `uvx
basic-memory mcp`-only setup also works — the hooks fall back to `uvx`/`uv` when no
binary is on PATH.
- **[uv](https://docs.astral.sh/uv/)** — the documented prerequisite for the hooks'
fallback path. Install per platform:
- macOS: `brew install uv` (or the curl installer below)
- Linux/macOS: `curl -LsSf https://astral.sh/uv/install.sh | sh`
- Windows: `powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"`
- [Basic Memory](https://github.com/basicmachines-co/basic-memory) connected as an
MCP server. `uv tool install basic-memory` is recommended — it puts a
`basic-memory` binary on PATH, which the hooks call directly and which keeps the
hook version consistent with your MCP server.
- Claude Code.

### What the hooks execute

The hook scripts are zero-logic shims: they resolve the Basic Memory CLI
(`BM_BIN` override → `basic-memory` / `bm` on PATH → `uvx "basic-memory>=<floor>"`)
and exec `basic-memory hook <event>` with the hook JSON on stdin. All behavior
lives in the released Python package — versioned, typed, and tested. Two
disclosures:

- **Network fetch on first run.** When no binary is on PATH, the `uvx` fallback
downloads `basic-memory` from PyPI at a pinned minimum version (bumped by
release tooling); later runs use uv's cache.
- **Event capture is opt-in and off by default.** Setting `captureEvents: true`
(the JSON boolean — strings never enable it) records redacted lifecycle-event
envelopes to a local inbox under your Basic Memory home. Inspect with
`basic-memory hook status`, project with `basic-memory hook flush`.

If nothing is resolvable the shims exit silently — the plugin stays invisible
when Basic Memory isn't installed.

## Installation

```bash
Expand Down Expand Up @@ -101,6 +124,7 @@ settings (or select it via `/config`).
| `recallTimeframe` | `3d` | Recency window for the session brief |
| `recallPrompt` | _(built-in)_ | The instruction appended to the brief |
| `preCompactCapture` | `extractive` | How checkpoints are produced |
| `captureEvents` | `false` | Opt-in: record redacted lifecycle-event envelopes to the local inbox (see `basic-memory hook status` / `flush`). Only the JSON boolean `true` enables it. |

See [DESIGN.md](./DESIGN.md) for the complete configuration schema, the
Claude-Code-project ↔ Basic-Memory-project mapping, and team-workspace behavior.
Expand Down
Loading
Loading