Reproduce “MemRepair: Hierarchical Memory for Agentic Repository-Level Vulnerability Repair” on OpenResearch

Turn your favorite coding agents into research agents that review literature, develop hypotheses, and run experiments.

Universal app for Apple silicon and Intel. Requires macOS 11 or later.

About this paper

Simiao Liu, Li Zhang, Fang Liu, Xiaoli Lian, Yang Liu, Yinghao Zhu

MemRepair introduces a memory-augmented agentic framework for automated vulnerability repair at the repository level, achieving state-of-the-art success rates across diverse benchmarks in C/C++, Python, Go, and JavaScript. It integrates a three-tier memory hierarchy and a feedback-driven refinement loop to improve patch reliability and contextual understanding.

Key insights

  • Automated vulnerability repair agents benefit substantially from an architecture capable of explicit experience retrieval and continuous learning, mimicking how human security experts leverage accumulated knowledge.
  • A hierarchical memory system, especially the Refinement-Trajectory Memory (L3) which captures "failure-to-success" paths, is crucial for guiding agents to rectify semantic errors and bridge the localization-to-repair gap.
  • Generalized security patterns (L2) and project-specific repair conventions (L1) effectively augment LLMs, leading to more precise and context-aware vulnerability fixes across diverse codebases.

Summary by alphaXiv.

Tip: change arxiv.org to autoarxiv.org in any arXiv abstract link to open the paper here.