How Domestic AI Compute Can Deliver Production-Grade LLM Inference
This article examines whether domestic AI accelerators can meet the highest standards for production LLM inference, arguing that single-point benchmarks are misleading. Using an extreme workload—roughly 100MB of text input per request, near-zero prefix cache hits, and very short outputs—it shows how prefill compute can be drained while revenue per card drops. The article breaks inference into prefill and decode stages, explains their different hardware bottlenecks, provides a capacity-modeling pseudocode example, and outlines six governance measures such as input limits, prefix caching, pool scheduling, continuous batching, metering, and observability. It concludes that real-world effective throughput and stability, not peak FLOPS, should determine hardware selection.
1. The Problem Starts with an Extreme Input
When evaluating whether domestic compute can deliver production-grade inference at the highest standard, the most misleading judgment comes from single-point benchmarks. What truly determines service quality is a class of underestimated extreme workloads: a single request with roughly 100MB of plain-text input, very short prompts per turn, very short outputs, and almost no prefix cache hits.
Using the common industry approximation (1 token ≈ 4–5 bytes), 100MB of text translates to about 20 million tokens. This type of request stacks three characteristics at once: it blows out the context window in a single pass, the cache hit rate is zero, and the output length approaches zero. The consequence is not “a bit slower”—it continuously drains the cluster’s most expensive and scarcest resource, prefill compute, while the revenue side sees almost no corresponding output.
Consider an abstract capacity model: suppose a class of domestic accelerator has public specs of roughly 1 PFLOPS FP8 dense compute, roughly 2 PFLOPS FP4 dense compute, 144GB of memory, memory bandwidth around 4TB/s, 2TB/s single-card scale-up interconnect, and 128 cards per switching layer. Under these specs, uncached prefill throughput is about 26K tps, total decode throughput per card is about 7.4K tps, single-stream output is about 138 tps, the prefill-to-decode card ratio is about 1.24:1, and the revenue index per card per hour is about 17.6. When the workload is swapped to the extreme scenario above, prefill is triggered repeatedly while decode is nearly idle, revenue per card may drop by about 30%, and rack, power, and cooling costs do not fall accordingly—this is the underlying reason why “unlimited usage” must be governed.
2. The Two Workload Types Have Completely Different Hardware Bottlenecks
Inference service must be modeled as two separate stages; otherwise capacity planning will inevitably be distorted.
The prefill stage is a one-time parallel computation over a long sequence, with bottlenecks concentrated in compute and long-text KV access. The decode stage is token-by-token autoregression, where each step reads the entire KV cache and weights, with bottlenecks concentrated in memory bandwidth, memory capacity, and interconnect latency.
This leads to three engineering conclusions:
- Single-stream output speed is roughly determined by memory bandwidth; doubling bandwidth raises the single-stream speed ceiling by about 1.7–2x, not a linear doubling.
- Total throughput is constrained simultaneously by compute, bandwidth, and capacity, and requires balanced configuration to be fully utilized.
- The P:D card ratio is the tuning knob for cost and SLA; an imbalanced ratio causes both “expensive cards sitting idle” and “queue timeouts.”
An illustrative capacity calculation logic (pseudocode, expressing method only, not pointing to any specific product interface):
# Input: request profile and public hardware specsprefill_tokens = 20_000_000 # input size per requestcache_hit = 0.0 # prefix cache hit rateout_tokens = 8 # extremely short output# Effective compute: the hit portion is not recomputedeff_prefill = prefill_tokens * (1 - cache_hit)# Stage time estimation (coefficients must be calibrated by benchmarking)t_prefill = eff_prefill / prefill_tpst_decode = out_tokens / (decode_tps_per_card * cards)# Resource usage ratio -> derive P:D ratioratio = t_prefill / max(t_decode, 1e-6)
3. Breaking Down “Revenue per Card” into Optimizable Variables
Hourly output per card can be abstracted as: effective throughput × billing coefficient × cache reuse rate ÷ unit energy and rack amortization. The combination of extreme long text, zero cache hits, and ultra-short output pushes the numerator to its lowest and the denominator to its highest, forming the “most expensive conversation.”
There are six actionable governance measures:
- Input-side constraints: caps on per-request context and per-turn input length, with over-limit requests routed to an asynchronous batch channel;
- Prefix cache reuse: stable system prompts and templated prompts to raise the hit rate from 0 to a high level;
- Pool scheduling: physical isolation of long-text pools and short-conversation pools to avoid mutual contention;
- Continuous batching and chunked prefill: improving memory bandwidth utilization in the decode stage and reducing long-request blocking of the queue;
- Metering and quotas: differentiated metering by token and stage, rate-limiting abnormal profiles to replace a “one-size-fits-all unlimited” approach;
- Observability: P99 first-token latency, queue wait, cache hit rate, and effective tokens per card as primary metrics.
4. Conclusion
Whether domestic compute can provide the highest-standard inference service should not be judged by peak compute, but by “effective output and stability under real request profiles.” Public specs show it already has a complete engineering loop in bandwidth, compute, interconnect, and memory capacity; combined with a reasonable P:D ratio, cache reuse, and quota governance, it can fully support a production-grade SLA. Conversely, if extreme input profiles are not governed, any hardware will be dragged into a low-output range. For developers, the reliable path is to first build the request profile and capacity model, then discuss hardware selection.
