mrkeyoor.comAsk

sgl-project/sglangtested 17 Nov 2026commit f534dba

sglang review

Use SGLang if you operate a shared model service and can compare a pinned model and configuration against vLLM on representative traffic.

  • README install 77 s
  • README snippet failed
740/743passed, run exited non-zero
  • 10158.3 MB on disk
  • 168 dependencies
AI Toolsevaluationupdated 25 Nov 2026
+157stars / 7d

SGLang is an open-source inference framework for language, vision-language and diffusion models. Its programming frontend composes model calls; an application or agent runtime handles tool execution.

Verdict

Use SGLang if you operate a shared model service and can compare a pinned model and configuration against vLLM on representative traffic. Include completed requests, first-token latency, errors and answer quality in that decision. Contributors should start from the recorded Rust baseline: the build succeeded in 262 seconds, while cargo test returned 740 passes and three failures. Skip SGLang if you want a complete local agent host with model management and tool execution already assembled.

SGLang infographic: serve language, vision-language and diffusion models, plus our test result and who it suits
Tested 24 November 2026: the README snippet failed. Before that: 17 Nov: 740 of 743 source tests passed; uv install took 77 s.

We ran it

Lab card: what happened when we ran sglang
Lab card from our sandbox run
Screenshot of sglang (sglang.io)
sglang.io
Install✓ · 54s603 packages
Build✓ · 262s
Tests✗ · 127s740 passed · 3 failed of 743 (cargo test)
Repo12232 files~3,510,167 lines of source · 172.1 MB · 127 CI workflows · tests dir

Answers from our run

Does sglang build from source?

Dependencies installed in 54 seconds (603 packages), and the build succeeded in 262 seconds. We cloned commit f534dba into a clean Debian container with 3 CPUs and no project-specific setup.

Do sglang's tests pass?

No. The project's own test command finished in 127 seconds and reported 740 passed, 3 failed (cargo test).

Who should not use sglang?

Developers wanting a complete local agent host with model management and tool execution assembled.

What are the alternatives to sglang?

vLLM, llama.cpp, Ollama. Use SGLang if you operate a shared model service and can compare a pinned model and configuration against vLLM on representative traffic.

Setup4/5In our 2026-11-24 run it installed as the README says in 77 s; the README gave no task we could run as written.Editor’s note: The Rust install and build completed, but the separate Python package check stopped before a supported model-serving deployment.
Docs4/5The README has an install section (“Get Started”) and usage in the same section; we did not run its quickstart ourselves.Editor’s note: The README and documentation extracts support specific commands; full model and hardware coverage was not exercised.
Community5/5Last push on 2026-11-24, 39,027 stars, maintainers answered or closed 8 of the 10 most-discussed issues we sampled and 7,348 open issues and pull requests is a heavy backlog for its size.Editor’s note: Sampled issues contain maintainer replies and user workarounds, without a project-wide measure of support responsiveness.
Maturity2/5Latest release v0.5.23 on 2026-11-02 (pre-1.0), repository created 2024-01-08 and its test suite did not pass in our sandbox (740 of 743 passed).Editor’s note: The Rust test command failed, while production reliability, upgrade behavior and serving correctness were not assessed.

How we score

Who it’s for

Inference engineers comparing shared model serving against vLLM with representative traffic.
Teams with repeated prompt prefixes and the capacity to tune model-specific caching and memory settings.
Contributors working on the Rust component who need a concrete build and test baseline.

Who it’s NOT for

Developers wanting a complete local agent host with model management and tool execution assembled.
Operators requiring both the current documented NVIDIA release route and CUDA 12: the installation guide targets CUDA 13 and identifies SGLang 0.5.19 as the last release with a CUDA 12 lane.
Teams choosing a server from a universal speed claim: independent results change with the model and configuration.

Setup reality

