← AI Terminology

Model

A model in machine learning is a mathematical function with learned parameters that maps inputs to outputs — the result of a training process that adjusted those parameters to minimise a loss function on training data.

"The model" refers to both the architecture (structure) and the weights (learned values).
Why It Matters in AI
The model is the core deliverable of ML: everything else (data pipelines, training loops, evaluation) exists to produce a model that generalises well to new inputs. Understanding the distinction between architecture (the fixed computational graph — e.g. a 7B transformer) and weights (the learned values that capture knowledge — 14GB of floats) is fundamental. Model weights are IP: they represent billions of dollars of training compute and can be fine-tuned, distilled, or deployed independently of their training code.
Key Points
Aspect Description
Inference Running the model on new inputs — the deployment phase; weights are frozen
Checkpoint A saved snapshot of model weights at a point during or after training
Model card Standardised documentation: training data, intended use, limitations, evaluation results
Architecture The fixed computational structure: layers, connections, operations — unchanged after training
Weights/params Numerical values learned during training that encode all the model's knowledge
Foundation model A large, general-purpose model (GPT-4, Llama 3) fine-tuned for specific applications
Simple Analogy
A recipe (architecture) vs. a cooked dish (trained model): the recipe specifies structure and steps; the dish is the result of following those steps with specific ingredients and quantities (weights). Two chefs following the same recipe with different ingredients (training data) produce different dishes — same architecture, different models.
Common Usage Examples
  • model = torchvision.models.resnet50(pretrained=True) — load pretrained model with its weights
  • torch.save(model.state_dict(), "model.pt") — save weights (checkpoint) to disk
  • model.load_state_dict(torch.load("model.pt")) — restore weights for inference
  • HuggingFace: AutoModel.from_pretrained("meta-llama/Meta-Llama-3-8B") — load model + weights from Hub
  • model.eval() — switch model to inference mode (disables dropout, fixes batch norm statistics)
Summary
In short: A model is an architecture plus learned weights — the trained function that maps inputs to outputs and represents the accumulated knowledge from a training run.