Hacker Courses The online courses programmers keep recommending, ranked from 20 years of public forum comments.
i
CS336: Language Modeling from Scratch
Image: cs336.stanford.edu
#288 overall

CS336: Language Modeling from Scratch

Stanford University

2 recommenders · 2 threads · recommended in 1 year, 2026 · score 1.7

Search for it ↗

Stanford's graduate course on building language models end to end, covering architecture, training, scaling laws, systems and kernel optimization, with assignments. Commenters point to its lecture notes and assignments as the way to learn the full pipeline.

Commenters call it a deep, theory-and-systems-oriented route into LLMs, with one saying the lecture notes made computational bottlenecks much more intuitive.

Machine Learning & AIadvancedfreevideo lectures#language models#llm#scaling laws#pytorch#systems

Recommendations by year

20062026

What commenters said (2)

  1. Strongly recommendsjvican2026in “Train Your Own LLM from Scratch”

    If you're interested in this resource, I highly recommend checking out Stanford's CS336 class. It covers all this curriculum in a lot more depth, introduces you into a lot of theoretical aspects (scaling laws, intuitions) and systems thinking (kernel optimization/profiling). For this, you have to do the assignments, of course... https://cs336.stanford.edu/

  2. Recommendsdanbrooks2026in “I were 17, I'd learn how to build LLMs from scratch”

    I had the same inspiration!

    I spent a days reviewing the lecture notes for CS336: Language Modeling from Scratch - and then trained a nanoGPT-esque model in PyTorch.

    I'd recommend trying it for those who are curious. Computational bottlenecks become much more intuitive when you've looked at the overall process.

Related courses

Keyboard

In the course grid
←↑→↓
Move between courses
Home End
Start / end of row (with Ctrl: first / last)
PgUp PgDn
Jump several rows
Enter
Open course
S
Save / unsave course
1–5
Best, Trending, Hidden gems, Evergreen, Saved
[ ]
Previous / next topic
On a course page
← →
Previous / next course in your list
S
Save / unsave
O
Open the course website
Esc
Back to the grid
Everywhere
/
Search
T
Light / dark theme
?
This help