POLYU SCHOOL OF DESIGN · SD2112 · WEEK 03 · LECTURE + WORKSHOP

Learning from examples.

Week 3 — concepts, neurons, GPUs, and a picture that blends two ideas.

SD2112 · WEEK 03

Today

01

Last week, in your words

02

What is a concept?

03

Prototypes: Rosch, 1975

04

The birth of AI, twice

05

Neurons that learn: Hinton

06

Parallel: GPUs and modern AI

07

Blending concepts

08

Activity: the blend

SD2112 · AI IN DESIGN · WEEK 03

02

01

Last week, in your words

the film · the wall · the map

SD2112 · AI IN DESIGN · WEEK 03

03

01 · QUESTION · WORD CLOUD

AlphaGo. One word.

You watched the film. The first word that comes to mind.

SD2112 · AI IN DESIGN · WEEK 03

04

Word cloud

01 · WEEK 2 · THE WALL · 125 PICTURES · ONE RULE EACH · THE CAPTIONS

Every picture the pairs uploaded last week, both rounds: LeWitt's ten points with a twist, then a rule of the pair's own, turned into p5.js by a language model. Nobody defined "a picture"; every one of these is one.

01 · THE SEMESTER

Where we are

1 · What is AI?

Week 1

Two ways to teach a machine

Week 2

Rules that make things: code, chance, generative art

Week 3

Learning from examples: concepts, neurons, Move 37

2 · AI for the creative process

Week 4

Language machines: LLMs, prompts, agents

Week 5

Image machines: diffusion, CLIP, mediation

Week 6

Sound machines: music, voice, spectrograms

Mid-term

Week 7

Mid-term quiz · project pitches · teams · reflection due

3 · AI inside products

Week 8

AI as design material: use vs incorporate

Week 9

Data, bias and privacy

Week 10

Recommendation systems and the feed

4 · The designer's turn

Week 11

Curating outputs and datasets · authorship

Week 12

Language as an interface: chatbots and agents

Showcase

Week 13

Poster fair · final quiz

SD2112 · AI IN DESIGN · WEEK 03

06

02

What is a concept?

ideas · definitions · Plato · Wittgenstein

SD2112 · AI IN DESIGN · WEEK 03

07

02 · THE CLASSICAL THEORY · ARISTOTLE TO THE DICTIONARY

A concept is a definition.

A definition is a list of properties a thing must have to belong: necessary, and together sufficient. Bachelor = man + unmarried.

Categorising is then trivial: check each property, apply the concept. X is a bachelor if X is a man and X is unmarried. A machine can do that.

New ideas by assembly: put definitions together and you have a new one. Kant: analytic, all in the words.

Aristotle, pointing down at the things, is this theory: sort them by the properties they share and keep the ones that are necessary. Plato, pointing up, disagrees.

Plato and Aristotle, detail of Raphael's The School of Athens, 1509–1511. Public domain, Wikimedia Commons.

SD2112 · AI IN DESIGN · WEEK 03

08

02 · SOUNDS EASY · TRY THESE

Write the definition.

A PRIME NUMBER

Easy.

Divisible only by one and by itself. Every number is in or out, no argument. Mathematics is where the classical theory lives.

FURNITURE

Try.

Movable, for a room, for living? A lamp? A rug? A built-in wardrobe? Every list you write admits something wrong or leaves out something right.

SUNSET COLOUR

Try.

Orange? Pink? Grey over Kowloon? You know it when you see it, and you cannot say it in a way a stranger could check.

A PIZZA

Try.

Dough, tomato, cheese, baked. Then a white pizza, a calzone, pineapple. Is a pizza defined by its base, its shape, its country, or by pizza places?

AN A+ ESSAY

The rubric tries.

Argument, evidence, structure, style, with bands. It is the best list we can write, and two markers still disagree at the edge.

SD2112 · AI IN DESIGN · WEEK 03

09

"But in what way will you look for it, Socrates, this thing that you don't know at all what it is? Or even if you should meet right up against it, how will you know that this is the thing you didn't know?"

Meno to Socrates. Plato, Meno, 80d, c. 385 BC.

SD2112 · AI IN DESIGN · WEEK 03

10

02 · PLATO · MENO · WHERE IDEAS COME FROM

Ideas are real. Definitions are not their essence.

Socrates calls it a debater's trick: you cannot seek what you know, because you know it, nor what you don't know, because you don't know what to look for.

His answer: learning is remembering. The soul has seen the ideas; the world is a copy; to learn is to recognise. He shows it with a slave boy who "finds" geometry he was never taught.

Whatever you think of the soul, the lesson holds: we have ideas without definitions. The definition is not the essence of a concept.

Socrates, Roman marble after a Greek original, 1st century, Louvre. Photo: Eric Gaba, CC BY-SA 2.5, Wikimedia Commons.

SD2112 · AI IN DESIGN · WEEK 03

11

"Don't think, but look!"

Ludwig Wittgenstein, Philosophical Investigations, §66, 1953, on what all games have in common

SD2112 · AI IN DESIGN · WEEK 03

12

02 · WITTGENSTEIN · 1953 · FAMILY RESEMBLANCE

No feature runs through all of them.

Six games, seven features. A definition would need a full column; there is none. Chess and ring-a-ring-a-roses share almost nothing, yet both are games, because a chain of resemblances links them: overlapping and criss-crossing, like the resemblances in a family.

WITTGENSTEIN, 1953, §66 · "CONSIDER FOR EXAMPLE THE PROCEEDINGS THAT WE CALL GAMES" board ball cards winning luck skill players chess football poker patience tennis ring-a-ring-a-roses in all of them? no no no no no no no No column is full: no feature runs through every game. A definition needs a full column. The resemblances overlap and criss-cross instead.

After Philosophical Investigations §66–67. The features are ours; the argument is his.

SD2112 · AI IN DESIGN · WEEK 03

13

02 · THE CLASSICAL THEORY · WHERE IT LEAVES US

Easy to check. Impossible to write.

THE BENEFIT

Categorising is trivial.

Set formal requirements and the check is mechanical: every property, present or absent. That is why a rule-based machine can hold a concept at all: a definition is a rule.

NEW IDEAS

By assembly.

Put two definitions together and you have a third: unmarried + man. Which properties survive when you combine "pet" and "fish"? Assembly is exactly where definitions start to fail.

THE PROBLEM

Most concepts have no definition.

Outside mathematics and law, almost nothing you design has one, and you use those concepts all day without it. So what is a concept, if not a definition?

SD2112 · AI IN DESIGN · WEEK 03

14

03

Prototypes

Rosch · 1975 · a middle and an edge

SD2112 · AI IN DESIGN · WEEK 03

15

03 · QUESTION · WORD CLOUD

Name a fruit. The first one that comes to mind.

One word. Do not think.

SD2112 · AI IN DESIGN · WEEK 03

16

Word cloud

03 · ELEANOR ROSCH · BERKELEY · 1975

I asked people to rate fruits.

Rosch gave about two hundred students lists of items in ten categories, fruit, birds, furniture, vehicles, and asked for each: how good an example of the category is this? From 1, a very good example, to 7, a very poor one.

If a concept were a definition, an orange and an olive would be equally fruit, and the ratings would be noise.

They were not. People agreed, strongly and quickly: some fruits are more fruit than others.

Two papers in 1975, with Carolyn Mervis: typicality is real, shared, and it is made of family resemblance, counted.

Eleanor Rosch, 2012 (Wikimedia Commons, CC0). Rosch 1975, J. Exp. Psych.: General 104; Rosch & Mervis 1975, Cognitive Psychology 7.

SD2112 · AI IN DESIGN · WEEK 03

17

03 · ROSCH · 1975 · THE FRUIT

Some fruits are more fruit than others.

Thirteen of her fifty-one fruits, in her order. Orange, apple and banana sit at the very top, about 1 on the scale; tomato is above 5; the olive comes last.

Nobody had trouble answering, and the ratings were the same across people: the concept has a shape, and it is shared.

Compare the word cloud. Your first fruit was near the top of this list. A prototype is what a room produces when it does not think.

A concept with a middle and an edge cannot be a definition. Definitions have no middle.

ROSCH, 1975 · "HOW GOOD AN EXAMPLE OF A FRUIT IS THIS?" 1 · a very good example 7 · a very poor one 1 2 3 4 5 6 7 1 orange 2 apple 3 banana 4 pear 5 plum 6 strawberry 7 pineapple 8 lemon 9 honeydew 10 date 11 coconut 12 tomato 13 olive

Rank order of Rosch's 1975 goodness-of-example ratings for fruit, 1 = a very good example, 7 = a very poor one; the positions are approximate, the order is hers.

SD2112 · AI IN DESIGN · WEEK 03

18

03 · WHAT TYPICALITY DOES

The middle is faster, first, and easier.

JUDGED

Typical items are called members more often.

Hampton, 1979.

FASTER

Categorising a typical item takes less time.

Rips, Shoben & Smith, 1973.

LEARNED FIRST

Children learn the typical members before the atypical ones.

