Skip to content

SkillOpt-Sleep Self-Improvement

Lets an agent review past sessions offline and propose gated improvements to its own skills and memory

Stars
18,813
Licence
MIT
Files
1 file

What it does

This skill teaches an AI agent (the dsh agent) to run an offline improvement cycle based on its own past work. It reads recent session logs, finds recurring tasks, replays them, and proposes edits to instruction and skill files, but only keeps a proposal if it scores better on a held-out check. Proposals are staged for review; live files change only when the user explicitly adopts them, and a nightly schedule can be set up.

Great for

  • Developers who run a coding agent daily and want it to learn their preferences over time
  • Teams experimenting with scheduled, self-optimising agent configurations
  • Users who want a reviewed, evidence-based way to update AGENTS.md or SKILL.md files

Skip it if

  • Sensitive projects where session transcripts must not leave the machine: real backends send truncated transcript excerpts to a model provider, so redact or use the mock backend first
  • Users wanting a quick one-off answer: the cycle is multi-stage and can consume significant API budget
  • People without the dsh-skillopt plugin installed, since the skill depends on its skillopt_* tools

Try asking

  • “Make my agent better the more I use it, starting with a dry run on my last week of sessions”
  • “Review my past Claude sessions and distill recurring tasks into proposed skill updates”
  • “Run the sleep cycle with the codex backend and show me the held-out score before adopting anything”
  • “Schedule a nightly self-optimisation run at 03:17 for this project”
Step-by-step guide: how to use SkillOpt-Sleep Self-ImprovementInstall, first run, examples, tips and FAQs

Install in 3 steps

  1. 1

    Download the skill

    The ZIP contains the 1 original files, the MIT licence and an attribution note.

    skillopt-sleep.zip
  2. 2

    Add it to your agent

    Claude Code (all projects)

    mkdir -p ~/.claude/skills && unzip skillopt-sleep.zip -d ~/.claude/skills/

    Claude Code / Agent SDK (this project only)

    mkdir -p .claude/skills && unzip skillopt-sleep.zip -d .claude/skills/

    Claude apps (web/desktop): Settings → Capabilities → Skills → Upload skill, and choose the ZIP.

  3. 3

    Ask for the task

    No special command needed — the agent reads the skill's description and loads it when your request matches. Try one of the prompts above.

Get better results

  • Start with skillopt_status and skillopt_dry_run using the default mock backend, which makes no model calls, to check the plumbing
  • Before adopting, review the held-out baseline versus candidate score and the exact proposed edits in the report
  • For sensitive sessions, export tasks with skillopt_harvest, redact them, mark them reviewed, then replay with the tasks file

What's inside

  • SKILL.md

Redistributed unmodified from microsoft/SkillOpt under the MIT licence. The assessment was drafted with AI from the skill's files on 2026-10-29. Skills can instruct your agent to run code — read SKILL.md and any scripts before installing.