memorix icon indicating copy to clipboard operation
memorix copied to clipboard

Memory hygiene directions from Claude Code Auto Memory research

Open AVIDS2 opened this issue 3 months ago • 2 comments

Context

Researched Claude Code's Auto Memory design (community source-level analyses, not an official spec — caveat noted in the research doc). The full comparison lives in docs/1.4.5-AGENT-AUTO-MEMORY-RESEARCH.md.

The short version: CC's design is strongest in its memory-hygiene rules and weakest in its single-agent sandbox. Memorix already owns the shared cross-agent layer, so the useful directions are about hygiene, not architecture.

Proposed directions

  1. "Only store the underivable" as explicit guidance. Code, file paths, and Git history are re-derivable and don't belong in observation memory. Memorix has admission/freshness machinery but the agent-facing guidance doesn't state the rule this crisply. → guidance-layer change.

  2. Dual-channel feedback. Our observation vocabulary leans negative (gotcha / problem-solution). Validated approaches ("this worked, keep doing it") should be recorded too, to prevent behavior drift. → needs a small model decision first: new type vs formation/admission directive.

  3. Session-level dedup of already-surfaced memory. The Workset governor budgets tokens but doesn't track "already shown this session". A surfaced-set would stop the same record being recalled repeatedly inside one session. → retrieval governor change.

  4. Explicit ignore semantics. "The user said ignore memory" should mean: proceed as if memory were empty — no citing, no comparing. Currently implicit at best. → guidance-layer change.

  5. Done already: security boundary test. CC deliberately excludes project settings from its memory-path resolution. Memorix has the same property by construction (only MEMORIX_DATA_DIR / home default), and it's now pinned by a regression test in tests/config/data-dir-boundary.test.ts.

None of these change the storage model. Scheduling is a release decision.

AVIDS2 avatar Aug 14 '26 09:08 AVIDS2

Progress: all five directions are now shipped and scored. Retrieval dedup measured 25% -> 19% duplicate rate with hits and token budget unchanged (session-replay exam); guidance rules measured 0/4 -> 4/4 inside the token ceiling (guidance-content exam). Closing scope remains the release decision.

AVIDS2 avatar Aug 14 '26 12:08 AVIDS2

Completed in Memorix 1.8.5.

The five hygiene directions are now shipped and measured: session retrieval duplicate rate decreased from 25% to 19% with hits and token budget preserved, and the guidance-content exam moved from 0/4 required rules to 4/4 within the token ceiling. The implementation keeps capture, qualification, retrieval, feedback, retention, and explicit durable-memory promotion separate.

Closing this research follow-up as completed; the detailed design and measurements remain in the repository research documentation.

AVIDS2 avatar Aug 30 '26 03:08 AVIDS2