feat(pipeline): add Unix toolbox orientation to pipeline skills
- Add Orientation sections to housekeeping, reflect, evolve with shell commands (find -mtime, grep -c, git diff, wc -c) for efficient scoping - Update CLAUDE.md memory retrieval to use domain-scoped L0 grep Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -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
|
||||
|
||||
@@ -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.
|
||||
|
||||
@@ -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 "<!-- L0:" memory/ --include="*.md" | grep -v glacier/ | sort
|
||||
|
||||
# Entry counts for files approaching archival threshold
|
||||
grep -c "^- " memory/cog-meta/self-observations.md memory/personal/observations.md memory/*/observations.md memory/*/*/observations.md 2>/dev/null
|
||||
```
|
||||
|
||||
Focus on recently-changed files. Skip files that haven't been modified since last run.
|
||||
|
||||
## Memory Files
|
||||
|
||||
Read these files on activation:
|
||||
|
||||
Reference in New Issue
Block a user