betaFeedback

WorksComputer Science

SkillCore: Internalizing Generalizable Skills via Scaffolding-Removed Fine-Tuning

Abstract

Runtime skills can improve agents' problem-solving capabilities by providing procedural guidance for tasks such as code review and debugging. However, these benefits reach only a minority of users, as most do not proactively invoke skills in practice. We argue that such generalizable procedures should become part of the model's capabilities rather than remain optional external add-ons, making them directly available without explicit skill loading. To this end, we present SkillCore, a data pipeline and supervised fine-tuning recipe for internalizing generalizable skills. We transform real agent trajectories by removing skill-loading scaffolding while preserving the task context and subsequent agent actions, thereby supervising direct execution without external skill content. To preserve access to task-specific skills that provide genuinely external information, we mix these scaffold-removed trajectories with a small proportion of skill-native trajectories that preserve supervision for skill invocation. On a held-out skill-free evaluation, SkillCore improves task completion quality over the base Qwen3-8B and Qwen2.5-72B models by 54.4% and 24.8%, respectively, while preserving task-specific skill invocation on a separate probe and general coding performance on SWE-bench Verified.

Introduction

Large language models (LLMs) are increasingly deployed as agents that reason, plan, and act across domains including software engineering and scientific discovery [4] (Yao et al. 2023; Wang et al. 2024b; Yang et al. 2024). Their effectiveness depends not only on the underlying model but also on the surrounding runtime scaffold, including prompts, tools, memory, and control flow [17, 15]. A prominent example is the agent skill:

Figure 1. The skill utilization gap. Skill-invoked trajectories are rare but associated with higher observed task success than those without skill use. This high-value, low-utilization pattern motivates internalizing reusable procedures from generalizable skills so their benefits are available without runtime invocation.

a reusable package of instructions, scripts, and resources that is loaded into context on demand to guide a specialized workflow without updating model parameters [1]. By supplying reusable procedural guidance, skills can improve agent performance across a range of tasks (Wang et al., 2024a).

Despite these benefits, runtime skills can benefit agents only when actually invoked. In our collected agent trajectories, only 3.2% contain a successful skill load followed by subsequent agent actions, suggesting that skills are rarely used in practice. As a result, the procedural guidance they provide is not available to the agent by default. This gap motivates skill internalization: incorporating reusable skill-provided procedures into the model’s parameters so that the agent can execute them without access to the corresponding skill content. The key question is therefore which skill-provided capabilities should be internalized and which should remain available through runtime invocation.

To determine what should be internalized, we distinguish between generalizable and task-specific skills. Generalizable skills encode reusable procedures for tasks such as systematic debugging, code review, and table extraction that transfer across tasks and environments. Task-specific skills, by contrast, contain procedures or resources tailored to a particular task or system, such as private APIs, system-bound instructions, or task-specific information. Accordingly, an effective internalization approach should make generalizable procedures available without runtime skill access while preserving runtime access to task-specific skills when specialized procedures, external information, or functionality are required.

In this work, we propose SkillCore, a framework that integrates a trajectory construction pipeline with a tailored supervised fine-tuning recipe to internalize generalizable skills while preserving runtime access to task-specific skills. Specifically, for generalizable skills, the data pipeline applies skill-scaffold removal: it removes the skill invocation, returned document, and associated loading artifacts while preserving the task context and the agent’s subsequent actions. This produces training trajectories that retain the demonstrated actions while excluding the skill-relevant context that originally guided them. Fine-tuning on these trajectories transfers the demonstrated procedure into the model’s parameters, enabling direct execution without the skill. By contrast, for task-specific skills, the training recipe retains a small proportion of skill-native trajectories with their invocation scaffolding intact, preserving supervision for when and how such skills should be invoked.

We evaluate SkillCore along three complementary dimensions: internalization of generalizable skills, retention of task-specific skill invocation, and preservation of general coding capability. First, a held-out skill-free evaluation assesses whether SkillCore improves model performance when generalizable skill content is unavailable. In this setting, SkillCore improves task completion quality over the base Qwen3-8B and Qwen2.5-72B models by 54.4% and 24.8%, respectively. Second, on a separate evaluation suite constructed from task-specific skill trajectories, SkillCore preserves skill invocation at rates comparable to those of the corresponding base models. Third, the resulting models maintain or improve performance on the auxiliary SWE-bench Verified evaluation [9, 12]. Ablations further show that retaining generalizable-skill scaffolding leads to more runtime skill invocations when skill content is unavailable, whereas omitting skill-native supervision suppresses appropriate task-specific calls.

Related Work

Agent Harnesses and Runtime Skills

