Remember Your Trace: Memory-Guided Long-Horizon Agentic Framework for Consistent and Hierarchical Repository-Level Code Documentation
Bae, Suyoung, Lee, Jaehoon, Choi, Changkyu, Choi, YunSeok, Lee, Jee-Hyong
–arXiv.org Artificial Intelligence
Automated code documentation is essential for modern software development, providing the contextual grounding that both human developers and coding agents rely on to navigate large codebases. Existing repository-level approaches process components independently, causing redundant retrieval and conflicting descriptions across documents while producing outputs that lack hierarchical structure. Therefore, we propose MemDocAgent, a long-horizon agentic framework that generates documentation within a single, integrated context spanning the entire repository. It combines two components: (i) Dependency-Aware Traversal Guiding that predetermines a traversal order respecting dependency and granularity hierarchies; (ii) Memory-Guided Agentic Interaction, in which the agent interacts with RepoMemory, a shared memory accumulating prior work traces through read, write, and verify operations. Through an in-depth multi-criteria evaluation, MemDocAgent achieves the best performance over both open- and closed-source baselines and demonstrates practical applicability in real software development workflows.
arXiv.org Artificial Intelligence
Sep-30-2026
- Country:
- Europe (0.68)
- North America > United States (0.67)
- Asia > Middle East
- UAE (0.27)
- Genre:
- Workflow (1.00)
- Research Report > New Finding (0.67)
- Technology:
- Information Technology
- Software Engineering (1.00)
- Information Management (0.92)
- Software > Programming Languages (0.92)
- Artificial Intelligence
- Representation & Reasoning > Agents (1.00)
- Natural Language > Large Language Model (1.00)
- Machine Learning (0.94)
- Information Technology