How it works
Model inference is the process of using a trained model to produce predictions from new inputs. Unlike training, the model's weights are not changed during inference. The input passes through the network in a sequence of calculations, with fixed weights, and the result is generated according to the prompt and decoding settings. In language systems, the input is tokenized, processed by the network and the model returns a sequence of tokens that forms the final response. The neural network performs a series of multiplications and sums of activations, and the result is converted into probabilities by an output layer. Decoding chooses which token comes out at each step, essentially asking the model: what is the most likely word to come next?
Practical example
A customer support system receives a message from a customer, sends it to the model and the model returns a ready response. The model does not learn from the interaction; it only processes the input with what it learned during training. The response can be sent to the agent or to the customer's app, depending on the product architecture. Time to first token and response length define the user experience. In a translation service, the input is tokenized into words from the source language, passes through the network and is converted into tokens of the target language, one by one.
What it's for
Inference is the production moment. Response quality depends on model quality, input quality and generation settings. Latency, token volume and cost per query define whether the model can meet product demand. Many products use large models for complex tasks and smaller models for routine work, reducing cost without losing quality. Recommendation services process user interaction in real time, generating a choice before the user finishes typing. The speed of this generation is what differentiates an agile experience from noticeable slowness.
Difference between X and Y
Inference uses a trained model; training updates the weights. Inference is a static process; training is iterative. Once trained, the model can be inferred as many times as needed, without changing the weights.