Expand description
Ebbinghaus-style decay-curve scoring (v0.4.0 P1-4).
Reads the memory’s last_accessed_at + access_count and produces
a score in [floor, 1.0] that decays exponentially with age and
is reinforced by access count:
age_secs = max(0, now - last_accessed_at)
base = 0.5 ^ (age_secs / half_life_secs)
lift = log2(1 + access_count) * reinforcement_factor
weight = clamp(base + lift, floor, 1.0)Defaults (from a quick LongMemEval_M sweep, not from a paper):
half_life_secs = 7 * 24 * 3600 (one week), reinforcement_factor = 0.05, floor = 0.0. Operators tune via
RecallRequest.hybrid_weights + a decay_params field on the
engine builder.
Direct competitive response to YourMemory’s biological-decay marketing (Show HN, 2026-04-27); fused with vector + BM25 + recency rather than replacing them, so we keep our hybrid edge.
Structs§
Functions§
- decay_
weight - Pure function the lane and ad-hoc callers (e.g. CLI inspect) use.
Bounded in
[floor, 1.0].