Save this video free

EfficientML.ai Lecture 12 - Transformer and LLM (MIT 6.5940 Fall 2026)

MIT HAN Lab · 1:16:34 · Watch on YouTube

EfficientML.ai Lecture 12 - Transformer and LLM (MIT 6.5940 Fall 2026) Watch on YouTube →

Overview

The lecture explains how Transformer components, including self-attention, feed-forward networks, positional encodings, and KV caching, underpin modern large language models. It compares encoder and decoder architectures, details techniques such as RoPE, GQA, and SwiGLU, and connects scaling and in-context learning to model families including BERT, GPT, T5, and LLaMA, then surveys multimodal models and mixture-of-experts routing.

Key takeaways

Chapters

0:00 LLM Applications: ChatGPT, Translation, Coding, and Multimodal Models
4:00 Why Transformers Replaced RNNs and Convolutional Language Models
9:40 Transformer Inputs: Tokenization, Embeddings, and Layer Components
15:20 Scaled Dot-Product Attention and Multi-Head Attention
20:00 Causal Masks Separate GPT Generation from Bidirectional Attention
23:00 Transformer FFNs, LayerNorm, and Residual Connections
27:45 Position Information and the Original Transformer’s Translation Results
31:10 Encoder-Decoder, BERT, and GPT Architectures
36:00 Relative Position Encoding with ALiBi
40:00 RoPE: Rotary Position Embeddings and Context Extension
48:00 KV Cache: Faster Autoregressive Decoding at a Memory Cost
54:30 GQA, MQA, and SwiGLU Reduce LLM Inference Costs
1:01:00 Emergent Capabilities, In-Context Learning, and LLaMA Scaling
1:08:20 Multimodal Models: Flamingo, PaLM-E, and RT-2
1:14:25 Mixture-of-Experts Routing and Capacity Trade-Offs

Keep these chapters and the full searchable transcript in your own library.

Transcript excerpt

0:02 Okay. Uh let's get started for today's lecture. So we will talk about uh transformers and large language models. Uh we will have um just introduction of the transformer architecture and uh some application of large language models and we will talk more uh more details like uh how do you do the deployment, how do you do the post training, how do you uh apply large language models to different kind of applications in uh future lectures. So today uh we will just dive into the overall architecture and have a very high level overview of the large language model architecture and its applications. So to begin with um we all know that uh CH GBT come out in late 2022 and Sam's uh chatbots large language models

0:54 becomes very prevalent and uh accessible to almost everyone and at the very beginning it's just a a chatbot and you can type in something like some just some easy questions and get some response from the uh model at that time. uh later um we can see we see that it is applied to more and more application domains. So machine translation is very familiar uh another very familiar application to everyone and a language model can take the taxing uh from one lang language and uh generate the corresponding tax in another language uh while preserving the original meaning and the context. So with more and more advanced language language models you may feel that nowadays machine

1:41 translators are performing much better than let's say five years ago or 10 years ago right and another very important application is uh uh use large language model to assist people do coding tasks and this is a very uh early uh example for uh AI assistant coding uh said it uh which is

This is the start of the transcript. Save this video free for the whole transcript, searchable and time-coded.

Related notes

Summary, takeaways, and chapters were generated by AI from the video's transcript and may contain errors. The video belongs to its creator, MIT HAN Lab.

Want the full transcript?

Save this video in YouTube Collector to get its complete searchable transcript, your own AI summaries, and a library that keeps every video you collect in one place.