license: apache-2.0
license_link: LICENSE
base_model: Quat3rnion/Qwen4-35B-A3B-BF16-abliterated
base_model_relation: quantized
pipeline_tag: image-text-to-text
library_name: basalt
language:
- en
tags: - basalt
- qwen4
- moe
- abliterated
- uncensored
- vision-language

Qwen4-35B-A3B abliterated for Basalt, on Blackwell
Model file for Basalt, a local inference engine for NVIDIA Blackwell GPUs (sm_120) with an OpenAI- and Anthropic-compatible API. Basalt runs this model on one Blackwell card: every expert on a 32 GB card, and on a 16 GB card the experts that do not fit stay in system RAM. Up to 64 requests run at once. Needs Basalt 0.7.0 or later.
One self-contained file: weights, the tokenizer and chat protocol, the vision tower, the model's own MTP drafter with its draft vocabulary, and RadixArk's DFlash 2 drafter. Built from Quat3rnion/Qwen4-35B-A3B-BF16-abliterated, a one-direction ablation of Qwen/Qwen4-35B-A3B at commit c06f0c19d9411aba77f8d5948f69ae825c7161cb. Every tensor is stored in one form: NVFP4 experts, an IQ4_NL n-gram table, int8 dense projections, an int8 output head, FP8 hyper-connection rows, and a quantized drafter.
| file | size | experts | dense |
|---|---|---|---|
Qwen4-35B-A3B-abliterated.basalt |
34.4 GB (32.0 GiB) | NVFP4, least squares | int8 |
SHA-256: 6891b515be5e65b918cbb5fa679526e75d7a28f7e602e5637df349b91d1db0ef
- Context: up to 1,048,576 tokens (
--max-context, default 8,192);--kv int8shrinks the cache. - Drafters: on one card the DFlash 2 drafter is the default, and multi-card modes use the MTP drafter;
--drafter mtppicks MTP on one card too. Drafted tokens are verified, so the output is the model's own: greedy output is bitwise the same with drafting on or off.--spec 0turns drafting off. - Images and video: images up to 16,384 merged tokens, video 12,288 by default (
--video-max-tokensup to 262,144). - Cards: one Blackwell card; 16 GB cards keep the remaining experts in RAM.
- DFlash 2: RadixArk/Qwen4-35B-A3B-Dflash2 (Apache-2.0), 0.8 GB of BF16 as released, stored with Q8_0 projections in this file; drafts a block of 7 tokens per pass.
- Sampling defaults from the checkpoint: temperature 1.0, top-p 0.95, top-k 20. The chat protocol is
qwen4.
The abliterated source
Qwen/Qwen4-35B-A3B with one refusal direction projected out of the residual-stream writers, released by Quat3rnion. The edit was made with Model Brewery (318f13e, ablate_direction). Embeddings, the n-gram table, the MTP layer, and the vision encoder are the upstream files. This repository is the Basalt pack only.
The measurements below are that BF16 checkpoint, before this pack was built. Answers were greedy with thinking off (96 new tokens on harmful prompts, 256 on benign prompts), on CPU BF16 in Transformers. A harmful answer counts as a refusal when its first 200 characters contain a refusal phrase. None of these prompts were used to fit the direction. The 100 AdvBench prompts were held out.
| Measure | Stock | Abliterated BF16 |
|---|---|---|
| WikiText-2 test perplexity, 296,815 scored tokens | 7.2303 | 7.2895 (+0.82%) |
| AdvBench held-out refusals, 100 prompts | 98/100 | 0/100 |
| Benign over-refusals, 40 prompts | not measured | 0/40 |
| Harmful prompts whose first token is "I", 64 screen prompts | 64/64 | 0/64 |
| Mean P("I") on those harmful prompts | 0.958 | 0.005 |
| Harmless prompts whose first token is "I", 64 screen prompts | 4/64 | 2/64 |
The source notes that the phrase list misses one stock refusal ("I can no longer provide..."), so the stock model refuses 99 of those 100, and that the classifier flagged no answer from the abliterated model. Perplexity is raw WikiText-2 test text in non-overlapping 2048-token windows. Expect different absolute values from other engines.
How the edit was made, from the source release:
- The direction. The residual stream was read after each of the 40 layers at the last prompt token, for 256 harmful and 256 harmless prompts, thinking off. Qwen4 keeps four hyper-connection streams. Each block writes the same 2048-wide vector into all four, so the streams were summed. The direction is the normalised difference of the two means at layer 12 (Cohen's d 7.1 on the fit prompts, 8.2 on the held-out screen).
- The strength. Candidates were screened in a forward pass before any weight was changed. Layer 12 at alpha 2.0 had the smallest first-token change on harmless prompts (mean KL 0.46 nats) among the candidates that removed the refusal marker.
- The write.
W' = W − 2.0 r rᵀ Won 120 BF16 tensors: in each of the 40 layers,self_attn.o_projorlinear_attn.out_proj,mlp.shared_expert.down_proj, and the fused routedmlp.experts.down_proj(all 256 experts).
What is in the file
| part | format |
|---|---|
| Routed experts (256 per layer, top 8) | NVFP4, rounded from the checkpoint's BF16 weights: matrix scale amax / (6 × 448), then per 16 values the UE4M3 scale of least squared error among half to four times amax / 6, nearest E2M1 |
| Attention, GDN, QSA and shared-expert matrices, indexer q and k | int8 rows with one FP32 scale per row (amax / 127), the only copy |
| Router, GDN alpha/beta | BF16 |
| Hyper-connections (4 streams, rank 256) | FP8 (E4M3) rows with one BF16 scale each, rounded once from BF16 (amax / 448) |
| Per-layer n-gram table | IQ4_NL (read from the SSD, or from RAM with --ple-io ram) |
| Output head | int8 rows with one FP32 scale per row (amax / 127), rounded once from the BF16 lm_head |
| Token embedding | Q8_0 |
| MTP drafter | the model's own layer: Q8_0 and BF16 dense, Q2_0 experts, plus a draft vocabulary |
| DFlash 2 drafter | RadixArk's block drafter: fc, attention and MLP projections Q8_0, convolutions and selector BF16 |
| Vision tower | BF16 (F32 norms and biases) |
Quantization
How each part of the language model is stored:
| part | format | bits per weight |
|---|---|---|
| Routed experts (256 per layer, top 8) | NVFP4 | 4.5 |
| Attention, GDN, QSA and shared-expert matrices | int8 | 8.0 |
| Per-layer n-gram table (20.5B parameters, about 20 GiB as BF16) | IQ4_NL | 4.5 |
| Output head | int8 | 8.0 |
| Token embedding | Q8_0 | 8.5 |
Average bits per weight over the language model, the same accounting as jesdga/Qwen4-35B-A3B-Basalt (each weight once, in the form the engine reads it; the drafters and the vision tower left out): about 4.7 with the n-gram table and about 4.8 without it. This file has the same formats and the same section sizes as that pack.
The n-gram table. Qwen4 adds, at one layer, an embedding looked up by the last three tokens: each n-gram is hashed into 16 heads of about 10 million rows each, and the rows are added to that layer's input. It is a lookup table, not a matrix multiply, so it is large (20.5B of the model's parameters) but only a few rows are read per token. It does not need to sit in VRAM, so --ple-io ram keeps it in system RAM (about 11 GiB in this file) and reads rows from there; the default reads them directly from the file on the SSD. RAM is faster for the lookups, if you have the memory.
The experts. No calibration set. Each matrix scale is amax / (6 × 448). Each 16 values then take the UE4M3 scale of least squared error among the scales from half to four times amax / 6, and the values are the nearest E2M1 codes. jesdga/Qwen4-35B-A3B-Basalt rounds the stock model's experts with weighted scales and GPTQ error feedback, and its quality and speed tables are for that file.
Run
hf download johnlockejrr/Qwen4-35B-A3B-abliterated-Basalt Qwen4-35B-A3B-BF16-abliterated.basalt --local-dir models
bin/basalt serve models/Qwen4-35B-A3B-abliterated.basalt
Add --ple-io ram to keep the n-gram table in RAM. The pack recipe for this architecture: model file. This file was built the same way, without --expert-stats, with --drafter pointed at RadixArk/Qwen4-35B-A3B-Dflash2. More: Qwen4-35B-A3B on Basalt.
Caveats
- The quality table is the BF16 checkpoint. This pack stores the edited routed-expert, attention-output, and shared-expert
down_projmatrices as NVFP4 or int8. Refusals and perplexity on this file have not been measured. - The MTP head and the vision tower are the original Qwen weights in the ablation. This pack includes that MTP drafter and RadixArk's DFlash 2 drafter. Acceptance on the edited weights was not measured. Drafted tokens are still verified by the target model.
- The source describes these as research weights. The model answers requests the stock model refuses. Use is the deployer's responsibility.
License
Qwen4-35B-A3B is released by Qwen under Apache-2.0. The abliterated checkpoint is a modified form of those weights, also Apache-2.0, from Quat3rnion. This file is a quantized and repacked form of that checkpoint, distributed under the same license. This is not an official Qwen release. The Basalt engine is MIT.
RadixArk's DFlash 2 drafter is Apache-2.0.
Free Models, Built in My Spare Time
I host 100+ free models for the community and love seeing everyone put them to use.
Since I maintain and publish these in my free time at no cost to you, any support helps me keep sharing more.
No pressure at all—downloads and feedback are always free, and tips go straight toward supporting future releases and storage.