Our sandbox installed SGLang commit f534dba in 54 seconds, built it in 262 seconds, and failed cargo test in 127 seconds: 740 passed and three failed of 743. The November 17, 2026 run covered ./rust/ with 3 CPUs and 12 GB RAM, recording 603 dependencies. The log names sglang-server --lib as the rerun target.

The separate November 24 package check used checkout 2c07dbe76be9 and installed PyPI SGLang 0.5.9 in 77.1 seconds after omitting the README's --prerelease=allow flag. Its example step failed because the runner expected a Python code block in the README, which instead links to the quickstart and cookbook.

The installation guide's NVIDIA route targets Linux, Python 3.11 or newer and CUDA 13. Docker users need a compatible driver and NVIDIA Container Toolkit. Model weights require storage, and gated or private weights require access credentials. The Rust harness, Python package check and documented model-serving route are separate checks.

SGLang's Rust build succeeded in our sandbox, but cargo test finished with 740 passes and three failures. Use SGLang if you operate a shared model service and can compare representative traffic against vLLM. Skip it if you want a complete local agent host: the serving framework and programming frontend occupy a different layer from tool execution and orchestration, a distinction discussed in the TensorSharp author's comparison.

The serving decision turns on completed requests and the time users spend waiting. In ZenML's October 9, 2026 replay, SGLang 0.5.20 decoded active requests faster than vLLM 0.31.0, yet completed fewer requests and took longer to deliver the first token. Those exact versions belong beside the result. Installation commands, model architecture, quantization, hardware and launch flags determine which comparison applies to a deployment.

What people use SGLang for

SGLang serves language, vision-language and diffusion models, according to the project README. Its frontend tutorial describes structured prompts and a server backend. Prefix caching reuses computations when requests begin with identical tokens, reducing repeated input processing. The examples below cover quantized models, replayed coding-agent traffic and a large DeepSeek deployment, with each result attached to the person or organization reporting it.

Who and workload What happened What the result describes
qiulang, Qwen2.5-7B AWQ on NVIDIA A10 Reported 14.92 requests/s for SGLang versus 9.50 for vLLM at 30 concurrent requests April-May 2025 measurements with SGLang 0.4.5 and vLLM 0.8.4
qiulang, Qwen3-4B AWQ Favored vLLM for consistency, throughput and overall performance A model change reversed the author's preference
ZenML, Qwen3.8-27B coding-agent traffic on one H100 Stock SGLang completed 277 requests against stock vLLM's 504 October 9, 2026 replay using SGLang 0.5.20 and vLLM 0.31.0
GitHub commenter jinleic, DeepSeek-V3.2-Exp on eight H200 GPUs Reported approximately 46 tokens/s with 1K input/output lengths and concurrency one One concurrent request on that deployment

For repeated conversation prefixes, the SGLang Team's HiCache article reports 15.5 times effective input throughput against its GPU-only baseline with DeepSeek-V4-Flash and Mooncake L3 storage. The project measured input processing, including cached tokens. Its explanation connects the gain to retaining conversation history beyond GPU memory, with CPU memory and external storage holding prefixes for later reuse.

What happened when we ran it

Our November 17, 2026 run at commit f534dba installed the Rust component in 54 seconds, built it in 262 seconds, and failed cargo test in 127 seconds: 740 passed and three failed of 743. We measured ./rust/ with three CPUs and 12 GB RAM, recording 603 dependencies. The failing library summary contained 541 passes, three failures and one ignored test, followed by the suggested library rerun target.

Rust harness step Recorded result
Install Succeeded in 54 seconds; 603 dependencies recorded
Build Succeeded in 262 seconds
Tests Failed, exit 101, in 127 seconds; 740 passed, three failed of 743
Failing library summary 541 passed, three failed, one ignored
Suggested rerun cargo test -p sglang-server --lib

Several suites completed successfully before the command ended with error: test failed, to rerun pass -p sglang-server --lib. The checkout contained 12,232 files, approximately 3,510,167 source lines and 172.1 MB. The scan recorded 127 CI workflow files, a tests directory and no Dockerfile. Separately, the README documents a published Docker image, so the scan result describes the inspected files rather than container availability.

