An AI model is a mathematical function with learned parameters that maps an input, such as text, an image or a row of sensor readings, to an output such as a label, a number, a ranking or newly generated content. Artificial intelligence uses the word in a narrow sense: the model is the trained artifact that results from applying a learning algorithm to data, not the algorithm itself and not the whole product built around it.
Among AI fundamentals, the model is the unit that is trained, evaluated, versioned and deployed. A machine learning model, the most common synonym, consists of an architecture that fixes the form of the function and a set of model weights that fix its behavior. The same architecture with different weights is a different model, which is why weights are treated as the valuable asset.
How an AI model turns data into a function
An AI model is created by optimizing parameters against an objective. During training, an optimizer such as stochastic gradient descent adjusts the weights so that a loss function, for example cross-entropy for classification or mean squared error for regression, decreases on the training data. The result is a function that approximates the patterns present in that data.
Once training stops, the weights are frozen and the model is used for AI inference: it receives new inputs and computes outputs in a single forward pass or, for generative models, in many passes. Training is expensive and happens rarely; inference is cheap per call but runs millions of times, so both costs matter when a model is chosen.
The following table separates the parts that together make up a usable AI model, because confusion between them causes many licensing and engineering mistakes.
| Component | What it defines | Typical form |
|---|---|---|
| Architecture | Shape of the function and data flow | Code or configuration file |
| Weights | Learned numeric values | Tensors from kilobytes to hundreds of gigabytes |
| Hyperparameters | Settings chosen before training | Learning rate, depth, batch size |
| Preprocessing | How raw input becomes numbers | Tokenizer, scaler, image resizer |
| Decoding or threshold rules | How raw scores become outputs | Sampling temperature, decision cutoff |
Main types of AI models
AI models are usually classified by what they predict and by how they learn. A discriminative model estimates the probability of a label given an input, while a generative model learns the distribution of the data itself and can produce new samples. Learning paradigms include supervised, unsupervised, self-supervised and reinforcement learning.
Model size varies by more than eight orders of magnitude, from a logistic regression with a few dozen parameters to a large language model with hundreds of billions. Size alone does not determine quality; the match between model, data and task does.
| Model family | Typical parameters | Typical tasks |
|---|---|---|
| Linear and logistic models | Tens to thousands | Scoring, risk estimation, baselines |
| Tree ensembles | Thousands to millions of nodes | Tabular prediction, fraud detection |
| Convolutional networks | Millions to hundreds of millions | Image classification, detection |
| Transformer language models | Hundreds of millions to trillions | Text generation, coding, translation |
| Diffusion models | Hundreds of millions to billions | Image, audio and video generation |
A foundation model is a large model pretrained on broad data and then adapted to many downstream tasks through fine-tuning or prompting. It is a subtype of AI model, distinguished by scale and reuse, not by a different mathematical nature.
AI model versus related concepts
The term AI model is often used loosely for the algorithm, the application or the service. Precise usage matters in contracts, regulation and engineering, because obligations attach to different layers. The EU AI Act, for example, distinguishes general-purpose AI models from the AI systems that integrate them.
| Term | What it refers to | Relation to the model |
|---|---|---|
| Learning algorithm | Procedure that fits parameters | Produces the model |
| Model architecture | Untrained structure of the function | Template the model instantiates |
| Model weights | Learned values only | The trained state of the model |
| AI system | Model plus data pipelines, interface and rules | Contains one or more models |
| Compound AI system | Several models and tools working together | Orchestrates multiple models |
A practical test helps: if a component can be saved to a file, loaded and called with an input to return an output, without the surrounding user interface or retrieval database, it is the model. Everything else belongs to the system.
Evaluating and choosing an AI model
A model is only as useful as its generalization, its ability to perform well on data it did not see during training. Evaluation therefore uses a held-out test set with reliable ground truth labels and metrics that match the business goal, such as precision and recall for rare events or calibration for risk scores.
Selection is a trade-off between accuracy, latency, cost and controllability. A smaller model that answers in 20 milliseconds on a CPU often beats a larger model that is two points more accurate but needs a GPU cluster. The decision table below summarizes typical starting points.
| Situation | Recommended starting point | Reason |
|---|---|---|
| Structured tabular data | Gradient-boosted trees | Strong accuracy with modest data |
| Little labeled data, open-ended text | Prompted foundation model | Reuses broad pretraining |
| Strict explainability required | Linear model or shallow tree | Decisions can be traced |
| On-device or real-time use | Small distilled or quantized model | Low memory and latency |
| Many labeled images | Fine-tuned vision network | Exploits domain-specific features |
Limitations and common misconceptions
Every AI model inherits the biases and gaps of its training data, and its inductive bias, the assumptions built into its architecture, limits what it can learn efficiently. Experienced practitioners watch for the following failure modes.
- Distribution shift: accuracy drops when production data differs from training data, for example after a change in customer behavior.
- Overfitting: the model memorizes training examples instead of learning general patterns.
- Overconfident outputs: scores and fluent text can look certain while being wrong, a problem known as poor calibration or, in language models, hallucination.
- Model drift without monitoring: frozen weights do not adapt, so performance must be measured continuously after deployment.
- Misreading the model as understanding: a model encodes statistical regularities; whether this amounts to understanding remains scientifically disputed.
A frequent misconception is that a model is retrained automatically whenever it is used. In nearly all deployments, inference does not change the weights; any learning from user feedback requires a separate training run and a new model version.
In plain words
An AI model is a recipe that a computer learned by itself from examples. Engineers show it thousands or millions of cases, and it slowly tunes many internal dials until its answers match the examples well.
After that, the dials are fixed. The model can then take something new, such as a photo or a question, and give its best answer based on what it learned. It is only as good as the examples it saw, so a model trained on poor data gives poor answers.
A real-world example
A regional hospital wants to predict which patients are likely to be readmitted within 30 days of discharge. Its data team trains a gradient-boosted tree model on five years of anonymized records, about 120,000 discharges, using features such as age, diagnosis codes, length of stay and number of previous admissions.
On a held-out year of data, the model reaches an area under the ROC curve of about 0.78, clearly better than the simple checklist used before. The team sets a threshold that flags the top 10 percent highest-risk patients for a follow-up call by a nurse. After six months, monitoring shows that accuracy is stable, and the hospital records a measurable reduction in avoidable readmissions among flagged patients, while clinicians keep the final decision.