An agent’s capabilities depend not only on its underlying model but also on its harness, i.e., the surrounding system of prompts, memory, tools, retrieval mechanisms, and control flow [17, 15]. For example, ReAct interleaves reasoning with actions in an agent control loop (Yao et al., 2023), whereas Toolformer and ToolLLM train models to decide when and how to invoke external tools and APIs [14, 13]. Together, these mechanisms augment the model’s parametric capabilities with external information and actions.

Agent skills augment agents at runtime by packaging instructions, scripts, and resources into discoverable directories loaded when relevant [1]. Beyond expert-created skills, prior work learns reusable procedures from experience. Voyager learns executable programs through open-ended exploration and retrieves them by natural-language descriptions (Wang et al., 2024a), while Agent Workflow Memory abstracts successful trajectories into reusable workflows (Wang et al., 2025). Building on these foundations, newer work structures skill acquisition more explicitly: Skill-Weaver practices web tasks to synthesize reusable APIs (Zheng et al., 2025), SKILL-DISCO compiles shared control-flow subgraphs into executable skills [6], and SkillRL co-evolves a hierarchical skill bank and agent policy through reinforcement learning (Xia et al., 2026). Although their representations and acquisition strategies differ, these methods all rely on external skill or workflow libraries retrieved at inference time. SkillCore instead internalizes generalizable procedures to reduce this dependence, while retaining runtime access to task-specific skills.

Context Distillation and Skill Internalization

Context distillation transfers behavior induced by privileged runtime context into model parameters. Prior work distills fixed prompts, instructions, demonstrations, and explanations so models can reproduce the corresponding behavior with less context [3, 5, 16]. A related line of work distills the results of costly inference-time reasoning into model parameters, allowing direct responses without repeating the reasoning process (Yu et al., 2024). Despite demonstrating effective context-to-parameter transfer, these approaches primarily operate on non-interactive input–output examples rather than multi-turn agent trajectories with tool use and environment feedback.

Recent work extends this paradigm to agent trajectories and skills. On-Policy Context Distillation trains a student without privileged context to match a context-conditioned teacher on student-generated trajectories (Ye et al., 2026), while Skill-SD conditions only the teacher on skills summarized from completed on-policy trajectories (Wang et al., 2026). SKILL2 and SIRI instead integrate skill internalization into agentic reinforcement learning: the former progressively withdraws skill context [10], whereas the latter mines and validates skills from current-policy roll-outs before distilling beneficial skill-guided actions into the plain policy ([7]). Together, these approaches depend on newly sampled on-policy behavior, typically obtained from controlled, executable benchmark tasks. LatentSkill offers an offline alternative by converting textual skills into modular LoRA adapters that must still be selected and loaded at inference time ([8] (Yu et al. 2026)). SkillCore instead constructs supervision offline from heterogeneous real-world user trajectories whose original environments cannot be readily reconstructed: it removes generalizable-skill scaffolding while preserving subsequent agent actions, then applies supervised fine-tuning. It therefore requires neither fresh policy rollouts nor an executable environment during corpus construction or training, and internalizes reusable procedures directly into the model’s parameters while retaining runtime access to task-specific skills.

Methodology

Overview

Let τ=(μ1,…,μL)\tau= (\mu_1, \ldots, \mu_L) denote an agent trajectory. Each message μi=(ri,ci)\mu_i = (r_i, c_i) has one of four roles rir_i: system, user, assistant, or tool; its content cic_i may be natural language, a structured tool call, or a tool result. The skill scaffold comprises the invocation and returned skill content, assistant utterances whose function is to announce or manage the skill use, and later accesses to the skill’s internal files. For generalizable skill calls, we remove this scaffold while preserving the task context, non-target skill interactions, and substantive downstream agent behavior, yielding a scaffold-removed trajectory τ~\tilde{\tau}. The validated outputs form the scaffold-removed corpus DremovedD_{\mathrm{removed}}.

Task-specific skills encode procedures or resources that transfer less readily across tasks, making their internalization less broadly useful. Some also depend on external information, proprietary interfaces, or environment-specific functionality that cannot be supplied by model parameters alone. For these skills, we retain skill-native trajectories, including their skill calls and returned content, to preserve supervision for runtime invocation. These trajectories constitute the skill-native corpus DnativeD_{\mathrm{native}}. SkillCore trains on a mixture of DremovedD_{\mathrm{removed}} and DnativeD_{\mathrm{native}} to balance direct execution of generalizable procedures with runtime use of task-specific skills. Figure 2 summarizes the framework; the following subsections describe data construction, training, and evaluation.

