Install any skill in seconds. Free to start, no credit card required.
Get Started Free →A universal self-improving agent that learns from ALL skill experiences. Uses multi-memory architecture (semantic + episodic + working) to continuously evolve the codebase. Auto-triggers on skill completion/error with hooks-based self-correction.
.claude/skills/self-improving-agent/SKILL.md| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-07 | ✗→✓ | ▲ Improved | 104% | 0% |
| case-02 | ✗→✓ | ▲ Improved | 236% | 0% |
| case-08 | ✗→✓ | ▲ Improved | 383% | 0% |
| case-10 | ✗→✓ | ▲ Improved | 19% | 0% |
| case-11 | ✗→✓ | ▲ Improved | -49% | 0% |
Turn evidence from completed work into a small, auditable behavior change. The default result is a candidate or no change—not an automatic rewrite of skills.
Do not use it for routine session summaries, raw transcript storage, speculative ideas without evidence, or project facts that belong in project documentation.
Every run ends in exactly one state:
candidate: reusable but not yet validated.validated: representative evidence supports the lesson, but no owner change is claimed yet.applied: the validated lesson was installed in one named durable owner with a change reference.rejected: disproved, unsafe, too specific, or obsolete.superseded or rolled_back: an applied/validated lesson was replaced or reverted.no-delta: no reusable behavior change was found.open-question: evidence is insufficient and the missing proof is named.An artifact is not proof of improvement. An applied lesson must change future behavior and have a representative check that demonstrates the change.
Before editing durable guidance, state:
If any item is unknown, capture a candidate and stop before validation or application.
Prefer facts over interpretation. Record only the minimum reusable summary; do not copy transcripts, tool inputs, credentials, private paths, or customer data.
Claude Code failure hooks explicitly enabled with apb init --hooks can call:
bashagent-playbook self-improve
Manual corrections or successes use an explicit summary and evidence label:
bashapb self-improve capture \ --kind correction \ --summary "Verify the current source before relying on cached state" \ --evidence "focused-test"
The CLI stores redacted events and deduplicated candidates under ~/.agent-playbook/self-improvement/. Override the root with AGENT_PLAYBOOK_DATA_DIR or --data-dir.
Keep a candidate only when all are true:
Use apb behavior inbox to inspect the prioritized queue. Repeated evidence increases occurrence count; it does not automatically increase truth. Use apb behavior owners <candidate-id> --repo . for local suggestions, but treat every result as a review candidate rather than an ownership decision.
Choose the smallest proof that can falsify the candidate, encode it as an executable artifact, and run it with apb self-improve eval. See references/eval-artifact.md for the schema and safety boundary.
| Candidate | Minimum proof | |---|---| | Prompt or workflow rule | Representative prompt plus rubric | | CLI/runtime behavior | Focused automated test | | External integration | Live capability check against current docs/runtime | | Safety rule | Negative test showing the unsafe path is blocked | | Repeated heuristic | Multiple independent episodes or explicit human confirmation |
Separate facts, hypotheses, and missing evidence. Structural validation alone does not prove that guidance is semantically current or executable by the host.
Run the artifact first. A baseline scenario is recommended when the previous behavior can be reproduced safely; at least one candidate scenario is required:
bashapb self-improve eval cand-123 --artifact behavior-eval.json apb self-improve review cand-123 \ --decision validate \ --reason "baseline reproduced and candidate scenarios passed" \ --eval-result /path/printed/by/the/eval/command.json
Validation accepts only a passing CLI-generated eval result for the same candidate. It does not claim runtime behavior changed.
Generate a local Behavior Change Proposal before editing the owner:
bashapb behavior proposal cand-123 \ --owner "skill:self-improving-agent" \ --output behavior-proposal.md
The proposal contains the behavior diff intent, eval proof, acceptance criteria, privacy boundary, and rollback plan. It does not edit the owner or create a remote pull request.
After changing exactly one durable owner, record the application separately:
bashapb self-improve review cand-123 \ --decision apply \ --reason "installed after the focused test passed" \ --owner "skill:self-improving-agent" \ --change-ref "commit:abc123"
Other decisions:
bashapb self-improve review cand-123 --decision observe --reason "needs a second episode" apb self-improve review cand-123 --decision reject --reason "project-specific exception"
Apply into the narrowest owner:
Never silently modify repository rules, publish packages, or trigger external actions as a side effect of capture.
Run the representative task after application. Report:
If the new rule does not change the representative behavior, revert or reject it.
Export applied rules and open candidates as Markdown for Obsidian or another local knowledge system:
bashapb self-improve export --output /path/to/vault/Agent/Learning.md
The export is a sink, not the source of truth. Candidate and active-rule state remain structured and auditable in the CLI data directory.
Skills describe judgment; host adapters provide events and actions. Check the current host before claiming support:
apb init --hooks.event wiring depends on each host's current extension API.
undocumented behavior.
Use apb conformance to inspect local-static contracts. A proven distribution or hook configuration does not prove host discovery or runtime invocation; those remain unverified until an observed host run supplies bounded evidence.
See references/learning-lifecycle.md for schemas and adapter contracts. Use evals/cases.json with evals/rubric.md when changing this skill.
| Case | Status | Duration (ms) | Turns | Tokens | Tool calls | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Without | With | Δ | Without | With | Δ | Without | With | Δ | Without | With | Δ | ||
case-06 | pass→pass | 7,674 | 11,463 | +49% | 1 | 1 | 0% | 372 | 2,956 | +695% | 0 | 0 | — |
case-07 | fail→pass | 15,667 | 15,268 | -3% | 1 | 1 | 0% | 1,594 | 3,245 | +104% | 0 | 0 | — |
case-01 | fail→fail | 13,070 | 17,511 | +34% | 1 | 1 | 0% | 1,235 | 2,285 | +85% | 0 | 0 | — |
case-02 | fail→pass | 23,419 | 31,840 | +36% | 1 | 1 | 0% | 1,626 | 5,462 | +236% | 0 | 0 | — |
case-03 | fail→fail | 26,908 | 16,890 | -37% | 1 | 1 | 0% | 2,273 | 2,183 | -4% | 0 | 0 | — |
case-04 | pass→pass | 11,909 | 11,629 | -2% | 1 | 1 | 0% | 1,120 | 2,870 | +156% | 0 | 0 | — |
case-05 | pass→fail | 16,908 | 14,467 | -14% | 1 | 1 | 0% | 1,836 | 3,253 | +77% | 0 | 0 | — |
case-08 | fail→pass | 10,146 | 24,650 | +143% | 1 | 1 | 0% | 705 | 3,408 | +383% | 0 | 0 | — |
case-09 | pass→pass | 11,026 | 13,541 | +23% | 1 | 1 | 0% | 1,505 | 2,969 | +97% | 0 | 0 | — |
case-10 | fail→pass | 17,032 | 2,626 | -85% | 1 | 1 | 0% | 1,833 | 2,184 | +19% | 0 | 0 | — |
case-11 | fail→pass | 30,117 | 7,559 | -75% | 1 | 1 | 0% | 4,200 | 2,138 | -49% | 0 | 0 | — |
case-12 | pass→fail | 19,059 | 11,260 | -41% | 1 | 1 | 0% | 1,978 | 2,187 | +11% | 0 | 0 | — |
case-13 | fail→pass | 10,130 | 10,003 | -1% | 1 | 1 | 0% | 843 | 2,695 | +220% | 0 | 0 | — |
case-14 | pass→pass | 14,031 | 9,022 | -36% | 1 | 1 | 0% | 1,207 | 3,268 | +171% | 0 | 0 | — |
case-15 | fail→fail | 4,745 | 11,368 | +140% | 1 | 1 | 0% | 642 | 2,146 | +234% | 0 | 0 | — |
case-16 | fail→pass | 7,342 | 10,790 | +47% | 1 | 1 | 0% | 1,075 | 2,572 | +139% | 0 | 0 | — |
case-21 | pass→pass | 10,653 | 3,314 | -69% | 1 | 1 | 0% | 978 | 2,374 | +143% | 0 | 0 | — |
case-17 | fail→pass | 13,801 | 4,284 | -69% | 1 | 1 | 0% | 1,837 | 2,502 | +36% | 0 | 0 | — |
case-18 | pass→pass | 12,565 | 12,695 | +1% | 1 | 1 | 0% | 1,949 | 3,253 | +67% | 0 | 0 | — |
case-19 | fail→pass | 23,053 | 17,308 | -25% | 1 | 1 | 0% | 3,110 | 2,520 | -19% | 0 | 0 | — |
case-20 | fail→pass | 17,588 | 10,264 | -42% | 1 | 1 | 0% | 1,992 | 2,636 | +32% | 0 | 0 | — |
case-22 | fail→pass | 26,739 | 4,810 | -82% | 1 | 1 | 0% | 1,900 | 2,378 | +25% | 0 | 0 | — |
case-23 | pass→pass | 8,488 | 10,111 | +19% | 1 | 1 | 0% | 1,067 | 2,462 | +131% | 0 | 0 | — |
case-24 | fail→fail | 9,294 | 10,064 | +8% | 1 | 1 | 0% | 1,415 | 2,704 | +91% | 0 | 0 | — |
DecimalAI ran this skill against gemini-3.6-flash twice over the same eval suite — once with the skill loaded and once without — and compared the two runs case by case. 24 cases were attempted, and 20 counted toward the lift figure. The other 4 produced results that are not comparable between the two arms, so they are excluded from the headline rather than averaged into it. The headline lift of +38 percentage points is the difference between those two pass rates over the 20 comparable cases. 4 cases got worse with the skill loaded, and they are included in that figure.
Without the skill loaded, the model failed this case. With it loaded, the same prompt on the same model passed. This is one improved case from the latest verified run; every case, including any that regressed, is in the table above.
| Model | Method | Date | Lift |
|---|---|---|---|
| gemini-3.6-flash | verified | 8/2/2026 | +55% |
| gemini-3.6-flash | verified | 7/24/2026 | +68% |
Other measured skills in the registry, with their headline benchmark lift.