Analysis updated 2026-05-18
Reproduce the SkillOpt text-space optimization approach on the HotpotQA benchmark.
Train a reusable natural-language skill file to improve a frozen model's question-answering accuracy.
Study how a validation gate can prevent overfitting when optimizing prompts instead of weights.
Deploy a trained skill file into your own QA agent's system prompt.
| joshhu/skillopt-qa | alibaba/omnidoc-tokenbench | arccalc/dwmfix | |
|---|---|---|---|
| Stars | 43 | 43 | 43 |
| Language | Python | Python | Python |
| Setup difficulty | moderate | moderate | easy |
| Complexity | 4/5 | 3/5 | 2/5 |
| Audience | researcher | researcher | general |
Figures from each repo's GitHub metadata at analysis time.
Requires a running OpenAI-compatible chat endpoint, such as a local Qwen model served via vLLM.
This repository is a small, faithful reimplementation of Microsoft's SkillOpt, a research technique for improving AI agents without touching the underlying model. Instead of retraining a language model's internal weights, which is expensive and slow, SkillOpt trains a reusable block of plain natural language text called a skill file, which gets pasted in front of the agent's instructions to make it perform better on a task. This version is built specifically for HotpotQA, a benchmark of multi-step reasoning questions where the answer requires connecting facts from more than one source. The training process borrows ideas from neural network training, using rounds called epochs and small batches, but the thing being updated each round is text, not numbers. After each batch, a second AI model proposes a small, targeted edit to the current skill text. That candidate skill is tested on a held out validation set, and the edit is only kept if it actually improves accuracy, otherwise it is rejected and the optimizer is told not to repeat that idea. This validation gate is meant to prevent the skill from just memorizing the training examples. The only thing produced at the end of training is a single file, best_skill.md, which can be deployed with any compatible chat model by attaching it to that model's system prompt. To run it, you need Python 3.10 or newer, the uv package manager, and access to an OpenAI-compatible chat API endpoint, no GPU-specific packages are required, since the actual model runs elsewhere and this project just talks to it over the network. The default configuration expects a local Qwen model served through a compatible API. The project includes command line tools for downloading the HotpotQA dataset and for running the full training loop, along with a test suite that runs entirely offline using a fake model. The README includes a results table showing that on one experimental run, the optimized skill improved both validation and held out test scores over the seed skill, without changing any model weights, though the authors note the improvement was modest since the base model was already strong on this task.
A research reimplementation of Microsoft SkillOpt that trains a reusable text skill file to improve a frozen AI agent's accuracy on multi-step question answering, without retraining the model.
Mainly Python. The stack also includes Python, uv, OpenAI API.
Use freely for any purpose, including commercial use, as long as you keep the copyright notice.
Setup difficulty is rated moderate, with roughly 1h+ to a first successful run.
Mainly researcher.
This repo across BitVibe Labs
Verify against the repo before relying on details.