diff --git a/.claude/commands/evolve.md b/.claude/commands/evolve.md index 7595b62..2277114 100644 --- a/.claude/commands/evolve.md +++ b/.claude/commands/evolve.md @@ -22,6 +22,26 @@ Measure (don't edit content): - `memory/cog-meta/patterns.md` - Any domain satellite pattern files (e.g. `work/*/patterns.md`) +## Orientation (run FIRST, before any file reads) + +Use these shell commands to see exactly what changed since last run: + +```bash +# What did housekeeping and reflect change recently? +git diff HEAD~1 --stat memory/ + +# Detailed diff of architectural files (what you care about) +git diff HEAD~1 memory/cog-meta/patterns.md memory/hot-memory.md CLAUDE.md + +# What changed in the last 24h? +find memory/ -type f -name "*.md" -mtime -1 | sort + +# Current prompt weight components (quick file sizes) +wc -c memory/hot-memory.md memory/cog-meta/patterns.md memory/cog-meta/briefing-bridge.md 2>/dev/null +``` + +Use git diffs to understand what housekeeping/reflect actually did, instead of re-reading entire files. + ## Process ### 1. Architecture Review diff --git a/.claude/commands/housekeeping.md b/.claude/commands/housekeeping.md index 515c1e2..b748e5e 100644 --- a/.claude/commands/housekeeping.md +++ b/.claude/commands/housekeeping.md @@ -1,5 +1,23 @@ Use this skill to perform memory housekeeping. Trigger if the user says "housekeeping", "clean up memory", "prune memory", "archive old data", or similar maintenance requests. +## 0. Orientation (run FIRST, before any file reads) + +Use these shell commands to scope your work before reading files: + +```bash +# What changed since last run? Focus here first. +find memory/ -type f -name "*.md" -mtime -1 | sort + +# Quick entry counts for archival threshold checks (>50 = archive) +# Add paths for any domain observations files that exist +grep -c "^- " memory/cog-meta/self-observations.md memory/personal/observations.md memory/*/observations.md memory/*/*/observations.md 2>/dev/null + +# Completed action items count (>10 = archive) +grep -c "^\- \[x\]" memory/personal/action-items.md memory/*/action-items.md memory/*/*/action-items.md 2>/dev/null +``` + +Only read files that need work based on these results. Skip unchanged files. + ## 1. Garbage Collect Memory Review and archive stale data per CLAUDE.md glacier rules. All glacier files must have YAML frontmatter. diff --git a/.claude/commands/reflect.md b/.claude/commands/reflect.md index 3dd2f9e..8214d2a 100644 --- a/.claude/commands/reflect.md +++ b/.claude/commands/reflect.md @@ -11,6 +11,23 @@ If you spot issues in these files, note them in self-observations and evolve wil Self-improvement — pattern recognition, memory maintenance, knowledge base quality. +## Orientation (run FIRST, before any file reads) + +Use these shell commands to scope your work before reading files: + +```bash +# What changed since last run? Focus here. +find memory/ -type f -name "*.md" -mtime -1 | sort + +# L0 summaries for all domains — quick routing without opening INDEX.md files +grep -rn "