Rosch & Mervis, 1975.

EASIER TO TEACH

A category is learned faster from typical examples.

Mervis & Pani, 1980.

UNDERSTOOD

In a sentence, a typical member is understood more easily.

Garrod & Sanford, 1977.

SD2112 · AI IN DESIGN · WEEK 03

19

03 · PROTOTYPE THEORY

A concept is its best examples.

THE THEORY

A structured representation of what members tend to have.

Not a list of conditions but a picture of the typical case, and a distance from it. Membership is a degree: a robin is a very good bird, a penguin a poor one, and neither needs a definition.

THE GAIN

Only similarity is needed.

No definition to write: you judge a new thing by how much it resembles what you have seen. That is learning from examples, and it is why a machine can hold "chair" with no rule for it.

THE COST

Outliers, and combinations.

Exceptions are hard: there are fewer examples at the edge, so the edge is unsure. And combining concepts is a puzzle: which properties of "pet" and "fish" does "pet fish" keep?

SD2112 · AI IN DESIGN · WEEK 03

20

03 · QUICK CHECK · MULTIPLE CHOICE

Which sentence is prototype theory?

A

A chair is anything with a seat, a back and at least three legs

B

Every chair shares one feature that makes it a chair

C

Some chairs are better examples of "chair" than others

D

A chair is whatever the dictionary says it is

SD2112 · AI IN DESIGN · WEEK 03

21

Multiple choice

04

The birth of AI, twice

1956 · Dartmouth · 1958 · the perceptron

SD2112 · AI IN DESIGN · WEEK 03

22

04 · DARTMOUTH · SUMMER 1956

AI gets its name, and a bet.

31 August 1955: McCarthy, Minsky, Rochester and Shannon propose a summer study "on the basis of the conjecture that every aspect of learning or any other feature of intelligence can in principle be so precisely described that a machine can be made to simulate it."

Summer 1956, Dartmouth: the field gets its name. Turing's intelligence as computation becomes a programme.

Intelligence = analytical reasoning. Symbols, rules, search: the classical theory of concepts, built.

Haugeland named it GOFAI in 1985: good old-fashioned AI.

The first page of the proposal, 31 August 1955. Public domain, Wikimedia Commons.

SD2112 · AI IN DESIGN · WEEK 03

23

04 · THE OTHER BIRTH · ROSENBLATT · 1958

A machine modelled on the brain, not on logic.

Frank Rosenblatt, Cornell, 1957–58: the perceptron. Not a program that applies rules but a network of simple units modelled on neurons, whose connections adjust from examples.

Top: a brain, as he drew it: retina, projection areas, association areas, responses. Bottom: the perceptron, the same shape, in wires.

Show it a letter; it guesses; if wrong, the connections that voted wrong are weakened, the ones that voted right strengthened. Again.

No definition of "A" anywhere. The knowledge is in the weights, and the weights come from the examples.

Rosenblatt, "The design of an intelligent automaton", 1958, figures 1 and 2. Public domain, Wikimedia Commons.

SD2112 · AI IN DESIGN · WEEK 03

24

04 · THE MARK I PERCEPTRON · 1960 · PHOTO: US NAVY, PUBLIC DOMAIN

400 photocells look at a letter; motors turn the potentiometers that hold the weights when a guess is wrong. The New York Times, July 1958: the Navy expects it "will be able to walk, talk, see, write, reproduce itself and be conscious of its existence".

04 · ONE NEURON

A neuron is a weighted vote.

Two inputs, two weights, a bias, a threshold. Multiply, add, compare with zero: that is the whole unit. Three numbers hold everything it knows. Rosenblatt, 1958, called it a perceptron; the shape and the size are the week-1 cup.

ONE NEURON · ROSENBLATT, 1958 × +1.6 1.1 height ÷ width × -0.8 0.4 size INPUTS · THE OBJECT Σ + b b = -1.2 1.1×+1.6 + 0.4×-0.8 -1.2 = +0.24 WEIGHTS · THE KNOWLEDGE above 0? 1 GUESS +0.24 > 0 so: "cup" three numbers decide. learning = changing them when the guess is wrong

Rosenblatt, "The perceptron: a probabilistic model for information storage and organization in the brain", Psychological Review 65, 1958. In the html deck the neuron learns live, one example at a time.

SD2112 · AI IN DESIGN · WEEK 03

26

Live · click = pause · C = start again

04 · THE PERCEPTRON · WHAT THE CODE DOES

Twenty-four dots, one line, and a nudge.

THE EXAMPLES

Twenty-four points, two classes.

Twelve orange A and twelve teal B, placed with a bell-curve die: most land near the middle of their group, a few stray. These dots are all the machine ever sees.

THE RULE

Three numbers draw one line.

w1, w2 and b are one straight line across the canvas. The rule guesses A on one side of it and B on the other. Where the line starts is arbitrary; it begins wrong.

THE NUDGE

Wrong? Move a little.

Every frame is one pass over the examples. Where the guess is wrong, the three numbers move a little towards that example, so the line turns. When nothing is wrong, it stops: "wrong: 0".

ADD POINTS

Click, and it has to move again.

A click adds an A where you click; shift-click adds a B. Put an A among the Bs and it never settles: one line cannot. C starts again.

SD2112 · AI IN DESIGN · WEEK 03

27

04 · THE PERCEPTRON · 1958 · IN P5.JS

Wrong? Nudge the three numbers. Again.

let pts = [], w1 = 0.3, w2 = -1, b = 0.1; // three numbers

const lr = 0.05; // how big a nudge

const g = (m, s) => randomGaussian(m, s); // a bell-curve die

function setup() {

createCanvas(600, 600); randomSeed(3); frameRate(8);

for (let i = 0; i < 12; i++) { // twelve A, twelve B

pts.push([g(-.45, .2), g(-.3, .2), -1]);

pts.push([g(.45, .2), g(.35, .2), 1]);

}

}

function guess(x, y) { return w1 * x + w2 * y + b > 0 ? 1 : -1; }

function draw() { // one pass per frame

let wrong = 0;

for (let [x, y, t] of pts) // wrong? nudge

if (guess(x, y) != t) { wrong++; // a little, towards it

w1 += lr * t * x; w2 += lr * t * y; b += lr * t; }

background(255); stroke(0); strokeWeight(2);

let ya = -(b - w1) / w2, yb = -(b + w1) / w2; // where the rule

line(0, 300 - 300 * ya, 600, 300 - 300 * yb); // says 0

for (let [x, y, t] of pts) {

fill(t < 0 ? '#ED6D24' : '#64C2C3');

circle(300 + 300 * x, 300 - 300 * y, 14);

}

fill(0); noStroke(); text('wrong: ' + wrong, 16, 24);

}

One pass per frame; a wrong guess moves the three numbers a little. "wrong: 0": every example is on its side, the line has settled. Click adds an A, shift-click a B · edit it live.

SD2112 · AI IN DESIGN · WEEK 03

28

Live · click = add an A · shift-click = a B · C = again
ctrl+enter runs it

04 · 1958 · 1969 · 1986

A machine that learns, and what it took.

1958 · ROSENBLATT

The perceptron.

The paper in Psychological Review, then the Mark I. A machine that learns, and the press promising consciousness within the year. Rosenblatt died in 1971, aged 43, with the idea out of fashion.

1969 · MINSKY & PAPERT

One line cannot.

Perceptrons, the book: a single layer can only draw one straight line, so it cannot even learn XOR. Funding for networks dries up for a decade. The rules school, Minsky's own, wins the seventies.

1986 · BACKPROPAGATION

Rumelhart, Hinton & Williams.

Four pages in Nature: put units in layers, send the error backwards, nudge every weight. Hidden units invent their own features. Connectionism has its learning rule, and the other school of AI is back.

SD2112 · AI IN DESIGN · WEEK 03

29

04 · THE LIMIT, AND THE FIX

One line cannot. Two layers can.

XOR: A on one diagonal, B on the other. No straight line separates them, so one neuron never settles. Add a hidden layer of two neurons and the network can draw two lines and vote on them. The band is a rule nobody wrote.

1969 · MINSKY & PAPERT · ONE LINE CANNOT A on one diagonal, B on the other: no line gets all of them right 1986 · A HIDDEN LAYER, TRAINED BY BACKPROPAGATION x, y two lines A or B each hidden unit is one neuron, one line each; the output unit votes on their two verdicts. wrong guess: the error travels backwards and every weight moves a little. (9 weights here; 60 million in AlexNet) TWO LINES · A IN THE BAND, B OUTSIDE a rule nobody wrote: "A is in the band"

Minsky & Papert, Perceptrons, 1969 · Rumelhart, Hinton & Williams, "Learning representations by back-propagating errors", Nature 323, 1986.

SD2112 · AI IN DESIGN · WEEK 03

30

05

Neurons that learn

Hinton · connectionism · 1986 · 2012 · 2024

SD2112 · AI IN DESIGN · WEEK 03

31

05 · GEOFFREY HINTON

Fifty years betting on the brain.