Overview of SkillCore

Figure 2. Overview of SkillCore. (1) Skill-Scaffolded Demonstrations: Given a user task, a skill retriever selects and loads a relevant skill (e.g., Filter Rows Skill) into the agent’s context. Guided by the skill, the agent interacts with the environment to produce a successful trajectory of agent actions and environment observations. (2) Scaffolding-Removed Fine-Tuning: We remove the skill scaffold while preserving the task context and subsequent agent actions, yielding scaffold-removed trajectories for supervised fine-tuning that transfer the demonstrated procedure into the model’s parameters. (3) Evaluation: We assess generalizable skill internalization (base vs. fine-tuned agent on the same task without external skill content, judged by an LLM), task-specific skill invocation retention (appropriate skill invocation when task-specific skill content is not provided in context but remains accessible at runtime), and preservation of general coding capability (the auxiliary SWE-bench Verified evaluation).

Data Curation and Scaffold Removal

Skill-Use Filtering. We collect 3,352,057 real-world agent trajectories and filter for those containing valid structured use_skill calls. We consider a call effective only when it specifies a non-empty skill name, is paired with a successful skill-loading result, and is followed by at least one agent action. Only 108,514 trajectories (3.2%) pass this filter, indicating that successfully loaded and subsequently used skills are sparse in the collected trajectories. Because annotating and transforming the entire filtered pool is costly, we select 44,960 trajectories for subsequent annotation and scaffold transformation while preserving coverage over distinct skills.

Quality and Generalizability Annotation. For each selected trajectory τ\tau, let Ceff(τ)C_{\mathrm{eff}}(\tau) denote its set of effective skill calls. We use Claude Opus 4.8 ([2]) to assign a trajectory-level quality score q(τ)∈{1,…,5}q(\tau) \in\{1,\ldots,5\} and, for each κ∈Ceff(τ)\kappa\in C_{\mathrm{eff}}(\tau), a generalizability score gen⁡(κ)∈{1,…,5}\operatorname{gen}(\kappa) \in\{1,\ldots,5\} that assesses the reusability of the loaded skill procedure beyond the current task. Scores near 1 indicate task-specificity, whereas scores near 5 indicate broad reusability. The judge also returns two Boolean labels: applied⁡(κ)\operatorname{applied}(\kappa) indicates whether subsequent agent actions apply the loaded skill’s procedure, and skillobj⁡(κ)\operatorname{skillobj}(\kappa) indicates whether the user’s task targets the skill itself.

Let validend⁡(τ)\operatorname{validend}(\tau) indicate that the task is completed or ends because of collection truncation, noloop⁡(τ)\operatorname{noloop}(\tau) that no repeated error loop occurs, and nodissat⁡(τ)\operatorname{nodissat}(\tau) that the user expresses no dissatisfaction. We define the Boolean trajectory-quality gate and the set of generalizable calls targeted for scaffold removal as

pass⁡(τ)=I[q(τ)≥4∧validend⁡(τ)∧noloop⁡(τ)∧nodissat⁡(τ)],G(τ)={κ∈Ceff(τ):gen⁡(κ)≥4∧applied⁡(κ)∧¬skillobj⁡(κ)}.(1)\begin{aligned} \operatorname{pass}(\tau) &= \mathbb{I}\left[q(\tau) \ge4 \land\operatorname{validend}(\tau)\right. \\ &\qquad\left.{}\land\operatorname{noloop}(\tau) \land\operatorname{nodissat}(\tau)\right], \\ \mathcal{G}(\tau) &= \{\kappa\in C_{\mathrm{eff}}(\tau) : \operatorname{gen}(\kappa) \ge4 \\ &\qquad{}\land\operatorname{applied}(\kappa) \land\neg\operatorname{skillobj}(\kappa)\}. \tag*{(1)} \end{aligned}

where I(⋅)\mathbb{I}(\cdot) denotes the indicator function. Thus, pass⁡(τ)=1\operatorname{pass}(\tau)=1 means that τ\tau passes the trajectory-quality gate, while G(τ)\mathcal{G}(\tau) contains the calls selected for scaffold removal. We transform τ\tau only when pass⁡(τ)=1\operatorname{pass}(\tau)=1 and G(τ)≠∅\mathcal{G}(\tau)\ne\varnothing. High-quality trajectories with no call selected for removal remain intact as skill-native supervision.

