可复用技能引导大语言模型(LLM)智能体处理重复请求,但每次调用仍需模型解释技能并重构其编排。智能体能否在无人工干预的情况下将这种编排编译为可执行的快速路径?我们首先研究零样本技能专业化,该方法无需执行证据即可编译,结果发现尽管技能有过程指导,但对运行时绑定的错误假设会导致生成的计划脆弱,恢复成本高昂。这促使我们提出SkillCache,一种单轨迹技能专业化方法,它将已完成的调用编译为程序和自然语言步骤的参数化胶囊,在复用前重放该胶囊,并由计划执行器驱动,仅在需要时将控制权返回给模型,同时保留源技能用于恢复。借助Claude Code工具,在87项SkillsBench任务上,相同请求的预热执行在奖励相当的情况下,Claude Sonnet 4.6可减少81%的令牌使用量,Claude Opus 4.8可减少74%,且胶囊在受控请求变化下仍保持有效。胶囊还可跨模型迁移,使三个开源权重模型的平均奖励提升12-25个百分点,同时令牌使用量减少72-81%,这表明执行基础编译是高效重复技能使用和跨模型迁移的有前景方法。
英文摘要:
Reusable skills guide large language model (LLM) agents through recurring requests, but each invocation still requires the model to interpret the skill and reconstruct its orchestration. Can agents automatically compile this orchestration into an executable fast path without human intervention? We first study zero-shot skill specialization, which compiles without execution evidence, and find that despite the skill's procedural guidance, incorrect assumptions about runtime bindings can make generated plans brittle and recovery costly. This motivates SkillCache, a one-trace skill specialization method that compiles a completed invocation into a parameterized capsule of programs and natural-language steps, replays it before reuse, and drives it with a plan executor that returns control to the model only when needed, keeping the source skill for recovery. With the Claude Code harness, warm execution of the same request reduces tokens on 87 SkillsBench tasks by 81% with Claude Sonnet 4.6 and by 74% with Claude Opus 4.8 at comparable reward, and capsules stay effective under controlled request changes. Capsules also transfer across models, raising three open-weight models' mean reward by 12-25 percentage points while reducing their tokens by 72-81%, suggesting that execution-grounded compilation is a promising approach to efficient repeated skill use and cross-model transfer.
MS-Eval: Benchmarking Sub-Agent Delegation and Orchestration in MCP-Intensive Working Scenarios
Zhejiang University(浙江大学);School of Engineering, Westlake University(西湖大学工程学院);Institute of Advanced Technology, Westlake Institute for Advanced Study(西湖高等研究院先进技术研究院)
From Failed Trajectories to Reliable LLM Agents: Diagnosing and Repairing Harness Flaws
State Key Laboratory of Complex System Modeling and Simulation Technology(复杂系统建模与仿真技术国家重点实验室);Institute of Software, Chinese Academy of Sciences(中国科学院软件研究所);University of Chinese Academy of Sciences(中国科学院大学);School of Computer Science and Technology, Tianjin University(天津大学计算机科学与技术学院)