Back to all posts
Applied AI June 12, 2026 5 min read

Karpathy's LLM Wiki versus a vector store: two ways to give an AI a memory

Karpathy hands the AI a wiki of markdown files and lets it compile knowledge into pages. I hand it a vector store of atomic notes and let it search by meaning. Same goal, opposite bet.

Earlier this year Andrej Karpathy posted a gist describing what he calls an LLM Wiki, and it spread fast, for good reason. It is the cleanest answer going to a real problem. How do you give an AI a memory that compounds instead of starting from zero every session. I run a different design for the same job, the vector-store knowledge base I wrote about in the last post. They chase the same goal and make opposite bets on how to get there. Here is an honest comparison, including where mine loses.

What Karpathy's LLM Wiki is

The structure is three layers. A raw folder of source material the agent reads but never edits. A wiki folder of markdown files the agent owns completely, full of entity pages, concept pages, and summaries. And a schema file that tells the agent how to keep the wiki tidy.

The clever part is what happens when a new source comes in. The agent does not just file it. It reads it, pulls out what matters, and edits the wiki to absorb it. It updates entity pages, revises summaries, adds cross-links, and flags anything that contradicts what was already there. His framing is knowledge as compiled code. You compile the understanding once into pages and stop re-deriving it from scratch on every question.

Retrieval is plain. The agent reads an index file that lists every page, opens the ones that look relevant, and follows the wiki links between them. No embeddings, no vector search. At the scale he describes, a few hundred pages, that is enough.

What I run instead

My knowledge base makes the opposite choice at almost every step. Instead of pages, it stores atomic notes, one fact or one decision each, every one stamped with where it came from and how sure I am of it. Instead of the agent reading an index and opening files, it runs a search that blends meaning and keywords and returns the most relevant notes ranked, even when none of the words match. Nothing is compiled into a page ahead of time. The synthesis happens fresh each time the AI pulls the relevant notes and reasons over them.

The trade is real. The wiki pre-builds the answer. The vector store finds the pieces on demand.

Where they agree

These are cousins, not opposites in spirit.

  • Both are maintained by the AI, not by hand. The human curates the sources and asks the questions. The agent does the filing.
  • Both separate immutable raw material from the derived layer built on top of it.
  • Both exist to make knowledge compound across time instead of being re-derived on every query.

The argument is not about whether to let the AI keep a memory. It is about what shape that memory should take.

Where they split

  • Substrate. His is plain markdown files in a folder. Mine is a database behind a server. Files you can read, diff, and carry anywhere. A database you have to query.
  • Retrieval. He navigates: read the index, open a page, follow a link. I search by meaning and rank the hits. Navigation is precise when you know the page exists. Search wins when you do not.
  • Shape of a fact. He compiles facts into pages that get rewritten over time. I keep each fact atomic with its own source. Compiling reads better. Atomic keeps the provenance of every single claim intact, which matters a lot when a later decision rests on who said something and how sure they were.
  • Scale. Reading an index and opening pages is fine at a few hundred. Ranked search holds up into the thousands without pulling the whole brain into context just to find one thing.
  • Contradictions. His agent flags them when a source arrives. Mine surfaces them at query time and leans on me to clean house. His is the more proactive design here.

So which one wins

There is no single winner, because they are tuned for different readers.

If the reader is a person, and what you want is a durable, browsable research artifact you fully own, Karpathy's wiki wins, and it is what I would tell most people to start with. Plain markdown has no lock-in, survives any tool change, costs nothing to run, and you can read the whole thing in a text editor. For a personal knowledge base that is hard to beat.

Here is a concrete case for why a person would rather read the pages than just ask questions. Say I have been off a project for two weeks and I open it back up on a Monday. If all I have is a question box, I can only get back what I know to ask for, and the things most likely to burn me are the ones I have already forgotten. I will not ask about the constraint I no longer remember exists. Reading is different. I open the project index, work down the entity and design pages, and the whole shape comes back, including the decision from week one that quietly governs the thing I am about to change. The wiki shows me what I was not looking for. The question box only answers what I aim at.

That is the real divide on the human side. Asking specific questions is the right tool when I already know the territory and I want one fact out of it fast. Reading the pages is the right tool when I need to rebuild the territory in my own head, whether I am onboarding, picking work back up, reviewing a design before a client call, or handing the project to someone who has never seen it. A person browsing builds a mental model. A person querying collects answers that tend to evaporate by the next morning. For that kind of understanding, a stack of well-kept pages beats the fastest search every time.

If the reader is an AI agent that has to pull the one relevant decision out of thousands, across long projects, without being told which page to open, the vector store wins. Ranked search by meaning, and a stamped source on every note, matter more in that setting than a clean page does. That is the setting I work in, which is why I built it the way I did.

The honest end of it is that this is a split between substrate and retrieval, not a real either-or. The strongest design probably keeps Karpathy's durable markdown as the source of truth and puts a search index on top of it. His method is the better default. Mine earns its extra complexity only when an AI has to do the remembering at scale, where handing back the wrong memory is worse than working a little harder to find the right one.

Building an AI memory for real work and unsure which way to jump? That choice is worth thinking through before you commit. admin@westarkdata.com.