shapesinfinity.
Learn AI · Beginner · 3 min

Weights and Biases: The AI's Memory

How does an AI remember what it learned? Two hidden numbers control everything.

Weights and Bias Flow
Input dataMultiply by weightsAdd biasMake predictionCheck errorUpdate weights

Data flows in, gets multiplied by weights, bias is added, then the model predicts and learns.

goes inthe AI workscomes out

In simple words

Think of weights like volume knobs and bias like a starting point. Together, they teach the AI to recognize patterns.

The real definition

Weights (importance numbers) decide how much each input matters. Bias (adjustment value) shifts the output to fit the training data better. Both are learned during training.

Like… Recipe with Salt

Weights are ingredient amounts. Bias is salt that fixes the taste. Change them and the dish changes completely.

But: Recipes don't learn; AI adjusts weights automatically until answers improve.

You see it every day

on your phone

Face unlock

Weights decide which face features matter most. Bias helps the phone accept the right person.

out in the world

Crop disease

A farm uses AI with learned weights to spot sick plants. Bias prevents false alarms.

at work

Email filter

Company email AI uses weights to detect spam. Bias stops it from blocking real messages.

Step by step

  1. 1

    Start with random numbers

    The AI begins with weights and bias set to random values.

  2. 2

    Feed in training data

    You show the AI many labeled examples so it learns patterns.

  3. 3

    Measure the error

    Check how wrong the predictions are compared to true answers.

  4. 4

    Adjust and repeat

    Tiny changes to weights and bias make predictions better.

Remember

Weights control how much each input affects the answerBias is a bonus number that shifts the resultBoth start random and improve during trainingThousands of weights work together in real neural networksLarger weights mean more important; negative weights mean opposition

Memory trick

W = volume knob, B = starting point. Together they tune the AI like a radio.

Words

weights WAYTS
Numbers that show how important each input is.
bias BY-us
A number added to shift the output up or down.
neural network NOO-rul NET-work
AI inspired by how brains connect neurons together.
training TRAY-ning
Teaching an AI by showing it labeled examples.
prediction pred-IK-shun
The answer the AI gives based on input data.
error AIR-ur
The difference between the AI guess and true answer.

Check yourself

quick check

What do weights control in a neural network?

Hint

Think about how important each piece of data is.

quick check

An AI learns to recognize cats. What do weights and bias do together?

Hint

What happens to numbers when the AI learns?

think

If all weights were zero, what would happen to predictions?

Show a good answer

The AI would ignore all inputs and rely only on bias. Every prediction would be the same. Weights must be non-zero to use input data.

Tell a friend

“Weights and bias are the AI's tuning knobs. They learn to turn the right way during training.”

People also ask

Why does AI start with random weights?

Random starting points let the AI explore different solutions. Training then adjusts them toward the right values.

Can weights be negative?

Yes. Negative weights mean the input pushes the answer down. Positive weights push it up. Both types matter.

How many weights does real AI have?

Millions or billions. An image recognition AI may use billions of weights. More weights allow more complex learning.