T-CQRS: Causal State Reconstruction and State-Determination-Aware Retrieval for Distributed RAG in .NET 11

Distributed systems often rely on message logs to keep data consistent. But networks drop, delay, and reorder messages in real-world conditions. When out-of-order events arrive, sorting them on the .NET managed heap triggers repeated garbage collection cycles. This hurts tail latency. Querying these event streams with Retrieval-Augmented Generation (RAG) brings a separate challenge. Embedding search matches text by similarity alone. It cannot tell whether an event is active or superseded. As a result, outdated facts often enter the model prompt. We address these issues with Topological Command Query Responsibility Segregation (T-CQRS) and State Determination Frontier (SDF) retrieval. T-CQRS re-sequences out-of-order events in memory with value structs and pooled buffers in .NET 11 Preview. In our tests with 10,000 disordered events, no Gen-0 garbage collections were observed. Building on this graph, SDF finds the latest state-changing event (Fq) and extracts its prerequisite causal ancestors (Cq). Across 5,000 benchmark queries with five random seeds, SDF achieved a precision of 1.000 compared to 0.585 for dense vector search (d = 11.00). It maintained complete recall (SDR = 1.000), removed all observed stale evidence, and reduced prompt tokens by 30.0%. In-memory lookups averaged 18.02 microseconds.

Authors

Institutions

Publication Details

Journal
HAL (Le Centre pour la Communication Scientifique Directe)
Published
2026-08-25
DOI
https://doi.org/10.5281/zenodo.22100371
Primary Topic
Software System Performance and Reliability
Type
preprint
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
preprint

T-CQRS: Causal State Reconstruction and State-Determination-Aware Retrieval for Distributed RAG in .NET 11

Gheorghe Chesler, Mateus Yonathan
HAL (Le Centre pour la Communication Scientifique Directe)
Software System Performance and Reliability
preprint

T-CQRS: Causal State Reconstruction and State-Determination-Aware Retrieval for Distributed RAG in .NET 11

Gheorghe Chesler, Mateus Yonathan
preprint en

Abstract

Distributed systems often rely on message logs to keep data consistent. But networks drop, delay, and reorder messages in real-world conditions. When out-of-order events arrive, sorting them on the .NET managed heap triggers repeated garbage collection cycles. This hurts tail latency. Querying these event streams with Retrieval-Augmented Generation (RAG) brings a separate challenge. Embedding search matches text by similarity alone. It cannot tell whether an event is active or superseded. As a result, outdated facts often enter the model prompt. We address these issues with Topological Command Query Responsibility Segregation (T-CQRS) and State Determination Frontier (SDF) retrieval. T-CQRS re-sequences out-of-order events in memory with value structs and pooled buffers in .NET 11 Preview. In our tests with 10,000 disordered events, no Gen-0 garbage collections were observed. Building on this graph, SDF finds the latest state-changing event (Fq) and extracts its prerequisite causal ancestors (Cq). Across 5,000 benchmark queries with five random seeds, SDF achieved a precision of 1.000 compared to 0.585 for dense vector search (d = 11.00). It maintained complete recall (SDR = 1.000), removed all observed stale evidence, and reduced prompt tokens by 30.0%. In-memory lookups averaged 18.02 microseconds.

HAL (Le Centre pour la Communication Scientifique Directe)
Software (Germany) (DE), R2M Solution (Italy) (IT)
Peace, Justice and strong institutions
Software System Performance and Reliability
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.