Memory Conflict Detection
- title
- Memory Conflict Detection
- type
- concept
- summary
- Detecting contradictory knowledge and keeping both visible instead of silently overwriting
- tags
- ai-agents, memory, design-patterns
- created
- 2026-04-07
- updated
- 2026-04-07
The practice of detecting when a new piece of knowledge contradicts an existing one and keeping both visible rather than silently overwriting. This matters for any knowledge system where facts change over time โ agent memory, wikis, configuration databases โ because silent overwrites destroy the context about what changed and why.
The problem with overwriting
The simplest approach to updating knowledge: find the old entry, replace it with the new one. This works when the new information is unambiguously correct. It breaks when:
- The "new" information might be wrong (an agent misread something, a source is unreliable)
- The old and new information are both partially true in different contexts
- Understanding the contradiction itself is valuable (it reveals a change in the system or a gap in understanding)
In agent memory specifically, silent overwriting means the agent loses history. If a deployment script changed from requiring --force to not requiring it, both facts are useful: the current state and the knowledge that it used to be different.
How conflict detection works
When storing a new memory:
- Check existing memories for semantic overlap (same topic, similar tags, matching entities)
- Compare claims โ if the new memory asserts something that contradicts an existing memory, flag it
- Store both memories and create a conflict record linking them
- Surface conflicts to the agent or human for explicit resolution
The detection can be simple (exact tag + entity match with differing values) or sophisticated (embedding similarity above threshold with contradictory sentiment). hippo-memory uses the simpler approach: conflicts are stored in SQLite and mirrored to .hippo/conflicts/ as files, resolved explicitly with hippo resolve <id> --keep <mem_id>.
Resolution strategies
- Keep newest โ trust the most recent observation. Simple but loses history.
- Keep both with context โ annotate both with timestamps and let the consumer decide. Preserves the most information.
- Merge โ create a new entry that captures the nuance ("deploy required --force before v2.3, no longer needed after"). Most accurate but requires understanding.
- Human arbitration โ flag for manual review. Safest for high-stakes knowledge. This is a form of human-in-the-loop applied to knowledge management.
Relevance to this wiki
This wiki handles conflicts through the lint workflow: periodic scans that flag contradictions between pages for human review. The approach is similar in spirit to conflict detection but batch-oriented rather than real-time. If the wiki's ingest rate increases, real-time conflict detection during ingest (checking new claims against existing pages) would catch issues earlier.
byzantine-fault detection in multi-agent systems is a related problem at a different scale: agents producing conflicting outputs from the same prompt. The same principle applies โ keep contradictions visible and resolve explicitly rather than letting one silently win.