Log inStart free
LESSON 12.05 · 6 STAGES · 3 CONTROLS · 3 CHECKSPRO · PREVIEW

Prefix tuning and prompt tuning

Train a few vectors next to a frozen model and watch its answers change.


Pro lesson. Stage 1 is free to watch. Pro opens all 6 stages, 3 controls and 3 checks, in this lesson and every other.

Go Pro · $8.25/mo
EXPLAINER · 12.05 · FINE-TUNING BAY175 FROZEN · P(BLUE) 0.003
01
Stage 1 of 6 · Frozen model
The pretrained model keeps all 175 numbers frozen. After "bot", it writes "what", not "blue".
Explain it simply

You see the sky question as a row of token chips. It ends with bot, the word that starts the answer. The two grey bands are the model's layers, and frozen means their numbers never change. Asked this way, the model writes another question word, not a color.

The chat question about the sky as 8 token chips, then two grey layer bands. The frozen model's next token is "what".

tokenstrained vectorsfrozen layerserroroutput
layer 1 · frozenlayer 2 · frozenuserwhatcoloristhesky?botwhatp 0.22what0.22the0.20?0.18color0.14blue0.00next token after "bot"the frozen modellayer 1 · frozenlayer 2 · frozenuserwhatcoloristhesky?botwhatp 0.22what0.22the0.20?0.18color0.14blue0.00next token after "bot"the frozen model
Toy: 12.01's frozen model, 2 trained vectors
STAGE 1 / 6
MATH · STAGE 1HOVER A SYMBOL OR A SHAPE
p(y∣x; θ),θ frozenp(\sy{y}{out}{y} \mid \sy{x}{data}{x};\ \sy{th}{param}{\theta}),\quad \sy{th}{param}{\theta}\ \text{frozen}
p(blue∣x)=0.003,175 numbers frozenp(\text{blue} \mid x) = 0.003,\quad 175\ \text{numbers frozen}

The frozen model gives every next token a chance.

Common mix-ups

MYTHA soft prompt is a hidden prompt made of words.

The fix, and 1 more mix-up with the diagram to show them, come with Pro.

Predict, then reveal
3 CHECKS · PRO
Q01After 100 steps on the color loss, does prompt tuning get the sky color right?

Make your guess, then test it in the diagram. All 3 checks come with Pro.

PRO LESSON · YOU WATCHED STAGE 1 OF 6
Unlock the full explainer
  • 5 more stages and 3 live controls
  • 2 mix-up cards and 3 predict-then-reveal checks
  • Watch it as a narrated video, in three voices
  • Every Pro lesson and capstone · 656 in total

$99 a year, or $15 a month. Cancel any time.