<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Ethan Beirne</title>
    <description>The latest articles on DEV Community by Ethan Beirne (@ethanbeirne).</description>
    <link>https://dev.to/ethanbeirne</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4031160%2Fa7b9e9de-b068-4572-ab1d-e1dce3fade31.png</url>
      <title>DEV Community: Ethan Beirne</title>
      <link>https://dev.to/ethanbeirne</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/ethanbeirne"/>
    <language>en</language>
    <item>
      <title>Bitemporal AI Memory: How to Preserve What an Agent Knew Then</title>
      <dc:creator>Ethan Beirne</dc:creator>
      <pubDate>Sun, 19 Jul 2026 04:58:47 +0000</pubDate>
      <link>https://dev.to/ethanbeirne/bitemporal-ai-memory-how-to-preserve-what-an-agent-knew-then-2g96</link>
      <guid>https://dev.to/ethanbeirne/bitemporal-ai-memory-how-to-preserve-what-an-agent-knew-then-2g96</guid>
      <description>&lt;h1&gt;
  
  
  Bitemporal AI memory solves a problem ordinary RAG cannot see
&lt;/h1&gt;

&lt;p&gt;Most agent memory systems optimize for a simple question: &lt;strong&gt;which stored chunks are relevant now?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Production systems eventually need a harder question:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;What information was available to the agent when it made a specific decision?&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Those questions are not equivalent. If a fact, policy, permission, or architecture decision is corrected later, a latest-state memory system can silently rewrite the context behind an earlier action.&lt;/p&gt;

&lt;h2&gt;
  
  
  Two timelines, not one
&lt;/h2&gt;

&lt;p&gt;Bitemporal memory records two independent clocks for every fact:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Event time:&lt;/strong&gt; when the fact was valid in the real world.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;System time:&lt;/strong&gt; when the AI system learned, revised, or retired the fact.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Consider a contract amendment that became effective on January 1 but entered the agent's memory on January 12. A decision made on January 5 must not use that amendment, even though its effective date is earlier.&lt;/p&gt;

&lt;p&gt;A single timestamp cannot represent both truths.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why overwriting breaks historical replay
&lt;/h2&gt;

&lt;p&gt;Suppose a customer risk rating changes from low to high. If the memory layer overwrites the original row, a later audit sees only the high rating. It may appear that the agent ignored information that it did not actually possess.&lt;/p&gt;

&lt;p&gt;A bitemporal record keeps:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;the original value&lt;/li&gt;
&lt;li&gt;the correction&lt;/li&gt;
&lt;li&gt;when each value applied&lt;/li&gt;
&lt;li&gt;when the system received each version&lt;/li&gt;
&lt;li&gt;which version was eligible for each retrieval&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That supports three different queries:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Current truth:&lt;/strong&gt; what is valid now?&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Known at decision time:&lt;/strong&gt; what could the agent have used then?&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Revised historical truth:&lt;/strong&gt; what do we now believe was true on that date?&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  A practical test for any memory system
&lt;/h2&gt;

&lt;p&gt;You can test this without a large benchmark:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Store an architecture decision and its source.&lt;/li&gt;
&lt;li&gt;Run an agent task that retrieves it.&lt;/li&gt;
&lt;li&gt;Add a correction later with an older effective date.&lt;/li&gt;
&lt;li&gt;Replay the original task using its historical cutoff.&lt;/li&gt;
&lt;li&gt;Verify that the later correction does not leak backward.&lt;/li&gt;
&lt;li&gt;Confirm that a current query does use the correction.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;If both queries return the same memory version, the system is storing history but not reconstructing historical knowledge.&lt;/p&gt;

&lt;h2&gt;
  
  
  What a production implementation should preserve
&lt;/h2&gt;

