AI · free download

A memory your assistant can’t quietly lose.

Some assistants load one memory file into every conversation and stop loading it at a size limit. Claude Code, for one, loads only the first 200 lines or 25 KB (its memory documentation). Portable memory is a folder of plain-text notes, one small index, and a guard script that tells you when the index is too long or too big, or when it cannot tell.

Free · MIT licence · 55 KB · needs Node.js · no accounts, no network

$ node memory-size-check.mjs --dir example
memory-size-check: OK
  total_bytes: 758
  derived_budget: 6048
  headroom: 5290
(exit 0)

$ node memory-size-check.mjs --dir broken
memory-size-check: CANNOT-CHECK
  why: could not find the heading that separates the protected part from the cuttable part
  This is NOT a pass. The size is UNKNOWN. Fix the cause and run again.
(exit 2)

Real output on Node.js 24, shortened. The grey exit codes are added for you. The second run is an index with nothing in it: the guard refuses to call that fine.

What is in it

Notes, an index, two small scripts.

  1. Notes. One plain text file per thing worth remembering. Text survives every tool change, and git gives you history for free.
  2. The index. One small MEMORY.md that is loaded every time, split in two: rules that always apply (never cut), and one line per note (the only part you may trim, by moving detail into its own note).
  3. The guard. memory-size-check.mjs re-derives the size budget on every run. It checks bytes and lines. Exit 0 means fine, 1 means over, and 2 means it could not check, which is not a pass. It also refuses a mistyped option, a heading it cannot find, and an index with no rules and no notes.
  4. The search. memory-search.mjs finds a note by plain words and prints why it matched. It is not AI search, and it warns when two notes score almost the same.
Try it

Break it on purpose.

You need Node.js, which is free; we tested version 24. Unzip the pack and run these from inside the portable-memory folder. They work in bash and PowerShell; in cmd.exe, skip the lines that start with #. The pack includes a made-up business so you can see it work.

# 1. a healthy memory: OK, exit 0
node memory-size-check.mjs --dir example

# 2. find a note, and see WHY it matched
node memory-search.mjs "how do we quote a job" --dir example/notes

# 3. break it: an index with nothing in it must not pass
mkdir broken
echo "" > broken/MEMORY.md
node memory-size-check.mjs --dir broken

# 4. check the scripts themselves: 59 cases, all must pass (one needs symlinks and may be skipped on Windows)
node test.mjs
Before you use it

What it is, and what it is not.

Search is plain words

It is word matching, not AI search. It works best when notes are named after the words people will search for, and it can be confidently wrong on a paraphrase. So it prints why each note matched and flags near-ties as low confidence.

It does not make an assistant read

It makes the habit cheap and refuses to hide a full index. You still tell your assistant to read the note before changing anything it has touched before, and to write a note when it learns something.

How far it has been tested

We use it on our own notes. The commands above were run on Node.js 24 on Windows. The 59 test cases passed on Node.js 24 on Windows (one skipped) and on Node.js 22 on Linux (all of them). Nothing has been tried on macOS. The 200-line and 25 KB limits are the ones Claude Code documents; set yours with --max-lines and --cliff. Tell us what you find on other setups.

Download

portable-memory.zip

The guard and its tests, the search tool, the index template, a SKILL.md your assistant can read, a made-up example business, and the MIT licence. It contains none of our notes.

SHA-256 c6ea2eb7e1d210bfe6a4b782dba1a8068fa289f8b0eb4affd43f77c0e4138809

Check it on Mac:

shasum -a 256 portable-memory.zip

Check it on Linux:

sha256sum portable-memory.zip

Check it on Windows:

certutil -hashfile portable-memory.zip SHA256

Using it for your business?

Tell us what worked and what got in your way. That is how it gets better.

Tell us how it went