What is it?
Running a model for real users is an engineering problem: it must answer quickly, handle many people at once and not cost a fortune. Serving software and GPU choices decide that.
Also known as: LLM serving, inference server, inference optimization, time to first token, TTFT, tokens per second, throughput vs latency, model deployment.
Technical definition
LLM inference has a compute-bound prefill phase and a memory-bandwidth-bound decode phase. Techniques: continuous batching, paged KV cache (KV Cache), quantisation (Quantization of AI Models), speculative decoding (Speculative Decoding), tensor/pipeline parallelism, prefix caching, request routing and autoscaling. Metrics: TTFT, inter-token latency, tokens/s, GPU utilisation and cost per million tokens. Engines include vLLM, llama.cpp-based servers, TensorRT-LLM, and managed endpoints from cloud and model providers; verify features per version.
Entity type: concept · Freshness class: volatile.
When should I use it?
Relevant to anyone self-hosting models or choosing managed endpoints.
Implementation patterns
- Separate gateway (auth, rate limits, routing) from model servers.
- Autoscale on queue depth or GPU utilisation.
- Warm pools to avoid cold-start latency.
- Canary new model versions.
- Cache repeated prefixes/responses where safe.
Technologies and frameworks
Commonly associated: vLLM, TensorRT-LLM, Triton Inference Server, KServe, Ray Serve, managed model endpoints. Names are examples of what exists, not recommendations, and projects change quickly.
Practical guide
- Collect real prompt/response length distributions.
- Estimate memory: weights + KV cache × concurrency.
- Choose engine and hardware.
- Load-test and set SLOs.
- Add monitoring and autoscaling.
Common failure modes
- Cold starts of large models.
- OOM from long contexts and high concurrency.
- Benchmarking with unrealistic prompts.
- Single point of failure.
- No back-pressure or timeouts.
Troubleshooting
- High tail latency — Limit max context/output; tune batching; add replicas.
- Cost too high — Quantise, route easy requests to smaller models, cache (LLM Cost Optimization).
Contrasted with
- What is Local AI? Running Models on Your Own Device — Local AI is personal-scale serving; production serving adds concurrency, reliability and scaling.
Questions this page answers
- How do I serve an LLM in production?
- What is time to first token?
- How much GPU memory do I need to serve a model?
- How do I scale LLM inference?
Typical goals: size infrastructure for an LLM; reduce latency and cost.
Sources and verification
Status: not independently verified. This entry was authored on 2026-10-06 from general technical knowledge, without live checking of the sources below. Treat every source as a lead to confirm (identifier, title, authorship, current version) before publication or citation.
Freshness class: volatile — Products, versions, protocols, benchmarks, leaderboards, regulations and dates. Verify against the primary source before relying on specifics; re-review every 3 months.
Time-sensitive claims to verify before relying on them:
- Engine feature sets, hardware support and cost/performance claims.
Canonical sources (unverified leads):
- Kwon et al., PagedAttention / vLLM (2023) — arXiv:2309.06180
- Serving engine documentation (vLLM, Triton, TensorRT-LLM) — locator to be identified