&lt;p&gt;A useful bitemporal memory layer should retain:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;immutable version identities&lt;/li&gt;
&lt;li&gt;event-time and system-time validity windows&lt;/li&gt;
&lt;li&gt;source provenance and checksums&lt;/li&gt;
&lt;li&gt;retrieval filters and selected memory versions&lt;/li&gt;
&lt;li&gt;policy and permission results&lt;/li&gt;
&lt;li&gt;links from decisions back to supporting evidence&lt;/li&gt;
&lt;li&gt;deterministic as-of queries&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The goal is not to store private model reasoning. The goal is to preserve enough evidence to explain which state produced a material decision.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why this matters beyond compliance
&lt;/h2&gt;

&lt;p&gt;Temporal correctness improves more than audits. It also helps with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;reproducible evaluations&lt;/li&gt;
&lt;li&gt;backtests without lookahead bias&lt;/li&gt;
&lt;li&gt;debugging behavior after memory corrections&lt;/li&gt;
&lt;li&gt;incident reconstruction&lt;/li&gt;
&lt;li&gt;policy-version migration&lt;/li&gt;
&lt;li&gt;multi-agent workflows using changing shared state&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Founder disclosure: I am building &lt;a href="https://www.lians.ai" rel="noopener noreferrer"&gt;Lians&lt;/a&gt;, an open-source bitemporal memory and record layer for AI agents. The complete guide, including query models and evaluation checks, is available at &lt;a href="https://www.lians.ai/blog/bitemporal-ai-memory" rel="noopener noreferrer"&gt;Bitemporal AI Memory: Event Time, System Time, and Historical Recall&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;I am especially interested in how other teams handle late-arriving facts. Do you preserve historical versions, or does your current memory stack mostly optimize for the latest state?&lt;/p&gt;

</description>
      <category>ai</category>
      <category>llm</category>
      <category>rag</category>
      <category>opensource</category>
    </item>
    <item>
      <title>Try to Break Our AI Memory Benchmark</title>
      <dc:creator>Ethan Beirne</dc:creator>
      <pubDate>Sat, 18 Jul 2026 07:10:33 +0000</pubDate>
      <link>https://dev.to/ethanbeirne/try-to-break-our-ai-memory-benchmark-420d</link>
      <guid>https://dev.to/ethanbeirne/try-to-break-our-ai-memory-benchmark-420d</guid>
      <description>&lt;p&gt;Facts change. An earnings forecast is revised. A policy is amended. A medication dose is corrected. An entity record is updated.&lt;/p&gt;

&lt;p&gt;Many AI memory systems retain both the old and new versions. When retrieval ranks both highly, stale information can silently enter the model context.&lt;/p&gt;

&lt;p&gt;We built &lt;a href="https://github.com/Lians-ai/Lians" rel="noopener noreferrer"&gt;Lians&lt;/a&gt; to prevent that failure while preserving the historical record. That is a meaningful technical claim, especially for regulated AI, so it should be independently tested rather than accepted as marketing.&lt;/p&gt;

&lt;h2&gt;
  
  
  The challenge
&lt;/h2&gt;

&lt;p&gt;We have opened a public challenge asking developers to try to break Lians temporal recall.&lt;/p&gt;

&lt;p&gt;The included benchmark currently reports:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;0 stale facts in top-5 recall&lt;/li&gt;
&lt;li&gt;100 percent supersession accuracy on 22 fact pairs&lt;/li&gt;
&lt;li&gt;Point-in-time reconstruction through &lt;code&gt;recall_at&lt;/code&gt; and &lt;code&gt;snapshot&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;We want adversarial tests, not applause.&lt;/p&gt;

&lt;h2&gt;
  
  
  Run the benchmark
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git clone https://github.com/Lians-ai/Lians.git
&lt;span class="nb"&gt;cd &lt;/span&gt;Lians/agentmem
pip &lt;span class="nb"&gt;install&lt;/span&gt; &lt;span class="nt"&gt;-e&lt;/span&gt; &lt;span class="s2"&gt;".[dev]"&lt;/span&gt;
pytest tests/test_supersession_benchmark.py tests/test_recall_quality.py &lt;span class="nt"&gt;-v&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;No API key is required.&lt;/p&gt;