The November 24 package check used checkout 2c07dbe76be9 in a fresh, unprivileged ghcr.io/astral-sh/uv:python3.12-bookworm container with two CPUs, 4 GB RAM, no published ports and no secrets. The recipe was quickstart-lib. It ran uv pip install sglang in a fresh virtual environment, omitting the README's --prerelease=allow flag. The installed package was SGLang 0.5.9, a separate version identifier from the repository checkout.

The package runner's example step failed because it found no Python code block in the README. Its separate no-snippet finding recorded the same condition. The README instead sends readers to the quickstart for their first model and request, and to the cookbook for a model-and-hardware launch command. The table records the package check's timings, installed footprint, dependency count and cleanup outcome.

Package-check question Answer Verdict Why
Did the recipe clone the repository? Yes, in 11 seconds Completed The clone step recorded that duration
Did the package install? Yes, SGLang 0.5.9 in 77.1 seconds Completed with a command difference The runner omitted the README's prerelease flag
What occupied disk after installation? Site-packages measured 10,158.3 MB Recorded This is the directory measurement, including installed dependencies
How many dependencies were installed? 168 packages besides SGLang Recorded The dependency-count step supplied that count
Did the README example step run? No; the runner found no Python code block Failed The README directs readers to the quickstart and cookbook
Did cleanup complete? Teardown returned ok Completed The teardown record reports success

Where people get stuck: model support and recovery

Issue #3836 reports DeepSeek-R1 stalling during prefill after an idle period, followed by a watchdog timeout. Users restored service by restarting it. In the same discussion, mindhash reported that health status stayed at 200, which prevented their recovery logic from detecting the stalled service. That report gives operators a concrete acceptance check: exercise a small generation request with a timeout after an idle interval.

Report What the discussion says Reported action or outcome
DeepSeek-R1 idle stall, issue #3836 Prefill stalled and the watchdog timed out; health responses stayed at 200 Restarting the service or pod restored operation; a maintainer suggested latest source
RTX 5090 multi-GPU failure, issue #7227 The installed NCCL package caused trouble with multiple GPUs RodriMora reported success after upgrading nvidia-nccl-cu12
DeepSeek-V3.2-Exp recognition, issue #11060 Transformers raised KeyError: 'deepseek_v32' A maintainer reported a fix in the support branch and said the Docker image would be updated
DeepSeek-V4 GPU visibility, issue #23602 A commenter said the image appeared to hardcode CUDA_VISIBLE_DEVICES=4,5,6,7 The commenter reported a workaround by setting CUDA_VISIBLE_DEVICES manually
gpt-oss loading and output, issue #8833 Users reported an unrecognized architecture and wrongly formatted output Upgrading Transformers was suggested for recognition; the formatting complaint is a separate report

Memory adjustments also change serving capacity. The official FAQ recommends reducing --chunked-prefill-size to 4096 or 2048 for prefill out-of-memory errors and lowering --max-running-requests for decoding failures. Lowering --mem-fraction-static reduces the cache pool, maximum concurrency and peak throughput. For long-prompt input-logprob requests, it recommends restricting logprob_start_len to the necessary portion. These settings address different sources of memory demand.

Fast decoding can leave users waiting in a queue

ZenML measured median output-token time of 22.51 ms for stock SGLang versus 53.94 ms for stock vLLM, but median first-token time was 76.29 seconds versus 8.66 seconds. The October 9, 2026 replay used Qwen3.8-27B on one H100, with SGLang 0.5.20 and vLLM 0.31.0. Stock SGLang generated 205.79 tokens/s against vLLM's 391.94 tokens/s across the measured serving window.

Qwen3.8-27B combines Gated DeltaNet and attention. ZenML identifies per-request linear-attention state as the bottleneck in this configuration: stock SGLang reached five running requests against vLLM's 31, with up to 27 requests waiting. Turning radix caching off increased SGLang's completions to 435 but produced 11 connection resets. Completed streams, queue time and reset counts therefore belong beside active decoding speed in a serving comparison.

