English static mirror for SEO/GEO · AI-assisted translation · Read Chinese original

Microsoft SkillOpt Explained: Training AI Agent Skills Like Deep Learning Weights

Forum topic · ✨步子哥 · 2026-06-10

Summary

SkillOpt, a research paper from Microsoft Research with collaborators, treats an AI agent's skill document (a natural-language strategy file injected into the agent's context) as the trainable "external parameters" of a frozen model, and optimizes it with the rigor of a deep learning optimizer. The system introduces five mechanisms: trajectory-based forward passes, minibatch reflection over failures and successes, bounded text updates (a text learning-rate budget with cosine decay), strict holdout validation gating plus a rejected-edit buffer for negative feedback, and epoch-level slow/meta updates. Evaluated across 6 benchmarks (SearchQA, SpreadsheetBench, OfficeQA, DocVQA, LiveMathematicianBench, ALFWorld), 7 models (GPT-5.5 family and Qwen variants), and 3 execution frameworks, SkillOpt lifts GPT-5.5's average score from 58.8 to 82.3 (+23.5), with SpreadsheetBench up +38.9 and OfficeQA up +39.0. Smaller models benefit most—GPT-5.4-nano roughly doubles on DocVQA and ALFWorld. Optimized skills are compact (379–1,995 tokens), auditable, editable, and transfer across models and even execution frameworks (Codex to Claude Code: +59.7). Code is open-sourced on GitHub.

Key points

  • Core idea: SkillOpt treats an agent's skill document—a natural-language file inserted into the agent's context (system prompt prefix, or a persisted SKILL.md in tool-calling frameworks)—as the trainable "external parameters" of a frozen model, optimizing it like deep learning weights.
  • Analogy to deep learning: trainable state = skill doc; optimizer = a separate optimizer LLM; gradients = execution trajectories + scores; learning rate = a text learning-rate budget; early stopping = holdout validation gating; momentum = slow/meta updates.
  • Paper: "SkillOpt: Executive Strategy for Self-Evolving Agent Skills" — arXiv: https://arxiv.org/abs/2605.23904 — Open source (MIT): https://github.com/microsoft/SkillOpt (5.5k stars)
  • Why existing approaches fall short

    The post contrasts three mainstream approaches to skill/prompt optimization, all lacking deep-learning-optimizer properties:

    1. Hand-written prompts — limited expert coverage, no systematic iteration from feedback, must be redone per domain/model. 2. One-shot LLM prompt generation — no iterative refinement, unpredictable quality, poor robustness. 3. Self-evolution (Reflexion, Voyager, etc.) — uncontrolled, non-reproducible, prone to overfitting to local failure modes.

    Five core mechanisms

    1. Forward pass: the target model executes tasks on the training split, recording full trajectories (messages, tool calls, observations, outputs, validator feedback). Multiple batches can accumulate before an update. 2. Backprop (minibatch reflection): trajectories are grouped into failed/successful batches (default size 8). Failure-driven reflection proposes corrective edits; success-driven reflection preserves effective behavior. Edits are hierarchically merged, prioritizing failure corrections; 16 analysis workers run in parallel by default. 3. Bounded text updates: a text learning-rate budget limits edits per step (preventing destructive rewrites), with constant/linear/cosine/autonomous schedules; some fields are "slow-update protected." 4. Validation gating + rejected-edit buffer: a candidate skill is accepted only if it strictly beats the current skill on a held-out selection set; rejected edits and their failure modes go into a buffer that steers subsequent reflection away from repeated mistakes. 5. Epoch-level slow/meta updates: after each epoch, outcomes are classified (improved/regressed/persistent-failure/stable-success) and durable domain knowledge is written to protected fields; an optimizer-side "meta-skill" records cross-epoch editing patterns but is not deployed, keeping deployment artifacts compact and auditable.

    Experimental results

  • Scale: 6 benchmarks (SearchQA, SpreadsheetBench, OfficeQA, DocVQA, LiveMathematicianBench, ALFWorld), 7 models (GPT-5.5, GPT-5.4, GPT-5.2, GPT-5.4-mini/nano, Qwen3.5-4B, Qwen3.6-35B-A3B), 3 execution frameworks (direct chat, Codex CLI, Claude Code CLI) — 52 evaluation units.
  • GPT-5.5 gains: SpreadsheetBench 41.8→80.7 (+38.9), OfficeQA 33.1→72.1 (+39.0), LiveMathematicianBench 37.6→66.9 (+29.3), SearchQA only +2 (baseline already high; skills add process, not recall). Average: 58.8→82.3.
  • Small models gain most: GPT-5.4-nano roughly doubles on DocVQA (30.8→80.2) and ALFWorld (34.3→69.4); Qwen3.5-4B jumps +50.7 on ALFWorld. Suggests "small model + skill" can substitute for larger models.
  • Cross-framework transfer is striking: a skill optimized under Codex transferred to Claude Code yielded +59.7 (even beating in-domain optimization); reverse transfer +43.6 — skills encode general process knowledge, not framework-specific commands.
  • Artifact properties: optimized skills span 379–1,995 tokens (median ~920); median of 2.5 accepted edits per run — one accepted edit once delivered +39 points. Learned rules are procedural, general, and actionable.
  • Comparisons and limitations

  • vs. TextGrad: TextGrad is a general text-space autodiff framework with no standalone deployable artifact or explicit validation gating; SkillOpt produces a deployable best_skill.md with strict gating and negative feedback.
  • vs. EvoSkill: EvoSkill optimizes a skill library via Pareto-frontier filtering; SkillOpt optimizes a single compact skill with stronger training-stability guarantees.
  • Limitations: (1) requires scored feedback and automatic verifiers — poor fit for subjective/creative tasks (strong-model-as-judge is an open direction); (2) training costs ~0.6–3.6 M tokens per test-point gain (~$6–$36 per point at GPT-5.5 API prices), paid once and amortizable across transfers; (3) single-skill scope may not cover highly heterogeneous domains (skill libraries/routing are future work).
  • Practical guidance (from the post)

  • Best-fit tasks: process-heavy work (strict formats, tool-call protocols), multi-step reasoning (math, code), embodied decision-making, cross-model/framework deployment.
  • Poor fit: creative generation, one-off tasks where training cost can't be amortized.
  • For teams: start with process tasks, version skills in Git, add human audit (optimizers can produce biased rules), and build an internal skill library.
  • Quick start: pip install skillopt, then python scripts/train.py --config configs/searchqa/default.yaml --optimizer_model gpt-5.5 --target_model gpt-5.5, producing a deployable best_skill.md.

Takeaway

SkillOpt formalizes prompt engineering as systematic, feedback-driven optimization: skill documents become trainable, auditable, reproducible, and transferable agent assets rather than hand-tuned one-off prompts. Training-time-only costs, near-zero deployment overhead, and demonstrated cross-model/cross-framework transfer make it a notable milestone for agent development.

Tags

#ai-agents#microsoft#skillopt#prompt-optimization#llm#self-evolving-agents#machine-learning#open-source

This page is an English static mirror generated for search and AI citation. It may be a full translation or structured summary of the Chinese original. Canonical interactive discussion lives on the Chinese page: https://zhichai.net/topic/177981060