&lt;h2&gt;
  
  
  Try to break it
&lt;/h2&gt;

&lt;p&gt;The most useful tests will go beyond the included examples:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Add a fact with an event timestamp.&lt;/li&gt;
&lt;li&gt;Add a corrected or superseding fact.&lt;/li&gt;
&lt;li&gt;Confirm present-time recall excludes the stale version.&lt;/li&gt;
&lt;li&gt;Reconstruct what was known before the correction.&lt;/li&gt;
&lt;li&gt;Change the wording while keeping the same underlying entity and metric.&lt;/li&gt;
&lt;li&gt;Test ambiguous names, partial corrections, conflicting sources, or delayed updates.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;We are specifically looking for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Stale facts appearing in present-time recall&lt;/li&gt;
&lt;li&gt;A valid update failing to supersede the old version&lt;/li&gt;
&lt;li&gt;Two distinct facts being incorrectly merged&lt;/li&gt;
&lt;li&gt;Historical reconstruction returning information that was not yet known&lt;/li&gt;
&lt;li&gt;Differences across environments or embedding configurations&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Report evidence
&lt;/h2&gt;

&lt;p&gt;The canonical challenge is &lt;a href="https://github.com/Lians-ai/Lians/issues/60" rel="noopener noreferrer"&gt;GitHub issue #60&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Please include the fact pair or dataset, your environment, the command or script, the expected result, and the actual result.&lt;/p&gt;

&lt;p&gt;If a failure is reproducible, we will turn it into a regression test and credit the contributor. People who find meaningful edge cases will also be invited to a technical pairing session with the maintainers.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why this matters
&lt;/h2&gt;

&lt;p&gt;A current answer and a historical reconstruction are different products.&lt;/p&gt;

&lt;p&gt;A system reviewing a past financial decision, clinical recommendation, legal analysis, or policy action must preserve what was knowable at the time. Later corrections should improve current answers without rewriting the original decision context.&lt;/p&gt;

&lt;p&gt;That is the standard we want Lians to meet. The fastest way to improve the product is to expose the benchmark, make the claims falsifiable, and welcome critical results.&lt;/p&gt;

&lt;p&gt;If your team is deploying an agent that depends on changing facts, you can also request a free temporal-memory audit at &lt;a href="https://www.lians.ai/" rel="noopener noreferrer"&gt;lians.ai&lt;/a&gt;. We will examine one sanitized workflow and identify where stale facts or missing evidence could affect reliability.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>rag</category>
      <category>showdev</category>
      <category>testing</category>
    </item>
    <item>
      <title>Why AI audit logs break when the facts change</title>
      <dc:creator>Ethan Beirne</dc:creator>
      <pubDate>Thu, 16 Jul 2026 14:35:13 +0000</pubDate>
      <link>https://dev.to/ethanbeirne/why-ai-audit-logs-break-when-the-facts-change-1nd8</link>
      <guid>https://dev.to/ethanbeirne/why-ai-audit-logs-break-when-the-facts-change-1nd8</guid>
      <description>&lt;p&gt;Most AI agent audit logs can tell you what prompt ran, what model answered, and which tools were called.&lt;/p&gt;

&lt;p&gt;That is useful until someone asks a harder question six months later:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Why did the agent make that decision with the information available at the time?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Imagine an agent reviewing a company, customer, or transaction. It retrieves a policy, a filing, an entity record, and a risk rule. Later, the policy is updated, the filing is amended, and the entity record is corrected.&lt;/p&gt;

&lt;p&gt;If you replay the workflow using today's sources, you are not reproducing the original decision. You are running a new decision against a different world.&lt;/p&gt;

&lt;p&gt;You have an activity log, not decision reconstruction.&lt;/p&gt;

