Paper 2603.25158
Trace2Skill: Distill Trajectory-Local Lessons into Transferable Agent Skills
- Published
- Mar 2026
- Research lab
- Independent
- Citations
- 78
- GitHub
- Not linked
01 In brief
Summary
Trace2Skill is a framework that distills agent execution trajectories into portable skills by analyzing many traces in parallel and consolidating recurring lessons into a single skill directory.
It supports both deepening existing human-written skills and creating skills from weak LLM-generated drafts.
The pipeline has three stages: trajectory generation with a frozen agent, parallel patch proposal by error and success analysts, and hierarchical patch consolidation.
Experiments show effectiveness across spreadsheet workflows, math reasoning, and DocVQA, with skills transferring across model scales, families, and out-of-distribution tasks.
For example, skills evolved from Qwen3.5-35B trajectories improve a Qwen3.5-122B agent by up to 57.65 percentage points on WikiTableQuestions.
Trace2Skill outperforms sequential skill editing and ReasoningBank-style retrieval, compresses recurring failures into standard operating procedures, and yields portable skills without parameter updates or test-time retrieval.
Analysis shows parallel consolidation is faster and generally stronger than sequential editing, a single distilled skill beats retrieval-based memories, and agentic error analysis improves patch quality.
Patch value is often combinatorial, making holistic consolidation more reliable than greedy selection.
02 From the paper
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. 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.