rem-sleep — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited rem-sleep (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
Like biological REM sleep, this skill processes raw experience (session logs) into consolidated long-term memory.
Works with: OpenClaw, Claude Code, or any agent with session logs and memory files.
Periodic "sleep cycles" that:
Process recent session logs → extract significant events → update MEMORY.md
Review MEMORY.md → remove stale/outdated entries → merge duplicates → compress
Run both consolidate then defrag.
Option A: Using grep/jq (no extra software)
# OpenClaw session logs location
SESSIONS_DIR="$HOME/.openclaw/agents/main/sessions"
# Search for patterns in recent sessions
grep -r "decision\|learned\|important\|remember\|TODO" "$SESSIONS_DIR" --include="*.jsonl" | head -100
# Parse JSONL and search content
find "$SESSIONS_DIR" -name "*.jsonl" -mtime -3 -exec cat {} \; | \
jq -r 'select(.content) | .content' 2>/dev/null | \
grep -i "decision\|learned\|important"Option B: Using Repo Prompt (if installed)
# More powerful semantic search
rp -e 'search "decision" --context-lines 2'
rp -e 'search "learned" --context-lines 2'
rp -e 'search "important" --context-lines 2'Option C: Using memory_search (OpenClaw built-in)
If your agent has the memory_search tool, use it to semantically search memory files:
memory_search("decisions made this week")
memory_search("lessons learned")From search results, look for:
Two-tier system:
memory/YYYY-MM-DD.md): Raw events, specific detailsConsolidation prompt:
Review these session excerpts. Extract significant information that should be remembered long-term. Focus on: decisions, facts about people/projects, lessons learned, and preferences. Format as bullet points suitable for MEMORY.md.
Read MEMORY.md and identify:
STALE: [entry] — reason it's outdated
DUPLICATE: [entry A] ≈ [entry B]
INCONSISTENT: [entry A] vs [entry B]
BLOAT: [verbose entry] → [compressed version]Ensure MEMORY.md has logical sections:
Recommended cadence:
Trigger options:
# Native search (no dependencies)
grep -r "pattern" ~/.openclaw/agents/main/sessions --include="*.jsonl"
# With Repo Prompt
rp -e 'search "PATTERN" --context-lines 2'
# Helper script (if using Repo Prompt)
./scripts/gather-sessions.sh [days_back]rem-sleep/
├── SKILL.md # This file
├── README.md # GitHub readme
└── scripts/
└── gather-sessions.sh # Helper script (requires Repo Prompt)PRs welcome! Ideas for improvement:
GitHub: https://github.com/stewnight/rem-sleep-skill
~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.