&lt;h2&gt;
  
  
  The hidden problem is time
&lt;/h2&gt;

&lt;p&gt;Agent systems need to distinguish at least three clocks:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Event time:&lt;/strong&gt; when the agent performed an action.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Valid time:&lt;/strong&gt; when an underlying fact was true in the real world.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;System time:&lt;/strong&gt; when your platform learned or stored that fact.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;A record can be valid in March, corrected in June, and audited in September. The September review may need both the March version that influenced the original decision and the June correction that changed the current truth.&lt;/p&gt;

&lt;p&gt;Without those distinctions, old facts can resurface as if they are current, or current facts can silently rewrite the past.&lt;/p&gt;

&lt;h2&gt;
  
  
  What evidence must be preserved
&lt;/h2&gt;

&lt;p&gt;For a meaningful reconstruction, I would preserve:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The exact retrieved source content or an immutable source version&lt;/li&gt;
&lt;li&gt;The prompt, policy, and instruction versions&lt;/li&gt;
&lt;li&gt;Model and tool configurations&lt;/li&gt;
&lt;li&gt;The permissions and identity active during the run&lt;/li&gt;
&lt;li&gt;Intermediate facts, citations, and transformations&lt;/li&gt;
&lt;li&gt;The order and timestamp of each state transition&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Logging only an ID is not enough if the document, policy, or record behind that ID can change later.&lt;/p&gt;

&lt;p&gt;Content hashes help prove integrity, but the original content or a recoverable immutable version still needs to exist.&lt;/p&gt;

&lt;h2&gt;
  
  
  Corrections, changes, and disagreements are different
&lt;/h2&gt;

&lt;p&gt;A new fact should not always overwrite an old fact.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Correction:&lt;/strong&gt; The previous record was wrong. Preserve it for audit, but make the correction authoritative for current decisions.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Real-world change:&lt;/strong&gt; Both facts were true at different times. Give each fact a validity interval.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Disagreement:&lt;/strong&gt; Two sources conflict and neither one clearly supersedes the other. Preserve both with provenance and surface the conflict.&lt;/p&gt;

&lt;p&gt;This structure lets current retrieval avoid stale information while point-in-time retrieval can still reproduce what the system knew earlier.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why this matters beyond compliance
&lt;/h2&gt;

&lt;p&gt;Decision reconstruction is not only an audit requirement. It improves:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Debugging when an agent behaves unexpectedly&lt;/li&gt;
&lt;li&gt;Evaluations across prompt, model, and policy versions&lt;/li&gt;
&lt;li&gt;Incident response after a source or rule changes&lt;/li&gt;
&lt;li&gt;Human review of high-impact decisions&lt;/li&gt;
&lt;li&gt;Trust between operators, customers, and regulators&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If an agent cannot explain what evidence it used at decision time, it becomes harder to improve safely.&lt;/p&gt;

&lt;h2&gt;
  
  
  What we are building
&lt;/h2&gt;

&lt;p&gt;At &lt;a href="https://lians.ai" rel="noopener noreferrer"&gt;Lians&lt;/a&gt;, we are building a system of record for AI in regulated workflows. The goal is to reconstruct what an AI system knew, did, and why at the moment a decision was made, even after the underlying facts change.&lt;/p&gt;

&lt;p&gt;We are three weeks old, pre-1.0, and working with a functioning product. We are looking for 5 to 7 design partners in financial research, risk, compliance, and other evidence-heavy agent workflows.&lt;/p&gt;

&lt;p&gt;If you operate an agent where policies, records, filings, or external sources change over time, I would genuinely value hearing how you handle reconstruction today.&lt;/p&gt;

&lt;p&gt;What breaks first in your current audit trail when the facts change?&lt;/p&gt;

</description>
      <category>ai</category>
      <category>architecture</category>
      <category>security</category>
      <category>startup</category>
    </item>
  </channel>
</rss>
