CoolFace
Modelpublic

mlx-community/Qwen3.8-Flash-Next-Uncensored-oQ5e-mtp

sourceHugging Faceotherupdated 10d agoView on Hugging Face
6likes2.5kdownloads
Model Card

Qwen3.8-Flash-Next-Uncensored (MLX, oQ5e, MTP)

Calibrated 5-bit mixed-precision MLX quantization of orcarouter/Qwen3.8-Flash-Next-Uncensored, the BF16 abliterated build of Qwen/Qwen3.8-Flash-Next. Produced with oMLX oQe (oQ level 5 with imatrix weighting). 5.72 bits per weight effective, 128.54 GB on disk (119.7 GiB) across 25 safetensors shards. Everything from the source is kept: the routed experts, the 51B-parameter n-gram embedding table (quantized, not left in BF16), the Lightning MTP head, and the full vision + video tower.

This is the build that runs the model's full 262,144-token context on a 128 GB Apple Silicon Mac. A real 250,073-token request completed in 214 s on a MacBook Pro M5 Max with Lightning MTP and TurboQuant KV on (numbers below).

[!WARNING] The source model has had its safety alignment removed by abliteration. It will comply with requests the original Qwen3.8-Flash-Next refuses. Released for research, red-teaming and interpretability work. Read the source model card's disclaimer before use and add your own moderation if you deploy it. You are responsible for what you do with it.

Model details

Quantized bytimteh673
Model typeQwen4ExpForConditionalGeneration (qwen4_exp), sparse MoE vision-language model with thinking mode, tool calling and an MTP head
Sourceorcarouter/Qwen3.8-Flash-Next-Uncensored (BF16, 360 GB)
Upstream baseQwen/Qwen3.8-Flash-Next
Parameters~180B total as stored (125B transformer + 51.2B n-gram table), ~6B active per token
Architecture48 layers, hidden 2560; hybrid attention: 36 Gated-DeltaNet linear layers + 12 full-attention layers (interval 4, 24 query heads, 2 KV heads, head dim 256); 512 routed experts, top-10, plus a shared expert; 3-gram PLE embedding table; QSA sparse-attention indexer (budget 2048); 1-layer MTP head
Context262,144 tokens native
LanguagesEnglish, Chinese (multilingual capable)
LicenseQwen Community License 1.0, inherited from the upstream model (LICENSE in this repo). The OrcaRouter source card labels itself Apache-2.0; the upstream Qwen repo and the LICENSE file shipped with the weights say Qwen Community License 1.0, so that is what is declared here.
Quantization tooloMLX v0.7.0.dev2, quantize_oq_streaming (oQe)
FormatStandard MLX affine safetensors, no custom kernels or loader

What is in this repo

FilesSize
model-00001-of-00025.safetensors ... model-00025-of-00025.safetensors128.54 GB (119.72 GiB)
config.json (with the full per-tensor quantization map), model.safetensors.index.json, oq_imatrix_report.json0.7 MB
tokenizer, chat template, preprocessor config, LICENSE23 MB

The size shown by oMLX's estimator and in its upload dialog (119.7 "GB") is GiB. The decimal figure is 128.5 GB.

Quantization layout

oQ is sensitivity-driven mixed precision: every layer's quantization error is measured on calibration data, and bits go where the data says they matter. The "e" (oQe) adds an importance matrix so that inside each quantization group the clipping favors the weights that carry activation energy. Output is plain affine quantization that any MLX runtime can read.

ComponentPrecisionBytes
Routed experts (512 per layer, 48 layers)5-bit, group 64, imatrix-weighted83.05 GB
PLE n-gram embedding table (51.2B params)5-bit, group 3238.40 GB
Attention, GDN, shared experts, routers, normsmixed 5 / 6 / 8-bit by measured sensitivity (routers 8-bit)3.04 GB
MTP head (mtp.*, 76 tensors)6-bit, group 641.81 GB
Embeddings and lm_head8-bit1.35 GB
Vision + video tower (333 tensors)BF16, untouched0.90 GB
Total5.72 bpw effective128.54 GB

Bit histogram over the 871 quantized text tensors: 209 at 8-bit, 498 at 6-bit, 164 at 5-bit. 128 n-gram shards at 5-bit. The exact per-tensor map is in config.json under quantization.

How it was made

Built on a MacBook Pro M5 Max (128 GB) with oMLX 0.7.0.dev2 from the 360 GB BF16 source, streamed tensor by tensor (the full model never sits in memory).

  • —Sensitivity pass: measured on a uniform 4-bit MLX build of the same model (the orcarouter 4-bit release), since the BF16 source is 2.8x the machine's memory. 48 layers scored, 128 samples x 256 tokens.
  • —Importance matrix: collected on a temporary uniform 4-bit proxy that oMLX builds and deletes itself. Calibration set oqe_code_multilingual (code, English, Korean, Chinese, Japanese, tool calls, reasoning). The adaptive collector ran to its maximum of 1,024 samples x 512 tokens: 937 tensor entries, 6,144 layer forwards, 128 MTP-head forwards. Expert coverage 75,243 of 75,264 (21 experts were never routed on the calibration set and fall back to plain oQ). Three tensors have no imatrix entry by design (lm_head and the two hyper-connection mixer projections) and are quantized with plain oQ. Full report in oq_imatrix_report.json.
  • —Time: about 80 minutes end to end, of which 46 minutes was imatrix collection. The imatrix cache is keyed by source, calibration set and sample counts, not by bit width, so the same matrix was reused unchanged for the sibling oQ6e build.

