# self-reflection

self-reflection stores mistakes and operational lessons in local markdown memory so the agent avoids repeated failures.

- skill · `type=skill` · Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, OpenCode, Windsurf (Devin Desktop), Claude.ai · 162 installs · ★ 675 repo stars
- Author: sundial-org
- License: not stated · policy=link-only · description only; the file stays with the author
- Source: https://github.com/sundial-org/awesome-openclaw-skills/tree/HEAD/skills/self-reflection/SKILL.md
- Updated: 2026-03-07
- Security check: automated, 2026-11-16 (text) — no signs of malicious code found.
- HTML: https://affpapa.org/en/nevibecode/skills/self-reflection

## What it does

This tool schedules periodic reviews for coding agents. Triggered during recurring heartbeats or manual inspection via `self-reflection check`, the agent inspects recent steps, reviews saved notes, and logs new solutions with `self-reflection log`.

Lessons live in a markdown log file, while interval states stay inside a JSON config file. You can read previous entries, view metrics, or restart the counter directly from the shell. Your local environment must have both `jq` and `date` installed for the execution scripts to parse files.

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add sundial-org/awesome-openclaw-skills --skill self-reflection -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/self-reflection/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/self-reflection/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add sundial-org/awesome-openclaw-skills --skill self-reflection -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/self-reflection/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add sundial-org/awesome-openclaw-skills --skill self-reflection -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/self-reflection/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install sundial-org/awesome-openclaw-skills skills/self-reflection
```

2. **Manually: put the files in place**
- File: `.github/skills/self-reflection/SKILL.md`

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add sundial-org/awesome-openclaw-skills --skill self-reflection -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/sundial-org/awesome-openclaw-skills --path skills/self-reflection
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/self-reflection/SKILL.md` — The legacy .windsurf/skills/ path still works

### OpenCode

**Skills CLI (Vercel)**
```bash
npx skills add sundial-org/awesome-openclaw-skills --skill self-reflection -a opencode
```

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/sundial-org/awesome-openclaw-skills/tree/HEAD/skills/self-reflection/SKILL.md

## When to use it
- log agent errors together with verified fixes
- run scheduled checks to see if review time arrived
- load previous operational lessons into context
- track review statistics and reset timers

## Example prompts
- Run self-reflection check to see if an update is needed
- Store a fix using self-reflection log "network" "no retry flag" "pass --retry 3"
- Print the last entries with self-reflection read 5

## Similar
- [journal-reflection](https://affpapa.org/en/nevibecode/skills/journal-reflection.md) — skill · 746 installs
- [session-reflection-analysis](https://affpapa.org/en/nevibecode/skills/session-reflection-analysis.md) — skill · ★ 339 repo stars
- [memory-reflect](https://affpapa.org/en/nevibecode/skills/memory-reflect.md) — skill · 1500 installs
- [self-improving-agent](https://affpapa.org/en/nevibecode/skills/pskoett-self-improving-agent.md) — skill · 408 installs
- [self-improvement](https://affpapa.org/en/nevibecode/skills/self-improvement.md) — skill · 2100 installs
- [review-gladiator](https://affpapa.org/en/nevibecode/commands/review-gladiator.md) — command · ★ 78 repo stars

From the same set: [sundial-org/awesome-openclaw-skills](https://affpapa.org/en/nevibecode/by/sundial-org/awesome-openclaw-skills.md) — 37 cards

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
