Stanford’s CS336, Language Modeling from Scratch, teaches students to build the components behind a language model. Datawhale’s open-source project repository adapts that material for Chinese learners through localized notes, examples based on Qwen and DeepSeek, and six coding assignments that cover the model pipeline from tokenization to alignment.

The repository has attracted more than 1,700 GitHub stars and appeared in GitHub Trending. Its code-heavy structure gives developers a guided route through model architecture, training systems, data preparation, scaling, alignment, and evaluation.

From tokenizer to GRPO in six assignments

Across 16 chapters, each assignment builds on infrastructure introduced earlier in the course. Learners finish with a readable codebase that touches every major stage of language-model development.