The Cost of Running a Trillion-Parameter Model Locally
A practical cost breakdown of local deployment for a 670-billion-parameter model, covering why memory capacity and bandwidth—not GPUs—drive the bill, how layered weight placement works, one-time versus ongoing expenses, quantization trade-offs, and how to benchmark prefill and decode performance before choosing between self-hosting and cloud pay-as-you-go.
1. First, Define What Actually Drives the Cost
When teams evaluate how much it costs to run a very large parameter model locally, the first instinct is to look up GPU prices. At the 670-billion-parameter scale, however, the GPU is only part of the bill. What really determines feasibility and total cost of ownership is memory capacity, memory bandwidth, the data path between the host and the accelerator, and the throughput you are willing to accept.
A frequently cited high-performance reference scenario is a dual-socket server CPU paired with a single consumer GPU, running roughly 377GB of 4-bit quantized weights under a restricted expert-selection policy. In that setup, the prefill stage reaches over 200 tokens/s, while the decode stage runs at about 14 tokens/s. The value of these numbers is not that they look good. It is that they reveal three things: the weights must live in host memory, computation is split across different devices, and the two stages differ in performance by an order of magnitude. Every cost estimate below follows from those three points.
2. Where the Weights Go When VRAM Is Not Enough
At 4-bit quantization, 670 billion parameters come to roughly 377GB of weights. Add runtime overhead and actual usage typically rises another 10% to 20%. No single-GPU or single-machine multi-GPU VRAM pool can hold all of it, so the mainstream approach is layered placement:
- Small, hot components such as attention layers, normalization layers, and token embeddings stay resident in VRAM, using its high bandwidth to keep latency low;
- Large, cold weights such as the feed-forward and expert layers stay in host memory and are fetched on demand;
- Data is moved between host and accelerator over a high-bandwidth interconnect, and the efficiency of that transfer directly determines decode speed.
This explains a counter-intuitive result. Decode reads the relevant weights once for every token it generates, so it is bound by memory bandwidth and reaches only about a dozen tokens/s. Prefill is large-scale parallel matrix work with high compute utilization, so it reaches over 200 tokens/s. The first principle of cost evaluation follows: choose memory capacity and bandwidth first, then talk about accelerators.
3. The Cost List: One-Time Investment and Ongoing Spend
One-time investment falls into four categories:
- Host platform: dual-socket server CPUs, motherboard, redundant power supplies, chassis and cooling;
- Memory: the most commonly underestimated item, usually several hundred GB to 1TB of registered memory, with all channels populated to get full bandwidth;
- Accelerator: a single consumer card with ample VRAM is enough for the hot layers, so there is no need to buy cards in bulk;
- Storage and networking: model files run to hundreds of GB, so a dedicated data disk is recommended to avoid competing with the system disk for IO.
Ongoing spend covers power (full-load system draw is not low and must be converted using local electricity rates), cooling for the server room or office space, and operations staff. A cloud alternative turns capital expenditure into operating expenditure billed hourly or per token, with object storage holding the model files, a container platform running the inference service, and logging plus monitoring and alerting covering observability.
4. Quantization and Precision: The Main Cost Lever
Quantization is the primary way to bring total cost down, but it is not lossless. The practical ranges are:
- 4-bit: smallest footprint and lowest memory threshold, with acceptable quality loss on general tasks, suitable for local validation;
- 8-bit: quality closer to the original precision, with roughly double the memory requirement;
- Higher precision: generally reserved for fine-tuning or evaluation baselines, not for local inference at this parameter scale.
Note that throughput cannot be converted from size across quantization formats. Formats differ in memory alignment, blocking, and compute-kernel support, so actual throughput has to be measured.
5. Do Not Be Misled by a Single Number: Two Stages, Two Performance Profiles
When evaluating an option, look at at least four metrics separately: prefill throughput, decode throughput, time to first token, and how much performance degrades under long context. A restricted expert-selection policy improves results noticeably, but it means some experts are never activated, so the output distribution is not fully equivalent to activating all of them. The business side therefore has to answer two questions: is that policy acceptable, and how much performance remains once context is pushed beyond 32K?
A reproducible benchmark with a shared script is recommended, for example:
# Pseudocode: stage-by-stage benchmark producing comparable metricsdef bench(model, prompt_len, gen_len, expert_policy):t0 = time.now()prefill_out = model.prefill(prompt_len, policy=expert_policy)prefill = (prompt_len, time.now() - t0)t1 = time.now()for _ in range(gen_len):prefill_out = model.decode_one(prefill_out)decode = (gen_len, time.now() - t1)return {"prefill_tps": prefill[0]/prefill[1],"decode_tps": decode[0]/decode[1]}
6. The Hidden Cost of Concurrency and Memory
Concurrency on a single local machine is squeezed by memory bandwidth: as concurrency goes from 1 to 4, per-request decode speed often drops roughly linearly, and total throughput gains stay limited. If the workload needs multiple concurrent streams, the marginal cost of adding nodes horizontally is usually lower than adding more memory inside one machine. This has to be worked out in advance during capacity planning.
7. Conclusion and Recommended Next Steps
Back to the original question: running a 670-billion-parameter-class model locally puts most of the cost in a large-memory host platform, while the accelerator can be kept modest. On performance, accept the structural reality that prefill is fast and decode is slow, and use a restricted expert policy to buy usability. The suggested path is to define the quality floor and concurrency target first, work backward to the memory and bandwidth requirements, validate with a shared benchmark script, and then compare the total cost of ownership between self-hosting and cloud pay-as-you-go. If sensitive data is involved or the load is stable over the long term, Baidu AI Cloud’s general-purpose compute and storage combinations are worth considering for absorbing peaks elastically.
