See the idea, then play with it.
Small, beautiful, self-contained explorers for the big machine-learning ideas. Each one runs right in your browser — perfect for a projector. More are on the way.
Model Builder ★
The literal glassbox: build a neural network by dragging layers or by writing Spectra code — the two stay in sync — then send a fruit through it and watch the answer light up while the wrongness curve drops as it trains.
Decision-Tree Builder ★
The most see-through AI: grow a decision tree deeper and watch it carve the space into yes/no blocks — the region map, the flowchart of questions, and the Spectra code stay in sync — then drop a fruit in and watch it fall to an answer.
Mean, median & spread
Drag data points along a line and watch the average, the middle, and the spread move — and feel why one far-away value yanks the mean but not the median.
Percentages & proportions
Slide how many of 100 squares are filled and see the same amount as a count, a percent, a decimal and a fraction — then fill a smaller class to the same percent to see why proportions compare fairly.
Histograms
Slide the number of bins and watch the same numbers re-pour into bars — too few smear the shape, too many make noise. Mark the mean and median to see a long tail drag the average right.
Cleaning data
A messy fruit survey arrives with a typo, an impossible value, and a blank cell — click each red cell to fix it and watch the chart lose its fake fruit and the average snap back to something you can trust.
Randomness & probability
Spin a wheel many times and watch the odds settle toward the truth — the law of large numbers, and why more data helps an AI learn.
Coordinates & the graph
Drag a marker and read its (x, y) off the two axes, then turn a whole data table into a scatter of dots — the moment a spreadsheet becomes a graph that every other idea is drawn on.
Vectors as arrows
Drag the tip of an arrow to change its length and direction, then add a second arrow tip-to-tail to watch two vectors combine — the move behind a network’s weights and word embeddings.
Distance & similarity
Drag two fruits around a grid and watch the straight-line distance change — the closer they sit, the more alike they are. The quiet engine under k-NN, k-means and recommenders.
Gradient descent
Roll a ball down a loss valley to the lowest point — and see how the “speed” (learning rate) makes or breaks the journey. The engine of training.
Build-a-network
Add hidden neurons one at a time and watch a tiny network bend its boundary to wrap two checkerboard teams a straight line could never split — while the loss curve dives.
Activation functions
Bend a signal with ReLU, sigmoid, or tanh, see where a neuron switches on, and discover why a plain line can never make a bump — the reason networks need a switch between layers.
CNN filters on images
Slide a tiny 3×3 pattern-finder over a hand-drawn 7 and watch the feature map light up wherever its edge lives — the core operation that lets computers see.
Embeddings: a map of meaning
Words live on a map where near means similar. Light up a word’s neighbours, then try the famous arrow trick: king − man + woman lands on queen.
Tokenization
A model reads numbers, not letters. Chop a sentence by character, word, or subword and watch the token count change — then reveal the ID numbers the model truly reads.
Reinforcement learning maze
A critter learns to reach the cheese using only rewards — no teacher. Scrub the number of tries and watch the arrows and the best path form, avoiding the pit.
Generative models
A tiny Markov chain learns which word follows which, then babbles brand-new sentences in the same style. Turn the creativity knob from safe to surprising.
Prompt-and-response intuition
Keep one fixed bot and steer its answer by changing the topic, style, and length of your prompt — then see how a vague prompt gives a vague answer.
k-means clustering
Drop a few centers and step the algorithm — watch them walk into the natural groups all on their own, with no labels at all.
Choosing k
Slide the number of groups and watch the same dots split and merge while the total spread falls — sharply at first, then barely. That bend is the “elbow,” the sensible number of groups to pick.
Similarity recommender
Six fruits sit in a taste space — pick the one you like and watch the others line up by how close they sit. The nearest is the best suggestion: “you liked this, try that.”
Hierarchical grouping
Merge the two closest groups again and again and watch a tree build from the bottom up — then slide one cut line to read off every possible grouping, from many small to a few big.
Dimensionality, simply
Rotate a line through a tilted cloud and project every point onto it, squashing two numbers into one. Find the direction that keeps the most spread — and watch the two groups stay apart.
Outlier hunt
Spot the days that don’t belong — then make the harder call: is each one noise to remove, or signal worth studying? Far away doesn’t always mean wrong.
k-nearest neighbors
Drop a mystery fruit and watch its closest neighbors vote on what it is — the simplest way a machine makes a decision.
Decision boundary
Paint two groups of dots and watch the dividing border form — then flip from a straight line to neighbors and see the same data carved a completely different way. Simple vs. flexible, made visible.
The line of best fit
Drag a line through the dots and watch the total “wrongness” shrink — the heart of predicting numbers with regression.
Let the computer fit it
Make a rough guess, then hit Auto-fit and watch the line snap to the exact best fit — the computer calculates it in one step instead of hunting for it.
Residuals
See each dot’s miss as a stick and as a literal square, and read the residual plot that tells you whether the line really caught the trend — the heart of “least squares.”
Multiple features
Switch clues on and off and watch a house-price model snap onto the diagonal as real clues are added — then add a “lucky number” with no signal and watch the test error climb.
Over-fitting
Slide a flexibility dial and watch a curve memorize the dots it studied while its error on new, unseen dots makes the classic U — down to a sweet spot, then back up.
Logistic regression
Bend an S-curve over pass/fail dots — slide the midpoint to set the yes/no line, change the steepness to set confidence, and see why a straight line can’t be a probability.
Decision tree
Grow a flowchart of yes/no questions one step at a time — watch it carve the fruit into clean boxes and explain every guess in plain language.
Random forest
Let a crowd of different trees vote — and watch the accuracy climb and the boundary smooth out as you add more. A so-so crowd beats one clever tree.
Ensemble voting
Combine many so-so voters by majority and watch the crowd beat any single member — then make them all think alike and watch the boost vanish. The idea behind random forests.
Naive Bayes
Each clue casts a vote from a learned bell curve — watch two so-so hints multiply into one confident belief, like “82% cat.”
Train/test split
Hide some fruit, train on the rest, then grade on what it never saw — and watch the “studied with the answer key” score fall to the honest one. The first rule of fair testing.
Confusion matrix
Slide a threshold and watch every guess fall into one of four boxes — correct catches, correct skips, misses, and false alarms. See why one accuracy number can hide a problem.
Precision vs. recall
Slide a threshold on a puppy finder and feel the see-saw: get picky and every flag is right but you miss some; get eager and you catch them all but flag junk too. Watch the trade-off curve.
ROC curve & AUC
Slide a radar threshold between real planes and bird clutter and watch catch-rate and false-alarm rate move together — sweeping out the ROC curve, with one number (AUC) for the whole detector.
Bias & fairness
A ripeness checker trained mostly on apples judges the rare bananas badly — yet the overall score looks fine. Add bananas to the training pile and watch the per-group gap close.
Data leakage
Let test answers sneak into study and watch the score rocket to a fake 100% — then check on brand-new data and see the real skill never moved. The gap is the leakage lie.
Spam-or-not
Build a message from word chips and watch a spam filter weigh each word’s vote into one verdict — add “free” and it jumps to junk, add normal words and it slides back.
The perceptron
Tune one neuron’s three weights to slide its dividing line between two groups — or let the learning rule do it — then meet the pattern a single line can never split.
Attention: what should I focus on?
Click a word and watch it decide which earlier words to pay attention to — the big idea behind transformers and modern chatbots.
Trends & seasons
Split a wiggly two-year temperature line into a slow trend plus a repeating season — slide the repeat length and watch the folded years snap on top of each other right at 12 months.
Moving average
Slide a window across a jagged daily sales line to iron out the noise — a spotlight shows each smoothed point as the average of the days beneath it. Too wide and the real hump flattens out.
Forecast tomorrow
Extend a trend-plus-season pattern into the future and watch the confidence cone fan out the further ahead you predict — then reveal the truth riding the cone’s wide edge, never the tip.