Coupling-Aware Scaffold Transformation. For each trajectory selected for scaffold removal, we construct a compact, indexed representation that fits within Claude Opus 4.8’s context window. Messages and skill calls receive stable identifiers, while long system fields and tool results retain only informative prefixes and suffixes. We choose between exact deletion and local rewriting based on whether the target scaffold can be isolated from assistant content. When it can, Claude Opus 4.8 identifies the target calls κ∈G(τ)\kappa\in G(\tau) and their corresponding text spans, which are then removed deterministically. Otherwise, Claude rewrites only the affected local window and leaves the remainder of the trajectory unchanged. Both routes remove the scaffold associated with calls in G(τ)G(\tau), including later accesses to skill-internal files, while preserving non-target skill interactions and downstream agent behavior. We denote the resulting trajectory by τ~\tilde{\tau}.

Transformation Validation. We retain a transformed trajectory τ~\tilde{\tau} only after it passes two complementary validation stages. First, a deterministic structural gate verifies that the invocation and linked result for every target call κ∈G(τ)\kappa\in G(\tau) have been removed, while all non-target skill calls are retained. It also verifies that all remaining tool calls and results are correctly paired, the system message remains unchanged, and the user request is non-empty. These checks ensure that scaffold removal does not corrupt the agent interaction protocol. However, they cannot determine whether the target scaffold has been fully removed or task-relevant content has been inadvertently deleted.

We then use Claude Opus 4.8 to conduct a semantic review of each transformation that passes the structural gate. It checks six properties: complete removal of the target scaffold, preservation of the original task intent, preservation of task-relevant agent actions, coherence of the edited message sequence, absence of later access to the removed skill’s internal files, and continuity of the overall discourse and task structure. A trajectory is retained only if all six checks pass, yielding 10,037 validated scaffold-removed candidates. Figure 3 summarizes the full data-construction pipeline.

SkillCore’s trajectory curation and transformation pipeline

Figure 3. SkillCore’s trajectory curation and transformation pipeline. We select skill-using trajectories, score them for quality and generalizability, and keep the high-quality ones with generalizable skills. Each is then transformed to remove the skill scaffold, validated for structural and semantic faithfulness, and filtered by context length to form the scaffold-removed training corpus.

Training

Before training, we serialize each trajectory using the Hermes agent template implemented in SWIFT (Zhao et al., 2025). We estimate serialized sequence lengths with the Qwen2.5-72B tokenizer and retain trajectories below a 65,536-token threshold. We then train on a mixture of DremovedD_{\mathrm{removed}} and DnativeD_{\mathrm{native}}, where skill-native trajectories preserve task-specific skill calls and their returned skill content. By default, we set the native-to-removed data ratio to 25%. This mixture provides supervision for both direct execution of internalized procedures and runtime invocation of task-specific skills.

We apply loss only to assistant language and structured tool calls. For serialized tokens x1:Nx_{1:N}, let wt∈{0,1}w_t \in\{0,1\} be the loss mask, with wt=1w_t = 1 for assistant tokens and wt=0w_t = 0 otherwise. System, user, and tool-result tokens therefore provide context without supervision:

L(θ)=−1∑t=1Nwt∑t=1Nwtlog⁡pθ(xt∣x<t).(2)\mathcal{L}(\theta) = -\frac{1}{\sum_{t=1}^{N} w_t}\sum_{t=1}^{N} w_t \log p_{\theta}(x_t \mid x_{<t}). \tag*{(2)}

Evaluation

Skill-Content-Free Continuation. This suite tests whether the model can complete tasks supported by a generalizable skill when its content is no longer provided. We construct 348 continuation tasks spanning 274 skills, prioritizing broad skill coverage. The suite includes target skills both represented in and absent from the final training corpus, enabling us to assess transfer beyond skills observed during training. We manually review each task to verify the source trajectory, skill categorization, and the validity of the evaluation prefix. Each task provides the base and fine-tuned checkpoints with the same trajectory prefix ending immediately before the target skill call; neither the call nor its returned skill content is provided. Both checkpoints generate up to three assistant rounds, stopping once a round contains no tool call. When a generated round invokes a tool, we replay the next aligned source-recorded tool result rather than execute the tool, so the protocol measures controlled continuation rather than closed-loop success. We evaluate each continuation along two axes. The first is the residual use_skill invocation rate, which measures continued runtime skill invocation when the target skill content is withheld. The second is overall trajectory quality and task completion, which we assess with an LLM-as-a-judge protocol (Zheng et al., 2023) using Claude Opus 4.8; it produces a pairwise preference between the base and fine-tuned continuations, together with a 1–5 score for each (higher is better).

