The AI Agent Memory That's Impossible to Lie To

The video presents an AI agent memory system that stores facts and skills as deterministic, verifiable computational units called “cells,” ensuring integrity by re-executing and validating all claims to detect any tampering instantly. This approach enables reliable, efficient, and portable knowledge recall across different hardware platforms without relying on traditional model context storage, with plans for further development and open-source release.

The video introduces an AI agent memory system that stores thousands of facts and skills, each associated with a precise computational cost. For example, the greatest common divisor (GCD) of 1071 and 462 is stored as 21, computed in 925 cycles. This memory allows the agent to recall facts instantly without recomputing them repeatedly. When the presenter deliberately alters a stored fact to an incorrect value, the system quickly detects the lie by re-executing all claims in the memory file, rejecting the entire file if any discrepancy is found. This verification process is extremely fast, taking only milliseconds, ensuring the integrity of the agent’s memory.

The core of this system is built around “cells,” which are small, deterministic computational units or functions written in Rust and compiled into tiny executables. Each cell performs a specific task, such as calculating the GCD using the Euclidean algorithm. These cells are content-addressed by their cryptographic hash, meaning any change in the code results in a new cell identity, preventing stale or tampered data. Because cells are deterministic and sandboxed—they cannot access clocks, files, networks, or environment variables—their outputs are guaranteed to be consistent across different machines and environments.

The agent uses a cell search mechanism to find the appropriate cell to execute based on the task at hand. When asked a question, the agent identifies the best matching cell and runs it with the given inputs. If the answer has been computed before, it is retrieved from the cache instantly, saving computational resources. This approach allows the agent to maintain a procedural memory that is both reliable and efficient, as it does not rely on storing answers in the model’s context but rather on verified, executable facts.

The system supports a wide range of computations, including integer and real number operations, physics calculations, and more, running on various hardware platforms such as CPUs, GPUs, and even an emulated Z80 chip for verification purposes. The GPU implementation enables massive parallelism, which the presenter plans to explore further in future videos. Importantly, the system excludes non-deterministic operations like networking or file access to maintain the integrity and reproducibility of results.

Overall, this AI agent memory system offers a robust, verifiable, and portable way to store and recall knowledge. Facts are not just trusted records but claims that can be independently checked by re-executing the corresponding cells. This design ensures that memory cannot be corrupted or lied to, enabling consistent behavior across different machines and use cases. The presenter plans to expand the system’s capabilities and share the code on GitHub for broader use and experimentation.