Deploying Trillion-Parameter Models: VRAM, Model Selection, and Evaluation Checklists
This article explores the practical deployment of trillion-parameter models, covering VRAM and communication estimation, tiered model selection matrices, inference deployment, fallback routing, and evaluation migration checklists. It provides engineering formulas and checklists for architects and developers planning ultra-large model applications.
1. Handling Rumors: What Information to Use
Recently, several media outlets cited anonymous evaluations and investment banking research notes, claiming that an unidentified model might reach the trillion-parameter scale and lead existing products on certain benchmarks. According to secondhand reports, a vendor may release a flagship model with around three trillion parameters by the end of this year, alongside a medium-sized model with roughly seven hundred billion parameters. At the time of writing, this information has not been officially confirmed by the vendor.
This article uses this information as background context and makes no judgments regarding any product’s performance, pricing, or release timeline. When planning, you can handle such rumors as follows:
- Treat the parameter scale only as a reference upper bound for stress testing, not as a basis for procurement or capacity expansion.
- Define your targets for cost, latency, and quality as ranges, narrowing them down only after official specifications and pricing are released.
- Decouple the API layer from specific model names to allow for model replacement, avoiding binding business logic to a single model version.
2. Training VRAM and Communication Estimation
2.1 Separating Total and Activated Parameters
In the Mixture of Experts (MoE) architecture, the total parameters (P) determine the weight scale that must reside in the cluster during training, while the activated parameters (P_act) determine the overhead of a single forward pass. The storage pressure during the training phase must be calculated based on P, and the inference compute should be calculated based on P_act. Inference costs cannot be directly extrapolated linearly from the total parameters.
Common approximations are as follows:
- Training compute is approximately 6 × P_act × D, where D is the number of training tokens.
- The compute per generated output token is approximately 2 × P_act FLOPs.
2.2 Weight VRAM
Weight size = Total parameters × Bytes per parameter. Taking 3 trillion parameters as an example:
| Precision | Bytes per parameter | Weight size |
|---|---|---|
| FP32 | 4 | 12 TB |
| BF16 / FP16 | 2 | 6 TB |
| FP8 / INT8 | 1 | 3 TB |
| INT4 | 0.5 | 1.5 TB |
Here, 1 TB is calculated as 1000 GB. Weight size is only the starting point; both training and inference have additional overheads.
2.3 Model States During Training
Taking BF16 mixed-precision training with the Adam optimizer as an example, each parameter requires approximately the following storage:
- BF16 weights: 2 bytes
- BF16 gradients: 2 bytes
- FP32 master weights: 4 bytes
- Adam first-order momentum: 4 bytes
- Adam second-order momentum: 4 bytes
This totals about 16 bytes. For a 3-trillion-parameter model, the model states amount to approximately 48 TB.
If sharding methods like ZeRO-3 or FSDP are adopted, each GPU theoretically holds 48 TB ÷ N of the model states. Taking 4096 GPUs as an example, each GPU holds about 11.7 GB. This is the lower bound. Activations, communication buffers, VRAM fragmentation, and framework overheads need additional reserved space.
Activation VRAM can be estimated using the empirical formula provided by Korthikanti et al. (2022). Under mixed precision without recomputation enabled, the activation per layer is approximately s·b·h·(34 + 5·a·s/h) bytes. Here, s is the sequence length, b is the micro-batch size, h is the hidden dimension, and a is the number of attention heads. With selective or full recomputation enabled, activation VRAM drops significantly, but at the cost of extra compute.
The single-GPU feasibility check can be written as:
Single-GPU available VRAM × 0.9 − model state shard − activations − communication buffer ≥ 0
If the result is negative, you need to increase the number of GPUs, raise the sharding degree, enable recomputation, or reduce the sequence length and micro-batch size.
2.4 Communication Volume Estimation
Gradient synchronization for data parallelism can be estimated using ring all-reduce. The send/receive volume per GPU is approximately 2 × S × (N − 1) / N, where S is the number of bytes of gradients to synchronize per GPU, and N is the data parallelism degree.
Example: S = 6 GB, N = 64. The send/receive volume per GPU is about 11.8 GB. If the effective bandwidth is 50 GB/s, a single synchronization takes about 0.24 seconds. If gradient synchronization can overlap with backward computation, the actual time exposed on the critical path will be shorter.
Expert parallelism in MoE relies on all-to-all communication. The total dispatch and merge volume per token per MoE layer is approximately 2 × k × h × bytes per element × (1 − 1/EP). Here, k is the number of experts selected per token, and EP is the expert parallelism degree.
Example: h = 8192, k = 8, BF16 with 2 bytes per element, EP = 64. This results in about 0.26 MB per token per layer. If the model has 100 MoE layers and processes 1 million tokens per step, the cross-GPU traffic for the forward pass is about 26 TB, and the backward pass will generate another stream of the same magnitude. This number dictates the network topology design: intra-node high-bandwidth interconnects must be prioritized, and cross-node communication requires hierarchical aggregation.
2.5 Training Checklist
- Precision and sharding schemes are finalized and have passed the single-GPU VRAM check.
- The ratio of communication volume to compute time is acceptable, and gradient synchronization can overlap with computation.
- Checkpoint size has been estimated. A full checkpoint including optimizer states is about 48 TB, while saving only BF16 weights is about 6 TB. The save interval must match the storage write bandwidth.
- Fault recovery time is within an acceptable range.
3. Tiered Model Matrix
3.1 Layering Strategy
Most teams will not use just one model. A common practice is to divide into three tiers:
- High tier: Flagship model, used for complex reasoning, long-chain tasks, and high-risk content moderation.
- Mid tier: Medium-sized model, used for most general generation, summarization, and classification tasks.
- Low tier: Small model, used for deterministic tasks like format conversion, keyword extraction, and intent recognition.
The criteria for layering typically include quality requirements, latency budget, cost per call, data sensitivity, and concurrency scale.
3.2 Request Classification Features
Requests need to be tagged before routing. Available features include:
- Task type: classification, extraction, generation, code, math, multi-step reasoning, etc.
- Input length and context length.
- Whether tool calling or external data access is required.
- User level, business line, and Service Level Agreement (SLA).
- Historical failure records, such as the error rate of similar questions on the mid-tier model.
3.3 Cost Model
Let the cost per call for the small model be c_s, the cost per call for the flagship model be c_L, and the escalation ratio be p_e. The average cost per request is:
Expected cost = c_s + p_e × c_L
Here, all requests first go through the small or mid-tier model, and only a p_e proportion of requests are escalated to the flagship model.
Example: c_s = 0.1 units, c_L = 3 units, p_e = 15%. The expected cost is 0.1 + 0.45 = 0.55 units, which is about 82% lower than sending all requests to the flagship model (3 units).
The escalation ratio p_e should not be set by intuition; it must be tested using evaluation data. If the mid-tier model’s pass rate for a certain task type already meets requirements, that task should not be escalated to the flagship.
4. Inference Deployment, Cost Estimation, and Fallback Routing
4.1 Cost Template per Million Tokens
Cost per unit token = Node hourly cost ÷ Effective output tokens per hour
Example: The node hourly cost is $30, and the sustained throughput is 3000 tokens/s, generating about 10.8 million tokens per hour. The cost per million output tokens is about $2.78. If the actual utilization rate is only 50%, the cost rises to about $5.56.
The following items should also be factored into the calculation:
- Network, storage, and redundant node costs.
- Peak provisioning. Capacity planning should be designed for P95 concurrency, not average values.
- Idle rates and double resources during canary releases.
The prefill phase for input tokens is compute-intensive, while the decode phase for output tokens is memory-bandwidth intensive. The VRAM occupied by the KV cache grows with concurrency and context length, and can be estimated using the following formula:
KV cache bytes ≈ 2 × number of layers × number of KV heads × head dimension × context length × concurrency × bytes per element
The coefficient 2 corresponds to the two caches for K and V. When long context and high concurrency occur simultaneously, the KV cache often exhausts VRAM before the weights do.
4.2 Fallback Routing Design
A practical routing system typically includes the following five layers:
- Entry classification: Use rules and lightweight classifiers to tag requests first.
- Primary path selection: Select the model tier based on tags.
- Quality fallback: Escalate to a higher tier if the output fails format, factual, or tool-calling validation. Escalate at most once to avoid loops.
- Capacity fallback: If the flagship model’s queue time exceeds the latency budget, route to the mid-tier model and log the event.
- Failure fallback: Switch to a backup model upon timeouts, rate limits, or server errors.
Timeout parameters need to be set separately by request type. For instance, interactive chat can set the time-to-first-token timeout to 2 seconds, while offline batch processing can be more lenient. Retry limits must be capped to prevent traffic amplification during outages.
Every routing decision should log the model version, duration, cost, and escalation reason to facilitate post-hoc analysis and threshold adjustments.
4.3 Deployment Checklist
- Capacity has been estimated based on P95 concurrency and target context length, with the KV cache included in the calculation.
- Batching parameters are tuned, including maximum batch size and waiting window.
- Model versions are pinned, and new versions are switched via canary releases.
- Monitoring covers time-to-first-token latency, per-token latency, error rate, fallback ratio, and cost per thousand requests.
- Fallback paths have been tested in drills, not just written in design documents.
5. Evaluation Migration Checklist
5.1 Custom Evaluation Sets
The relationship between public benchmark scores and actual business outcomes is often unstable. It is recommended to sample from real production traffic and stratify by task type. Have at least 100 samples per stratum, and 300 or more for critical business strata. When annotating, distinguish between items that must be correct and items that allow multiple phrasing.
Sample size can be estimated based on the following assumptions: to detect a 5-percentage-point accuracy difference, with a baseline accuracy of about 50%, a significance level of α = 0.05, and a statistical power of 80%. Under an unpaired design, about 1500 samples are needed per group. If using the same set of samples for a paired comparison between two models, the required sample size will be significantly reduced, and the McNemar test can be used.
5.2 Evaluation Metrics
- Accuracy and its confidence interval.
- Refusal rate and over-refusal rate.
- Factual error rate or hallucination rate.
- Output format compliance rate, including JSON and structured fields.
- P95 for time-to-first-token latency and total latency.
- Cost per correct answer. Calculated as total cost ÷ number of correct answers.
Cost per correct answer reflects the economics of migration better than cost per call. A model with a higher unit price might actually have a lower cost per correct answer if its accuracy is significantly higher.
5.3 Migration Checklist
- Prompts have been re-run on the new model, and output differences recorded.
- Output parsers have passed compatibility tests, including handling of malformed formats.
- Tool calling and function calling protocols have been verified item by item.
- Safety policies and compliance rules have been re-verified on the new model.
- Data is permitted to be sent to this service, and permission and data residency requirements are confirmed.
- The old model route remains in production and can be rolled back within minutes.
- Post-launch continuous sampling is in place, with weekly comparisons of quality and cost metrics.
Once official specifications and pricing are released, substitute the actual parameters, unit prices, and throughput into the formulas above to recalculate and determine resource allocation.