Task-Specific Skill Routing. This suite tests whether fine-tuning preserves the model’s propensity to invoke task-specific skills when they remain necessary at runtime. We construct 228 evaluation tasks spanning 188 task-specific skills that depend on external interfaces, private information, or task-specific resources. Each task uses a prefix from a high-quality trajectory whose recorded continuation invokes, successfully loads, and applies the target skill. The prefix ends immediately before the recorded skill call. We manually review each task to verify the source trajectory, skill categorization, and prefix validity. Each model then generates a single next action. We report three metrics that characterize this routing decision. The call rate is the fraction of tasks on which the model invokes use_skill; its change relative to the base checkpoint indicates whether fine-tuning shifts the model’s propensity to route through skills. The over-internalization rate is the fraction of tasks on which the model instead answers directly or invokes another tool. An increase indicates a shift toward handling the task without invoking the recorded target skill. Among generated use_skill calls, the correct-given-called rate measures how often the model selects the recorded target skill, separating whether to invoke from which skill to select. The call and over-internalization rates use all 228 tasks as the denominator; empty generations count as non-calls. This evaluates routing before skill loading, not subsequent task success.

General Coding Performance. We use SWE-bench Verified (Jimenez et al., [9]; OpenAI, [12]) as an auxiliary benchmark to assess whether fine-tuning preserves general coding performance.

Experiments

Overview

We evaluate SkillCore with Qwen3-8B and an agent-post-trained Qwen2.5-72B checkpoint on two complementary suites: skill-content-free continuation, which measures task performance when target skill content is withheld, and task-specific skill routing. We ask whether scaffold-removed supervision improves task completion while reducing residual skill invocation (RQ1); whether the observed performance gains arise from scaffold removal rather than training on the same trajectories with scaffolding retained (RQ2); how internalization-only training affects task-specific skill routing (RQ3); and how skill-native supervision trades off routing preservation against internalization (RQ4). We additionally examine the effects of corpus construction choices and check general coding performance.

Experimental Settings

All models undergo full-parameter fine-tuning using the Megatron backend (Narayana et al., [11]) and Hermes agent template implemented in ms-swift (Zhao et al., 2025). We use a maximum sequence length of 65,536 tokens, with left truncation retained only as a fallback after template serialization. System, user, and tool-result messages provide context without contributing to the loss, whereas assistant language and tool calls are supervised. We use Adam with an initial learning rate of 10−510^{-5}, cosine decay to 10−610^{-6}, a 5% warmup ratio, weight decay of 0.1, gradient clipping at 1.0, and seed 42. The global batch size is 128 for 8B and 64 for 72B, with a microbatch size of 1. We train the 8B and 72B models for 6 and 3 epochs, respectively. Training uses two nodes, each with eight 141-GB NVIDIA H200 GPUs.

RQ1: Can Scaffold-Removed Supervision Internalize Generalizable Skills?

We evaluate internalization-only models trained exclusively on DremovedD_{\mathrm{removed}}, without skill-native data from DnativeD_{\mathrm{native}}. Table 1 reports their performance on the skill-content-free continuation suite. For Qwen3-8B, the residual skill-invocation rate falls from 16.7% to 2.6%; its continuations win 82.8% of pairwise comparisons against those from the base checkpoint, while the mean judge score increases by 1.23 points (54.4%). For Qwen2.5-72B, residual invocation falls from 33.6% to 0.9%; its continuations win 62.4% of comparisons, with a mean judge-score increase of 0.45 points (16.0%). Across both model scales, scaffold-removed supervision improves task completion quality while substantially reducing residual skill invocation.

ModelTrainingCallOver-int.↓Corr@Call↑Win↑ΔQuality↑Residual↓SWE-b↑
Qwen3-8BBase50.050.089.5––16.74.2
Qwen3-8BScaffold-retaining–––58.9+0.42 (+16.4%)44.55.2
Qwen3-8BInternalization only13.286.893.382.8+1.23 (+54.4%)2.64.4
Qwen3-8BSkillCore52.646.591.775.9+1.00 (+42.8%)19.56.2
Qwen2.5-72BBase65.428.598.7––33.643.4
Qwen2.5-72BScaffold-retaining–––35.1−0.37 (−11.7%)59.545.6
Qwen2.5-72BInternalization only7.089.9100.062.4+0.45 (+16.0%)0.944.8
Qwen2.5-72BSkillCore65.830.395.354.9+0.22 (+7.3%)30.245.0

Table 1. Main results across the base model and three fine-tuning settings. Scaffold-retaining preserves the generalizable-skill scaffolds, whereas Internalization only trains exclusively on DremovedD_{\mathrm{removed}}. Δ\DeltaQuality reports absolute and relative changes in the mean 1–5 judge score against the paired base continuation.

