🤖 AI Summary
Existing memory-based coding agents are largely confined to homogeneous task domains and struggle to transfer knowledge across heterogeneous domains. This work proposes a Memory Transfer Learning (MTL) framework that constructs a unified memory pool spanning diverse domains and systematically investigates the transfer mechanisms of memory representations at varying levels of abstraction—from execution traces to abstract insights—in cross-domain coding tasks. For the first time, it reveals the critical influence of abstraction level on transfer efficacy and establishes principles for cross-model, cross-task memory reuse. Experiments demonstrate that MTL improves average performance by 3.7% across six coding benchmarks, with high-level abstract memories significantly enhancing positive transfer. Moreover, transfer effectiveness scales positively with memory pool size, supporting effective inter-model memory sharing.
📝 Abstract
Memory-based self-evolution has emerged as a promising paradigm for coding agents. However, existing approaches typically restrict memory utilization to homogeneous task domains, failing to leverage the shared infrastructural foundations, such as runtime environments and programming languages, that exist across diverse real-world coding problems. To address this limitation, we investigate \textbf{Memory Transfer Learning} (MTL) by harnessing a unified memory pool from heterogeneous domains. We evaluate performance across 6 coding benchmarks using four memory representations, ranging from concrete traces to abstract insights. Our experiments demonstrate that cross-domain memory improves average performance by 3.7\%, primarily by transferring meta-knowledge, such as validation routines, rather than task-specific code. Importantly, we find that abstraction dictates transferability; high-level insights generalize well, whereas low-level traces often induce negative transfer due to excessive specificity. Furthermore, we show that transfer effectiveness scales with the size of the memory pool, and memory can be transferred even between different models. Our work establishes empirical design principles for expanding memory utilization beyond single-domain silos. Project page: https://memorytransfer.github.io/