# SGLang v0.5.21 - Release & Upgrade Intelligence
- **Product:** SGLang (https://sgl-project.ai)
- **Version:** v0.5.21
- **Released:** Oct 02, 2026
- **Impact Score:** 9/10
- **Breaking Changes:** Source flagged
- **Canonical Analysis:** https://changelogs.us/sglang/updates/v0.5.21/

## Executive Summary (TL;DR)
SGLang v0.5.21 introduces major architectural updates including a Rust-based prefix cache core by default, runtime prefill/decode role switching, a new /v1/decisions API, and support for 10 new LLM, VLM, and diffusion models. It also enforces breaking changes by rejecting request-supplied chat templates by default, removing deprecated endpoints and legacy radix caches, and requiring session wrappers for RL weight updates.

## Breaking Changes & Deprecations
- Breaking Changes & Upgrade Notes * **The unified radix tree uses the Rust core by default.** Configurations the Rust core does not support fall back to Python automatically; set `SGLANG_UNIFIED_RADIX_TREE_CORE_BACKEND=python` to force the Python core everywhere: [#39627](https://github.com/sgl-project/sglang/pull/39627)

## New Features
- Added support for new LLM/VLM models: DeepSeek-V4.1 Flash, GigaChat 3.5, IQuest-Q1, MiMo-V2.6 / MiMo-V2.6-Pro, and Ling-3.0-flash-VL.
- Added support for new diffusion models: DiffusionGemma, Qwen-Image 2.1, Anima Base v1.0, Ming-Image 0.1 Design / Design-Layer, and FLUX 3 Action.
- Runtime role switching for disaggregated instances between prefill and decode without restarts (#28403).
- New Decisions API (/v1/decisions) turning an LLM/VLM into a low-latency classifier and scorer (#41208).
- Score API (/v1/score) supporting scoring all candidates in a single request (#38965, #41188).
- Run MiniMax-H3 with SGLang Diffusion inside ComfyUI (#35990).
- GLM-5.3-Flash support on AMD MI355X with FP8/MXFP4 MoE and MTP speculative decoding (#38546, #39341, #39778).
- Support for SM100 NVFP4 GenMHA and speculative decoding KV cache (#36340), LiLiCorr candidate-lattice reranker for DFlash drafts (#37462), and DSpark speculative decoding for LFM2-VL (#40651).
- Optional KV transfer checksums for PD disaggregation (#39500) and LongBench v2 support in one-batch server benchmarks (#39874).

## Improvements
- Unified radix tree prefix cache now runs on a Rust core by default (#39627).
- DeepSeek-V4.1 achieves 22% faster time-to-first-token on long prompts (#40352).
- Kimi K3 gains 20.6% higher prefill throughput in PD serving (#40045).
- C4 Indexer capture memory reduced by 58% to 18 GB when breakable CUDA graphs are enabled (#36534).
- Bounded cached-prefix DCP transfers improve Kimi Linear cached-prefix throughput by ~10.9x at concurrency 8 on 8x B200 (#40376).
- Reduced decode bootstrap latency on DeepSeek-V4-Pro 1P1D MI355X (mean TTFT down from 19.4 s to 15.1 s) (#38978).
- Improved numerical accuracy under PP, DP attention, and CP via SGLang-managed layer communication (#41557).
- Lazy-loading of built-in model definitions and nixl_ep at startup (#41061) and logging of forward and forward+idle occupancy over total wall time (#40802).

## Bug Fixes
- Rejected request-supplied chat_template inside chat_template_kwargs by default on /v1/chat/completions and /v1/tokenize (#28135) and restricted SafeUnpickler to explicit globals (#39858, #40259).
- Disabled FlashInfer MoE fused finalize by default for numerical accuracy (#40105) and deferred PD decode KV release on abort/transfer failure by default (#41023, #41404).
- Prevented pause_generation and weight updates from deadlocking in RL workflows (#40779) and recovered from stale torch extension locks in cpp_extension loaders (#40989).
- Fixed CUDA graph stream explosions for Kimi K3 (#40640) and DSpark (#40658), and avoided freeing multi-CTA KV counters captured by decode graphs (#39175).
- Fixed deferred FFN all-reduce completion before pipeline-parallel sends (#41079), deepstack addition/aux hidden-state capture (#41080), and last-layer FFN all-reduce in five models (#40868).
- Fixed NIXL transfer of MXFP8 KV block scales (#40792), device context during NIXL backend initialization (#38774), and FakeKVSender queue accumulation (#28652).
- Guarded FlashInfer CUTLASS MoE against 0-token inputs (#38780) and fixed top-1 MoE routing with non-unit scaling (#40187).

## Upgrade Command
```bash
python -m pip install 'sglang==0.5.21'
```