RQ2: Is Scaffold Removal Necessary?

The Scaffold-retaining control uses the same source trajectories and training epochs as internalization-only, but retains the generalizable-skill scaffolds. Compared with scaffold removal, retaining them raises residual invocation from 2.6% to 44.5% for 8B and from 0.9% to 59.5% for 72B, while reducing pairwise win rates from 82.8% to 58.9% and from 62.4% to 35.1%, respectively. It also yields smaller quality changes: +0.42 points (+16.4%) rather than +1.23 (+54.4%) for 8B, and −0.37 (−11.7%) rather than +0.45 (+16.0%) for 72B. Overall, this matched comparison indicates that the gains arise from scaffold removal rather than fine-tuning alone, enabling task completion with far less reliance on external skills.

RQ3: What Routing Cost Does Internalization-Only Training Impose?

The gains on generalizable skills come at a substantial cost to task-specific skill routing (Table 1). On the task-specific routing suite, the call rate drops from 50.0% to 13.2% for 8B and from 65.4% to 7.0% for 72B. Correspondingly, the over-internalization rate rises from 50.0% to 86.8% for 8B and from 28.5% to 89.9% for 72B, as the models respond directly or invoke another tool instead of calling the target skill. Among the relatively few generated skill calls, however, the target skill is usually selected correctly (Corr@Call: 93.3% and 100%). The main degradation therefore lies in deciding whether to invoke a skill, not in selecting which skill to invoke once a call is made. Overall, internalization-only training substantially weakens task-specific skill routing despite preserving conditional selection accuracy.

RQ4: Can Skill-Native Supervision Recover Task-Specific Routing?

We vary the native-to-removed ratio from 0% to 50%, where mixX denotes an X% ratio (Table 2). Increasing this ratio consistently raises task-specific call rates and reduces over-internalization, but also increases residual invocation and generally weakens skill-content-free continuation performance. From no mix to mix50, call rates rise from 13.2% to 66.7% for 8B and from 7.0% to 73.2% for 72B, while residual invocation rises from 2.6% to 27.0% and from 0.9% to 32.2%, respectively. Thus, skill-native supervision recovers routing at the cost of greater dependence on external skills. We use mix25 as the default SkillCore configuration because it most closely matches the base models’ call rates (52.6% vs. 50.0% for 8B; 65.8% vs. 65.4% for 72B), while retaining win rates above 50% and positive judge-score gains.

MetricNo mixmix10mix25mix50
Qwen3-8B
Call13.2%44.3%52.6%66.7%
Over-int.↓86.8%55.3%46.5%32.9%
Corr@Call↑93.3%92.1%91.7%88.2%
Win↑82.8%75.9%75.9%74.7%
ΔQuality↑+1.23+0.95+1.00+0.91
Residual↓2.6%12.4%19.5%27.0%
SWE-b†4.4%4.8%6.2%8.6%
Qwen2.5-72B
Call7.0%60.1%65.8%73.2%
Over-int.↓89.9%36.4%30.3%24.1%
Corr@Call↑100.0%94.9%95.3%93.4%
Win↑62.4%60.1%54.9%54.9%
ΔQuality↑+0.45+0.45+0.22+0.23
Residual↓0.9%21.6%30.2%32.2%
SWE-b†44.8%44.6%45.0%46.8%

Table 2. Routing–internalization trade-off across skill-native mixture ratios. No mix denotes internalization-only training, and mix25 is the default SkillCore configuration. ΔQuality denotes absolute judge-score changes.

Data Scalability

Starting from the core scaffold-removed corpus, we construct two doubled variants. The first adds trajectories whose serialized lengths fit within the 64K context limit, preserving their full content. The second adds trajectories exceeding 64K tokens and left-truncates them to the limit during training. Table 3 compares these variants. Data scaling has little effect on Qwen3-8B: the core and both expanded variants achieve similar win rates (81.3–82.8%) and quality gains (53.1–54.4%). Qwen2.572B benefits more clearly. The ≤\leq64K variant raises the win rate from 62.4% to 71.3% and the quality gain from 16.0% to 24.8%. The left-truncated variant yields smaller improvements (64.7% win and 18.9% quality gain), suggesting that truncation may remove task-relevant context. Both expanded variants increase residual skill invocation, so the additional data improves continuation quality without further reducing runtime skill dependence.

CorpusWin↑ΔQuality↑Residual↓
Qwen3-8B
Core82.8%+1.23 (+54.4%)2.6%
Expanded (≤64K)82.2%+1.21 (+53.1%)6.0%
Expanded (>64K, trunc.)81.3%+1.21 (+54.0%)5.5%
Qwen2.5-72B
Core62.4%+0.45 (+16.0%)0.9%
Expanded (≤64K)71.3%+0.70 (+24.8%)7.5%
Expanded (>64K, trunc.)64.7%+0.54 (+18.9%)12.1%