A psychologist, like Rosenblatt. 1986: backpropagation, with Rumelhart and Williams, when almost nobody believed in networks.

Connectionism: a concept is a pattern of activity over many units, never a list. Rosch's graded categories as an engineering brief.

2012: with his students Krizhevsky and Sutskever, AlexNet wins ImageNet. 2018: the Turing Award. 2023: leaves Google to speak about the risks.

2024: the Nobel Prize in Physics, with John Hopfield, "for foundational discoveries and inventions that enable machine learning with artificial neural networks".

Geoffrey Hinton at the 2024 Nobel Lectures, Stockholm University. Photo: Jay Dixit, CC BY-SA 4.0, Wikimedia Commons.

SD2112 · AI IN DESIGN · WEEK 03

32

05 · BACKPROPAGATION · 1986

Send the error backwards. Nudge every weight.

Forward: every unit sums its inputs, weighted, and passes a number on. At the end, a guess.

Backward: compare the guess with the truth. Share the error out along the same connections, so every weight moves a little, in proportion to its part in the mistake.

Then the next example. A million times.

The perceptron's rule, extended to units that never see the answer directly. Rumelhart, Hinton & Williams, Nature 323, 1986.

SD2112 · AI IN DESIGN · WEEK 03

33

05 · BACKPROPAGATION · 1986 · THE PICTURE, LIVE

The guess goes forward. The error comes back.

THE EXAMPLE PIXELS IN HIDDEN HIDDEN GUESS OUT chair 0.35 cup 0.65 THE TRUTH: a chair chair should be 1.00 it said 0.35 error: 0.65 then: every weight moves FORWARD · every unit sums its inputs and passes a number on · the guess comes out at the end BACKWARD · the error is shared out along the same connections · every weight moves a little, in proportion to its share

Nine pixels in, five and three hidden units, two out: nineteen units, 66 weights. Rumelhart, Hinton & Williams, "Learning representations by back-propagating errors", Nature 323, 1986.

SD2112 · AI IN DESIGN · WEEK 03

34

Live · click = pause · C = start again

05 · HUMANS + CONCEPTS · MACHINES + CONCEPTS

Two theories. Two machines.

HUMANS + CONCEPTS MACHINES + CONCEPTS RULE-BASED CLASSICAL THEORY a concept is a definition: necessary and sufficient conditions Aristotle · Kant · the dictionary GOFAI · SYMBOLIC AI knowledge written down as rules, applied by a program Dartmouth 1956 · ELIZA · expert systems ADAPTIVE PROTOTYPE THEORY a concept is its best examples, membership a matter of degree Wittgenstein 1953 · Rosch 1975 CONNECTIONISM · MACHINE LEARNING the knowledge is in the weights, found from examples Rosenblatt 1958 · Hinton 1986 · 2012 · today the same two ideas, in a mind and in a machine: a rule you can read, or examples you cannot

Rule-based: classical theory + GOFAI, a definition a machine applies. Adaptive: prototype theory + connectionism, examples held in weights nobody can read. Your reflection is about this distinction.

SD2112 · AI IN DESIGN · WEEK 03

35

05 · THE DEAL

Fluent. Fuzzy. Opaque.

FLUENT

It handles the case nobody wrote.

A learned concept covers the middle of its examples and interpolates between them. That is why it can write, draw and see: no list of conditions could.

FUZZY

Every answer is a degree.

Chair 0.93, stool 0.05. There is no line, only a slope, and it moves with the examples. The edge of the concept is exactly where it is least sure, and where you work.

OPAQUE

It cannot say why.

Sixty million numbers found by nudging. No line to point at, no rule to read, no fix but more examples. When it is wrong you cannot ask it; you can only retrain it.

SD2112 · AI IN DESIGN · WEEK 03

36

05 · WHERE WE ARE

Machine A is a rule you wrote. Machine B is a rule nobody wrote.

SD2112 · AI IN DESIGN · WEEK 03

37

AFTER THE BREAK · GPUS · MODERN AI · THEN THE BLEND

Break. Ten minutes.

SD2112 · AI IN DESIGN · WEEK 03

38

06

Parallel

every unit at once · GPUs · 2012 · today

SD2112 · AI IN DESIGN · WEEK 03

39

06 · PARALLEL CALCULATION

Every unit decides on its own.

A Turing machine does one step at a time, and its whole state sits in one place, readable. A network is thousands of small sums that do not wait for each other and share nothing: harder to read, and far faster for some tasks, if you have something that can do thousands of sums at once. For decades, nobody did.

A TURING MACHINE · ONE STEP AT A TIME 1 2 3 4 5 6 7 8 9 10 1 0 1 1 0 0 1 0 1 1 0 1 0 0 one head, one tape: the whole state is in one place, and you can read it the next step waits for this one · rules, applied in order exact · explainable · one thing at a time A NETWORK · EVERY UNIT AT ONCE Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ thirty-two sums at once, none of them waiting: one tick for all no state in one place, nothing to read · examples, not rules fast, with thousands of small processors · opaque either way AlexNet: about 700 million multiply-adds per picture; a GPU does thousands at a time

The rule-based machine is serial by nature; the learned one is parallel by nature. The chip you run it on decides whether that is a strength or a wait.

SD2112 · AI IN DESIGN · WEEK 03

40

06 · THE SAME RULE, 240,000 TIMES · IN P5.JS

One core, pixel by pixel. A GPU, all at once.

let cores, i = 0, t0; // pixels per frame: a slider

const n = 60, W = 600, H = 400; // steps per pixel; the canvas

function setup() {

createCanvas(W, H); pixelDensity(1);

cores = createSlider(0, 12, 8, 1, 'cores: 2^k');

cores.input(restart); restart();

}

function restart() { // from the top, blank

background(255); loadPixels(); i = 0; t0 = millis();

}

function draw() {

let k = 1 << cores.value(); // 2^k pixels in this frame

for (let j = 0; j < k && i < W * H; j++, i++) { // pixel i

let a = (i % W - 420) / 200, b = (floor(i / W) - 200) / 200;

let x = 0, y = 0, s = 0; // c; z starts at 0

while (x * x + y * y < 4 && s < n) { // z = z² + c, again

let t = x * x - y * y + a; y = 2 * x * y + b; x = t; s++;

}

let v = s == n ? 0 : 255 * sqrt(s / n), q = 4 * i;

pixels[q] = v * .3; pixels[q + 1] = v * .6; pixels[q + 2] = v;

}

updatePixels(); noStroke(); fill(255); rect(0, 380, 600, 20);

let sec = nf((millis() - t0) / 1000, 1, 1);

fill(0); text(k + '/frame · ' + i + ' px · ' + sec + ' s', 10, 394);

}

The Mandelbrot rule from week 2, one pixel after another. The slider is how many pixels are done in each frame: 1, or 4,096. Same rule, same picture, a thousand times sooner · edit it live.

SD2112 · AI IN DESIGN · WEEK 03

41

Live · the slider is how many at once · click = from the top
ctrl+enter runs it

06 · GPUS · NOT ONLY FOR GAMING

The chips made for games.

A graphics processing unit does the same small calculation on millions of pixels at once: textures, shading, vertices, physics. Games needed that, and paid for twenty years of it.

2007: CUDA. NVIDIA opens the chip to any calculation that has the same shape: many small identical jobs, no waiting.

A neural network is exactly that shape: multiply, add, everywhere, at once. What a CPU did in weeks, a graphics card did in days.

The other school of AI finally had its engine.

An NVIDIA GeForce GTX 580, late 2010: the card AlexNet was trained on, two of them. Photo: TheStriker, CC BY-SA 4.0, Wikimedia Commons.

SD2112 · AI IN DESIGN · WEEK 03

42

06 · INSIDE THE GTX 580 · THE GF110 DIE · 512 CORES · 3 BILLION TRANSISTORS

The chip under the fan, sanded down and photographed: sixteen blocks of thirty-two small processors, each doing the same job on its own piece of the picture. This, twice, is what learned to see in 2012. Photo: Fritzchens Fritz, CC0, Wikimedia Commons.

06 · 2012 · ALEXNET

Deep: the features are learned too.

30 September 2012: Krizhevsky, Sutskever and Hinton win the ImageNet challenge with an eight-layer network: 15.3% error against 26.2% for the runner-up, trained on 1.2 million labelled photos in about a week on two GTX 580s. The other entries ran on hand-crafted features; AlexNet grew its own from the pixels.

PIXELS EDGES PARTS OBJECTS A LABEL leg seat back chair 0.93 stool 0.05 table 0.02 input: the pixels layer 1 (convolutional) layers 2 – 5 (convolutional) layers 6 – 8 (fully connected) output: 1,000 scores AlexNet, 2012: 8 layers, 60 million weights, all found from 1.2 million labelled photos. nobody wrote a rule for "edge" or "leg"; the layers became those detectors because it lowered the error

ImageNet: Fei-Fei Li, from 2006; 14 million images labelled by 49,000 Mechanical Turk workers in 167 countries.

SD2112 · AI IN DESIGN · WEEK 03

44