Installation starts with your accelerator and CUDA lane

The installation guide's NVIDIA route targets Linux, Python 3.11 or newer and CUDA 13. It identifies v0.5.19-cu129 as the last CUDA 12 image tag and SGLang 0.5.19 as the last release with a CUDA 12 lane. Current Docker instructions require a compatible NVIDIA driver and NVIDIA Container Toolkit. Other accelerators have separate platform guides linked from the README's hardware table.

The README's Python command is uv pip install --prerelease=allow sglang. The installation guide explains that uv versions older than 0.12.0 can silently install SGLang 0.5.9 without the flag because some dependencies publish only prereleases. On uv 0.12.0 and newer, it describes the flag as harmless. The November 24 package check recorded the omitted flag and the older resolved package together.

For reproducibility, the installation guide recommends a specific release or dated nightly image. It also describes a host cache directory for downloaded weights and passing HF_TOKEN for gated or private models. Record the image, model revision, driver, quantization and launch arguments together. The cookbook supplies model-specific launch commands, while the hardware table identifies the platform guides that lead to those commands.

Rollbacks need answer checks as well as healthy infrastructure

A commenter in the r/mlops operating discussion reports adding output-level monitoring so answer quality can trigger rollback. They describe infrastructure staying healthy while a model revision degrades answers. That account supports including judged answers in a rollout sample alongside HTTP success, latency and server health. It is a reported operating practice, with answer-quality signals serving a different purpose from infrastructure checks.

The installation example binds to 0.0.0.0 and publishes port 30000, while the request tutorial uses a local client with api_key="None". For an evaluation, keep access restricted and decide authentication, request limits and network rules before opening the endpoint to other users. The FAQ documents --enable-deterministic-inference because temperature zero alone can still produce different outputs as batching and cache-dependent kernel choices change numerical results.

SGLang vs vLLM, llama.cpp, Ollama and TensorRT-LLM

SGLang versus vLLM results change with the model: qiulang preferred SGLang for Qwen2.5-7B AWQ and vLLM for Qwen3-4B AWQ, while ZenML's H100 replay favored stock vLLM for completed requests. These comparisons make the model and traffic shape part of the selection decision. The TensorSharp author's guide addresses a separate choice, positioning local model management and portable execution alongside shared model serving.

Choice When it belongs on your shortlist Evidence
SGLang vs vLLM Shared serving with representative concurrent traffic qiulang's model-dependent results and ZenML's versioned H100 replay
SGLang vs llama.cpp Shared serving versus portable local execution and GGUF The TensorSharp author's selection guide
SGLang vs Ollama Serving controls versus simpler local installation and model management The TensorSharp author's selection guide
SGLang vs TensorRT-LLM A deployment centered on NVIDIA optimization The TensorSharp author's selection guide

In qiulang's multi-GPU A10 setup, switching from data parallelism to tensor parallelism improved performance. Data parallelism uses separate model replicas; tensor parallelism divides model computation across devices. The author's small quantized model fit on one A10, yet the parallelism choice still changed consistency and throughput. Include that setting in a comparison record, rather than assuming GPU count alone describes the deployment.

What the other reviews get wrong

WeavAI's guide presents a 29% H100 inference-speed lead as a general SGLang advantage, while ZenML's H100 replay measured stock SGLang at 0.53 times vLLM's generated tokens/s. The WeavAI wording omits the workload conditions needed for a general recommendation. Different benchmarks can produce different results; ZenML's replay explains its own result through concurrency, queueing and hybrid-model state.

Zhongzhu Zhou's technical review describes shared-prefix reuse as "for free". The project's HiCache explanation describes capacity, eviction and recovery costs instead. A reusable prefix must have identical tokens, its restored state must be sufficient to continue the model, and restoring it must cost less than recomputation. That is a conditional optimization with storage and transfer work attached to it.

