AgentPack: A Dataset of Code Changes, Co-Authored by Agents and Humans

Yangtian Zi, Zixuan Wu, Aleksander Boruch-Gruszecki, Jonathan Bell, Arjun Guha · OpenReview

Abstract

Fine-tuning large language models for code editing has typically relied on mining commits and pull requests. The working hypothesis has been that commit messages describe human intent in natural language, and patches to code describe the changes that implement that intent. However, much of the previously collected data is noisy: commit messages are terse, human-written commits commingle several unrelated edits, and many commits come from simple, rule-based bots. The recent adoption of software engineering agents changes this landscape. Code changes co-authored by humans and agents tend to be more narrowly scoped and focused on clearer goals. Their commit messages, generated by LLMs, articulate intent and rationale in much greater detail. Moreover, when these changes land in public repositories, they are implicitly filtered by humans: maintainers discard low-quality commits to their projects. We present AgentPack, a corpus of 1.3M code edits co-authored by Claude Code, OpenAI Codex, and Cursor Agent across public GitHub projects up to mid-August 2025. We describe the identification and curation pipeline, quantify adoption trends of these agents, and analyze the structural properties of the edits. Finally, we show that models fine-tuned on AgentPack can outperform models trained on prior human-only commit corpora, highlighting the potential of using public data from software engineering agents to train future code-editing models.

Introduction

Training Large Language Models (LLMs) to perform precise code editing requires high-quality datasets where natural language instructions are paired with clean, functional code patches. Historically, researchers have relied on mining public GitHub commits. However, this approach suffers from significant noise: human developers often write cryptic commit messages (e.g., "fixed bug") or bundle multiple unrelated changes into a single commit.

The emergence of Software Engineering (SE) Agents—such as Claude Code, OpenAI Codex, and Cursor Agent—presents a new opportunity. These tools produce scoped changes and generate detailed, LLM-authored explanations of the rationale behind each edit. AgentPack leverages this shift to provide a superior training signal for the next generation of code-editing models.

Methodology

To construct AgentPack, we developed a systematic pipeline to identify and extract high-quality agent-human collaborations from the GitHub public timeline between April and August 2025.

  1. Identification: We scanned for specific agent signatures, such as the Co-authored-by: Claude <[email protected]> tag used by Claude Code.
  2. Implicit Human Filtering: To ensure quality, we only included commits that were successfully merged into a project's primary branch. This utilizes the global community of maintainers as a filter, ensuring that the agent's work was reviewed and approved by a human.
  3. Extraction and Classification: We extracted full git patches and associated descriptions. Using a Qwen3-4B model optimized via the DSPy framework, we categorized a sample of these edits to understand the functional distribution of agent usage.

Dataset Characteristics

AgentPack comprises 1.3 million code edits totaling approximately 60GB. A defining characteristic of this dataset is the "Agent Advantage": the richness of the natural language descriptions. As shown in the table below, agent-authored commit messages are significantly longer and more detailed than those found in traditional human-only datasets like CommitPackFT.

Comparison of AgentPack with prior human-only commit datasets.

While the dataset is dominated by popular languages like Python, TypeScript, and JavaScript, it also includes a diverse range of low-resource languages such as OCaml, Fortran, and Julia, demonstrating the broad utility of SE agents across the programming spectrum.

Functional Analysis

Contrary to the assumption that AI agents are primarily used for minor bugfixes, our analysis reveals that agents are frequently employed for substantive creative work. The most common label in the dataset is "New Feature," followed by "Configuration or build" and "Bugfix."

Distribution of commit message labels across different agents.

This distribution suggests that agents are assisting in the full lifecycle of software development, providing high-quality examples of feature implementation and architectural refactoring.

Experimental Results

To validate the utility of AgentPack, we fine-tuned DeepSeekCoder (1.3B and 6.7B) on the dataset and compared performance against EditCoder, which was trained on human-only data. On the HumanEvalFix benchmark, the 1.3B model trained on AgentPack achieved a pass@1 score of 0.32, a significant improvement over the 0.20 achieved by the human-data baseline. These results highlight the high information density of agent-human collaborative data.

Conclusion

AgentPack demonstrates that the data generated by the current wave of SE agents is a potent resource for training better code-editing models. By leveraging the detailed rationale provided by agents and the implicit quality control of human maintainers, we can overcome the noise inherent in traditional commit history. Future work will focus on capturing the original human prompts to further bridge the gap between user intent and code implementation.

Summary updated

BibTeX
@misc{zi2025agentpack,
  author = {Yangtian Zi and Zixuan Wu and Aleksander Boruch-Gruszecki and Jonathan Bell and Arjun Guha},
  title = {{AgentPack: A Dataset of Code Changes, Co-Authored by Agents and Humans}},
  year = {2025},
  eprint = {2509.21891},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2509.21891},
}
Figure