The engine
Five capabilities and one invariant.
Conventional agent memory assumes truth is timeless. A user works at Anthropic in February and OpenAI in
May; flat memory either forgets the old fact or keeps both as a contradiction the agent repeats back.
GapTime makes time a first-class property of every fact, so memory stays correct as the world changes.
Bi-temporal fact store
Every fact carries two half-open intervals: valid time [validFrom, validTo), when it was
true in the world, and transaction time [txFrom, txTo), when GapTime recorded it. An open
end means still valid, or current belief. The two axes are queried independently or together.
"What was true on March 15" and "what did we believe on March 15" are different
questions, and both have exact answers.
Contradiction detection
For a single-valued predicate, a different object over an overlapping valid interval is a contradiction.
GapTime classifies the overlap with the thirteen Allen interval relations and closes the older fact over
only the contradicted span, keeping any surviving prefix and suffix. Same-object overlaps merge instead
of duplicating.
"David works at OpenAI now" supersedes "David works at Anthropic" without erasing that
Anthropic was once true.
Time-travel queries
asOf(t) returns facts true at a valid-time instant; reconstructAsOf(t)
reconstructs what the system believed at a transaction-time instant, regardless of any later change;
query takes both coordinates; history returns every version.
reconstructAsOf answers a regulator's "reconstruct what the system knew at
time T" directly, from the data model itself.
Hybrid retrieval
search fuses an in-memory Okapi BM25 lexical index over an inverted postings map, n-hop
graph traversal, and an optional pluggable vector hook by reciprocal rank fusion, filtered to your time
coordinates. The lexical and graph signals need no database and no model.
Relevant facts surface with no external search service; semantic recall is opt-in when
you want it.
Provenance and audit
Source, ingestion timestamp, content hash, and actor are mandatory on every fact. The transaction-time
axis is append-only, and auditTrail() returns it as a frozen, tamper-resistant event log,
the record-keeping primitive behind EU AI Act Article 12 and ISO/IEC 42001.
Every answer traces back to the exact input that produced it, with a history a regulator
can reconstruct.
The invariant
GapTime never calls a provider API. It holds zero credentials, opens zero network connections, and
never sends a byte anywhere. The write path is deterministic and needs no model; turning free text into
facts is a pluggable extractor you supply and control.
Nothing new to audit: no credential to store, no egress path to review, no vendor in
the request loop.