Summary

Karpathy proposes replacing RAG-style retrieval with an LLM-maintained persistent wiki: a structured collection of markdown files that the LLM incrementally builds and keeps current as new sources arrive. Unlike RAG, knowledge is compiled once and compounded over time rather than re-derived on every query. The architecture has three layers — immutable raw sources, LLM-owned wiki, and a schema (CLAUDE.md/AGENTS.md) that governs wiki conventions and workflows.

Karpathy 提出用「持久型 wiki」取代 RAG 架構:LLM 主動維護一份結構化的 markdown 知識庫,每次新增來源時更新實體頁、概念頁、交叉引用,而非每次查詢都重新從原始文件合成答案。知識只編譯一次,並隨時間複利累積。

Key Points

  • Core distinction: wiki is a “persistent, compounding artifact” — cross-references already exist, contradictions already flagged, synthesis already done. RAG rediscovers from scratch every query.
  • Three layers: raw sources (immutable), wiki (LLM-owned markdown), schema (CLAUDE.md-style config that disciplines the LLM as a wiki maintainer)
  • Three operations: Ingest (new source → update 10-15 wiki pages), Query (search wiki → synthesize → file valuable answers back as new pages), Lint (periodic health check for contradictions, orphans, stale claims)
  • Navigation files: index.md (content catalog by category, LLM reads first on every query), log.md (append-only chronological record, parseable with grep)
  • Why it works: LLMs eliminate the maintenance burden that causes humans to abandon wikis. Bookkeeping cost is near zero; humans focus on sourcing and asking good questions.
  • Lineage: Vannevar Bush’s 1945 Memex — private, curated, associative trails. The missing piece was who does the maintenance; LLMs solve that.
  • Tooling: Obsidian as IDE, qmd for local BM25/vector search at scale, Marp for slides, Dataview for frontmatter queries

Insights

  • The vault itself (this repo) is an instantiation of exactly this pattern: Clippings/ = raw sources, ai/ = LLM-compiled wiki, CLAUDE.md = schema. The key gap Karpathy identifies — filing Q&A answers back into the wiki — is precisely what /qa-vault closes.
  • Karpathy’s index.md maps directly to vault-index.md here. His log.md has no current equivalent — could be valuable to add.
  • The “Lint” operation is now /lint-vault. Karpathy frames this as a first-class operation, suggesting it should run regularly (weekly cron), not just on-demand.
  • The schema (CLAUDE.md) co-evolving with the LLM over time is the highest-leverage element — it’s what makes the LLM a “disciplined wiki maintainer rather than a generic chatbot.”

Connections

Raw Excerpt

This is the key difference: the wiki is a persistent, compounding artifact. The cross-references are already there. The contradictions have already been flagged. The synthesis already reflects everything you’ve read. The wiki keeps getting richer with every source you add and every question you ask.