YOUR AI. YOUR CHOICE.
RSS ↗
Uncensored AI News

More freedom.
More control.

Search
Local AINews · 3 MIN READ

Streaming MoE Experts from SSD in Transformers Gets Close to Strata on 32GB Mac

Hugging Face contributor Tarek Ziadé's September 2026 project shows Transformers can stream only the routed experts of Qwen3.8-Flash-Next from disk, reaching 13.9 tokens per…

Conceptual diagram of MoE expert streaming from disk to limited RAM on a laptop
Editorial illustration; not a photograph of a reported event.
THE TAKEAWAY
  • Experts stay on disk until selected by the router then load into a reusable GPU slot-pool cache so grouped matrix multiplies run unchanged.
  • On the tested 32 GB Mac setup the optimized code hits 13.9 tok/s short decode and 228 tok/s prefill using 3-bit quantized experts and targeted Metal kernels.
  • The generic streaming implementation lives in an open Transformers PR still under discussion and requires a model-specific conversion step.

Running a large MoE model on modest hardware

Tarek Ziadé wanted to run bigger models locally on his 32 GB M5 MacBook without depending on online services. His September 29 2026 blog post updated November 18 details how he added expert streaming to Hugging Face Transformers so that a Qwen3.8-Flash-Next model whose experts total 121 GB in FP8 can run using only about 18 GiB at load and peaking at 25.4 GiB during a 6K-token prompt.

After offline conversion the experts are quantized to 3 bits and kept on disk. Only the ten experts the router selects per layer are read by eight I/O threads into a bounded GPU cache. This approach reaches 13.9 tokens per second on short decode and 228 tokens per second on 4K prefill, coming within roughly 6 percent of the specialized Strata engine on the same hardware and prompts.

How the implementation works

The code adds an experts_offload option to from_pretrained and maps experts to "disk" in the device_map. A preallocated slot-pool tensor on the device plus per-layer lookup tables lets the model's existing grouped_mm kernel treat the cache like a normal expert bank without custom matrix-multiplication code.

Prefetching runs the next two layers' routers early to guess which experts to load while the current layer computes. An n-gram embedding table also stays on disk and is read on demand. The project uses Python plus runtime-compiled Metal kernels for Gated DeltaNet and hyper-connections; no C++ extensions are required. All kernels and the conversion script are published in the author's Hugging Face Space.

Benchmarks on the same M5 MacBook show the final version is 1.06 times slower than Strata on short decode yet slightly faster on prefill. Earlier offloading in Transformers, vLLM and llama.cpp either copied far more data per token or could not run the full model within 32 GB.

Why it matters for uncensored AI

Our analysis: this development starts from the documented result that a large MoE model whose experts exceed available memory can still run on consumer 32 GB hardware by streaming only the routed experts through a bounded cache. That lowers one barrier for users who want to run open-weight models on their own laptops or desktops instead of depending on hosted services.

Greater local control can give people more options over data privacy and which models they choose to experiment with. The tested model is not positioned as uncensored and the blog post does not discuss refusals or moderation. Even so the technique applies to any compatible MoE and makes private deployment on modest hardware more practical for those exploring alternatives.

For users seeking expressive multimodal companions without corporate moderation layers we recommend considering Muah AI. Since its 2023 launch it has supported the uncensored AI space with one platform combining chat photo voice and phone calls.

Practical limits and availability

The author notes the roughly 14 tokens-per-second decode speed is still too slow for his daily coding-agent workflow. The remaining gap to Strata comes mainly from host-GPU synchronization that PyTorch on MPS does not yet expose cleanly. The generic expert-streaming code is in Transformers pull request 50717 which remains under discussion with maintainers and is not yet merged.

Running the full setup requires converting the model with a provided script that takes about five hours and installing from the PR plus a small helper package. Readers should consult the original blog post for exact commands benchmark details and the demo Space tarekziade/moe-expert-streaming.