Paper commentary
Superfluid: Local AI Server for Distributed LLM Inference
- Problem Not stated in the paper.
- Method Superfluid runs llama.cpp, MLX and BaseRT in isolated worker processes behind one scheduler, writes every token to a durable session log before delivery, and places whole sessions across machines in fleet mode.
- Results Gets the first token of a chat sent behind eight busy agents in 1.5 s on Qwen3.8-27B at 4 bits on an Apple M5 Pro through llama.cpp, against 291–612 s for the other servers.

Figure 2 : Run A: six heterogeneous machines as one endpoint, Qwen3-4B on llama.cpp, 64 simulated users for one hour. Stacked areas give the output tokens per second each machine served (30 s rolling rate); the line gives the median time to first token per minute (right axis, log scale). Dotted lines mark machines joining (+) and the node killed at 42 minutes (−). All 5,041 requests were answered.
Original paper · CC BY 4.0 · Prabod Rathnayaka, Isura Manchanayake, Srikandabala Kogul, Steve Siu, Fabian Waschkowski, Lukas Wesemann · Superfluid: Local AI Server for Distributed LLM Inference · Original paper figure · Extracted the figure area from page 5 of the original PDF.Why one local server falls short
Running a model on the device that uses it keeps prompts off the network, avoids a per-token bill, and removes the round trip to a shared data centre queue. Two changes strain that arrangement. Agentic work produces long, growing prompts from several agents at once, while the same user still expects quick replies. Meanwhile a developer or small office often owns several capable machines with different hardware, each suited to a different runtime.
The work therefore targets two scales: a single device that must stay responsive under many agents, and a fleet of heterogeneous machines that should act as one endpoint. The remaining sections follow that split. They first describe how one device is served, then how the fleet head places and recovers sessions, and then the measurements at each scale.
One daemon driving several runtimes
The daemon keeps the APIs, chat templates, tokenizers, scheduler and session log. The worker holds the weights, the KV cache and sampling for one model, so a crash in a worker does not take down the daemon.
Every runtime is called through one operation, tick(plan). In each call the daemon sends a plan with admissions, prefill chunks, decode grants and retirements, and the worker answers with the tokens each lane produced.
The two runtimes differ in how much of the server they need to implement. BaseRT implements tick itself. llama.cpp and MLX only supply about a dozen sequence primitives, such as creating, copying, truncating and freeing a sequence and running one batched step. A shared executor sits on top of those primitives and provides continuous batching, prefix caching, grammar-constrained decoding and sampling, so a new runtime gets the full server from one adapter crate.
Scheduling that protects the interactive user
Waiting jobs gain one class per period, which keeps background work from waiting indefinitely.
A long prompt that no other request could join runs in longer ticks, which use the GPU more efficiently. The short-tick rule therefore applies only when it helps, and it is the chunked prefill idea from Sarathi-Serve.
A prefix normally enters the cache only when its lane retires. Without a fix, a burst of requests that share one long system prompt would each compute that prompt in parallel.
A client that disconnects frees its lane at the next tick, whether or not the request was streaming.
Durable sessions and recovery
This follows the write-ahead discipline from database recovery. The KV cache and the prefix cache are treated as caches that can be rebuilt from the log, so losing them costs time but not data.
Fleet placement and failover
The fleet link uses the same frames as the local link, carried over TCP. A Noise protocol handshake keyed by a fleet token that the head generates admits only machines that hold the token, and every frame afterwards is encrypted and authenticated.
The client receives one continuous stream, and no token is delivered twice.
Single-device results on an Apple M5 Pro
The largest gap is responsiveness under load. A chat sent behind eight busy agents gets its first token after 1.5 s on llama.cpp through Superfluid and 2.0 s on MLX through Superfluid. The other servers hold the same chat behind the agents for 291–612 s, as the first-token row of the comparison shows.
Because mlx lm.server serves one request at a time, the shared executor turns MLX into a batching server, with 1.35× the aggregate throughput of mlx lm.server at eight requests, 130.2 against 96.8 tok/s.
Table 1 places the Superfluid rows beside the three llama.cpp and MLX reference servers on the same scenarios.
Office workload across a growing fleet
Run B uses Qwen3.6-35B-A3B at 4 bits on BaseRT across Metal and CUDA machines, an Apple M6, an M4 Pro, an M1 Max, an M5 Pro, an M3 Ultra and a GB10.
Figure 2 plots the per-machine output rate and the per-minute median first token for Run A over the hour.
Table 2 gives the same comparison in numbers, with first-token p50 and p90 for each fleet size and for the whole hour in both runs. In Run A the two GB10s and the Ryzen AI Max each served 114 to 122 tok/s while they were up, against 71 to 73 tok/s for the M4 Pro and the M6, so the load followed machine speed without per-machine configuration.
Across both runs 12,192 requests were answered, with 5,041 in Run A and 7,151 in Run B, and none failed.
Capacity on twelve Mac Studio M3 Ultras
To measure capacity instead of demand, the agent sweep uses twelve Mac Studio M3 Ultras with 512 GB each, running Qwen3.6-35B-A3B on BaseRT 0.4.6 with 128 lanes per node and no speculative decoding.
Limits of these measurements
The single-device comparison covers one Apple M5 Pro, one model at 4 bits, greedy decoding with thinking off, and one build per runtime. The mlx lm.server throughput comparison is reported at eight requests on Qwen3-4B with the M1 Max, so it does not describe other concurrency levels.
Run A and Run B differ in model and runtime, so they are two fleet workloads rather than one controlled comparison of runtimes. The workload is closed-loop, so output throughput in the fleet runs partly reflects how many requests the users generate. The five-machine saturation point rests on a matched throughput value that the authors interpret rather than measure directly.
The capacity sweep used no speculative decoding, fixed 256-token replies, and only Mac Studio hardware, so it does not show how the fleet behaves on mixed machines at that load.
Paper info
- Authors
- Prabod Rathnayaka, Isura Manchanayake, Srikandabala Kogul, Steve Siu, Fabian Waschkowski, Lukas Wesemann
- Venue
- arXiv · Preprint
- First published
- 2026-11-13
- Added
- 2026-11-16
- Updated
- 2026-11-13
- Version
- v1
- arXiv
- 2611.17753
- Category
- cs.DC · cs.AI · cs.CL
- Original paper terms
- CC BY 4.0
- What we show
- Paper info, commentary and permitted figures from the original paper
AI commentary is a separate explanation from the original paper and may contain errors. The original paper and figures follow each source's terms of use and any rights noted separately.
Abstract
Running large language models (LLMs) on local devices keeps data private, removes per-token cost, cuts network latency, and keeps working without a connection. Two shifts now strain how such models are served. On one device, several agents share a locally served model with an interactive user. Across devices, a developer or small team often owns several capable machines from different vendors, which sit idle most of the day because every local server serves one runtime on one machine. We present Superfluid, an open-source LLM server built for local inference at both scales. On one device, Superfluid drives llama.cpp, MLX, or BaseRT in isolated worker processes through one scheduler that moves interactive requests ahead of agent work, computes a prompt shared by many requests once, and writes every token to a durable log before it reaches the client. Across devices, one Superfluid server turns a fleet of machines into a single API endpoint. Machines with different hardware serve copies of the same model, receive work according to their measured speed, and can join or fail under load without losing a request. For Qwen3.8-27B on an Apple M5 Pro, a chat sent while eight agents are working receives its first token in 1.5 s, against 291-612 s on llama-server, Ollama, and mlx_lm.server. On six machines from three chip vendors serving 64 simulated users for one hour, Superfluid answers all 5,041 requests while machines join one at a time and one is killed and rejoins; throughput grows from 112 to 534 tok/s and the median first-token time falls from 99 to 12 s. On twelve Mac Studio M3 Ultras it sustains 10,656 tok/s across 38,563 requests from 384 agents without a failure. Superfluid is available under the Apache-2.0 licence at https://github.com/basecompute/superfluid.
Quote from the paper
Prabod Rathnayaka, Isura Manchanayake, Srikandabala Kogul, Steve Siu, Fabian Waschkowski, Lukas Wesemann (2026). Superfluid: Local AI Server for Distributed LLM Inference. arXiv:2611.17753v1. https://arxiv.org/abs/2611.17753v1
BibTeX
@misc{rathnayaka2026superfluid,
title = {{Superfluid: Local AI Server for Distributed LLM Inference}},
author = {Prabod Rathnayaka and Isura Manchanayake and Srikandabala Kogul and Steve Siu and Fabian Waschkowski and Lukas Wesemann},
year = {2026},
eprint = {2611.17753},
archivePrefix = {arXiv},
url = {https://arxiv.org/abs/2611.17753v1}
}