Instructions to use Vontra/Qwen3.8-Flash-Next-MLX-4bit with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use Vontra/Qwen3.8-Flash-Next-MLX-4bit with MLX:
# Make sure mlx-vlm is installed # pip install --upgrade mlx-vlm from mlx_vlm import load, generate from mlx_vlm.prompt_utils import apply_chat_template from mlx_vlm.utils import load_config # Load the model model, processor = load("Vontra/Qwen3.8-Flash-Next-MLX-4bit") config = load_config("Vontra/Qwen3.8-Flash-Next-MLX-4bit") # Prepare input image = ["http://images.cocodataset.org/val2017/000000039769.jpg"] prompt = "Describe this image." # Apply chat template formatted_prompt = apply_chat_template( processor, config, prompt, num_images=1 ) # Generate output output = generate(model, processor, formatted_prompt, image) print(output) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
- Pi
How to use Vontra/Qwen3.8-Flash-Next-MLX-4bit with Pi:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "Vontra/Qwen3.8-Flash-Next-MLX-4bit"
Configure the model in Pi
# Install Pi: npm install -g @earendil-works/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "mlx-lm": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "Vontra/Qwen3.8-Flash-Next-MLX-4bit" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Hermes Agent
How to use Vontra/Qwen3.8-Flash-Next-MLX-4bit with Hermes Agent:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "Vontra/Qwen3.8-Flash-Next-MLX-4bit"
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default Vontra/Qwen3.8-Flash-Next-MLX-4bit
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use Vontra/Qwen3.8-Flash-Next-MLX-4bit with OpenClaw:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "Vontra/Qwen3.8-Flash-Next-MLX-4bit"
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:8080/v1 \ --custom-model-id "Vontra/Qwen3.8-Flash-Next-MLX-4bit" \ --custom-provider-id mlx-lm \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
Qwen3.8 Flash Next — MLX 4-bit
A native Apple-silicon conversion of Qwen/Qwen3.8-Flash-Next, quantised directly from the official BF16 checkpoint.
Original model · Qwen overview · MLX-VLM · Qwen Community License 1.0
About this conversion
This repository contains a 4-bit affine MLX conversion of Qwen3.8 Flash Next. It was produced directly from Qwen's BF16 weights using group size 32. The smaller group is intentional: it also covers the model's 160-wide hashed n-gram embedding tables instead of leaving them in BF16.
| Item | Value |
|---|---|
| Base model | Qwen/Qwen3.8-Flash-Next |
| Format | MLX safetensors |
| Quantisation | 4-bit affine, group size 32 |
| Conversion stack | mlx-vlm 0.6.3, mlx 0.32.0 |
| Weight shards | 22 |
| Weight size | 111.58 GB (103.91 GiB) |
| Configured context | 262,144 tokens |
| Architecture | qwen4_exp vision-language sparse MoE |
The upstream tokenizer, chat template, vision processor, and generation configuration are preserved. The optional upstream MTP head is not included in this checkpoint.
Qwen3.8 Flash Next uses the new
qwen4_exparchitecture. Use an oMLX or MLX-VLM build that explicitly listsqwen4_expsupport. Older MLX-VLM releases cannot load this checkpoint.
Do not attach a Qwen3.8 27B MTP drafter to this model. The hidden sizes differ and the drafter is incompatible with Flash Next.
Quick start
hf download Vontra/Qwen3.8-Flash-Next-MLX-4bit \
--local-dir Qwen3.8-Flash-Next-MLX-4bit
With a compatible MLX-VLM runtime:
python -m mlx_vlm.generate \
--model Qwen3.8-Flash-Next-MLX-4bit \
--prompt "Explain sparse mixture-of-experts routing." \
--max-tokens 512
Measured performance
Validated on an Apple M3 Studio with text-only generation after model load:
| Test path | Result |
|---|---|
| oMLX server, warmed 543–566-token responses | 24.1–24.2 tokens/s |
| oMLX server, warmed shorter responses | 24.6–26.1 tokens/s |
| Standalone MLX exact-copy smoke test | 31.0 tokens/s |
The standalone result is a short smoke test; the longer oMLX figures better represent sustained chat generation. Results vary with prompt length, cache state, sampling settings, runtime version, and memory pressure.
Architecture
Qwen3.8 Flash Next is an experimental vision-language architecture combining Gated DeltaNet, Qwen Sparse Attention, sparse mixture-of-experts layers, widened gated residual streams, and hashed bigram/trigram embeddings.
| Architecture detail | Upstream value |
|---|---|
| Language-model parameters | 125B total / 6B active |
| N-gram embedding | 51B parameters |
| Layers | 48 |
| Routed / active experts | 512 / 10, plus 1 shared |
| Attention heads / KV heads | 24 / 2 |
| Hidden size | 2,560 |
| Native configured context | 262,144 tokens |
For upstream evaluations, intended use, limitations, safety guidance, and the complete architecture discussion, see the original model card.
Conversion and validation
- Source: official BF16 checkpoint.
- All 3,671 converted tensors and 22 indexed shards were checked locally.
- The release payload was scanned for credentials, personal contact details, private paths, private network information, logs, caches, and private organisation data.
- Deterministic standalone and warmed oMLX server generation tests passed on Apple silicon.
- Quantisation can reduce output quality relative to BF16. Test the model on representative workloads before production use.
This is a community conversion, not an official Qwen release.
License and attribution
The upstream model is released under the Qwen Community License 1.0. The required licence text is included in this repository.
Model design, training, evaluations, and upstream documentation belong to Qwen and the original contributors. The MLX conversion, Apple-silicon validation, and packaging are provided by Vontra.
- Downloads last month
- 301
4-bit
Model tree for Vontra/Qwen3.8-Flash-Next-MLX-4bit
Base model
Qwen/Qwen3.8-Flash-Next