Karpathy's 7 GitHub Repositories, in Order, Are a Free AI Degree
From micrograd to autoresearch, completing these 7 repositories in order is equivalent to doing an AI degree. The cost of training a GPT has fallen from $43,000 in 2019 to $48 today.
Andrej Karpathy, former Tesla AI director and OpenAI founding member, has put a series of projects on GitHub. Someone ordered them and found that these 7 repositories make up a complete AI course—from the most basic backpropagation to an agent that can autonomously run research overnight. 7 repositories, 306,741 stars combined.
Each repository builds on the one before it. Learn them in order; don't skip.
1. micrograd
How do neural networks actually learn? Implement backpropagation in about 100 lines of Python.
This is the starting point and the foundation for understanding everything.
2. nn-zero-to-hero
Video course. Accompanying Jupyter notebooks, from a single neuron to GPT.
github.com/karpathy/nn-zero-to-hero
3. minbpe
How does text become tokens? The tokenizer every LLM must pass through, written in clean, minimal code.
4. nanoGPT
Train and fine-tune your own GPT. The simplest implementation, with no bells and whistles.
5. llm.c
The same training process, but with nothing hidden under the hood. Pure C and CUDA, no PyTorch.
6. nanochat
A complete end-to-end chat model. Training a GPT-2-level model cost about $43,000 in 2019; now, with this repository, about $48.
7. autoresearch
The agent does research automatically. It modifies training code, trains for 5 minutes, keeps the improvements, and repeats overnight.
github.com/karpathy/autoresearch
The above is the practical part. Karpathy also provides video courses—the same AI content actually taught at Stanford—also on GitHub:
Order matters. Some people jump straight to nanoGPT, skip micrograd, and get confused the first time the loss doesn't go down. Start with backpropagation and work up step by step; only then does the whole picture become clear.
There's a reality: most people will bookmark this list and never open it. Those who can run through it completely are already ahead of 90% of bookmarkers.
By the way, the change in the cost of training a GPT from zero to one explains the progress in this field better than any course. In 2019, $43,000. Now, $48.
发布时间: 2026-10-27 14:23