Hacker ApprovedDepartments

Build an LLM from Scratch

Build an LLM from Scratch by Sebastian Raschka

by Sebastian Raschka

Shares rank 2 of 10 machine learning books by recommenders

Readers say working through it built a real understanding of transformers and backpropagation, and the author made it free to read online.

Readers say working through it built a real understanding of transformers and backpropagation, and the author made it free to read online.

8 people gave an opinion

recommend it
8
criticize it
0
approval share
100%
Each figure is one person. RecommendsCriticizes

Recommended in 5 of 13 months

  1. November 2025: not recommended
  2. December 2025: not recommended
  3. January 2026: not recommended
  4. February 2026: not recommended
  5. March 2026: recommended
  6. April 2026: recommended
  7. May 2026: not recommended
  8. June 2026: not recommended
  9. July 2026: not recommended
  10. August 2026: recommended
  11. September 2026: recommended
  12. October 2026: recommended
  13. November 2026: not recommended (month in progress)

Why it doesn’t carry the badge

  • 8 people recommend itNeeds 10 or more, not met.
  • Nobody criticizes itNeeds 2 to 1 or better, met.
  • Recommended in 5 of 13 monthsNeeds 4 or more, met.

The same three rules apply to every product, and the badge can’t be bought. How the badge works

What people say about it

The reasons people give, with the number of comments that give each one. Open a reason to read what they said.

Why people recommend it

Each mark is one comment

  • Clear explanations of new concepts

    “I think it's an excellent book! One of my barriers in ML is the resources, I find them overcomplicated or too simplistic without a mid term.”

    Comment from 24 Aug 2026 in “I were 17, I'd learn how to build LLMs from scratch”

    “this book is almost perfect. Every new concept is well described and every is well founded.”

    Comment from 26 Oct 2026 in “Sebastian Raschka's from-scratch video course on building reasoning models”
  • Builds real understanding of transformers

    “I feel like I didn’t really understand the transformer mechanism until I worked through that book.”

    Comment from 16 Mar 2026 in “LLM Architecture Gallery”

    “finally getting how back propagation works via autograd etc. was really fun and enlightening”

    Comment from 26 Oct 2026 in “Sebastian Raschka's from-scratch video course on building reasoning models”

Other machine learning books people recommend

The four most recommended other machine learning books, with the same counts for each, so you can compare like for like. The tick on each bar marks the 2 to 1 line the badge needs.

Build an LLM from Scratch by Sebastian Raschka compared with 4 alternatives
ProductRecommendCriticizeApprovalMonthsOwnedBadge
Build a Large Language Model (From Scratch)by Sebastian Raschka160100%8—Approved
Build an LLM from Scratchby Sebastian RaschkaThis page80100%5——
Python Data Science Handbookby Jake VanderPlas80100%2——
The Little Learnerby Daniel P. Friedman and Anurag Mendhekar6275%2——
Probabilistic Machine Learningby Kevin P. Murphy50100%3——
See all 10 machine learning books, ranked

What people said

8 of the 9 comments that mention it, newest first. Each links to the original comment.

“this book is almost perfect. Every new concept is well described and every is well founded.”

RecommendsComment from 26 Oct 2026 in “Sebastian Raschka's from-scratch video course on building reasoning models”

“finally getting how back propagation works via autograd etc. was really fun and enlightening”

RecommendsComment from 26 Oct 2026 in “Sebastian Raschka's from-scratch video course on building reasoning models”

“I made it free to read so anyone can learn”

RecommendsComment from 8 Sep 2026 in “Training a GPT from scratch in C on a RISC-V MCU with no FPU, in 37KB of code”

“I think it's an excellent book! One of my barriers in ML is the resources, I find them overcomplicated or too simplistic without a mid term.”

RecommendsComment from 24 Aug 2026 in “I were 17, I'd learn how to build LLMs from scratch”

“is something amazing that I think anyone who wants to engineer things around LLMs should at least blast through and read”

RecommendsComment from 24 Aug 2026 in “I were 17, I'd learn how to build LLMs from scratch”

“answers your question exactly”

RecommendsComment from 11 Aug 2026 in “Show HN: Needle2: 14MB agentic LLM for phones, wearables, smart home and robots”

“I'm better off reading [2] if I'm looking into that”

RecommendsComment from 6 Apr 2026 in “Show HN: I built a tiny LLM to demystify how language models work”

“I feel like I didn’t really understand the transformer mechanism until I worked through that book.”

RecommendsComment from 16 Mar 2026 in “LLM Architecture Gallery”

Counts come from 1,795,640 Hacker News comments, November 2025 to November 2026. How we count. Report a mistake.