课程定位
CS 224N 是 Stanford NLP 的旗舰课,也是很多人进入 LLM 领域的第一站。课程从词表示和语言模型讲起,逐步过渡到 Transformer、预训练、微调和 RLHF,既有数学推导也有大量工程实现。
主要内容
- 词表示:word2vec、GloVe、子词/tokenization
- 语言模型:n-gram、RNN/LSTM、注意力
- Transformer:self-attention、位置编码、架构细节
- 预训练模型:BERT、GPT、T5、缩放规律
- 适配与对齐:微调、提示、RLHF、DPO
- NLP 任务:句法、语义、问答、机器翻译、信息抽取
- final project:通常是 LLM/agent 相关的研究或应用
课程大纲 / 课件
官方 slides 在课程官网逐讲链接;B 站为第三方搬运。
先修
微积分与线性代数;CS 124、CS 221 或 CS 229 之一。
考核与工作量
通常为 4–5 次作业 + 期中 + final project;作业包含大量 PyTorch 实现。具体以当季官网为准。
适合谁
NLP/LLM 方向必选;想做 agent、RAG、对齐、多模态语言模型的人;想从传统 NLP 转向 LLM 的工程师。
学习建议
先修 CS 229 或至少理解 softmax/交叉熵/反向传播。想深入“从零训练 LLM”,接着上 CS 336。
相关课程
官方课程描述(英文原文)
Methods for processing human language information and the underlying computational properties of natural languages. Focus on deep learning approaches: understanding, implementing, training, debugging, visualizing, and extending neural network models for a variety of language understanding tasks. Exploration of natural language tasks ranging from simple word level and syntactic processing to coreference, question answering, and machine translation. Examination of representative papers and systems and completion of a final project applying a complex neural network model to a large-scale NLP problem. Prerequisites: calculus and linear algebra; CS124, CS221, or CS229.