Every Claude Code session normally starts from zero. You re-explain the codebase, the conventions, the decisions you already made, the footgun you hit last week. The model is sharp but amnesiac. I got tired of paying that tax every morning, so I built Trove: a personal, file-based memory index that Claude Code reloads into context at the start of every session.
First principles
- A Claude Code session knows only what is in its context window. Nothing carries over to the next session unless something puts it back.
- Context is finite, and everything loaded at startup is paid for in every session. Loading a whole memory store each time does not scale.
- So durable memory has to live outside the model, on disk, and loading has to be selective: a small map that is always loaded, with the details opened only when they are needed.
- Memory can be wrong or go stale. A person has to be able to read, fix and delete it without special tools, which points to plain files.
The rest of the design follows from those four constraints.
One fact, one file
A memory you cannot read or edit by hand is a black box. Trove keeps every durable fact as a single file on disk, so the whole store is portable, greppable, diffable, and yours. There is no database, no service, no lock-in. Claude picks the format by the shape of the content: Markdown for prose like decisions and gotchas, JavaScript Object Notation (JSON) for structured context like mappings and configuration.
~/.claude/trove/
INDEX.md # one line per entry, newest first
entries/
use-pgx-not-orm.md # prose -> Markdown
service-ports.json # structured -> JSON
staging-db-mirror.md
A prose entry carries frontmatter and a body. The body links to related entries with double brackets, so the trove becomes a small wiki of your own decisions.
---
title: Use pgx + sqlc, not a heavy ORM, in Go services
slug: use-pgx-not-orm
type: decision
created: 2026-06-13
tags: [go, postgres, data-layer]
---
We standardised on pgx for the driver and sqlc to generate type-safe
query code from plain SQL. GORM was rejected for hiding query cost.
**Why it matters:** reach for this on any new Go service.
**Related:** [[deploy-single-binary]]
The index is the engine
What makes this cheap is INDEX.md. It is the only thing loaded into context at session start: one compact line per entry, so the model knows everything it has without paying to load every full file. Recall then scans that index and opens only the few entries that matter, instead of dumping the whole store into the prompt.
The index is also the human-readable map. You can skim and prune it like a notebook’s table of contents, and each one-line hook is written to match how you would later ask for it. That single file is the difference between a pile of notes and a memory you can actually use.
Packaged as a Claude Code plugin
Trove ships as an installable plugin, so the workflow travels with you. The first version bundled three skills and a SessionStart hook. The skills are namespaced, and the hook reloads the index every time a session starts.
/plugin marketplace add anishfyi/trove
/plugin install trove@velofy-trove
/reload-plugins # a fresh plugin is not live until you reload
/trove:init # scaffold ~/.claude/trove
The marketplace was called anishfyi-trove when this post was first written. It was renamed to velofy-trove on 12 September 2026, so the install line above uses the current name.
From there, “remember this” captures an entry and “what do I know about X” recalls it. The skills trigger on intent, so most of the time you never type the command at all. A few packaging details cost me time: skills inside a plugin are addressed as /plugin:skill, hooks belong in hooks/hooks.json and are referenced through ${CLAUDE_PLUGIN_ROOT}, and a renamed repository leaves GitHub Pages in an error state until you trigger a fresh build.
Since then, version 0.2.0 added /trove:index and /trove:query, a SessionEnd reminder hook, and a Rust engine that indexes a whole repository. The Trove documentation covers both layers.
What is worth remembering
A memory is only useful if it is curated. Trove is opinionated about what earns a file.
- Save: decisions and their rationale, gotchas and footguns, conventions you expect Claude to follow, external references like dashboards and tickets, and project constraints that are not obvious from the code.
- Skip: secrets, transient task state, and anything easy to re-derive from the codebase or Git history. If a fact is one of those, capture what was non-obvious about it instead.
Why it compounds
Teach it something once and it knows it for good. You stop re-explaining the repository, you stop repeating the same mistake, and past decisions are one recall away, so you do not re-argue them. A new machine, or a teammate on a project-scope trove, inherits all of it at once. The longer you use it, the more leverage it has, because each session begins further ahead than the last.
Trove is open source under MIT at github.com/anishfyi/trove, with documentation at velofy.co/trove. It pairs naturally with Querion, which reads a Trove-built semantic layer to answer data questions in your own business language.