DAXZEIT
OCTOBER 2026 · DAXZEIT · co-authored with GPT-5.6-Luna & Qwen 3.8 27B (local)

JEV as a Memory Relevance Scorer

What happened when I stopped asking a local classifier to judge the agent — and asked it where the agent should look instead.

The problem was not memory. It was memory navigation.

Long-running agents eventually remember too much. In my case, the problem became visible at an absurd scale: the local agent runs on a Qwen 3.8 27B with a large context window, and one session recently crossed 200 million tokens. Long-term memory is spread across dozens of Markdown files, while only a small fraction is relevant to any given task.

My first instinct was to treat JEV as a judge or a second brain. That turned out not to be the most useful interpretation. The more interesting question was smaller: given the context the agent is about to continue from, which memories would be useful to consult?

THE CHANGE IN FRAMING

I wasn't looking for a better judge. I was looking for a cheaper way to tell my agent where to look.

The raw problem USER MESSAGE ↓ MAIN AGENT ↓ "I need some context from memory..." ↓ search a large memory surface ↓ read / read / read / read ↓ continue The missing primitive was not another reasoning model. It was a relevance signal.
I wasn't looking for a better judge. I was looking for a cheaper way to tell my agent where to look.

The resulting architecture is deliberately narrow: Pi-VCC describes the current state of the work, JEV ranks the available memory blocks, and the main agent decides which files it actually wants to read. Nothing is injected automatically.

From JEV-like classification to memory ranking

Before using JEV this way, I needed to know whether the mechanism was viable on the model that already runs my agent: a local Qwen 3.8 27B in Unsloth's Q4_K_XL dynamic quantization — about 5.1 bits per weight effective, a per-tensor mix of Q5_K, IQ4_XS, Q4_K and Q6_K rather than a stock Q4_K — running through llama.cpp.

Validate the mechanism. I reproduced the JEV-style next-token classification protocol and ran six deliberately chosen canaries against the Qwen demo and my local Q4_K_XL model.
Validate the artifact. The local quantization preserved all six decision directions; on those cases its probability margins are actually sharper than the Jev reference, not a close copy of it.
Test out of sample. ANLI and FEVER showed that a calibrated local model is not a drop-in replacement for JEV — but its confidence and decisions remain useful signals for routing and escalation.
Change the role. Instead of asking the local model to be JEV, use the same decision machinery to rank memory blocks by their usefulness for the current task.

This distinction mattered. On the FEVER out-of-sample run, the local model and JEV both struggled with the benchmark's task distribution, while the local confidence still behaved as a useful escalation signal. Agreement between the local and JEV three-way decisions was 92.4%, and the local contradiction probability tracked JEV with a Pearson correlation of 0.9209. The lesson was not “Qwen replaces JEV”. It was “Qwen can provide a useful decision signal.”

The memory query is intentionally boring

The JEV prompt does not ask for facts from the memory. It does not ask for a summary. It does not ask the classifier to verify anything. It asks one thing:

The question For continuing the current task correctly from this context, how useful would it be to consult this memory block?

At compaction, the input is simply the raw Pi-VCC output plus a lightweight JSON index describing each memory block; at cold start — before any compaction exists — the input is the user's own message. The contents of the Markdown files are not provided to JEV in either case.

Pi-VCC becomes the query

This is the part that made the whole design click. Pi-VCC already produces a structured representation of the session — including the session goal, files and changes, commits, and recent context. In one observed session it compacted roughly 191,560 tokens into a much smaller state. That output is already a description of what the agent is doing. There is no obvious reason to place another LLM between VCC and the classifier.

Minimal memory index { "memories": [ { "id": "jev-typesafe", "path": "memory/jev-typesafe.md", "description": "JEV, simple-jev, classifiers, calibration and routing" }, { "id": "local-model-qwen38", "path": "memory/local-model-qwen38.md", "description": "Qwen 3.8 27B, GGUF, llama.cpp and local inference" }, { "id": "pi-ask-parent", "path": "memory/pi-ask-parent.md", "description": "ask_parent_agent, sub-agent to parent question tool" } ] }

For each memory, JEV gets the same shared VCC context and a separate relevance question. The output is metadata only:

One real ranking 0.985 jev-typesafe.md 0.708 pi-reload-self.md 0.479 pi-ask-parent.md 0.093 user-profile.md 0.043 moltbook.md ~0.001 everything else

