# Review memories loaded upon Ace wake up **Linear:** MAN-9 — https://linear.app/manglasabang/issue/MAN-9/review-memories-loaded-upon-ace-wake-up **Status:** Done **Project:** junwonhome ## Description Review and optimize what memories are loaded when Ace wakes up. ## Outcome **Load order** ([session-start.sh]()): 1. identity/JUNWON.md 2. identity/ACE.md 3. identity/TOOLS.md 4. identity/GUARDRAILS.md 5. identity/TASK-MANAGEMENT.md 6. identity/core-memories.md 7. last-one-week/\*.md (daily notes, up to 7) 8. last-one-month/\*.md (weekly compilations, up to 4) 9. last-one-year/\*.md (monthly compilations, up to 12) 10. each-past-year/\*.md (annual files, 1 per year) ## Changes Made * [SOUL.md]() merged into [ACE.md](), original deleted * Created `last-one-year/` directory for monthly compilations * Fixed reflection.ts: monthly output → last-one-year/, annual reads from last-one-year/ and outputs to each-past-year/ * Moved session-start inline command to `.claude/hooks/session-start.sh` * [ACE.md]() deduplicated: removed 70-line Tasks section (was duplicate of [TASK-MANAGEMENT.md]()) * [TOOLS.md](): removed meta-explanation filler * Total memory: 6,107 → 4,203 words after Opus review pass ## Automated Compaction Added `checkCompaction()` to reflection.ts. Runs after temporal compilations in the heartbeat. Any file over its word trigger gets rewritten to its target by Opus, which reads ALL memory files first for full context. ## Word Limits | File | \# files | Trigger | Target | Max possible | Compacted | | -- | -- | -- | -- | -- | -- | | [JUNWON.md]() | 1 | 600 | 300 | 600 | 300 | | [ACE.md]() | 1 | 3,000 | 1,500 | 3,000 | 1,500 | | [TOOLS.md]() | 1 | 600 | 300 | 600 | 300 | | [GUARDRAILS.md]() | 1 | 1,000 | 500 | 1,000 | 500 | | [TASK-MANAGEMENT.md]() | 1 | 1,000 | 500 | 1,000 | 500 | | [core-memories.md]() | 1 | 1,000 | 500 | 1,000 | 500 | | last-one-week/ | 7 | 300 | 150 | 2,100 | 1,050 | | last-one-month/ | 4 | 400 | 200 | 1,600 | 800 | | last-one-year/ | 12 | 100 | 50 | 1,200 | 600 | | each-past-year/ | n (1/yr) | 500 | 300 | 500n | 300n | | **Total** | | | | **12,100 + 500n** | **6,050 + 300n** | Target: 10K tokens (\~7,500 words). When total exceeds \~15K tokens, compact everything to targets.