The vLLM forum's original memory explanation also needs its author's correction: qiulang had mistaken --max-total-tokens for the context-length setting and reported essentially equal memory use after switching to --context-length. Separately, the website's November 2 snapshot labels v0.5.23 latest, while the project X post says it announced SGLang v1.0. An announcement and an installable artifact are different records.

Questions people ask

The documented NVIDIA installation route uses CUDA 13; shared-serving comparisons turn on the model and traffic, with qiulang's preference changing between Qwen2.5-7B and Qwen3-4B. The installation guide identifies the environment requirements, and qiulang's comparison records the model-dependent result. For a deployment decision, pair the accelerator's installation route with completed requests and first-token latency from the intended workload, rather than choosing from an engine-wide speed claim.

What is SGLang, and what does its name stand for?

SGLang means Structured Generation Language, the expansion used in WeavAI's guide. The frontend tutorial describes a structured way to define prompts and connect them to a server. Zhongzhu Zhou's technical review identifies the paper as "SGLang: Efficient Execution of Structured Language Model Programs" and discusses the relationship between the Python frontend and serving runtime.

Where are the official SGLang GitHub repository, docs and cookbook?

The official repository is sgl-project/sglang, whose README links the SGLang documentation and SGLang cookbook. The README directs readers to the quickstart for a first model and request, and to the cookbook for model-and-hardware launch commands. Its platform table links separate hardware guides, including NVIDIA, AMD, TPU, Intel and Apple Silicon routes.

How do I install SGLang and send my first request?

The README's Python installation command is uv pip install --prerelease=allow sglang in an activated environment. The installation guide gives sglang serve MODEL_PATH --host 0.0.0.0 --port 30000, with MODEL_PATH replaced by a model ID or local directory and additional arguments chosen for the model and hardware. The request tutorial directs readers to the running server's /docs, /redoc and /openapi.json API references, using port 30000 in its examples.

How do I run SGLang in Docker, and which image matches my hardware?

The README starts with docker pull lmsysorg/sglang:latest. The installation guide describes current NVIDIA images as CUDA 13 images and identifies v0.5.19-cu129 as the last CUDA 12 tag. It recommends a release or dated nightly for reproducible deployments. Choose another accelerator's platform guide through the README's hardware table before selecting its model-specific launch configuration.

What is SGLang Omni, and how does it differ from SGLang Diffusion?

The README's ecosystem table lists SGLang Omni as a separate project for text-to-speech and automatic speech recognition. It describes SGLang Diffusion as built into this repository and the sglang Python package for image, video, audio and action generation. Because both descriptions include audio, the intended model and task determine which project's documentation to follow.

How should I choose between SGLang, vLLM, llama.cpp, Ollama and TensorRT-LLM?

The TensorSharp author's selection guide positions Ollama around simple installation and model management, llama.cpp around portable local inference, and TensorRT-LLM around NVIDIA optimization. For shared serving, compare SGLang and vLLM with the same model and representative traffic. ZenML's replay shows why completed requests and first-token latency can produce a different preference from active output-token speed.

How does SGLang compare with vLLM on DGX Spark?

The project's X post reports 38.28 tokens/s decode for Qwen3.8-27B on DGX Spark. That figure is a project-reported SGLang result attached to a particular model and device. The post also reports a separate RTX 5090 result using NVFP4 plus DSpark, so those hardware and configuration labels belong with their respective numbers when discussing local serving choices.

Is SGLang better than vLLM or llama.cpp for a single-user personal agent?

The personal-agent Reddit discussion asks about inference speed for one user's agent harness and proposes a two-GPU configuration. A personal-agent decision should use one-user response time, the intended context length and the exact model. The concurrent measurements above answer a shared-serving question, while the application still needs its own tool execution and orchestration layer.

Is switching from llama.cpp to SGLang worthwhile on Strix Halo?

