Skip to content

Solution for long term memory for agent coding CLIs and to facilitate handoff between different agent vendors

Rust

Merge main into release/3.2

AkitaOnRails37d7459ddb8e
diff --cc CHANGELOG.md
index 7832af1b,63f67d4a..c83c9658
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@@ -208,13 -21,13 +208,20 @@@ version in [`docs/changelog/`](docs/cha
relay and wiki sync companions take the same `rustls-webpki` bump.
### Fixed
+- Reserved local-embedding capacity for interactive search queries instead of
+ allowing concurrent page writes and backfill work to occupy every inference
+ slot. Excess queries fall back immediately to non-vector retrieval, and a
+ cancelled request retains its slot until its non-cancellable CPU inference
+ actually ends. An opt-in real-model contention probe records idle,
+ unbounded-load, and bounded-load p50/p95 query latency; hosted embedding
+ providers are unchanged.
+ - `mcp-bridge` and the `setup` self-check no longer send requests to the
+ server through `HTTP_PROXY`, `HTTPS_PROXY` or `ALL_PROXY`, as the hooks
+ already did. A sandbox such as ai-jail exports a proxy with an empty
+ `NO_PROXY`, and its filtering proxy answered the bridge's loopback
+ `initialize` with 405, so Claude Code reported `CONNECTION_CLOSED`.
+ ([#1504](https://github.com/akitaonrails/ai-memory/pull/1504))
+
- Bound native API-key hashes to their configured pepper with a persisted
Argon2id verifier. A restored database with existing keys now refuses to
serve under a different `[auth].token_pepper` instead of silently making
diff --cc crates/ai-memory-cli/templates/config.default.toml
index b14bc942,33086700..f684a6f2
--- a/crates/ai-memory-cli/templates/config.default.toml
+++ b/crates/ai-memory-cli/templates/config.default.toml
@@@ -203,6 -145,27 +156,57 @@@ observation_retention_days = 0 # 0
observation_prune_batch = 5000 # rows per prune transaction
ledger_retention_months = 0 # 0 = never delete hook event ledgers
+ # NOTE: commented example tables stay below the first real table, where the
+ # top-level keys have ended. A `[table]` header owns every key after it, so an
+ # example table uncommented above a top-level key would silently capture it.
+
+ # Optional env-only presets for managed harness launches. Select one with
+ # `ai-memory run --profile work claude`. `--env-file` overrides the profile,
+ # and repeated `--env` entries override both. Keep executable paths, native
+ # argv, and permission-bypass choices on the command line.
+ # [run.profiles.work.env]
+ # CLAUDE_CONFIG_DIR = "/home/me/.claude-work"
+ # ANTHROPIC_BASE_URL = "https://api.anthropic.com"
+
+ # Server-side drop list for tool events (#1241): the server acknowledges and
+ # discards a matching PreToolUse/PostToolUse event before it is sanitized or
+ # stored, whatever the client sends. Applies to every project on this server.
+ # At most 64 entries per list, 128 characters each. Example: Claude Code marks
-# plugin tool calls with their own tool-use id prefix.
++# plugin tool calls with their own tool-use id prefix. Subagent classification
++# runs first, so a matching marked event still seeds tracking that suppresses
++# the subagent session's unmarked tail.
+ # [ingest]
+ # drop_tool_use_id_prefixes = ["toolu_plugin_"]
+ # drop_tool_names = ["mcp__noisy__poll"]
++#
++# Drop whole hook event kinds instead of individual tool calls. In production
++# ~87% of pre-tool-use observations have an empty body and pre-tool-use pairs
++# 1:1 with post-tool-use, which carries the content. Dropping a kind also
++# turns off everything that kind's processing does:
++# user-prompt loses prompts: session summaries, baton open questions
++# and profile learning; with pre-tool-use, it also stops
++# the project fallback pointer advancing (session-start
++# still advances it)
++# pre-tool-use loses the pre-call evidence; a call that never produced
++# a post-tool-use then leaves no trace, so the session may
++# end lifecycle-only
++# post-tool-use loses results, the completed-call count and file-work
++# evidence
++# stop loses the opt-in assistant reply and the
++# normal-completion signal; OpenCode loses its turn
++# checkpoint/baton
++# pre-compact / lose the compaction checkpoint and its rewrite job
++# post-compaction (the session is not ended)
++# notification loses the observation (search/consolidation context)
++# subagent-start / lose the subagent metadata (when stored, they become
++# subagent-stop `other` observations)
++# session-start and session-end are rejected at startup (they open/close the
++# session state machine); any other known kind may be named. The portable
++# workstream ledger (`ai-memory run`) is not filtered by this key. Empty by
++# default (nothing dropped).
++# Env equivalent: AI_MEMORY_INGEST__DROP_EVENTS=pre-tool-use
++# drop_events = ["pre-tool-use"]
+
# Privacy strip.
#
# Built-in patterns ALWAYS run; they cover bearer tokens, vendor-prefixed