Save this video free

UUtah CS 6340 NLP | Fall 2026 | Pretraining & finetuning

UofU Data Science · 1:16:29 · Watch on YouTube

Part of University of Utah CS 6340. See all 25 lectures and search them

These notes were made with YouTube Collector. Paste any YouTube link and get the same: a summary, chapters and a searchable transcript.

Overview

Pretraining gives transformer models useful, transferable language patterns before task-specific fine-tuning; the lecture contrasts decoder-only models trained with next-token prediction against encoder-only models trained with masked language modeling. It also explains how attention masks, language-model and classification heads, and data choices shape model capabilities, then connects scaling laws to practical risks in corpus quality, bias, privacy, multilingual coverage, copyright, and benchmark contamination.

Key takeaways

Chapters

0:00 Transformer Attention, RoPE, and Modern LLM Building Blocks
5:32 Why Pretraining Improves Transformer Starting Weights
12:16 Three Choices Define a Pretraining and Fine-Tuning Setup
14:11 Decoder-Only Transformers Process Sources and Targets Together
22:12 Next-Token Prediction Trains Decoder-Only Models
24:37 Fine-Tuning a Decoder-Only Model with Its Language-Model Head
28:09 BERT-Style Encoder-Only Pretraining Uses Masked Language Modeling
34:06 The CLS Token and Classification Head Turn BERT into a Task Model
40:01 BERT's Benchmark Gains and Continuing Value for Retrieval
47:03 Comparing GPT, BERT, T5, and Teacher-Forcing Examples
52:45 Pretraining Corpora Mix Web, Code, and Higher-Quality Text
56:18 Scaling Laws Link Compute, Model Size, and Training Tokens
59:08 Bad Training Examples Can Destabilize Expensive Runs
1:03:25 Corpus Filtering Must Balance Harm, Representation, and Worker Safety
1:10:34 Multilingual Pretraining Requires Careful Sampling
1:13:30 Privacy, Copyright, and Benchmark Contamination in Web-Scale Training

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

Transcript excerpt

0:05 Hi everyone. All right. So we have covered what the transformer architecture is and now we are ready to jump into the next topic which uh will bring us closer to what large language models are and that's uh pre-training of the uh transformer-based uh language models and then fine-tuning them for the whatever task we want uh to to specialize them for that task. Okay, so just to recap um why transformer architecture is beneficial relative to let's say RNN LMS. First reason is this new attention mechanism that allows us to uh compute importance of every token to the next token. So even if we are at a token position thousand, we have already have seen

0:52 thousands of tokens due to how query keys uh are used just by multiplying them. we can measure the importance of the first token to processing of that token that's at the position thousand way after the first token. So empirically um transformers handle long uh longer text way better than RNN's uh although in theory RNN's could process a long history in practice they they do not. Then uh attention also brought us another benefit which is that we can now do word sense disambiguation. Namely if a word has multiple senses due to contextualization of each token embedding relative to what we have seen um in the in the context uh we we can get the right sense of the of the token.

1:40 And then of course uh if we know the right sense of a token we can we can understand the piece of text where that token occurs much better. And finally, RNNs did encode word order. So the last benefit is not relative to RNN's. It's more relative to those you know simple simpler neural networks like deep

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

In this course

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, UofU Data Science.

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.