Memory Lifecycle ​
LokulMem processes each turn through a deterministic pipeline.
Pipeline ​
- Normalize and canonicalize candidate facts.
- Extract via deterministic rules.
- Trigger fallback extraction only for ambiguity cases.
- Fuse candidates and score quality.
- Decide action with write policy (
ADD,UPDATE,SUPERSEDE,IGNORE). - Run risk validation before persistence.
- Persist and update retrieval state.
Why this matters ​
- Keeps writes conservative under uncertainty.
- Reduces duplicate or contradictory memory inserts.
- Produces explainable diagnostics for each decision.
Policy and safety ​
- Default extraction origin is user-only to prevent assistant contamination.
- Contradiction and temporal transitions can route facts to
SUPERSEDE. - High-risk conflicts can be downgraded to safe actions before write.