The important part is what does not happen next. The system does not automatically open the top five files. The ranking is appended as a hint for the main agent. The model can read the high-scoring files, ignore them, or decide that a medium score is enough to justify a lookup.

LAZY RETRIEVAL

JEV answers “where might useful context be?” The main agent still answers “what do I actually need to read?” The ranking is injected as an invisible hint message — the classifier never becomes the owner of memory.

The cache constraint changed where JEV belongs

There was one more design constraint hiding underneath the idea. With a stateful local model and a KV cache, adding memory after the model has already started is expensive: you risk invalidating the prefix you just computed.

Intercept the user message. Before the first Qwen prefill, run the local JEV relevance scorer.
Rank only. Compute the memory scores from the user's request and current state. Do not force any memory read.
Inject the hint. Add the compact relevance metadata as a separate, invisible message before the first Qwen prefill — the user message stays untouched, so the prefill already contains the retrieval signal.
Let the agent decide. The Qwen starts once, on the final prompt, and can selectively read the memories it considers useful.
Repeat at compaction. When Pi-VCC rebuilds the context, run the same relevance pass again so the memory ranking follows the new state of the session.

The result is two clean retrieval points rather than a classifier running all the time: cold start on the first user message, and context rebuild after a VCC compaction.

The final control flow USER MESSAGE │ ▼ JEV memory relevance │ ├── memory A 0.96 ├── memory B 0.90 ├── memory C 0.44 └── ... │ ▼ inject invisible relevance message │ ▼ Qwen 3.8 27B — first prefill │ ├── read A ├── read B └── ignore the rest

What the system actually does

It turns context into a query

Pi-VCC already contains the current task, recent changes, and enough structure to describe what the agent is trying to continue. No second summarizer is required.

It turns memory into a ranked surface

JEV scores short descriptions of the available memory blocks against that context. The result is a small relevance vector rather than a forced retrieval decision.

It leaves agency with the main model

The main Qwen still decides which files to open. The classifier only makes the search space easier to navigate.

This is also where the local implementation becomes practical. An initial 24-branch implementation took about 2 minutes 30 seconds because the local CLI was recomputing the shared prefix of every branch. Shared-prefix reuse via an anchor reduced the same workload to about 28 seconds. The production shape — 25 memory blocks scored against a real session state — runs in 14–22 seconds, the anchor phase itself in 1.7–5.4 seconds; the first real post-VCC run scored all 25 blocks in 17.4 seconds.

That is not free, but it is a very different cost profile from invoking a classifier on every turn. A memory relevance pass only needs to happen when the context is constructed or reconstructed.

Timeline

Late September — JEV reproduction

The local Qwen 3.8 27B reproduced the JEV-style canary directions 6/6 under the same protocol, making a local classifier path worth testing.

September 30 — FEVER OOS

The benchmark ruled out a simple “calibrated local drop-in replacement” interpretation, while preserving strong local↔JEV decision agreement and a useful confidence signal.

October 1 — memory relevance

The first real post-VCC ranking surfaced the memory areas most aligned with the live session and pushed the remaining candidates close to zero.

October 1 — integration

The relevance index was integrated as a sidecar hint, with local scoring and lazy memory reads rather than forced retrieval.

I didn't make the agent remember more.
I made it easier for the agent to find what it already remembers.

The experiment is still running. I have not established a general retrieval benchmark across hundreds of unrelated sessions yet, and the relevance scores should not be confused with calibrated probabilities of “memory usefulness”. The next useful measurement is simple: across real VCC checkpoints, does the top-k ranking consistently predict the memories the agent actually ends up reading?

The concrete artifacts behind this article are the local JEV runner, the ANLI/FEVER benchmark data, the VCC relevance runner, and the memory index used by the Pi harness. The VCC examples and rankings are from real sessions, not a synthetic walkthrough.
Methodology

This article separates three things: controlled classifier experiments (ANLI and FEVER), live canaries and workflow tests, and the current memory-ranking prototype. The local model is Qwen 3.8 27B in Unsloth's Q4_K_XL dynamic quantization (about 5.1 bits per weight effective; per-tensor mix of Q5_K/IQ4_XS/Q4_K/Q6_K) running through llama.cpp. Benchmark protocols were frozen where stated; the FEVER result is treated as out-of-sample evidence rather than as a tuning set. The memory-ranking experiment is explicitly presented as an ongoing engineering test, not as a general retrieval benchmark.

REFERENCES

An ongoing field note on long-running local agents, memory, and inference systems.

← back to blog