Grades 6–8 · Computing
How is training an AI model different from using it?
A machine-learning model uses adjustable parameters to turn inputs into outputs. In supervised training, examples include inputs and desired outputs. A training procedure compares predictions with those targets and changes parameters to reduce a chosen measure of error.
In the diagramLearning a rule and using it are different stagesTrainingInference1 → 3; 2 → 5; 3 → 7fit y = 2x + 1new input: x = 4prediction: 9Invented data; a fitted pattern may fail on new examplesOrdinary inference applies the available model without retraining it.
Consider invented pairs: input 1 has target 3, input 2 has target 5, and input 3 has target 7. A starting rule y = x + 1 predicts 2, 3 and 4, all too small. Changing its multiplier from 1 to 2 gives y = 2x + 1, which matches all three targets. The multiplier 2 and added value 1 are parameters. A training procedure searches for adjustments that reduce prediction errors; this small comparison shows an improvement rather than a full training algorithm.
During inference, the fitted rule is applied to an input. For input 4, this model predicts 9. Using the model in this ordinary way does not itself change its parameters. Additional training or another update procedure would be needed to change the fitted rule.
A model can match its training examples yet fail on new ones. The real process might stop following the apparent pattern, or the examples may leave out important conditions. Evaluation on separate data helps assess that problem. Training changes a model using a learning procedure; inference produces outputs from the model currently available.
About this explanation
Starting knowledge: Understand inputs, outputs, a simple rule and comparing a prediction with a known result.
Sources
- Google for Developers — Introduction to Machine Learning: Supervised Learning
- Google for Developers — Machine Learning Glossary: ML Fundamentals