NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Repo-To-Skill: Distilling GitHub Repositories Into AI4AI Skills

Jianlyu Chen, Yuyang Hu, Hongjin Qian, Jiawei Liu, Wenqing Wei, Xiaolong Chen, Defu Lian, Zhicheng Dou, Chaozhuo Li, Qiwei Ye, Zheng LiuarXiv 2026

TL;DR

Autonomous AI agents for machine learning research often waste time and compute on trial-and-error because they lack "operational knowledge"—the practical know-how required to make code and APIs actually work. This paper introduces DisCo, an agent framework that distills massive GitHub repositories and scientific papers into compact, verified, and reusable "skills." By equipping a fixed research agent with this distilled skill library, the authors demonstrate massive performance leaps across major AI research benchmarks, including a 134.3% relative improvement on MLE-bench.

What Problem Does This Paper Address?

Current AI agents designed for end-to-end machine learning research typically consist of two parts: a powerful LLM backbone (providing reasoning and planning) and an engineering harness (handling execution and tool orchestration). However, this standard architecture lacks operational knowledge—the domain-specific expertise required to configure training pipelines, correctly use complex package APIs, and avoid common implementation pitfalls.

Without this knowledge, agents are forced to learn through costly trial-and-error, burning through their token and execution budgets on misconfigured runs. While this information exists in human-facing documentation and code repositories, it is far too massive to fit directly into an agent's active context window. The challenge lies in automatically extracting this scattered, declarative knowledge and transforming it into an actionable, verified format that agents can easily consume.

Methods

The authors present DisCo (Distillation and Composition), an agent framework that operates in two distinct modes:

  • Creator Mode: Automatically distills raw software repositories and papers into structured skills.
  • Researcher Mode: Uses these distilled skills as selective operating context to solve novel research tasks.

The Skill Representation

DisCo structures operational knowledge into modular skills, each containing three layers:

  1. SKILL.md: The knowledge interface detailing use conditions, procedures, and failure modes.
  2. references/: The knowledge substrate containing deep API documentation and algorithmic details.
  3. scripts/: The execution interface consisting of executable wrappers that the agent can directly invoke.

These skills are organized into a hierarchical skill graph to enable progressive disclosure. Instead of loading thousands of skills at once, the agent reads a high-level router and only opens the specific sub-skills required for the current step, preventing context window bloat.

The Distillation Pipeline

The distillation process follows a strict four-stage pipeline:

  1. Scope Capability: Identify what the source repository or paper makes possible.
  2. Ground Evidence: Extract supporting knowledge directly from the source code, tests, and docs.
  3. Construct Skill Graph: Package the knowledge into the three-layer skill format.
  4. Verify & Refine: Run automated checks (such as repository-native tests, CLI smoke scripts, and tiny-fixture checks) to ensure the skill actually works before saving it.

Using this method, the authors built the AREX-Skill Library, a task-agnostic repository containing over 5,000 verified skills distilled from 1,000 popular ML repositories, mapped across 20 areas and 178 capability families.

The DisCo framework: Creator mode distills and verifies skills into the AREX-Skill Library, while Researcher mode selectively loads them during execution.

Datasets

The framework was evaluated across four distinct benchmarks to test different aspects of autonomous research:

  • MLE-bench: 75 machine learning engineering competitions testing end-to-end engineering and modeling choices.
  • PaperBench: 20 tasks requiring the agent to replicate results from scientific papers using cited, prior works as skill sources.
  • FrontierCS: 188 open-ended computer science problems evaluated via the Harbor framework.
  • PassNet: 200 samples testing graph-compiler pass generation.

Key Insights and Ideas

  • Knowledge Externalization Beats Harness Tweaking: Instead of modifying the core LLM backbone or building complex, bespoke orchestration loops, simply providing structured, externalized operational context yields massive performance gains.
  • The Difficulty Dividend: The value of distilled skills scales with task difficulty. On MLE-bench's "High" difficulty tasks, the skill-equipped agent saw a staggering 366.8% relative improvement. Harder tasks expose agents to larger search spaces where unguided trial-and-error is ruinously expensive.
  • Verification is the Differentiator: Unlike simple text summarization, DisCo explicitly runs code execution checks and diagnostic trials to verify skills. If a skill fails, it undergoes local repair before entering the library, ensuring the agent receives high-fidelity guidance.

Key Results

Holding the LLM backbone (GPT-5.5) and execution harness fixed, adding the distilled skills led to substantial improvements across all four benchmarks:

  • MLE-bench: The headline Any-Medal score jumped from 31.11% to 72.89% (+134.3% relative gain), outperforming strong public baselines that use custom harnesses.
  • PaperBench: Average replication scores rose from 29.45% to 39.59% (+34.4% relative gain).
  • FrontierCS: Scores improved from 70.63 to 77.14 (+9.22%), achieving a stronger score-efficiency frontier than competing agents by using fewer tool calls and steps.
  • PassNet: The primary benchmark score increased from 1.343 to 1.5313 (+14.0%), while reducing invalid/incomplete outcomes by 64.3%.
The quantitative impact of equipping a research agent with the AREX-Skill Library across four benchmarks.

Limitations and Future Work

  • Retrieval-Precision Failures: On a small number of tasks, the agent actually regressed slightly. The authors note that retrieving a poorly matched skill can occasionally distract the agent from discovering a better, task-specific strategy on its own.
  • Upfront Distillation Costs: While the cost of using skills during research is low, Creator Mode requires significant upfront compute and API costs (averaging $40 per repository) to build and verify the library.
  • Software Drift: The library relies on static snapshots of repositories. If an ML package undergoes a major breaking API change, the distilled skills will become obsolete until a re-distillation pass is run.

Future Directions: The authors suggest improving routing precision, implementing automated fallbacks to unguided reasoning when skills mismatch, and dynamically updating skills as software ecosystems evolve.

Summary updated

BibTeX
@misc{chen2026repo,
  author = {Jianlyu Chen and Yuyang Hu and Hongjin Qian and Jiawei Liu and Wenqing Wei and Xiaolong Chen and Defu Lian and Zhicheng Dou and Chaozhuo Li and Qiwei Ye and Zheng Liu},
  title = {{Repo-To-Skill: Distilling GitHub Repositories Into AI4AI Skills}},
  year = {2026},
  eprint = {2609.02749},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2609.02749},
}
Figure