The Strix Halo discussion includes andymaclean19's account of a working llama.cpp setup used every day. Their performance comparison concerns vLLM and llama.cpp with different model formats and request patterns. Keep that existing deployment as the baseline for a local comparison using the same model, precision, context and request count before choosing a replacement.

When does prefix reuse matter more than raw throughput?

The HiCache article describes requests that share identical starting tokens, such as the same document followed by different questions. Reusing the document's cached state reduces repeated input processing. The decision depends on prefix length, cache capacity and recovery cost: loading a retained prefix helps when it is cheaper than recomputing it, and the complete state needed by the model is available.

Why can SGLang decode faster but still deliver worse first-token latency and fewer completed requests?

ZenML's stock SGLang configuration ran at most five requests at once against vLLM's 31. Requests queued while active decoding proceeded quickly. With Qwen3.8-27B on one H100, the replay measured 22.51 ms median output-token time for SGLang but 76.29 seconds median first-token time. ZenML attributes this configuration's capacity bottleneck to the hybrid model's per-request linear-attention state.

Should I use tensor parallelism or data parallelism when the model fits on one GPU?

qiulang's A10 experiments improved after switching SGLang from data parallelism to tensor parallelism, even though the quantized Qwen model fit on one GPU. That result supports including both parallelism settings in a deployment comparison. Record response-time variation and completed requests alongside throughput, because the author's original data-parallel configuration showed variable response times as well as reduced throughput.

What we have not tested yet

Our Rust harness covered commit f534dba; the Python package check used checkout 2c07dbe76be9 and stopped before inference. We have not tested GPU serving, answer quality, production upgrades, security controls, sustained traffic or idle recovery ourselves. The Rust failure assertions and runtime-version logs are missing, so the causes of the three failed tests and the actual toolchain and operating-system versions are unknown. The lab-rust:1 label supplies neither version.

The November 24 check installed a PyPI package rather than demonstrating that Python serving code from checkout 2c07dbe76be9 ran. Its omitted prerelease flag and resolved SGLang 0.5.9 are not evidence of a defect in the README's documented command. No screenshots or completed known-answer tasks accompany that check, and the collected YouTube entries have no transcripts supporting a demonstrated outcome. The documentation examples here were not executed as part of this correction.

ZenML ran each setting once on one model and GPU type, without repeat measurements, confidence intervals or agent-task outcomes. Its replay used recorded prompts and fixed output lengths; the recordings are unpublished, and different settings reached different sessions. qiulang's A10 results are historical. The DGX Spark post has no matched vLLM result here, the personal-agent question has no controlled single-user comparison, and the Strix Halo commenter explicitly says, "I did not try SGLang."

The idle-stall discussion does not confirm a permanent recovery or health-check correction. The gpt-oss formatting complaint has no confirmed fix in the discussion excerpts. The local request and exposed-port examples do not assess a public access policy. Neither the v1.0 announcement nor the dated website label identifies which later wheel or container was available. Rendered layout, citation-handle resolution, automatic related links, recommendation modules and template content were not assessed in this text-only correction.

Alternatives

ProjectWhat it isPick it when
vLLM gh↗A competing model-serving engine in qiulang's and ZenML's independent comparisons.Choose it when matched traffic on your model favors its completed requests and user latency, as in ZenML's October 9, 2026 H100 replay.
llama.cpp gh↗The TensorSharp author's selection guide positions llama.cpp around GGUF and portable local inference.Shortlist it for local execution, then compare your model's single-user latency on the intended hardware.
Ollama gh↗The TensorSharp author's guide positions Ollama around local installation, model management and application-facing APIs.Choose it when simple local model installation and lifecycle management are your main requirements.

Sources

  1. SGLang README
  2. SGLang installation
  3. qiulang's vLLM and SGLang performance comparison
  4. ZenML's SGLang versus vLLM benchmark
  5. SGLang HiCache explanation
  6. DeepSeek-R1 idle-stall issue #3836
  7. Blackwell support issue #7227
  8. DeepSeek-V3.2-Exp support issue #11060

More ai tools reviews