06 · 2016 · ALPHAGO · MOVE 37

A move outside the human middle.

Seoul, 10 March 2016, game two, move 37. The commentators call it a mistake. Humans play it, said DeepMind, one time in ten thousand.

Trained on human games first, then on millions of games against itself. Move 37 came from the second set, and it was right.

Your word cloud at the start of class was the verdict. Creative, alien, or more examples?

SD2112 · AI IN DESIGN · WEEK 03

45

06 · MODERN AI · 2012 – 2026

The same loop, a billion times bigger.

2012

AlexNet

60 million weights, two gaming GPUs, a week. The examples school wins at seeing.

2014

GANs

Two networks, one forging, one judging. Edmond de Belamy, 2018, was one of these.

2017

The transformer

"Attention is all you need": the architecture inside every chatbot since.

2020

GPT-3

175 billion weights, trained on the web. Scale as the strategy.

2022

Diffusion · ChatGPT

Stable Diffusion, then ChatGPT: machine B reaches everyone through a text box.

2024

Two Nobel Prizes

Physics: Hopfield and Hinton, the networks. Chemistry: Hassabis and Jumper, AlphaFold.

2025

Editors that take references

Flux Kontext, Qwen-Image-Edit, FLUX.2: show the model pictures, not only words.

2026

You

Both machines in every tool. The designer decides which, and when, and with which examples.

SD2112 · AI IN DESIGN · WEEK 03

46

06 · HOW MANY NUMBERS · 1958 – 2026

A thousand times more numbers, every ten years.

1 a thousand a million a billion a trillion HOW MANY NUMBERS A MODEL HOLDS · EVERY LINE UP IS TEN TIMES MORE language and vision image models 3 one neuron 1958 60 thousand LeNet-5 1998 60 million AlexNet 2012 1.5 billion GPT-2 2019 175 billion GPT-3 2020 0.9 billion Stable Diffusion 2022 12 billion FLUX.1 2024 405 billion Llama 3.1 2024 20 billion Qwen-Image 2025 trillions the largest 2026, not published counts from the papers and model cards; the last one is an estimate: the labs no longer say

A learned model is measured by how many numbers it holds: three in our neuron, 60 million in AlexNet, 175 billion in GPT-3, trillions today. The loop never changed; the count did, and the chips that hold it.

SD2112 · AI IN DESIGN · WEEK 03

47

07

Blending concepts

pet fish · houseboat · a picture from two ideas

SD2112 · AI IN DESIGN · WEEK 03

48

07 · COMBINING CONCEPTS

Bachelor was easy. Pet fish is not.

THE CLASSICAL WAY

Add the conditions.

Man + unmarried. A rule combines any two definitions: everything from both, nothing new. It also gives you "fake gun" (a gun?) and "small elephant" (small?). Assembly is where lists show their seams.

THE PROTOTYPE PROBLEM

Typicality does not multiply.

Picture a pet: not a goldfish. Picture a fish: not a goldfish. Picture a pet fish: a goldfish (Osherson & Smith, 1981, who used a guppy). Which properties survive the combination? Nobody has found the rule (Hampton, 1988).

THE BLEND

Two inputs, one new space.

Fauconnier & Turner, 2002: we build a blended space that takes some structure from each input and grows structure of its own. A houseboat, a computer virus, a desk lamp. We do it all day; we cannot say how.

SD2112 · AI IN DESIGN · WEEK 03

49

07 · FAUCONNIER & TURNER · 2002

Two inputs. One new space.

Two input spaces: a house and a boat. A generic space of what they share: a structure, a place, people who use it.

The blend: a houseboat. It took the rooms from the house and the hull from the boat, and it is one thing, not two.

GENERIC what both share INPUT 1 house lived in · stays put INPUT 2 boat floats · moves · a crew THE BLEND houseboat lived in, and it floats after Fauconnier & Turner, The Way We Think, 2002

After Fauconnier & Turner, The Way We Think: Conceptual Blending and the Mind's Hidden Complexities, 2002.

SD2112 · AI IN DESIGN · WEEK 03

50

07 · FAUCONNIER & TURNER · WHAT A BLEND DOES

Some stays behind. Some is new.

SELECTIVE PROJECTION

Not every property comes across.

The house's foundations stay behind; so does the boat's cargo. The blend takes what it needs from each input and leaves the rest.

EMERGENT STRUCTURE

The blend has what no input had.

A mooring fee, a bathroom on deck, a view that changes. None of it was in the house or the boat. That is where the new idea lives.

EVERY MASH-UP

A computer virus. A desk lamp. A mermaid.

Every metaphor, every product mash-up, every "what if a chair were a cup" is one of these.

SD2112 · AI IN DESIGN · WEEK 03

51

07 · A MACHINE THAT BLENDS

Show it two pictures. Ask for one.

An image editor that takes references has the examples; a reference image is one more example, placed in front. Give it two and a sentence and one of three things comes back: a collage, both things side by side, which is what a rule would do; a blend, one thing with properties of both, which no definition could do; or the stronger prototype eats the other, which is the middle pulling, as always.

A COLLAGE cup and chair, side by side a rule can do this: both conditions, nothing new A BLEND one thing with properties of both no definition can do this; a prototype machine can ONE WINS the stronger prototype eats the other watch for it: the middle pulls, always

Cup and chair, three outcomes. Making the model blend rather than collage is a prompt-writing skill, and a design skill.

SD2112 · AI IN DESIGN · WEEK 03

52

07 · ON GENAI · IMAGE TO IMAGE

Four moves.

1 · PICK

The model with an image input.

On genai.polyu.edu.hk, choose the image editor that takes reference images: Flux, or Qwen Image Edit. Up to three images in. Same login as week 1.

2 · SHOW

Attach the references.

One to three pictures: your own from round 1, your partner's, one more if it helps. Each one is an example the model stands near. Their order matters: image 1 pulls hardest.

3 · TELL

One sentence, and what from where.

"Blend image 1 and image 2 into one thing: the shape of the first, the material of the second." Say "one thing, not two". A reference cannot forbid; the sentence can ask.

4 · ITERATE

One change per run.

Swap a reference, or change one phrase, never both: then you know which machine answered. Keep every prompt with its picture; the caption is the prompt and the references.

SD2112 · AI IN DESIGN · WEEK 03

53

07 · A PROMPT FOR A BLEND

Say what comes from where.

Fill the brackets. Attach the images in the order the prompt names them. Run once, look, change one line.

Name the thing you want as one noun if you can: "a lamp", "a room", "a creature". A blend needs a home.

Say what each image gives. Left open, the model averages, and the stronger prototype wins.

Ask for the line back: what it took from each. If it cannot say, look harder at the picture.

Blend the two concepts into ONE thing.

IMAGE 1 is [concept A]:

keep its [shape / colour / mood].

IMAGE 2 is [concept B]:

keep its [material / setting / use].

The result is a single object or scene,

not two things side by side.

Photographic, plain background.

Nothing I did not ask for.

Then, in one line: what did you take

from each image?

SD2112 · AI IN DESIGN · WEEK 03

54

08

The blend.

30 minutes · alone, then in pairs · genai.polyu.edu.hk

SD2112 · AI IN DESIGN · WEEK 03

55

ACTIVITY · 1 — ALONE

8 min

Pick a concept. Make it visible.

Any concept: as specific as your first bicycle, as broad as justice; abstract or concrete. Then: how would a picture say it? Write the prompt, text only, and generate on genai.polyu.edu.hk.

Look. Does the picture say the concept to a stranger? Change one thing, run again. Two runs at most.

Upload it. Caption: the concept, in 50 characters or fewer. That caption is what your partner will work from.

ROUND 1 · ALONE · 8 MIN

1. Pick a concept. Anything:

as small as "my first bicycle",

as big as "justice"; concrete or

abstract; "Tuesday", "hospitality",

"a minibus at 2 am", "entropy".

2. How would a picture say it?

Write the prompt. Text only.

3. Generate. Look. Change one thing.

Two runs at most.

4. Upload. Caption: the concept,

50 characters or fewer.

SD2112 · AI IN DESIGN · WEEK 03

56

08 · CAPTURE 1 · IMAGE UPLOAD · EVERYONE

Everyone: your concept, as a picture.

The image from round 1. Caption: the concept, 50 characters or fewer.

SD2112 · AI IN DESIGN · WEEK 03

57

Image upload

ACTIVITY · 2 — IN PAIRS

12 min

Blend two concepts into one picture.

Show each other your picture and your concept. Talk: how could the two become one thing, not two things side by side? What does each contribute?

Write the prompt together, from the template. Images in: your two pictures, plus one more if it helps; three at most. The image editor on GenAI. Two runs.

One upload per pair. Caption: concept A + concept B, and one line on what came from each.

ROUND 2 · IN PAIRS · 12 MIN

1. Show each other the picture and

the concept. Two minutes.

2. Talk: how could the two become

ONE thing? What from each?

3. Write the prompt together

(template, previous slide).

Images in: your two pictures,

plus one more if it helps. Max 3.

4. Image edit model. Two runs.

