Trace2Skill: Distill Trajectory-Local Lessons into Transferable Agent Skills

Jingwei Ni, Yihao Liu, Xinpeng Liu, Yutao Sun, Mengyu Zhou +5 more
3/26/2026
226 citations
cs.AI

No official code found. Best implementation: Qwen-Applications/Trace2Skill (331 stars, Python, last commit 2026-05-01). 1 more below.

Abstract

Large Language Model (LLM) agents increasingly rely on domain-specific skills, yet manually authoring such skills does not scale, and skills generated purely from parametric knowledge often miss critical operational pitfalls. We introduce Trace2Skill, a framework that consolidates broad execution trajectories in parallel into a unified skill directory through inductive reasoning over agent experience.

Show full abstract

Trace2Skill supports both deepening existing human-written skills and creating useful skills from weak LLM-generated drafts. Experiments demonstrate the effectiveness of Trace2Skill across diverse domains, including office workflows, math reasoning, and vision QA. Importantly, the evolved skills are not merely memorized artifacts of the trajectories used to create them: they often transfer across model scales, across model families, and to out-of-distribution settings. For example, skills evolved from Qwen3.5-35B trajectories improve a Qwen3.5-122B agent by up to $57.65$ percentage points on WikiTableQuestions. Further analyses show that Trace2Skill outperforms sequential skill editing and ReasoningBank-style retrieval memories, compresses recurring failures and workarounds into standard operating procedures (SoPs), and yields portable skills that can be reused without parameter updates or test-time retrieval.

View on arXivView PDF

Code Implementations(2)

Code implementations of this paper
RepositoryTypeStarsLanguageLicenseLast commit
Qwen-Applications/Trace2SkillCommunity331Python–2026-05-01
Hert4/trace2skillCommunity4PythonMIT2026-05-04

Official codebase of the paper -- Trace2Skill: Distill Trajectory-Local Lessons into Transferable Agent Skills

33124PythonApr 27, 20267 months ago
Hert4/trace2skillCommunity25%
MIT

Harness-agnostic framework for evolving agent skills from real trajectories. Implementation of Trace2Skill: Distill Trajectory-Local Lessons into Transferable Agent Skills ([arXiv:2603.25158](https://arxiv.org/abs/2603.25158)).

41PythonApr 22, 20267 months agoMIT

Similar Papers

Cite this paper

@article{ni2026traceskill,
  title  = {Trace2Skill: Distill Trajectory-Local Lessons into Transferable Agent Skills},
  author = {Jingwei Ni and Yihao Liu and Xinpeng Liu and Yutao Sun and Mengyu Zhou and Pengyu Cheng and Dexin Wang and Erchao Zhao and Xiaoxi Jiang and Guanjun Jiang},
  year   = {2026},
  eprint = {2603.25158},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2603.25158v5}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2603.25158.svg)](https://codeofpaper.com/paper/2603.25158)

Discussion