Cold start is the elevated prediction latency experienced when a model server container or function initializes without pre-loaded parameters. This delay occurs because the runtime must deserialize and transfer the model's weights from disk or object storage into accelerator memory—a process that can take seconds to minutes for large models, violating the strict Service Level Objective (SLO) thresholds required for real-time personalization.
Glossary
Cold Start

What is Cold Start?
Cold start refers to the latency penalty incurred when a model serving instance is initialized for the first time or after a period of inactivity, requiring weights to be loaded into memory before inference can begin.
Mitigation strategies include maintaining a pool of pre-warmed instances, using Readiness Probes to prevent traffic routing to uninitialized replicas, and employing model serialization formats like TensorRT engines that optimize load times. In serverless inference architectures, cold start latency is a critical design constraint, often addressed through provisioned concurrency or lightweight stub models that serve fallback predictions while the primary model initializes.
Key Characteristics of Cold Start Latency
Cold start latency is the delay incurred when a model instance initializes, loading weights from disk or object storage into accelerator memory before it can serve its first inference request. This phenomenon directly impacts autoscaling responsiveness and disaster recovery time objectives.
Weight Loading Bottleneck
The primary source of cold start latency is the time required to read model weights from persistent storage into GPU or CPU memory. For large language models, this can involve transferring hundreds of gigabytes over network or disk interfaces.
- Model Size Impact: A 70B parameter model in FP16 requires ~140GB of memory, taking minutes to load even on high-bandwidth NVMe storage
- Disk I/O Constraints: Traditional block storage may only sustain 1-2 GB/s read throughput, creating a hard floor on initialization time
- Network-Attached Storage: Loading from cloud object stores like S3 adds network latency and throughput variability, often making this the slowest path
- Memory Mapping: Techniques like
mmapcan defer page faults to first access, reducing apparent startup time but shifting latency to the first real inference request
Container Startup Overhead
In Kubernetes-orchestrated environments, cold start latency includes the full container lifecycle: image pulling, pod scheduling, and resource allocation before the model process even begins loading weights.
- Image Pull Time: Large container images containing CUDA runtimes and framework dependencies can take 30-60 seconds to pull on a cold node
- Node Autoscaling Delay: If no GPU node is available, the cluster autoscaler must provision a new VM, adding 2-5 minutes before pod scheduling begins
- Init Container Execution: Pre-loading steps like downloading model artifacts or setting up shared memory segments add sequential delays
- Health Check Gating: Readiness probes must pass before traffic is routed, meaning the model must be fully loaded and responsive before serving begins
GPU Kernel Compilation
When a model runs on a GPU for the first time, the CUDA or TensorRT runtime must just-in-time compile optimized kernels for the specific operations and tensor shapes in the model graph. This one-time compilation adds significant latency to the first inference.
- CUDA JIT Compilation: PyTorch's CUDA graphs and custom kernels are compiled on first execution, adding seconds to the initial forward pass
- TensorRT Build Phase: Converting an ONNX model to a TensorRT engine requires layer fusion, kernel selection, and precision calibration, which can take minutes
- Shape Polymorphism: Dynamic input shapes prevent full ahead-of-time compilation, forcing recompilation when new batch sizes or sequence lengths are encountered
- Cache Persistence: Compiled kernels can be serialized to disk and reloaded on subsequent starts, eliminating this overhead for repeat deployments
KV Cache Initialization
For generative transformer models, the key-value cache must be allocated in GPU memory before autoregressive decoding can begin. This allocation and zeroing of large memory buffers contributes to cold start latency.
- Memory Allocation: Allocating contiguous GPU memory for the KV cache across all transformer layers requires significant time for large context windows
- PagedAttention Pre-allocation: Systems like vLLM pre-allocate KV cache blocks to enable efficient memory management, but this upfront allocation extends startup time
- Context Length Scaling: A model configured for 128K token contexts requires proportionally larger KV cache buffers, increasing initialization time linearly
- NUMA-Aware Placement: Ensuring KV cache memory is allocated on the NUMA node local to the GPU minimizes access latency but requires careful orchestration during startup
Warm-Up Strategies
Production systems employ several techniques to eliminate or hide cold start latency from end users, ensuring that autoscaling events do not degrade the customer experience.
- Pre-Warming: Sending synthetic 'dummy' inference requests to newly started instances forces weight loading, kernel compilation, and cache allocation before real traffic arrives
- Over-Provisioning: Maintaining a buffer of idle, fully-loaded instances ready to absorb traffic spikes eliminates cold starts at the cost of higher baseline infrastructure spend
- Lazy Loading with Fallback: Routing initial requests to a fast but less accurate fallback model while the primary model loads, then seamlessly switching over
- Snapshot Restoration: Serializing the fully-initialized model state (weights + compiled kernels + KV cache) to disk and restoring it via direct memory copy, reducing startup from minutes to seconds
Impact on Autoscaling Responsiveness
Cold start latency directly determines how quickly a model serving system can react to traffic surges. The total scale-out latency is the sum of detection time, infrastructure provisioning, and model initialization.
- Scale-Out Lag: A 3-minute cold start means the system is under-provisioned for 3 minutes during a traffic spike, causing request queuing and P99 latency spikes
- HPA Synchronization: The Horizontal Pod Autoscaler's default 15-second metric polling window adds detection delay on top of cold start time
- Thrashing Risk: If cold start time exceeds the scale-down cooldown period, instances may be terminated before they finish initializing, creating a destructive cycle
- Predictive Scaling: Time-series forecasting of traffic patterns can trigger pre-emptive scaling before demand materializes, hiding cold start latency entirely from users
Frequently Asked Questions
Clear, technical answers to the most common questions about the initialization latency penalty in production machine learning systems.
A cold start is the latency penalty incurred when a model serving instance is initialized for the first time or after a period of inactivity, requiring model weights to be loaded from disk or object storage into accelerator memory before inference can begin. This initialization phase involves deserializing the model graph, allocating tensors on the GPU or CPU, and potentially warming up optimized kernels. Unlike a warm start where weights are already resident in memory, a cold start can add seconds to minutes of delay to the first prediction request. This is distinct from the cold start problem in recommender systems, which refers to the challenge of making predictions for new users or items with no historical interaction data. In the serving context, cold starts directly violate the Service Level Objective (SLO) for real-time applications where P99 latency must remain under a strict threshold, making them a critical concern for infrastructure engineers managing auto-scaling environments.
Enabling Efficiency, Speed & Accuracy
Intelligent Analysis, Decision & Execution
We build AI systems for teams that need search across company data, workflow automation across tools, or AI features inside products and internal software.
Talk to Us
Search across company data
Give teams answers from docs, tickets, runbooks, and product data with sources and permissions.
Useful when people spend too long searching or get different answers from different systems.

