Skills

Karpathy LLM Wiki

Use when building or maintaining a personal LLM-powered knowledge base.

Install

npx skills add Astro-Han/karpathy-llm-wiki --skill karpathy-llm-wiki -g -a claude-code -y
Category
AI and agents
Updated
3mo ago
License
MIT
Context cost
Mediumabout 3,000 tokens
Runs scripts
No, instructions only

What it does

Use when building or maintaining a personal LLM-powered knowledge base. Triggers: ingesting sources into a wiki, querying wiki knowledge, linting wiki quality, 'add to wiki', 'what do I know about', or any mention of 'LLM wiki' or 'Karpathy wiki'.

Karpathy LLM Wiki

Build and maintain a personal knowledge base using LLMs. You manage two directories: raw/ (immutable source material) and wiki/ (compiled knowledge articles). Sources go into raw/, you compile them into wiki articles, and the wiki compounds over time.

Core ideas from Karpathy:

  • "The LLM writes and maintains the wiki; the human reads and asks questions."
  • "The wiki is a persistent, compounding artifact."

Architecture

Three layers, all under the user's project root:

raw/, Immutable source material. You read, never modify. Organized by topic subdirectories (e.g., raw/machine-learning/).

wiki/, Compiled knowledge articles. You have full ownership. Organized by topic subdirectories, one level only: wiki/<topic>/<article>.md. Contains two special files:

  • wiki/index.md, Global index. One row per article, grouped by topic, with link + summary + Updated date.
  • wiki/log.md, Append-only operation log.

SKILL.md (this file), Schema layer. Defines structure and workflow rules.

Templates live in references/ relative to this file. Read them when you need the exact format for raw files, articles, archive pages, or the index.

Initialization

Triggers only on the first Ingest. Check whether raw/ and wiki/ exist. Create only what is missing; never overwrite existing files:

  • raw/ directory (with .gitkeep)
  • wiki/ directory (with .gitkeep)
  • wiki/index.md, heading # Knowledge Base Index, empty body
  • wiki/log.md, heading # Wiki Log, empty body

If Query or Lint cannot find the wiki structure, tell the user: "Run an ingest first to initialize the wiki." Do not auto-create.

The Grounding Invariant

Read the whole SKILL.md on GitHub

More in AI and agents