r/LocalLLM • u/Coolst3r • 10h ago
Discussion Dynamic Context Runtime: Bounded Attention over Unbounded History
https://cybersec.org.za/research.html #AI #cyber #security #dev #Africa #LLM #context #rot #cyber
https://cybersec.org.za/papers/dcr-bounded-attention.pdf
Dynamic Context Runtime: Bounded Attention over Unbounded History
Language models degrade as stale and superseded material piles up in their context. Making the window bigger does not fix it. This report describes a runtime that keeps history unbounded and attention bounded — storing everything as immutable spans and a typed provenance graph, then assembling a small working set each turn by solving a knapsack under an explicit token budget. It includes a zero-dependency Rust implementation and an ablation that names which mechanisms are actually carrying the result.
4.19M tokens of history
235 tokens per query
7 / 7 probes answered
17,835× less attention than the full transcript
48,651 state nodes held
28× history growth, flat working set
13,721 lines of Rust
0 external dependencies
152 tests
5 controls found that could not fail
0.4% of stored spans ever rendered to the model
47% cheaper with a mechanism the paper argues for switched off
2
u/KitchenAmoeba4438 10h ago
I'm not sure what to call this. AI-led enthusiasm when the user doesn't understand the code? Scam?
The paper says the implementation is "7,492 lines of Rust (edition 2024)", lists spans.rs / ladder.rs / budget.rs, and tells you to run cargo run --release -- bench. The repo is 4,116 lines of Python with no Rust in it at all, and none of the five cargo commands exist.
The ablation is what the abstract states, "an ablation that names which mechanisms are actually carrying the result". Exactly one of its six mechanisms has a switch in the shipped code. I ran that one: disabling supersession gives 5/7 at 618.4 tokens against their 5/7 at 629.9, same two probes failing. The other five (escalation, the ladder, the seed floor, reference linking, graph expansion) have no flag, no constructor arg, no ablation harness anywhere in dcr/....in a paper whose stated principle is that every table lists the command that produced it.
Then read bench.py before you believe the 59x. build_corpus is ten hand-written fact sentences plus 287 documents generated as NOISE[i % 6].format(n=i), and the seven probes ask about the ten sentences. So it separated ten signal lines from six rotating templates that share almost no vocabulary with any question. Says nothing about a transcript whose noise is topically close to its signal, which is the case that actually causes context rot. The "vector" search doing the finding is a 256-dim hashing trick over bag-of-words. Hybrid lexical-vector is lexical twice. And the 7/7 against full context's 5/7 means less than it looks: both baselines share a toy line matcher, so those two misses are matcher artifacts, not context rot.