Skip to main content
Back to trending

LLMs-from-scratch

Implement a ChatGPT-like LLM in PyTorch from scratch, step by step

  • ai
  • artificial-intelligence
  • attention-mechanism
  • deep-learning
  • finetuning
  • from-scratch
  • generative-ai
  • gpt
  • instruction-tuning
  • language-model
  • large-language-models
  • llm
  • machine-learning
  • natural-language-processing
  • pretraining
  • python
  • pytorch
  • tokenizer
  • transformers
View on GitHub
Stars
106,339
Forks
16,362
+ today
+1
Created
3y

Ranking data as of November 24, 2026 (UTC).

Star History

Today, hour by hour

106,339 stars
106,338106,339

Overview

Implement a ChatGPT-like LLM in PyTorch from scratch, step by step It ranks #4197 on GitTiger, gaining +1 star on November 24, 2026 (UTC).

The project is written in Jupyter Notebook and has 16,362 forks. It was created 3y ago.

Installation
git clone https://github.com/rasbt/LLMs-from-scratch.git
cd LLMs-from-scratch
# see README for setup