Inference, Quantization, and Serving

Inference, Quantization, and Serving

Key jargon

Term Plain-language meaning
Inference engine Runtime software that executes a trained model.
Quantization Representing weights or activations with lower precision to reduce memory or compute.
Throughput Work completed per unit time, often tokens or requests per second.
Time to first token (TTFT) Delay between request submission and the first generated token.

Key concepts

Concept map

flowchart LR
    A["Load model representation"] --> B["Schedule and batch requests"]
    B --> C["Generate tokens"]
    C --> D["Measure quality latency throughput"]

Serving concepts

Metrics

Time to first token, inter-token latency, total latency, input/output tokens per second, concurrency, queue time, memory, cache utilization, error rate, cost per successful task, and task-quality regression.

Exercise

Benchmark a small local model on ten non-sensitive prompts at two quantizations. Record hardware, runtime, model hash, quality rubric, latency, memory, and power if available.

Misconception

Requests per second alone hides prompt length, generation length, batching, and success quality.