DeepSeek Open-Sources DeepInfer: What Developers Need to Know for a Production-Grade Inference Stack
Originally published in Turkish. Read the original →

DeepSeek has released DeepInfer, the high-performance inference framework it built to run massive production workloads, to the open-source world under the Apache 2.0 license. We take a close look at the architecture of the engine, which supports NVIDIA SM100 GPUs and Huawei Ascend 950 NPUs, its DSpark speculative decoding capabilities, and the missing pieces developers need to build to set up a full live serving stack.
Training costs dominated the headlines in the race to develop large language models (LLMs) for a long time, but as of 2026 the real bottleneck and battleground of the AI economy has become inference efficiency. In an ecosystem where millions of concurrent users and autonomous agents consume billions of tokens per second, running models with the lowest latency and the lowest hardware cost provides a vital advantage. DeepSeek, which has struck the industry's most aggressive price-performance balance in this area, has released DeepInfer, the high-performance inference engine that powers its own massive production services, as open source under the Apache 2.0 license.
This step, which has generated great excitement in the open-source community, shows transparently how DeepSeek has pushed its marginal token generation costs far below those of its rivals. But a look at DeepInfer's codebase shows that it is not a ready-made package you install with one click and expose directly to end users as an API; it is a highly specialized offline runtime and kernel engine.
From the Legacy of vLLM, SGLang and TensorRT-LLM to Building From Scratch
When laying DeepInfer's first foundations, the DeepSeek engineering team drew heavily on the architectures of vLLM, SGLang and TensorRT-LLM, popular tools in the open-source ecosystem. But the unique communication bottlenecks introduced by Sparse Mixture-of-Experts (MoE) architectures and long context windows began to push the limits of general-purpose inference engines.
At that point DeepSeek removed the general-purpose abstraction layers entirely and rebuilt the runtime from the ground up around the mathematical structure of its own model family. With its first release optimized specifically for the offline inference workloads of the DeepSeek-V4.1-Flash model, DeepInfer offers a lean, ultra-fast execution layer stripped of unnecessary code.
The Core Technologies Powering the DeepInfer Architecture
What sets DeepInfer apart from standard inference libraries most is its custom operators and scheduling algorithms that go all the way down to the hardware level:
- TileLang Custom Operators and Sparse MoE Kernels: TileLang-based custom kernels that fit matrix multiplications and expert routing operations precisely to hardware caches maximize memory bandwidth utilization.
- Advanced Parallelism Strategies: Expert Parallelism (EP), Attention Data Parallelism and Balanced Context Parallelism are used together to minimize communication latency between multi-GPU/NPU nodes.
- Speculative Decoding With DSpark: The DSpark mechanism, which combines draft token generation with confidence-estimate scheduling, speeds up verification steps and multiplies the number of tokens generated per second.
- Asynchronous Scheduling: Batch preparation and scheduling on the CPU are fully overlapped with the execution steps of the accelerator (GPU/NPU), reducing hardware idle time to zero.
- Batch-Invariant Inference and Deterministic Sampling: Deterministic sampling support, which ensures the same input produces bit-for-bit identical output even across different batch sizes, provides critical reliability especially for enterprise testing, debugging and agent verification.
Day-Zero Support for NVIDIA SM100 and Huawei Ascend 950
One of the biggest strategic impacts DeepInfer has had on the industry is that it directly embraces a two-sided hardware ecosystem. The framework offers deterministic sampling and low-level kernel optimizations for next-generation accelerators with the NVIDIA SM100 architecture on one side, while on the other it provides first-class, day-zero compatibility for Huawei Ascend 950 NPU processors through the CANN software stack.
This setup, which lets Western cloud providers get maximum efficiency from NVIDIA clusters, also closes the software maturity gap in alternative AI chips and directly accelerates global hardware competition.
What Developers Need to Build for a Full Serving Stack
Although with DeepInfer DeepSeek has open-sourced the hardest mathematical and hardware part of the engine, there are critical infrastructure layers that engineering teams have to build on their own if they want to turn this package into a live API service in production.
The three core components left out of DeepInfer's scope that developers need to complete are:
1. A Distributed KV Cache Management System
The distributed KV Cache memory pool that prevents the same prefixes from being computed again and again in multi-turn conversations and long document analysis is not included in DeepInfer's core package. Engineering teams need to design an external memory layer that performs page-based memory transfers between RAM, NVMe disks and GPU memory (VRAM) and manages cache eviction.
2. Prefill and Decode Disaggregation
In modern large-scale LLM serving architectures, the compute-heavy initial reading stage (Prefill) and the memory-bandwidth-heavy token generation stage (Decode) run on different server clusters. DeepInfer provides the single execution engine, but the orchestration layer that transfers state between Prefill and Decode nodes over a high-speed network (RDMA / RoCE) has to be integrated by infrastructure teams.
3. Smart Load Balancing Across Data-Parallel Replicas
The higher-level router layer that queues incoming HTTP/gRPC requests, tracks which GPU replica holds the relevant cache data (cache-aware routing) and dynamically balances expert load across nodes is not included in the package either.
In short, DeepInfer hands AI infrastructure engineers the world's fastest Formula 1 engine for free; but building the chassis, gearbox and telemetry systems around that engine to turn it into a complete production vehicle ready for traffic is up to the architectural skill of developer teams.