Table 3. Data scalability results for the core corpus and two doubled variants.

Analysis

Transfer to Skills Absent from the Final Training Corpus. Because some evaluation tasks involve multiple target skills, the 348 tasks correspond to 381 task–skill pairs. Among them, 152 pairs cover 120 target skills absent from the final length-filtered training corpus. For the selected Qwen3-8B internalization-only checkpoint, this zero-frequency group achieves 82.2% pairwise wins, a mean judge score of 3.47, and 2.0% residual invocation. Figure 4 shows consistent quality gains across all frequency groups, including skills absent from the final training corpus. The gains do not increase monotonically with training frequency.

Quality analysis for the selected Qwen3-8B internalization-only checkpoint

Figure 4. Quality analysis for the selected Qwen3-8B internalization-only checkpoint. (a) Mean judge scores of the fine-tuned and base models across target-skill frequency groups; nn denotes evaluated task–skill pairs. (b) Number of tasks by paired judge-score change after fine-tuning.

Paired Quality Gains. The paired distribution in Figure 4 shows broad improvement rather than gains driven by a few outliers. Among the 348 skill-content-free tasks, 282 improve, 11 remain unchanged, and 55 decline. The most common change is a two-point increase, observed on 189 tasks, and the mean change is +1.23. These results indicate a systematic quality improvement.

Judge Consistency. We check whether the pairwise preferences used for the win rate agree with the separately assigned quality scores. In 97.9–98.2% of examples, the preferred continuation also receives the higher score, and 67.5% of comparisons differ by at least two points. A 50-case position-swap audit further shows that changing response order affects judgments mainly when the two scores are close. Thus, the reported win rates are well supported by the scalar quality scores and are not primarily driven by response order.

Conclusion

Motivated by the low utilization of runtime skills, we argue that generalizable skills should be internalized while task-specific skills providing external information remain callable. We present Skill-Core, which removes generalizable-skill scaffolds while preserving task descriptions and subsequent actions, and mixes in a small proportion of skill-native trajectories to retain task-specific skill invocation. SkillCore improves the skill-free response quality of Qwen3-8B and Qwen2.5-72B over their base models by 54.4% and 24.8%, respectively, while preserving task-specific skill invocation and general coding ability. SkillCore thereby makes capabilities delivered through runtime scaffolds intrinsic and available to all users by default.

Limitations

Our evaluation uses one training seed, one deterministic generation per checkpoint, and one Claude Opus 4.8 judgment per task. We therefore do not estimate variation across training runs, generations, or judges, and report point estimates rather than confidence intervals. The continuation suite replays recorded tool results instead of executing generated actions, while the routing suite evaluates only the decision to invoke a skill. Neither suite measures closed-loop task success.

Because the study uses real-world agent trajectories, sharing the data or derived models requires appropriate access controls and privacy review. Full-parameter fine-tuning at long context lengths also requires substantial computation, which may limit reproducibility and practical adoption. These constraints bound our claims to the evaluated models, data distribution, and protocols.

