diff --git a/python/sglang/srt/server_args.py b/python/sglang/srt/server_args.py index 883e84199..2386c26bc 100644 --- a/python/sglang/srt/server_args.py +++ b/python/sglang/srt/server_args.py @@ -6359,6 +6359,22 @@ class ServerArgs: ) if a2a_backend == "deepep": + if self.moe_runner_backend == "flashinfer_cutedsl": + if self.deepep_mode == "auto": + self.deepep_mode = "low_latency" + logger.warning( + "Forcing --deepep-mode low_latency: flashinfer_cutedsl " + "FP4 MoE has no DeepEP normal-dispatch handler, so " + "deepep auto mode would crash during prefill. " + "low_latency covers both prefill and decode." + ) + elif self.deepep_mode == "normal": + raise ValueError( + "flashinfer_cutedsl FP4 MoE only supports DeepEP " + "low_latency dispatch (masked layout). DeepEP normal " + "(prefill) dispatch has no CuteDSL FP4 handler. Pass " + "--deepep-mode low_latency or auto." + ) if self.deepep_mode == "normal": logger.warning("Cuda graph is disabled because deepep_mode=`normal`") self.cuda_graph_config.decode.backend = Backend.DISABLED