5. One upload. Caption:

A + B, and what came from each.

SD2112 · AI IN DESIGN · WEEK 03

58

08 · CAPTURE 2 · IMAGE UPLOAD · ONE PER PAIR

One per pair: the blend.

The image from round 2. Caption: A + B, and what came from each.

SD2112 · AI IN DESIGN · WEEK 03

59

Image upload

08 · WHAT JUST HAPPENED

You blended concepts with a machine that has no definitions.

Alone: your concept became its prototype. The picture the model found first was the middle of its examples, the typical bicycle, the typical justice. Rosch, on the wall.

In pairs: a blend, or a collage, or one concept ate the other. Where you got a collage, the machine combined like a rule: both, side by side. Where you got a blend, it did what no definition can do, and you cannot say how, and neither can it.

Where a concept got lost, it was the one with the weaker prototype. The middle pulls, in a mind and in a machine. You chose which pictures went in, and in what order.

The machine made every image. You chose the concepts. That was the design.

SD2112 · AI IN DESIGN · WEEK 03

60

08 · CHALLENGE 2 · DUE BEFORE WEEK 4

A picture from text and references.

THE CONCEPTS

Two or three, in a line each.

Your own, not today's. Say each in a line: what it is, and what a picture of it must have.

THE REFERENCES

One to three images, yours.

Your photographs, your drawings, your round-1 picture: not other people's work. Say what each one is for.

THE RESULT

One image, on Canvas.

The image, the prompt word for word, the references, and one sentence: what came from where, and what got lost. Name the model.

THE VOTE

Bring it next week.

The room votes in week 4; the winners get shown and a participation star. Evidence for your reflection: your second experiment of five.

SD2112 · AI IN DESIGN · WEEK 03

61

08 · HOMEWORK · WATCH BEFORE WEEK 4

Next week: language machines.

3Blue1Brown, "Large Language Models explained briefly": eight minutes on tokens, embeddings and transformers, the machine B that writes.

Watch it before class; the quiz in week 7 draws on it.

Bring the specs from week 2: next week they become briefs.

Also: a laptop, and your GenAI login.

SD2112 · AI IN DESIGN · WEEK 03

62

See you next week. Language machines.

venetanji.github.io/sd2112-teaching · www.youtube.com/playlist?list=PLU58DFEI5YDQ

a·t4x

SD2112 · AI in Design · Week 03
1

POLYU SCHOOL OF DESIGN · SD2112 · WEEK 03 · LECTURE + WORKSHOP

Learning from examples.

Week 3 — concepts, neurons, GPUs, and a picture that blends two ideas.

2

SD2112 · WEEK 03

Today

01 Last week, in your words

02 What is a concept?

03 Prototypes: Rosch, 1975

04 The birth of AI, twice

05 Neurons that learn: Hinton

06 Parallel: GPUs and modern AI

07 Blending concepts

08 Activity: the blend

3

01

Last week, in your words

THE FILM · THE WALL · THE MAP

4

01 · QUESTION · WORD CLOUD

AlphaGo. One word.

You watched the film. The first word that comes to mind.

ClassPoint · word cloud — answer on the projector

5

01 · WEEK 2 · THE WALL · 125 PICTURES · ONE RULE EACH · THE CAPTIONS

Every picture the pairs uploaded last week, both rounds: LeWitt's ten points with a twist, then a rule of the pair's own, turned into p5.js by a language model. Nobody defined "a picture"; every one of these is one.

6

01 · THE SEMESTER

Where we are

1 · What is AI?

WEEK 1

Two ways to teach a machine

WEEK 2

Rules that make things: code, chance, generative art

WEEK 3

Learning from examples: concepts, neurons, Move 37

2 · AI for the creative process

WEEK 4

Language machines: LLMs, prompts, agents

WEEK 5

Image machines: diffusion, CLIP, mediation

WEEK 6

Sound machines: music, voice, spectrograms

Mid-term

WEEK 7

Mid-term quiz · project pitches · teams · reflection due

3 · AI inside products

WEEK 8

AI as design material: use vs incorporate

WEEK 9

Data, bias and privacy

WEEK 10

Recommendation systems and the feed

4 · The designer's turn

WEEK 11

Curating outputs and datasets · authorship

WEEK 12

Language as an interface: chatbots and agents

Showcase

WEEK 13

Poster fair · final quiz

7

02

What is a concept?

IDEAS · DEFINITIONS · PLATO · WITTGENSTEIN

8

02 · THE CLASSICAL THEORY · ARISTOTLE TO THE DICTIONARY

A concept is a definition.

A definition is a list of properties a thing must have to belong: necessary, and together sufficient. Bachelor = man + unmarried.

Aristotle, pointing down at the things, is this theory: sort them by the properties they share and keep the ones that are necessary. Plato, pointing up, disagrees.

Plato and Aristotle, detail of Raphael's The School of Athens, 1509–1511. Public domain, Wikimedia Commons.

9

02 · SOUNDS EASY · TRY THESE

Write the definition.

A PRIME NUMBER

Easy.

Divisible only by one and by itself. Every number is in or out, no argument. Mathematics is where the classical theory lives.

FURNITURE

Try.

Movable, for a room, for living? A lamp? A rug? A built-in wardrobe? Every list you write admits something wrong or leaves out something right.

SUNSET COLOUR

Try.

Orange? Pink? Grey over Kowloon? You know it when you see it, and you cannot say it in a way a stranger could check.

A PIZZA

Try.

Dough, tomato, cheese, baked. Then a white pizza, a calzone, pineapple. Is a pizza defined by its base, its shape, its country, or by pizza places?

AN A+ ESSAY

The rubric tries.

Argument, evidence, structure, style, with bands. It is the best list we can write, and two markers still disagree at the edge.

10

"But in what way will you look for it, Socrates, this thing that you don't know at all what it is? Or even if you should meet right up against it, how will you know that this is the thing you didn't know?"

Meno to Socrates. Plato, Meno, 80d, c. 385 BC.

11

02 · PLATO · MENO · WHERE IDEAS COME FROM

Ideas are real. Definitions are not their essence.

Socrates calls it a debater's trick: you cannot seek what you know, because you know it, nor what you don't know, because you don't know what to look for.

Whatever you think of the soul, the lesson holds: we have ideas without definitions. The definition is not the essence of a concept.

Socrates, Roman marble after a Greek original, 1st century, Louvre. Photo: Eric Gaba, CC BY-SA 2.5, Wikimedia Commons.

12

"Don't think, but look!"

Ludwig Wittgenstein, Philosophical Investigations, §66, 1953, on what all games have in common

13

02 · WITTGENSTEIN · 1953 · FAMILY RESEMBLANCE

No feature runs through all of them.

Six games, seven features. A definition would need a full column; there is none. Chess and ring-a-ring-a-roses share almost nothing, yet both are games, because a chain of resemblances links them: overlapping and criss-crossing, like the resemblances in a family.

WITTGENSTEIN, 1953, §66 · "CONSIDER FOR EXAMPLE THE PROCEEDINGS THAT WE CALL GAMES" board ball cards winning luck skill players chess football poker patience tennis ring-a-ring-a-roses in all of them? no no no no no no no No column is full: no feature runs through every game. A definition needs a full column. The resemblances overlap and criss-cross instead.

After Philosophical Investigations §66–67. The features are ours; the argument is his.

14

02 · THE CLASSICAL THEORY · WHERE IT LEAVES US

Easy to check. Impossible to write.

THE BENEFIT

Categorising is trivial.

Set formal requirements and the check is mechanical: every property, present or absent. That is why a rule-based machine can hold a concept at all: a definition is a rule.

NEW IDEAS

By assembly.

Put two definitions together and you have a third: unmarried + man. Which properties survive when you combine "pet" and "fish"? Assembly is exactly where definitions start to fail.

THE PROBLEM

Most concepts have no definition.

Outside mathematics and law, almost nothing you design has one, and you use those concepts all day without it. So what is a concept, if not a definition?

15

03

Prototypes

ROSCH · 1975 · A MIDDLE AND AN EDGE

16

03 · QUESTION · WORD CLOUD

Name a fruit. The first one that comes to mind.

One word. Do not think.

ClassPoint · word cloud — answer on the projector

17

03 · ELEANOR ROSCH · BERKELEY · 1975

I asked people to rate fruits.

Rosch gave about two hundred students lists of items in ten categories, fruit, birds, furniture, vehicles, and asked for each: how good an example of the category is this? From 1, a very good example, to 7, a very poor one.

Two papers in 1975, with Carolyn Mervis: typicality is real, shared, and it is made of family resemblance, counted.

Eleanor Rosch, 2012 (Wikimedia Commons, CC0). Rosch 1975, J. Exp. Psych.: General 104; Rosch & Mervis 1975, Cognitive Psychology 7.

18

03 · ROSCH · 1975 · THE FRUIT

Some fruits are more fruit than others.

Thirteen of her fifty-one fruits, in her order. Orange, apple and banana sit at the very top, about 1 on the scale; tomato is above 5; the olive comes last.