References

  1. [1]Anthropic. 2025. Equipping agents for the real world with agent skills. https://www.anthropic.com/engineering/equipping-agents-for-the-real-world-with-agent-skills.
  2. [2]Anthropic. 2026. Introducing Claude Opus 4.8. https://www.anthropic.com/news/claude-opus-4-8.
  3. [3]Amanda Askell, Yuntao Bai, Anna Chen, Dawn Drain, Deep Ganguli, Tom Henighan, Andy Jones, Nicholas Joseph, Ben Mann, Nova DasSarma, Nelson Elhage, Zac Hatfield-Dodds, Danny Hernandez, Jackson Kernion, Kamal Ndousse, Catherine Olsson, Dario Amodei, Tom Brown, Jack Clark, and 3 others. 2021. A general language assistant as a laboratory for alignment. arXiv preprint arXiv:2112.08681.
  4. [4]Daniil A. Boiko, Robert MacKnight, Ben Kline, and Gabe Gomes. 2023. Autonomous chemical research with large language models. Nature, 624:570–578.DOI
  5. [5]Eunbi Choi, Yongrae Jo, Joel Jang, Joonwon Jang, and Minjoon Seo. 2023. Fixed input parameterization for efficient prompting. In Findings of the Association for Computational Linguistics: ACL 2023, pages 8428–8441.DOI
  6. [6]Zhongxin Guo, Danrui Qi, Hanwen Gu, Peng Cheng, and Yongqiang Xiong. 2026. SKILL-DISCO: Distilling and compiling agent traces into reusable procedural skills. arXiv preprint arXiv:2606.26669.arxiv.org/abs/2606.26669
  7. [7]Zhongyu He, Yuanfan Li, Fei Huang, Tianyu Chen, Siyuan Chen, Xingyang Li, Meng Hsuan Yu, Xiang-grong Liu, Leyi Wei, Lu Pan, Ke Zeng, and Xunliang Cai. 2026. SIRI: Self-internalizing reinforcement learning with intrinsic skills for LLM agent training. In Proceedings of the 2026 Conference on Empirical Methods in Natural Language Processing (EMNLP).
  8. [8]Edward J. Hu, Yelong Shen, Phillip Wallis, Zeyuan Allen-Zhu, Yuntao Bai, Zhi Lin, Sean Wang, Lulu Wang, and Weizhu Chen. 2022. LoRA: Low-rank adaptation of large language models. In International Conference on Learning Representations (ICLR).arxiv.org/abs/2106.09685
  9. [9]Carlos E. Jimenez, John Yang, Alexander Wettig, Shunyu Yao, Kexin Pei, Ofir Press, and Karthik Narasimhan. 2024. Swe-bench: Can language models resolve real-world github issues? In International Conference on Learning Representations (ICLR).arxiv.org/abs/2310.06770
  10. [10]Zhengxi Lu, Zhiyuan Yao, Jinyang Wu, Chengcheng Han, Qi Gu, Xunliang Cai, Weiming Lu, Jun Xiao, Yueting Zhuang, and Yongliang Shen. 2026. SKILL0: In-context agentic reinforcement learning for skill internalization. In Proceedings of the 2026 Conference on Empirical Methods in Natural Language Processing (EMNLP).arxiv.org/abs/2604.02268
  11. [11]Deepak Narayanan, Mohammad Shoeybi, Jared Casper, Patrick LeGresley, Mostofa Patwary, Vijay Anand Korthikanti, Dmitri Vainbrand, Prethvi Kashinkunti, Julie Bernauer, Bryan Catanzaro, Amar Phanishayee, and Matei Zaharia. 2021. Efficient large-scale language model training on GPU clusters using Megatron-LM. In Proceedings of the International Conference for High Performance Computing, Networking, Storage and Analysis, pages 1–15. Association for Computing Machinery.arxiv.org/abs/2104.04473
  12. [12]OpenAI. 2024. Introducing swe-bench verified. https://openai.com/index/introducing-swe-bench-verified/.
  13. [13]Yujia Qin, Shih ao Liang, Yining Ye, Kunlun Zhu, Lan Yan, Yaxi Lu, Yankai Lin, Xin Cong, Xiangru Tang, Bill Qian, Sihan Zhao, Lauren Hong, Runchu Tian, Ruobing Xie, Jie Zhou, Mark Gerstein, Dahai Li, Zhiyuan Liu, and Maosong Sun. 2024. ToolLLM: Facilitating large language models to master 16000+ real-world apis. In International Conference on Learning Representations (ICLR).arxiv.org/abs/2307.16789
  14. [14]Timo Schick, Jane Dwivedi-Yu, Roberto Dessi, Roberta Raileanu, Maria Lomeli, Eric Hambro, Luke Zettlemoyer, Nicola Cancedda, and Thomas Scialom. 2023. Toolformer: Language models can teach themselves to use tools. Advances in neural information processing systems, 36:68539–68551.arxiv.org/abs/2302.04761
  15. [15]Erik Schluntz and Barry Zhang. 2024. Building effective agents. Anthropic Engineering Blog. https://www.anthropic.com/engineering/building-effective-agents.
  16. [16]Charlie Snell, Dan Klein, and Ruiqi Zhong. 2022. Learning by distilling context. arXiv preprint arXiv:2209.15189.arxiv.org/abs/2209.15189
  17. [17]Theodore R Sumers, Shunyu Yao, Karthik Narasimhan, and Thomas L Griffiths. 2024. Cognitive architectures for language agents. Transactions on Machine Learning Research, 2024.arxiv.org/abs/2309.02427

Paper details

vlnc:W_cg6kffqg
Version
v1 · latest
Published
Fresh — added to the Hub within the last 30 days
Added
License
CC BY 4.0
Usage

views · 0

downloads · 0

A view counts once per browser per day, a download each time the PDF is requested.

  • Computer Science

Not recorded for this paper

View statement
Looking for related papers…
Contents