Open source · Inference systems

vLLM-MLX: inference on Apple Silicon

vLLM-MLX is an inference server built by Wayner Barrios for language and multimodal models on Apple Silicon. It combines a native MLX runtime with familiar client APIs and systems for sharing work across requests.

vLLM-MLX

From a model to a service

Running one prompt through a model is different from serving an application. A service must accept new requests while others are generating, handle repeated context, and expose an interface that existing tools can use. On a Mac, those tasks also need to fit the model and its working memory into the machine's available unified memory.

vLLM-MLX brings these serving concerns to Apple's MLX ecosystem. It exposes OpenAI-compatible and Anthropic-compatible APIs from a single process and supports language models as well as supported image, video, and audio workflows. The project is useful when building local applications or evaluating models on Apple hardware and when the application benefits from a server interface instead of direct model calls.

vLLM-MLX

Batching and shared context

Continuous batching lets the server schedule requests as they arrive and finish, so concurrent users can share model execution. Prefix caching reuses previously computed context when later requests have matching prefixes. The server also provides paged cache management and an optional SSD cache tier. These mechanisms address different parts of the workload; a cache hit and a faster decoding step are not the same result.

Multimodal prefix caching is particularly useful for repeated questions about the same image or shared visual context. The inference paper studies this setting alongside native model execution and scheduling on Apple Silicon. Whether caching helps a particular application depends on how its inputs repeat, how much cache can be retained, and how requests are distributed over time.

vLLM-MLX

Read the benchmark in context

The paper reports up to 525 tokens per second for text models on an Apple M4 Max and a 28x speedup for repeated image queries in its evaluated configuration. Those measurements describe particular models and workloads. They should not be read as the expected speed of every model or as the latency of a cold request that cannot reuse visual context.

The benchmark documentation provides more detailed serving comparisons. When testing your own setup, record the chip, memory, model, quantization, prompt length, generated tokens, concurrency, and cache state. Measure time to the first token separately from decoding throughput. A small model's tokens-per-second number alone cannot tell you whether a larger multimodal workload will meet an application's latency needs.

vLLM-MLX

Start with a small workload

Use the installation and quickstart instructions in the vLLM-MLX repository. Begin with a supported model that fits comfortably in your Mac's memory, start the server, and send a short request through the client API you plan to use. This checks the complete path from application to model before you add larger prompts, multiple users, or image inputs.

Next, try a representative sample of your actual workload. Compare cold and repeated requests, then increase concurrency gradually to see how batching affects throughput and latency. The repository documents a built-in serving benchmark and metrics endpoint for these measurements. For image, audio, tool calling, or structured output, check the relevant model support and configuration rather than assuming that every feature is available for every checkpoint.

vLLM-MLX

What the server does and does not change

The runtime targets Apple Silicon and MLX. Its API compatibility makes integration easier, but it does not make a locally loaded model identical to a hosted model. Reasoning quality, visual understanding, context limits, and tool behavior still depend on the selected model and configuration. Serving efficiency and model quality should be measured separately when deciding whether a deployment is useful.

For work on model behavior, see MoDA for visual grounding and CRYSTAL for reasoning evaluation. These are related research directions, not claims that their checkpoints run unchanged in this server. The research collection includes the inference paper, and the open source collection links the other tools and contributions.

Building Wiqonn and researching multimodal perception, video understanding, and efficient inference.

Get in touch