The Fault Line in Recursive Self-Improvement: How to Transfer Experiential Memory Across Models

    This article examines why a carefully tuned agent harness often degrades after switching the underlying model, and how to fix it. It explains that recursive self-improvement (RSI) in current practice rewrites the external harness rather than model weights, and that migration fails because only the final configuration is carried over, not the reasoning behind it. You will learn how to structure self-improvement memory as self-explanatory triples of change, rationale, and validation evidence; how to separate model-agnostic constraints from model-specific preferences when moving across model families; and the engineering practices for retrieval, lineage, rollback, and evaluation-set isolation that keep iterations from regressing.

    1. Where the Problem Starts: Why a Polished Harness Breaks After a Model Swap

    In agent engineering, what actually gets iterated on is rarely the hundreds of billions of parameters inside the model. It is the engineering layer wrapped around it, commonly called the harness. The harness includes system prompts, tool descriptions, call orchestration, parameter validation, failure interception, and retry policies. Recursive self-improvement (RSI), in today’s engineering context, usually means letting an optimizer automatically rewrite this layer rather than modifying model weights.

    The pain point is that this layer is tightly coupled to the behavioral habits of one specific model. A configuration refined over hundreds of trial-and-error rounds on one model can score even lower than the target model’s default configuration after migration. The reason is not mysterious: migration carries over the “what” but not the “why.”

    Faced with a screen full of complex rules, conditional branches, and interceptors, a new model cannot tell which rule exists to fix a critical defect and which is merely legacy redundancy. Without the rationale for each change, the optimizer typically makes two kinds of mistakes: deleting a patch that is still actively doing work, and retrying approaches already proven ineffective. Combined, they create a loop where more optimization means more degradation.

    A schematic failure chain looks like this:

    1. Initial harness H0 --optimize--> H1 (score up) --switch model--> H1' (score down)
    2. H1' --keep optimizing--> H2' (key rule deleted) --optimize again--> H3' (ineffective approach repeated)
    3. => The iteration curve trends downward with oscillation, while compute spend keeps rising

    2. The Core Mechanism: What Self-Improvement Memory Must Actually Store

    For experience to be transferable, a memory unit must be self-explanatory rather than storing only a final configuration. A common approach is to abstract every modification into a triple: the change, the rationale, and the validation evidence.

    • Change: a diff-able structured description of which prompt segment, tool constraint, or interception rule was modified.
    • Rationale: the failure samples that triggered the modification and the attribution conclusion, for example a class of inputs causing tool arguments to go out of range.
    • Validation evidence: before-and-after comparison results, the scope of cases covered, and the conditions under which the change takes effect or stops working.

    Only when all three are present can whoever picks this up next judge whether a rule is a load-bearing wall or a decorative one. In practice, memory can be organized as a retrievable entry store, tagged by task type, failure mode, and effective conditions, with relevant entries recalled and injected into context before optimization begins.

    1. {
    2. "id": "mem-0421",
    3. "task_type": "structured_output",
    4. "change": "Add enum value validation before tool calls",
    5. "reason": "12% of failure samples had calls interrupted by invalid enum values",
    6. "evidence": {"before": 0.71, "after": 0.86, "cases": 240},
    7. "scope": "batch scenarios with temperature<=0.3",
    8. "status": "active"
    9. }

    3. Cross-Model-Family Migration: Turning Past Memory into a Reusable Asset

    The key to cross-family migration is separating model-agnostic constraints from model-related preferences. The former include input validation, idempotent design, timeouts and graceful degradation, and output structure constraints, and they usually transfer directly. The latter include a specific model’s instruction-following habits, formatting preferences, and refusal tendencies, and they need recalibration.

    The recommended sequence is: first clean and deduplicate memory, explicitly flagging conflicting entries; then build a mapping table across capability dimensions (reasoning, long context, tool calling, structured output); then migrate only high-confidence entries and re-test them on the target model with a small comparison set; finally demote disproven entries to “candidate” status so they do not pollute the main store. The migration should preserve complete lineage, so any rule can be traced back to its source model and original evidence.

    It is worth stressing that this kind of mechanism is an engineering-level practice whose results depend on the specific task distribution and the quality of the validation set; there is no universal promise of gains. In deployment, logging services and monitoring alerts are typically needed to accumulate failure samples and observe the iteration curve. Experiment configurations and the memory store can be kept separately in object storage and a managed database, while training or evaluation jobs run on a container platform, ensuring reproducibility and rollback.

    4. Implementation Essentials and Common Pitfalls

    • Memory is not better when bigger: entry bloat crowds out context and introduces noise, so eviction and merging policies are needed.
    • Every change must be rollback-able: keep versions and baseline scores, and switch back immediately on any regression.
    • Keep the evaluation set independent from the optimization set: otherwise the optimizer overfits to evaluation noise.
    • Distinguish “fix” from “refactor”: fix-type changes require strong evidence, refactor-type changes require full regression.
    • Validate on a small sample before migrating: judge at minimal cost whether a piece of experience generalizes across models.

    In summary, the bottleneck in recursive self-improvement has shifted from “is there enough compute” to “is experience explainable and transferable.” Only by distilling the optimization process into structured memory that carries rationale and evidence, paired with strict validation and rollback mechanisms, can an agent inherit effective experience when the underlying model changes instead of inheriting baggage.