HyperHarness generates code that selects user history for an unchanged answering model
HyperHarness generates personalized retrieval and guidance code that cuts answer-time tokens from about 32,500 to 3,150 in one MemoryCD test while matching the long-context baseline.
HyperHarness, described in a new paper, generates executable code that runs before an answering model receives a request. That code selects relevant records from a user's permitted history and prepares instructions for using them. The answering model itself stays unchanged. In one matched MemoryCD test with Qwen3.5-9B, average answer-time tokens fell from about 32,500 to 3,150, and the task score matched a long-context baseline.
The design splits memory use into two steps. Retrieval selects records from the history, and answer guidance explains how the model should apply them. Retrieval has to preserve where a preference came from, so guidance can apply brevity to reviews without imposing it on every technical explanation. The paper evaluates personalization benchmarks, not coding-assistant tasks. The case therefore illustrates the design's logic rather than reporting a measured result.
The distinction from a stored profile is practical. A profile might hold 'prefers concise reviews' and apply it everywhere. A generated harness can decide when to search for review preferences and which records to include for the current question. A construction model writes the retrieval and guidance functions as code. The generated program passes host checks for interface compatibility and execution limits, which shows it can run within required boundaries. Those checks do not measure whether the personalization is good. That still requires evaluation.
Building a separate harness for every user could become expensive if each one required repeated experiments, so the system improves a shared generator instead. Task results across training users guide changes to the generator's code and prompts, while the construction model and the answering model stay frozen. After development, the generator is fixed. For an unseen user, it builds a harness from permitted history in a single pass, without a task-scored search over candidate harnesses. That harness is then reused across the user's requests rather than rewritten for each question.
Across three benchmarks and three answering models, HyperHarness ranked first in seven of nine settings and second in the other two. The token figure needs context, though. Construction, optimization and judging costs are excluded from the comparison of about 32,500 with 3,150 tokens, so it measures only answer-time token use. A shorter prompt does not always produce a better answer. The claim is narrower: selected history can preserve useful personalization without sending the full record on every request.
What changed
A new paper describes HyperHarness, which generates code that selects user history and prepares instructions before an unchanged answering model receives a request.
Type: Research
Why it matters
Teams building personalized assistants could send less stored history with each request and still keep task quality in these tests, which may lower answer-time cost. The reported savings exclude the cost of building and optimizing the harness, and the results come from benchmarks rather than production coding tasks.
What you can do
Before relying on stored memory, test whether the assistant applies a preference only in the conversations where it fits, using cases such as code reviews, tutorials and overriding instructions.
Original source
We have no link to the original source for this story yet.
Where we saw it
AI Engineering
AI wrote this summary from the sources listed, and nobody reviewed it individually before publication. Check the original source before you rely on it. How it works