optimize-memory

Converts legacy memory files into granular date-folder ledgers and entries while preserving evidence and chronology.

1|1|Updated Jul 6, 2026
One-click install
npx skills add https://github.com/gabesan21/project-of-projects --skill optimize-memory-gabesan21
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: optimize-memory
Source: https://github.com/gabesan21/project-of-projects/tree/main/.agents/skills/optimize-memory
Command: npx skills add https://github.com/gabesan21/project-of-projects --skill optimize-memory-gabesan21

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Memory files grow into oversized, flat documents that lose structure over time, making it hard to trace what was done, when, and with what proof. This Skill reorganizes them into a granular layout without losing identity, evidence, chronology, or critical decisions. ## Core Features & Use Cases - Convert mode: Moves flat memory files into memory/YYYY-MM-DD/ folders, splits oversized ledgers into one-thing-per-file entries, and indexes them under the ledger's ## Entries section. - Trim mode: Compacts ledgers over 1200 characters and entries over 800 characters by removing repeated plan text and duplicate evidence while preserving commits, PRs, and decisions. - Parallel wave delegation: Distributes conversion work across subagent workers with disjoint write sets, then validates deterministically by comparing commit hashes and field values before and after. - Use Case: During a weekly review, a ledger has grown to 2400 characters mixing delivery notes, telemetry, and decisions. The Skill splits it into a compact ledger plus four evidence-linked entries, verifies no commit hash was lost, and validates wikilinks. ## Quick Start Use optimize-memory to convert the oversized memory files in this project into the granular date-folder layout while preserving all evidence and decisions.

Frequently Asked Questions about optimize-memory

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I split an oversized memory ledger into smaller entries?▼

Use convert mode: move the file into a date folder matching its finished field, reduce the ledger to delivery, verification, and an entries index, then create one entry per thing done with at least one evidence wikilink. Entries are numbered chronologically and capped at 800 characters.

What character limits apply to memory ledgers and entries?▼

Ledgers are capped at 1200 characters and entries at 800 characters, measured with wc -c before writing. A ledger over the cap is holding entry content that should be moved out, and an entry that cannot fit should be split into two entries rather than compressed.

Does memory optimization run inside the kanban workflow?▼

No, it always runs outside the kanban. The memory directory is the scope's own harness, so no card is created, no task branch or PR is opened, and no task is moved during optimization.

How is data loss prevented when converting memory files?▼

A preflight inventory records all frontmatter fields, commit hashes, PR values, and event order. The candidate is compared deterministically against the original: every commit hash and literal field value must still appear, and any loss rejects the candidate and restores the original.

When should memory optimization not be performed?▼

Skip files with missing required fields or ambiguous chronology, which are marked BLOCKED rather than inferred. Flat memory finished before the cutoff date outside the current scope is tolerated legacy, and if no safe gain exists the file is left unchanged.