#1414th of 14 in Learning and cookbooks

hands-on-large-language-models

Companion notebooks for the O'Reilly book Hands-On Large Language Models

Stars
29.6k
License
Apache-2.0
Last commit
Apr 2026
Language
Jupyter Notebook
Stars, last 29 weeks+5,493
24 Mar 2026: 24,095 stars31 Mar 2026: 24,370 stars7 Apr 2026: 24,614 stars14 Apr 2026: 24,812 stars21 Apr 2026: 25,066 stars28 Apr 2026: 25,227 stars5 May 2026: 25,706 stars12 May 2026: 26,013 stars19 May 2026: 26,190 stars26 May 2026: 26,325 stars2 Jun 2026: 26,558 stars9 Jun 2026: 26,707 stars16 Jun 2026: 26,906 stars23 Jun 2026: 27,050 stars30 Jun 2026: 27,151 stars7 Jul 2026: 27,282 stars14 Jul 2026: 27,445 stars21 Jul 2026: 27,607 stars28 Jul 2026: 27,752 stars4 Aug 2026: 27,877 stars11 Aug 2026: 28,093 stars18 Aug 2026: 28,200 stars25 Aug 2026: 28,532 stars1 Sept 2026: 28,763 stars8 Sept 2026: 28,925 stars15 Sept 2026: 29,081 stars22 Sept 2026: 29,214 stars29 Sept 2026: 29,384 stars6 Oct 2026: 29,507 stars13 Oct 2026: 29,588 stars

24,095 on 24 Mar 202629,588 on 13 Oct 2026

From GitHub's daily star counts.

Checked on GitHub.

Overview

Code for every example in the book by Jay Alammar and Maarten Grootendorst, as one Jupyter notebook per chapter. Chapters cover tokens and embeddings, transformer internals, classification, clustering, prompt engineering, semantic search and RAG, multimodal models, and fine-tuning. Notebooks were built and tested on Google Colab with a free 16GB T4 GPU.

Who it is for: Developers learning how LLMs work who want runnable chapter code

Strengths

  • One notebook per chapter (12), each with an Open in Colab link
  • Covers embeddings, RAG, multimodal models and fine-tuning of BERT and generation models
  • Tested mainly on free Colab T4 16GB, so no local GPU is required
  • Bonus folder links to visual guides on Mamba, quantization and mixture of experts

Weaknesses

  • Explanatory text and figures are in the paid book, not in the repo
  • Local setup is only a quick-start guide; results may differ by OS and versions
  • No tagged releases; README states no pinned package versions
  • Not a library or tool, only teaching code

What it needs

  • GPU optional
  • Needs Google Colab, Jupyter, PyTorch

Also in Learning and cookbooks

See all 14
Also in Learning and cookbooks
RankProjectScore
1ai-engineering-from-scratchHands-on curriculum for building AI systems from math to agents68.9k starsMIT82 out of 100
2generative-ai-for-beginners21-lesson course on building generative AI apps in Python and TypeScript121.3k starsMIT81 out of 100
3hello-agentsChinese-language course on building LLM agents from scratch83.1k starscustom license76 out of 100
#4llms-from-scratchCode for the book on building a GPT-style LLM in PyTorch106.5k starscustom license75 out of 100
#5ai-agents-for-beginners18-lesson course on building AI agents with Microsoft Agent Framework77.1k starsMIT74 out of 100