v1 — token bench closed, 120 cells

Context as managed virtual memory.

Valera Studio Harness is a deterministic pager for long Claude Code sessions. Instead of resending the whole transcript every turn, it keeps a small, hot working set in context and faults in everything else from a plain-markdown store, on demand, by handle. Files are the truth — the agent works in a spotlight, not a warehouse.

Benchmarked

Same model, same tasks — only the memory strategy differs.

120 cells (15 sessions × 2 conditions × 3–5 repeats), Valera Studio Harness vs. a stock Sonnet session holding full raw context, identical pass/fail checks on both sides.

81.3%
cheaper in aggregate
$87.97 total spend on Valera Studio Harness vs. $471.65 on stock, across the full 120-cell batch
100%
task correctness (60/60)
vs. 91.7% for stock (55/60) — Valera Studio Harness matches or beats stock on every task type
17/17
recall probes recovered
a fact dictated early, checked 30+ turns later — verified against actual reply text, not a relaxed check
84%
cheaper on long sessions
savings grow with length: 63% short → 72% medium → 84% long

Cost per session

Median cost per session — all 15 benchmark sessions, shortest to longest

Line chart comparing median cost per session between Valera Studio Harness and stock Sonnet across 15 benchmark sessions grouped short, medium, long, Valera consistently well below stock and the gap widening with session length

Savings by session length

% cheaper than stock, median $ per session

Short
63.2%
Medium
71.7%
Long
84.4%
0% 25% 50% 75% 100%
Correctness

Cheaper didn't cost accuracy.

Stock's only two misses (short-04-mixed, medium-02-doc-gen) were plain task-correctness failures, unrelated to memory.

SessionValera passValera $Stock passStock $
short-03-recall-probe3/3$0.313/3$0.53
medium-03-recall-probe4/4$1.084/4$3.76
long-03-recall-probe5/5$2.285/5$11.17
long-05-recall-probe-25/5$2.575/5$15.18
short-04-mixed3/3$0.210/3$0.59
medium-02-doc-gen4/4$1.052/4$2.87
Design

Four layers, one working set.

Everything else — the full store — stays on disk until a query actually touches it.

01

STANDING.md

The resident layer. A short, fixed system prompt — non-negotiable floors, plus the mechanics of how the rest of memory reaches the agent. Never paged, never grows.

02

short/

Ungated capture. An agent writes here freely — inferred or measured, never as your own confirmed word.

03

long/

Durable, gated memory. Only you promote a short/ card here — that promotion is the trust mechanic the whole design leans on.

04

pager.py

Lexical matching surfaces a one-line catalog card when live text touches a memory's keys. The agent faults in the full card only when it needs it.

Every card in short/ and long/ carries the same four-field frontmatter, defined in MEMORY_SCHEMA.md: type, class, origin, keys. origin is the trust axis — origin: operator can only be minted by the human running the session, never written by an agent on its own initiative, which is what makes the promotion in 03 a real gate and not a formality. class is a strict public ⊂ crew ⊂ private ceiling that fails closed on anything missing or malformed. It's a plain markdown/YAML contract, not a database schema — the file on disk is the source of truth.

This is v1 — a working design that's already saving real money and passing its own checks, not a finished product. The findings doc is written to surface what's still uncertain, not just what looks good — read it before you take any number here on faith.
Get it

MIT licensed. Python 3.11+. No framework lock-in.

Clone it, edit STANDING.md for your own deployment, and run the harness against the Claude Agent SDK. Source and full quickstart ship together.

This is free (MIT licensed) — if it's useful to you, tips help fund development. Totally optional.

Pager design converges independently with, and adopted patterns from, TencentCloud/TencentDB-Agent-Memory (MIT) — their summary/no-silent-caps conventions informed this project's tier fields. Early design work also drew on a reading of mem0ai/mem0 (Apache 2.0).