ChatPaper.aiChatPaper

커밋 학습: 온라인 저장소 메모리를 통한 유기적 풀 리퀘스트 생성

Learning to Commit: Generating Organic Pull Requests via Online Repository Memory

March 27, 2026
저자: Mo Li, L. H. Xu, Qitai Tan, Ting Cao, Yunxin Liu
cs.AI

초록

대규모 언어 모델(LLM) 기반 코딩 에이전트는 통제된 벤치마크에서는 인상적인 성과를 보이지만, 실제 관리자들이 기각하는 풀 리퀘스트를 빈번히 생성합니다. 근본 원인은 기능적 오류가 아니라 유기성의 부재에 있습니다: 생성된 코드는 프로젝트별 규약을 무시하고, 내부 API가 이미 제공하는 기능을 중복 구현하며, 수년간의 개발 과정에서 누적된 암묵적인 아키텍처 제약을 위반합니다. 단순히 에이전트에 최신 저장소 스냅샷을 노출시키는 것만으로는 부족합니다. 스냅샷은 코드베이스의 최종 상태는 보여주지만, 그 상태에 도달하기 위한 저장소별 변경 패턴은 드러내지 않기 때문입니다. 우리는 이 격차를 해소하기 위한 온라인 저장소 메모리를 통한 'Learning to Commit' 프레임워크를 소개합니다. 엄격한 시간순 분할이 적용된 저장소에서 에이전트는 이전 커밋에 대해 지도 대조 반성을 수행합니다. 각 기록된 이슈를 맹목적으로 해결하려 시도하고, 자신의 예측과 실제 적용된 diff를 비교하며, 그 차이를 지속적으로 성장하는 기술 세트(코딩 스타일, 내부 API 사용법, 아키텍처 불변 조건을 포착한 재사용 가능한 패턴)로 정제합니다. 새로운 PR 설명이 도착하면, 에이전트는 누적된 이러한 기술들을 바탕으로 생성 과정을 조건화하여, 일반적인 사전 학습 사전 지식이 아닌 프로젝트 자체의 진화 과정에 기반한 변경 사항을 생성합니다. 평가는 기술 구축 단계에서 확인될 수 없는 진정한 미래의 병합된 풀 리퀘스트를 대상으로 하며, 기능적 정확성, 코드 스타일 일관성, 내부 API 재사용률, 수정 영역 타당성 등 다차원적으로 진행됩니다. 풍부한 커밋 기록을 가진 전문가 관리 저장소에 대한 실험 결과, 온라인 저장소 메모리가 보류된 미래 작업에 대한 유기성 점수를 효과적으로 향상시키는 것으로 나타났습니다.
English
Large language model (LLM)-based coding agents achieve impressive results on controlled benchmarks yet routinely produce pull requests that real maintainers reject. The root cause is not functional incorrectness but a lack of organicity: generated code ignores project-specific conventions, duplicates functionality already provided by internal APIs, and violates implicit architectural constraints accumulated over years of development. Simply exposing an agent to the latest repository snapshot is not enough: the snapshot reveals the final state of the codebase, but not the repository-specific change patterns by which that state was reached. We introduce Learning to Commit, a framework that closes this gap through Online Repository Memory. Given a repository with a strict chronological split, the agent performs supervised contrastive reflection on earlier commits: it blindly attempts to resolve each historical issue, compares its prediction against the oracle diff, and distils the gap into a continuously growing set of skills-reusable patterns capturing coding style, internal API usage, and architectural invariants. When a new PR description arrives, the agent conditions its generation on these accumulated skills, producing changes grounded in the project's own evolution rather than generic pretraining priors. Evaluation is conducted on genuinely future, merged pull requests that could not have been seen during the skill-building phase, and spans multiple dimensions including functional correctness, code-style consistency, internal API reuse rate, and modified-region plausibility. Experiments on an expert-maintained repository with rich commit history show that Online Repository Memory effectively improves organicity scores on held-out future tasks.
PDF21March 31, 2026