A concept with a middle and an edge cannot be a definition. Definitions have no middle.

ROSCH, 1975 · "HOW GOOD AN EXAMPLE OF A FRUIT IS THIS?" 1 · a very good example 7 · a very poor one 1 2 3 4 5 6 7 1 orange 2 apple 3 banana 4 pear 5 plum 6 strawberry 7 pineapple 8 lemon 9 honeydew 10 date 11 coconut 12 tomato 13 olive

Rank order of Rosch's 1975 goodness-of-example ratings for fruit, 1 = a very good example, 7 = a very poor one; the positions are approximate, the order is hers.

19

03 · WHAT TYPICALITY DOES

The middle is faster, first, and easier.

JUDGED

Typical items are called members more often.

Hampton, 1979.

FASTER

Categorising a typical item takes less time.

Rips, Shoben & Smith, 1973.

LEARNED FIRST

Children learn the typical members before the atypical ones.

Rosch & Mervis, 1975.

EASIER TO TEACH

A category is learned faster from typical examples.

Mervis & Pani, 1980.

UNDERSTOOD

In a sentence, a typical member is understood more easily.

Garrod & Sanford, 1977.

20

03 · PROTOTYPE THEORY

A concept is its best examples.

THE THEORY

A structured representation of what members tend to have.

Not a list of conditions but a picture of the typical case, and a distance from it. Membership is a degree: a robin is a very good bird, a penguin a poor one, and neither needs a definition.

THE GAIN

Only similarity is needed.

No definition to write: you judge a new thing by how much it resembles what you have seen. That is learning from examples, and it is why a machine can hold "chair" with no rule for it.

THE COST

Outliers, and combinations.

Exceptions are hard: there are fewer examples at the edge, so the edge is unsure. And combining concepts is a puzzle: which properties of "pet" and "fish" does "pet fish" keep?

21

03 · QUICK CHECK · MULTIPLE CHOICE

Which sentence is prototype theory?

A A chair is anything with a seat, a back and at least three legs

B Every chair shares one feature that makes it a chair

C Some chairs are better examples of "chair" than others

D A chair is whatever the dictionary says it is

ClassPoint · multiple choice — answer on the projector

22

04

The birth of AI, twice

1956 · DARTMOUTH · 1958 · THE PERCEPTRON

23

04 · DARTMOUTH · SUMMER 1956

AI gets its name, and a bet.

31 August 1955: McCarthy, Minsky, Rochester and Shannon propose a summer study "on the basis of the conjecture that every aspect of learning or any other feature of intelligence can in principle be so precisely described that a machine can be made to simulate it."

Haugeland named it GOFAI in 1985: good old-fashioned AI.

The first page of the proposal, 31 August 1955. Public domain, Wikimedia Commons.

24

04 · THE OTHER BIRTH · ROSENBLATT · 1958

A machine modelled on the brain, not on logic.

Frank Rosenblatt, Cornell, 1957–58: the perceptron. Not a program that applies rules but a network of simple units modelled on neurons, whose connections adjust from examples.

No definition of "A" anywhere. The knowledge is in the weights, and the weights come from the examples.

Rosenblatt, "The design of an intelligent automaton", 1958, figures 1 and 2. Public domain, Wikimedia Commons.

25

04 · THE MARK I PERCEPTRON · 1960 · PHOTO: US NAVY, PUBLIC DOMAIN

400 photocells look at a letter; motors turn the potentiometers that hold the weights when a guess is wrong. The New York Times, July 1958: the Navy expects it "will be able to walk, talk, see, write, reproduce itself and be conscious of its existence".

26

04 · ONE NEURON

A neuron is a weighted vote.

Two inputs, two weights, a bias, a threshold. Multiply, add, compare with zero: that is the whole unit. Three numbers hold everything it knows. Rosenblatt, 1958, called it a perceptron; the shape and the size are the week-1 cup.

ONE NEURON · ROSENBLATT, 1958 × +1.6 1.1 height ÷ width × -0.8 0.4 size INPUTS · THE OBJECT Σ + b b = -1.2 1.1×+1.6 + 0.4×-0.8 -1.2 = +0.24 WEIGHTS · THE KNOWLEDGE above 0? 1 GUESS +0.24 > 0 so: "cup" three numbers decide. learning = changing them when the guess is wrong

Rosenblatt, "The perceptron: a probabilistic model for information storage and organization in the brain", Psychological Review 65, 1958. In the html deck the neuron learns live, one example at a time.

Open the live sketch › — click = pause · C = start again

27

04 · THE PERCEPTRON · WHAT THE CODE DOES

Twenty-four dots, one line, and a nudge.

THE EXAMPLES

Twenty-four points, two classes.

Twelve orange A and twelve teal B, placed with a bell-curve die: most land near the middle of their group, a few stray. These dots are all the machine ever sees.

THE RULE

Three numbers draw one line.

w1, w2 and b are one straight line across the canvas. The rule guesses A on one side of it and B on the other. Where the line starts is arbitrary; it begins wrong.

THE NUDGE

Wrong? Move a little.

Every frame is one pass over the examples. Where the guess is wrong, the three numbers move a little towards that example, so the line turns. When nothing is wrong, it stops: "wrong: 0".

ADD POINTS

Click, and it has to move again.

A click adds an A where you click; shift-click adds a B. Put an A among the Bs and it never settles: one line cannot. C starts again.

28

04 · THE PERCEPTRON · 1958 · IN P5.JS

Wrong? Nudge the three numbers. Again.

let pts = [], w1 = 0.3, w2 = -1, b = 0.1;   // three numbers
const lr = 0.05;                            // how big a nudge
const g = (m, s) => randomGaussian(m, s);   // a bell-curve die
function setup() {
  createCanvas(600, 600); randomSeed(3); frameRate(8);
  for (let i = 0; i < 12; i++) {            // twelve A, twelve B
    pts.push([g(-.45, .2), g(-.3, .2), -1]);
    pts.push([g(.45, .2), g(.35, .2), 1]);
  }
}
function guess(x, y) { return w1 * x + w2 * y + b > 0 ? 1 : -1; }
function draw() {                           // one pass per frame
  let wrong = 0;
  for (let [x, y, t] of pts)                // wrong? nudge
    if (guess(x, y) != t) { wrong++;        // a little, towards it
      w1 += lr * t * x; w2 += lr * t * y; b += lr * t; }
  background(255); stroke(0); strokeWeight(2);
  let ya = -(b - w1) / w2, yb = -(b + w1) / w2;   // where the rule
  line(0, 300 - 300 * ya, 600, 300 - 300 * yb);   // says 0
  for (let [x, y, t] of pts) {
    fill(t < 0 ? '#ED6D24' : '#64C2C3');
    circle(300 + 300 * x, 300 - 300 * y, 14);
  }
  fill(0); noStroke(); text('wrong: ' + wrong, 16, 24);
}

One pass per frame; a wrong guess moves the three numbers a little. "wrong: 0": every example is on its side, the line has settled. Click adds an A, shift-click a B · edit it live.

Open the live sketch › — click = add an A · shift-click = a B · C = again

29

04 · 1958 · 1969 · 1986

A machine that learns, and what it took.

1958 · ROSENBLATT

The perceptron.

The paper in Psychological Review, then the Mark I. A machine that learns, and the press promising consciousness within the year. Rosenblatt died in 1971, aged 43, with the idea out of fashion.

1969 · MINSKY & PAPERT

One line cannot.

Perceptrons, the book: a single layer can only draw one straight line, so it cannot even learn XOR. Funding for networks dries up for a decade. The rules school, Minsky's own, wins the seventies.

1986 · BACKPROPAGATION

Rumelhart, Hinton & Williams.

Four pages in Nature: put units in layers, send the error backwards, nudge every weight. Hidden units invent their own features. Connectionism has its learning rule, and the other school of AI is back.

30

04 · THE LIMIT, AND THE FIX

One line cannot. Two layers can.

XOR: A on one diagonal, B on the other. No straight line separates them, so one neuron never settles. Add a hidden layer of two neurons and the network can draw two lines and vote on them. The band is a rule nobody wrote.

1969 · MINSKY & PAPERT · ONE LINE CANNOT A on one diagonal, B on the other: no line gets all of them right 1986 · A HIDDEN LAYER, TRAINED BY BACKPROPAGATION x, y two lines A or B each hidden unit is one neuron, one line each; the output unit votes on their two verdicts. wrong guess: the error travels backwards and every weight moves a little. (9 weights here; 60 million in AlexNet) TWO LINES · A IN THE BAND, B OUTSIDE a rule nobody wrote: "A is in the band"

Minsky & Papert, Perceptrons, 1969 · Rumelhart, Hinton & Williams, "Learning representations by back-propagating errors", Nature 323, 1986.

31

05

Neurons that learn

HINTON · CONNECTIONISM · 1986 · 2012 · 2024

32

05 · GEOFFREY HINTON

Fifty years betting on the brain.

A psychologist, like Rosenblatt. 1986: backpropagation, with Rumelhart and Williams, when almost nobody believed in networks.

