Cross-Model Agent Experience Reuse: Designing Self-Improvement Memory

    When you tune an LLM agent's harness to fit one model, the gains rarely transfer to the next model. This article explains why framework-level improvements break on model swaps, what recursive self-improvement means in current engineering practice, and how a self-improvement memory that stores both rules and their reasons can make agent experience portable across models. It also covers four practical concerns for production use (memory quality control, abstraction level, regression and rollback, security) and the boundaries where this approach fits.

    1. Where the Problem Lies

    When building LLM agents, engineers spend most of their time polishing the execution layer around the model, commonly called the harness. It includes prompt templates, tool-call definitions, input/output interception and validation rules, plus retry and error-correction logic. Once this layer is tuned to fit a specific model closely, results are usually good.

    That fit is fragile. One research team observed that a harness heavily iterated on Model A scored lower than Model B’s own default harness in some experiments after being moved to Model B. These results depend on the original study’s experimental conditions and evaluation criteria, and should not be generalized into a universal rule.

    The cause is straightforward. The rules in a harness preserve outcomes but lose the reasons behind them. Facing a pile of interceptors, special-case branches, and verbose prompts, a new model cannot reconstruct why each rule exists or which class of failure it addresses. The rules then turn from experience into noise.

    2. What Recursive Self-Improvement Actually Means

    Recursive Self-Improvement (RSI) is often understood as a model continuously modifying its own weights. In current engineering practice, it usually refers to something else.

    • No change to the underlying weights. Retraining billions of parameters is costly, slow, and risky.
    • Improvement of the outer harness. The system observes its own failures at runtime and automatically revises prompts, tool definitions, and validation rules.

    This approach iterates quickly, produces observable results, and is easy to roll back. Its drawback is that the improvements are tied to a specific model. Swap the underlying model, and the accumulated experience is hard to carry over directly. The question then becomes: how can self-improvement experience be decoupled from a specific model so it can still be inherited?

    3. Self-Improvement Memory: Storing Rules and Reasons Together

    Self-Improvement Memory (SIM) is the name this article uses to describe a class of design ideas; it is not a standard industry term. The points below summarize the approach based on related material. For concrete implementation details, refer to the original papers or project documentation.

    The core idea is to change what gets stored. The system saves not only the final rule but also the reasoning that produced it and the triggering situation. Think of it as having the agent keep an “improvement log”: each time it hits a failure and corrects course, it records what was changed, why, what went wrong at the time, and which class of problem the fix targets.

    An illustrative memory entry might look like this:

    1. {
    2. "scenario": "External retrieval tool returns empty results",
    3. "observed_failure": "Model fabricates an answer instead of triggering a retry",
    4. "root_cause": "No explicit check for empty responses",
    5. "remedy": "Check for empty values after the tool returns; if empty, rewrite the query and retry once",
    6. "applies_to": "Models with tool-calling capability",
    7. "confidence": 0.82
    8. }

    Here confidence is an illustrative value; the actual definition should be set by each team’s own standard.

    This structure yields two properties.

    1. Interpretable. Each memory entry carries its own context, cause, and remedy, so a new model reads full context rather than an isolated conclusion.
    2. Portable. Entries record abstract experience rather than syntax rules specific to one model. A new model can re-process this experience in light of its own characteristics, instead of copying the old model’s code.

    4. Why Experience Inheritance Is Worth the Effort

    The common path to stronger agent capability is scaling the model, adding data, and extending context. The cost of that path keeps rising. More importantly, each model generation often forces the engineering work in the layer above to start over.

    Experience inheritance changes the cost structure.

    • Accumulation does not expire with the model. The model can be upgraded while the memory store keeps growing, and a new model starts from existing experience.
    • The feedback loop is shorter. Failures are recorded, records are reused, and the system improves gradually through use.
    • Model and engineering are decoupled. The underlying model becomes a replaceable component, and the team avoids lock-in to a single model.

    5. Four Concerns for Production Use

    First, memory quality control. Not every correction is worth keeping long term. You can set admission criteria such as occurrence count, a confidence threshold, and recent hit rate. Periodically merge duplicate entries and retire entries that have not been hit for a long time, so the memory store does not become a new source of noise.

    Second, the level of abstraction. Entries that are too specific cannot be used across models. Entries that are too abstract lose their guiding value. A better approach is to store in layers: record concrete cases at the lower level and distill generalizable patterns at the upper level, preferring the upper-level patterns during migration.

    Third, regression and rollback. After a new model absorbs old experience, it may introduce new failures. Maintain a fixed regression test set and compare metrics such as task success rate and tool-call error rate before and after migration. Keep rollback capability so that inheritance does not cause regressions.

    Fourth, security and boundaries. Memory content should be treated as data, not executed as instructions. This means source tagging and content validation before writing, with permission isolation to restrict who can write. If contamination is found, you should be able to revoke related entries in bulk by source.

    At the infrastructure level, the required capabilities are fairly generic: object storage for memory entries, a logging service to trace each improvement process, monitoring and alerting to observe reuse effectiveness, and a containerized runtime to support evaluation and rollback. Most general-purpose cloud platforms can provide these, so teams can choose based on their own conditions and focus effort on the design of the memory mechanism itself.

    6. Applicability and Common Mistakes

    This mechanism is not suitable for every scenario. It needs observable failure signals to extract experience from failures. Without a regression test set, it is hard to judge whether a migration is truly effective. When tasks change rapidly, old memory can become stale quickly and requires more frequent retirement.

    Common mistakes in practice include the following.

    • Storing only conclusions, not reasons, which reproduces the same migration problem as the original harness.
    • Letting the memory store grow without pruning, which gradually degrades retrieval quality.
    • Executing memory content as instructions, which opens a door for contaminated content.
    • Validating the effect on one model and assuming it applies to all models.

    7. Conclusion

    Whether agent experience can persist across models comes down to preserving the reasons. Preserve the reasons, and experience has a chance to transfer; transferable experience spares the team from re-tuning from scratch on every model swap. Plan the structure, governance, and regression validation of memory early in the architecture, rather than patching it after the model has already changed.