Requirements

Apple Silicon only. Tested with oMLX 0.7.0.dev2, which ships its own qwen4_exp implementation (Lightning MTP, the PLE table on SSD, TurboQuant KV). The checkpoint is standard MLX safetensors, but stock mlx-lm / mlx-vlm need qwen4_exp support to load it and were not tested here.

Unified memoryWhat you get
128 GBRuns, full 262k context. oMLX keeps the 38 GB n-gram table on SSD (mmap) and holds about 84 GiB resident. This is the configuration measured below.
192 GB and upEverything resident, including the n-gram table (~135 GB). Faster decode, since n-gram rows are no longer gathered from disk.
96 GB or lessDoes not fit. Use a smaller oQ level.

Disk: 129 GB for the model, plus room for oMLX's KV cache spillover.

Running it with oMLX

Drop the folder into ~/.omlx/models/ (or download it there) and the model is discovered on the next rescan. Settings used for the numbers below, on a 128 GB M5 Max:

SettingValueWhy
SSD N-gram Offload (Qwen4)onoMLX forces this on automatically whenever the resident estimate exceeds its memory ceiling. Required on 128 GB.
Lightning MTPon, 3 draft tokens88 percent draft acceptance measured. Roughly doubles tokens per decode cycle.
TurboQuant KV cacheon, 4-bit, skip last layerKV for the full 262k window drops from 6.4 GB to 2.0 GB. Costs about 5 to 8 percent prefill speed. Optional on 128 GB, useful headroom.
Context window262144Native maximum.
Thinkingon, preservedVendor default.
Sampling (thinking)temperature 1.0, topp 0.95, topk 20, presence 0Vendor defaults. Instruct mode: 0.7 / 0.8 / 20 / presence 1.5.
Memory guardAggressive tier (or custom around 120 GB)Leaves the prefill sizer room.

Any OpenAI-compatible client then works against http://localhost:8000/v1. Vision input goes in user messages as image_url parts.

Measured performance

MacBook Pro M5 Max, 128 GB, 40-core GPU, oMLX 0.7.0.dev2, n-gram table on SSD, Lightning MTP with 3 drafts, TurboQuant KV 4-bit unless noted. Single request.

Prefill (prompt processing)

Prompt tokensPrefill tok/sTime to first token
4,0961,090 to 1,1533.6 to 3.8 s
32,7681,29625 s
65,5361,228 to 1,34049 to 53 s
131,0721,203109 s
200,0001,081 to 1,236162 to 185 s
250,073 (real chat request)1,165214 s

The 250k request ran with no memory-guard throttling; every prefill chunk stayed at the full 2,048-token step. Without TurboQuant KV the prefill numbers are 5 to 8 percent higher.

Decode (generation)

Context at the timeDecode tok/sMTP acceptance
Short prompt, 900-token answer5987.7 percent, 2.56 tokens per cycle
250,073-token promptabout 3088.9 percent

Decode is bound by the n-gram gathers from SSD in this configuration. On a machine where the table is resident, expect materially faster decode; oMLX's own estimate for the SSD path is about 2.5x slower than resident.

Compared with the sibling builds

BuildDiskResident on 128 GB (table on SSD)262k context on 128 GB
oQ3.5e-mtp (not published)89.8 GB~70 GiB, or fully resident at ~94 GiByes
oQ5e-mtp (this repo)128.5 GB~84 GiByes, measured
oQ6e-mtp150.5 GB~101 GiB with MTP offno, about 131k with MTP off

oQ5e is the highest level that keeps the full context window on a 128 GB machine. oQ6e trades that for 6-bit experts; see its card for the exact limits.

Limitations

  • —Apple Silicon and MLX only.
  • —Safety alignment removed by the source model's abliteration. No guardrails.
  • —21 of 75,264 routed experts and 3 shell tensors were quantized without imatrix weighting (plain oQ), as noted above.
  • —The n-gram table runs from SSD on 128 GB machines, which caps decode speed; this is a property of the machine, not the quantization.
  • —No formal perplexity or benchmark evaluation was run on this quant. The measurements above are throughput and a correctness spot check (long-context retrieval answer, tool calls and vision were exercised through oMLX).

Credits

bibtex
@misc{omlx,
  title  = {oMLX: LLM inference optimized for Apple Silicon},
  author = {jundot},
  year   = {2026},
  url    = {https://github.com/jundot/omlx}
}