2024: the Nobel Prize in Physics, with John Hopfield, "for foundational discoveries and inventions that enable machine learning with artificial neural networks".

Geoffrey Hinton at the 2024 Nobel Lectures, Stockholm University. Photo: Jay Dixit, CC BY-SA 4.0, Wikimedia Commons.

33

05 · BACKPROPAGATION · 1986

Send the error backwards. Nudge every weight.

Forward: every unit sums its inputs, weighted, and passes a number on. At the end, a guess.

The perceptron's rule, extended to units that never see the answer directly. Rumelhart, Hinton & Williams, Nature 323, 1986.

34

05 · BACKPROPAGATION · 1986 · THE PICTURE, LIVE

The guess goes forward. The error comes back.

THE EXAMPLE PIXELS IN HIDDEN HIDDEN GUESS OUT chair 0.35 cup 0.65 THE TRUTH: a chair chair should be 1.00 it said 0.35 error: 0.65 then: every weight moves FORWARD · every unit sums its inputs and passes a number on · the guess comes out at the end BACKWARD · the error is shared out along the same connections · every weight moves a little, in proportion to its share

Nine pixels in, five and three hidden units, two out: nineteen units, 66 weights. Rumelhart, Hinton & Williams, "Learning representations by back-propagating errors", Nature 323, 1986.

Open the live sketch › — click = pause · C = start again

35

05 · HUMANS + CONCEPTS · MACHINES + CONCEPTS

Two theories. Two machines.

HUMANS + CONCEPTS MACHINES + CONCEPTS RULE-BASED CLASSICAL THEORY a concept is a definition: necessary and sufficient conditions Aristotle · Kant · the dictionary GOFAI · SYMBOLIC AI knowledge written down as rules, applied by a program Dartmouth 1956 · ELIZA · expert systems ADAPTIVE PROTOTYPE THEORY a concept is its best examples, membership a matter of degree Wittgenstein 1953 · Rosch 1975 CONNECTIONISM · MACHINE LEARNING the knowledge is in the weights, found from examples Rosenblatt 1958 · Hinton 1986 · 2012 · today the same two ideas, in a mind and in a machine: a rule you can read, or examples you cannot

Rule-based: classical theory + GOFAI, a definition a machine applies. Adaptive: prototype theory + connectionism, examples held in weights nobody can read. Your reflection is about this distinction.

36

05 · THE DEAL

Fluent. Fuzzy. Opaque.

FLUENT

It handles the case nobody wrote.

A learned concept covers the middle of its examples and interpolates between them. That is why it can write, draw and see: no list of conditions could.

FUZZY

Every answer is a degree.

Chair 0.93, stool 0.05. There is no line, only a slope, and it moves with the examples. The edge of the concept is exactly where it is least sure, and where you work.

OPAQUE

It cannot say why.

Sixty million numbers found by nudging. No line to point at, no rule to read, no fix but more examples. When it is wrong you cannot ask it; you can only retrain it.

37

05 · WHERE WE ARE

Machine A is a rule you wrote. Machine B is a rule nobody wrote.

38

AFTER THE BREAK · GPUS · MODERN AI · THEN THE BLEND

Break. Ten minutes.

39

06

Parallel

EVERY UNIT AT ONCE · GPUS · 2012 · TODAY

40

06 · PARALLEL CALCULATION

Every unit decides on its own.

A Turing machine does one step at a time, and its whole state sits in one place, readable. A network is thousands of small sums that do not wait for each other and share nothing: harder to read, and far faster for some tasks, if you have something that can do thousands of sums at once. For decades, nobody did.

A TURING MACHINE · ONE STEP AT A TIME 1 2 3 4 5 6 7 8 9 10 1 0 1 1 0 0 1 0 1 1 0 1 0 0 one head, one tape: the whole state is in one place, and you can read it the next step waits for this one · rules, applied in order exact · explainable · one thing at a time A NETWORK · EVERY UNIT AT ONCE Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ Σ thirty-two sums at once, none of them waiting: one tick for all no state in one place, nothing to read · examples, not rules fast, with thousands of small processors · opaque either way AlexNet: about 700 million multiply-adds per picture; a GPU does thousands at a time

The rule-based machine is serial by nature; the learned one is parallel by nature. The chip you run it on decides whether that is a strength or a wait.

41

06 · THE SAME RULE, 240,000 TIMES · IN P5.JS

One core, pixel by pixel. A GPU, all at once.

let cores, i = 0, t0;                 // pixels per frame: a slider
const n = 60, W = 600, H = 400;       // steps per pixel; the canvas
function setup() {
  createCanvas(W, H); pixelDensity(1);
  cores = createSlider(0, 12, 8, 1, 'cores: 2^k');
  cores.input(restart); restart();
}
function restart() {                  // from the top, blank
  background(255); loadPixels(); i = 0; t0 = millis();
}
function draw() {
  let k = 1 << cores.value();         // 2^k pixels in this frame
  for (let j = 0; j < k && i < W * H; j++, i++) {   // pixel i
    let a = (i % W - 420) / 200, b = (floor(i / W) - 200) / 200;
    let x = 0, y = 0, s = 0;            // c; z starts at 0
    while (x * x + y * y < 4 && s < n) {   // z = z² + c, again
      let t = x * x - y * y + a; y = 2 * x * y + b; x = t; s++;
    }
    let v = s == n ? 0 : 255 * sqrt(s / n), q = 4 * i;
    pixels[q] = v * .3; pixels[q + 1] = v * .6; pixels[q + 2] = v;
  }
  updatePixels(); noStroke(); fill(255); rect(0, 380, 600, 20);
  let sec = nf((millis() - t0) / 1000, 1, 1);
  fill(0); text(k + '/frame · ' + i + ' px · ' + sec + ' s', 10, 394);
}

The Mandelbrot rule from week 2, one pixel after another. The slider is how many pixels are done in each frame: 1, or 4,096. Same rule, same picture, a thousand times sooner · edit it live.

Open the live sketch › — the slider is how many at once · click = from the top

42

06 · GPUS · NOT ONLY FOR GAMING

The chips made for games.

A graphics processing unit does the same small calculation on millions of pixels at once: textures, shading, vertices, physics. Games needed that, and paid for twenty years of it.

The other school of AI finally had its engine.

An NVIDIA GeForce GTX 580, late 2010: the card AlexNet was trained on, two of them. Photo: TheStriker, CC BY-SA 4.0, Wikimedia Commons.

43

06 · INSIDE THE GTX 580 · THE GF110 DIE · 512 CORES · 3 BILLION TRANSISTORS

The chip under the fan, sanded down and photographed: sixteen blocks of thirty-two small processors, each doing the same job on its own piece of the picture. This, twice, is what learned to see in 2012. Photo: Fritzchens Fritz, CC0, Wikimedia Commons.

44

06 · 2012 · ALEXNET

Deep: the features are learned too.

30 September 2012: Krizhevsky, Sutskever and Hinton win the ImageNet challenge with an eight-layer network: 15.3% error against 26.2% for the runner-up, trained on 1.2 million labelled photos in about a week on two GTX 580s. The other entries ran on hand-crafted features; AlexNet grew its own from the pixels.

PIXELS EDGES PARTS OBJECTS A LABEL leg seat back chair 0.93 stool 0.05 table 0.02 input: the pixels layer 1 (convolutional) layers 2 – 5 (convolutional) layers 6 – 8 (fully connected) output: 1,000 scores AlexNet, 2012: 8 layers, 60 million weights, all found from 1.2 million labelled photos. nobody wrote a rule for "edge" or "leg"; the layers became those detectors because it lowered the error

ImageNet: Fei-Fei Li, from 2006; 14 million images labelled by 49,000 Mechanical Turk workers in 167 countries.

45

06 · 2016 · ALPHAGO · MOVE 37

A move outside the human middle.

Seoul, 10 March 2016, game two, move 37. The commentators call it a mistake. Humans play it, said DeepMind, one time in ten thousand.

Trained on human games first, then on millions of games against itself. Move 37 came from the second set, and it was right.

Your word cloud at the start of class was the verdict. Creative, alien, or more examples?

Watch on YouTube ›

46

06 · MODERN AI · 2012 – 2026

The same loop, a billion times bigger.

2012 AlexNet

60 million weights, two gaming GPUs, a week. The examples school wins at seeing.

2014 GANs

Two networks, one forging, one judging. Edmond de Belamy, 2018, was one of these.

2017 The transformer

"Attention is all you need": the architecture inside every chatbot since.

2020 GPT-3

175 billion weights, trained on the web. Scale as the strategy.

2022 Diffusion · ChatGPT

Stable Diffusion, then ChatGPT: machine B reaches everyone through a text box.

2024 Two Nobel Prizes

Physics: Hopfield and Hinton, the networks. Chemistry: Hassabis and Jumper, AlphaFold.

2025 Editors that take references

Flux Kontext, Qwen-Image-Edit, FLUX.2: show the model pictures, not only words.

2026 You

Both machines in every tool. The designer decides which, and when, and with which examples.

