Neuron Lab
Drag the three sliders (on a keyboard: 1-3 pick a slider, arrow keys nudge it, H for a hint)
What is Neuron Lab?
Neuron Lab is a free game about what a neural network is actually made of. A single artificial neuron is much simpler than the name suggests: it multiplies each input by a weight, adds a bias, and fires if the total comes out above zero. Geometrically that means one neuron draws exactly one straight line and says yes to everything on one side of it. You drag the weights by hand until every dot is classified correctly, which is precisely what training a network does - just automatically, across millions of weights.
How to play Neuron Lab
Controls: Drag the three sliders (on a keyboard: 1-3 pick a slider, arrow keys nudge it, H for a hint)
- 1Solid dots should make the neuron fire, hollow dots should keep it off. A dot turns green when it is on the right side and red when it is not.
- 2Drag Weight A, Weight B and Bias. The weights turn the glowing boundary line and the bias slides it.
- 3Watch the neuron diagram above the graph: synapses get thicker with bigger weights (teal for positive, pink for negative) and the neuron lights up when the circled dot makes it fire.
- 4Get every dot green to clear a level and read a one-line lesson. The first level only needs one slider.
- 5Stuck? Tap the bulb for a hint and an arrow on the slider to move; tap again to see where each knob should go.
- 6The last level cannot be solved with one neuron. When you are convinced, tap 'Is this even possible?' to see how adding neurons solves it.
Neuron Lab tips and strategy
- Start by setting one weight and leaving the other at zero. A weight of zero means the neuron ignores that input entirely, which is how you get a purely vertical or horizontal boundary.
- The bias moves the line without rotating it. Get the angle right with the weights first, then slide it into place with the bias.
- A negative weight flips which side of that input counts, so reach for it whenever the line needs to lean the other way.
- If the lit region is on the wrong side entirely, negate both weights and the bias. That keeps the same line and swaps which half is the yes.
Neuron Lab FAQ
What is a neuron in a neural network?
A very small piece of arithmetic. It takes some numbers in, multiplies each by a weight, adds them up along with a bias, and outputs whether the result clears a threshold. There is no thinking involved in one neuron - the intelligence in a network comes from having a great many of them arranged in layers.
What are weights and biases?
The weight says how much one input matters, and its sign says which way. The bias shifts the whole decision up or down, making the neuron easier or harder to trigger. Training a neural network means nothing more than nudging these numbers until the outputs come out right.
Why can't one neuron solve XOR?
Because one neuron can only draw one straight line, and in the XOR pattern the two groups sit on opposite diagonal corners. No straight line separates them. This was a real crisis in AI research in the 1960s, and the fix - stacking neurons into layers so the boundary can bend - is what makes modern deep learning work.
Is this how real AI is trained?
The mechanism is the same, the scale is not. A real network adjusts its weights automatically using the error on each example, and a large model has billions of them rather than three. But every one of those weights is doing the same job as the sliders in this game.