Automate internal workflows
Use AI to route work, draft outputs, trigger actions, and keep approvals and logs in place.
Useful when repetitive work moves across multiple tools and teams.

Add AI to products and internal tools
Build assistants, guided actions, or decision support into the software your team or customers already use.
Useful when AI needs to be part of the product, not a separate tool.
Related Terms
Understanding the cold start problem requires familiarity with the broader ecosystem of model serving infrastructure and optimization techniques. These concepts form the foundation for diagnosing and mitigating initialization latency in production environments.
Prediction Latency
The total time elapsed between a client sending an inference request and receiving the complete prediction response. Cold start contributes directly to tail latency, as the first request to a newly initialized instance includes the overhead of weight loading and memory allocation. This metric is often decomposed into:
- Queue time: waiting for a worker
- Initialization time: loading model artifacts
- Compute time: the actual forward pass
P99 Latency
A percentile metric indicating that 99% of inference requests are served faster than this value. Cold start events disproportionately inflate P99 and P999 latencies because the unlucky requests that hit a cold instance experience orders-of-magnitude slower responses. Engineering teams target P99 thresholds in their Service Level Objectives (SLOs) precisely to catch these initialization spikes.
Quantization
A model optimization technique that reduces the numerical precision of weights and activations from 32-bit floats to lower-bit integers like INT8 or INT4. Quantization directly mitigates cold start by:
- Reducing the total bytes that must be read from disk into memory
- Decreasing the time required for memory allocation on the accelerator
- Enabling faster deserialization of model artifacts Smaller models load faster, shrinking the initialization window.

About the author
Prasad Kumkar
CEO & MD, Inference Systems
Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.
His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.
Partnered with leading AI, data, and software stack.
How We Work
Custom AI workflows for your Business
One-fit-all AI don't work for modern businesses. At Inferensys, we aim to understand your business & custom requirements; which we use to define most efficient agentic workflows, the data, and the tools for your business.
01
Review the use case
We understand the task, the users, and where AI can actually help.
Read more02
Pick the right approach
We define what needs search, automation, or product integration.
Read more03
Build the first useful version
We implement the part that proves the value first.
Read more04
Improve from there
We add the checks and visibility needed to keep it useful.
Read moreThe first call is a practical review of your use case and the right next step.
Talk to Us