47

06 · HOW MANY NUMBERS · 1958 – 2026

A thousand times more numbers, every ten years.

1 a thousand a million a billion a trillion HOW MANY NUMBERS A MODEL HOLDS · EVERY LINE UP IS TEN TIMES MORE language and vision image models 3 one neuron 1958 60 thousand LeNet-5 1998 60 million AlexNet 2012 1.5 billion GPT-2 2019 175 billion GPT-3 2020 0.9 billion Stable Diffusion 2022 12 billion FLUX.1 2024 405 billion Llama 3.1 2024 20 billion Qwen-Image 2025 trillions the largest 2026, not published counts from the papers and model cards; the last one is an estimate: the labs no longer say

A learned model is measured by how many numbers it holds: three in our neuron, 60 million in AlexNet, 175 billion in GPT-3, trillions today. The loop never changed; the count did, and the chips that hold it.

48

07

Blending concepts

PET FISH · HOUSEBOAT · A PICTURE FROM TWO IDEAS

49

07 · COMBINING CONCEPTS

Bachelor was easy. Pet fish is not.

THE CLASSICAL WAY

Add the conditions.

Man + unmarried. A rule combines any two definitions: everything from both, nothing new. It also gives you "fake gun" (a gun?) and "small elephant" (small?). Assembly is where lists show their seams.

THE PROTOTYPE PROBLEM

Typicality does not multiply.

Picture a pet: not a goldfish. Picture a fish: not a goldfish. Picture a pet fish: a goldfish (Osherson & Smith, 1981, who used a guppy). Which properties survive the combination? Nobody has found the rule (Hampton, 1988).

THE BLEND

Two inputs, one new space.

Fauconnier & Turner, 2002: we build a blended space that takes some structure from each input and grows structure of its own. A houseboat, a computer virus, a desk lamp. We do it all day; we cannot say how.

50

07 · FAUCONNIER & TURNER · 2002

Two inputs. One new space.

Two input spaces: a house and a boat. A generic space of what they share: a structure, a place, people who use it.

The blend: a houseboat. It took the rooms from the house and the hull from the boat, and it is one thing, not two.

GENERIC what both share INPUT 1 house lived in · stays put INPUT 2 boat floats · moves · a crew THE BLEND houseboat lived in, and it floats after Fauconnier & Turner, The Way We Think, 2002

After Fauconnier & Turner, The Way We Think: Conceptual Blending and the Mind's Hidden Complexities, 2002.

51

07 · FAUCONNIER & TURNER · WHAT A BLEND DOES

Some stays behind. Some is new.

SELECTIVE PROJECTION

Not every property comes across.

The house's foundations stay behind; so does the boat's cargo. The blend takes what it needs from each input and leaves the rest.

EMERGENT STRUCTURE

The blend has what no input had.

A mooring fee, a bathroom on deck, a view that changes. None of it was in the house or the boat. That is where the new idea lives.

EVERY MASH-UP

A computer virus. A desk lamp. A mermaid.

Every metaphor, every product mash-up, every "what if a chair were a cup" is one of these.

52

07 · A MACHINE THAT BLENDS

Show it two pictures. Ask for one.

An image editor that takes references has the examples; a reference image is one more example, placed in front. Give it two and a sentence and one of three things comes back: a collage, both things side by side, which is what a rule would do; a blend, one thing with properties of both, which no definition could do; or the stronger prototype eats the other, which is the middle pulling, as always.

A COLLAGE cup and chair, side by side a rule can do this: both conditions, nothing new A BLEND one thing with properties of both no definition can do this; a prototype machine can ONE WINS the stronger prototype eats the other watch for it: the middle pulls, always

Cup and chair, three outcomes. Making the model blend rather than collage is a prompt-writing skill, and a design skill.

53

07 · ON GENAI · IMAGE TO IMAGE

Four moves.

1 · PICK

The model with an image input.

On genai.polyu.edu.hk, choose the image editor that takes reference images: Flux, or Qwen Image Edit. Up to three images in. Same login as week 1.

2 · SHOW

Attach the references.

One to three pictures: your own from round 1, your partner's, one more if it helps. Each one is an example the model stands near. Their order matters: image 1 pulls hardest.

3 · TELL

One sentence, and what from where.

"Blend image 1 and image 2 into one thing: the shape of the first, the material of the second." Say "one thing, not two". A reference cannot forbid; the sentence can ask.

4 · ITERATE

One change per run.

Swap a reference, or change one phrase, never both: then you know which machine answered. Keep every prompt with its picture; the caption is the prompt and the references.

54

07 · A PROMPT FOR A BLEND

Say what comes from where.

Fill the brackets. Attach the images in the order the prompt names them. Run once, look, change one line.

Ask for the line back: what it took from each. If it cannot say, look harder at the picture.

Blend the two concepts into ONE thing.
 
IMAGE 1 is [concept A]:
keep its [shape / colour / mood].
 
IMAGE 2 is [concept B]:
keep its [material / setting / use].
 
The result is a single object or scene,
not two things side by side.
Photographic, plain background.
Nothing I did not ask for.
 
Then, in one line: what did you take
from each image?
55

08

The blend.

30 MINUTES · ALONE, THEN IN PAIRS · GENAI.POLYU.EDU.HK

56

ACTIVITY · 1 — ALONE

8 min

Pick a concept. Make it visible.

Any concept: as specific as your first bicycle, as broad as justice; abstract or concrete. Then: how would a picture say it? Write the prompt, text only, and generate on genai.polyu.edu.hk.

Look. Does the picture say the concept to a stranger? Change one thing, run again. Two runs at most.

Upload it. Caption: the concept, in 50 characters or fewer. That caption is what your partner will work from.

ROUND 1 · ALONE · 8 MIN
 
1. Pick a concept. Anything:
   as small as "my first bicycle",
   as big as "justice"; concrete or
   abstract; "Tuesday", "hospitality",
   "a minibus at 2 am", "entropy".
 
2. How would a picture say it?
   Write the prompt. Text only.
 
3. Generate. Look. Change one thing.
   Two runs at most.
 
4. Upload. Caption: the concept,
   50 characters or fewer.
57

08 · CAPTURE 1 · IMAGE UPLOAD · EVERYONE

Everyone: your concept, as a picture.

The image from round 1. Caption: the concept, 50 characters or fewer.

ClassPoint · image upload — answer on the projector

58

ACTIVITY · 2 — IN PAIRS

12 min

Blend two concepts into one picture.

Show each other your picture and your concept. Talk: how could the two become one thing, not two things side by side? What does each contribute?

Write the prompt together, from the template. Images in: your two pictures, plus one more if it helps; three at most. The image editor on GenAI. Two runs.

One upload per pair. Caption: concept A + concept B, and one line on what came from each.

ROUND 2 · IN PAIRS · 12 MIN
 
1. Show each other the picture and
   the concept. Two minutes.
 
2. Talk: how could the two become
   ONE thing? What from each?
 
3. Write the prompt together
   (template, previous slide).
   Images in: your two pictures,
   plus one more if it helps. Max 3.
 
4. Image edit model. Two runs.
 
5. One upload. Caption:
   A + B, and what came from each.
59

08 · CAPTURE 2 · IMAGE UPLOAD · ONE PER PAIR

One per pair: the blend.

The image from round 2. Caption: A + B, and what came from each.

ClassPoint · image upload — answer on the projector

60

08 · WHAT JUST HAPPENED

You blended concepts with a machine that has no definitions.

Alone: your concept became its prototype. The picture the model found first was the middle of its examples, the typical bicycle, the typical justice. Rosch, on the wall.

In pairs: a blend, or a collage, or one concept ate the other. Where you got a collage, the machine combined like a rule: both, side by side. Where you got a blend, it did what no definition can do, and you cannot say how, and neither can it.

Where a concept got lost, it was the one with the weaker prototype. The middle pulls, in a mind and in a machine. You chose which pictures went in, and in what order.

The machine made every image. You chose the concepts. That was the design.

61

08 · CHALLENGE 2 · DUE BEFORE WEEK 4

A picture from text and references.

THE CONCEPTS

Two or three, in a line each.

Your own, not today's. Say each in a line: what it is, and what a picture of it must have.

THE REFERENCES

One to three images, yours.

Your photographs, your drawings, your round-1 picture: not other people's work. Say what each one is for.

THE RESULT

One image, on Canvas.

The image, the prompt word for word, the references, and one sentence: what came from where, and what got lost. Name the model.

THE VOTE

Bring it next week.

The room votes in week 4; the winners get shown and a participation star. Evidence for your reflection: your second experiment of five.

62

08 · HOMEWORK · WATCH BEFORE WEEK 4

Next week: language machines.

3Blue1Brown, "Large Language Models explained briefly": eight minutes on tokens, embeddings and transformers, the machine B that writes.

Watch on YouTube ›

63

See you next week. Language machines.

VENETANJI.GITHUB.IO/SD2112-TEACHING · WWW.YOUTUBE.COM/PLAYLIST?LIST=PLU58DFEI5YDQ