TOKI: A Bitemporal Operator Algebra for Contradiction Resolution in LLM-Agent Persistent Memory

· Source: cs.AI updates on arXiv.org · Field: Technology & Digital — Artificial Intelligence & Machine Learning, Software Development & Engineering · Depth: Expert, medium

Summary

TOKI introduces a bitemporal operator algebra designed for contradiction resolution within LLM-agent persistent memory systems. It addresses the critical issue where existing production heuristics, such as last-writer-wins or evidence-weighted merge, fail to declare their isolation levels or explicitly manage write-time anomalies. TOKI redefines these four heuristics as a family of bitemporal operators, each with an isolation precondition and a provenance annotation that stores "losing" facts in an audit row. This framework explicitly treats contradiction resolution as write-time concurrency control, preventing replay inconsistency, belief-drift skew, and audit erasure—anomalies introduced by LLM judges. Empirical results show that while eight audited baseline systems admit at least one of these anomalies, TOKI excludes all three. The audit-row defense improves LoCoMo accuracy by 0.86, and removing the typed memory layer reduces accuracy by 0.49 on 1,444 answerable LoCoMo questions.

Key takeaway

For Machine Learning Engineers building LLM agents with persistent memory, you must explicitly address write-time concurrency control to prevent data anomalies. Implement a bitemporal memory system like TOKI's dual-row schema, ensuring each belief update includes isolation preconditions and provenance tracking. This approach guarantees replay consistency and prevents belief-drift skew or audit erasure, which are common in systems omitting keyed logging of LLM judge decisions.

Key insights

Contradiction resolution in LLM agent memory is write-time concurrency control, requiring explicit isolation and provenance.

Principles

Method

TOKI types four production heuristics as bitemporal operators over a dual-row schema. Each operator includes an isolation precondition and provenance annotation, storing losing facts in an audit row.

In practice

Topics

Code references

Best for: Research Scientist, AI Engineer, AI Scientist, Machine Learning Engineer, AI Architect

Related on AIssential

Open in AIssential →

Editorial summary, takeaway, and curation by AIssential. Original article published by cs.AI updates on arXiv.org.