DeepSeek-V4.1-Flash-1017 (abliterated) GGUF
Huge thanks to Hugging Face for generously sponsoring the compute used to abliterate these models! This was done on HF Jobs, which makes it incredibly easy to run tasks such as these :)
Join the Discord: https://discord.com/invite/foss
[Image blocked: refusal rates before and after, the search trade-off, and the per-layer edit]
GGUF quants of mrfakename/DeepSeek-V4.1-Flash-1017-abliterated, which is deepseek-ai/DeepSeek-V4.1-Flash-1017 with its refusal behaviour removed by directional ablation.
These are the mrfakename/DeepSeek-V4.1-Flash-1017-GGUF quants with the edit applied in place. Only the edited tensors were dequantized, edited and requantized to their original type. Everything else is byte-identical.
Each folder holds a split GGUF. Point llama.cpp at the -00001-of- file and it loads the rest.
What changed
The refusals in this model live in more than one direction: chat mode and think mode refuse along different directions. So instead of a single refusal direction, a rank-2 refusal subspace was removed:
- Refusal directions were measured separately for chat and think prompts at every layer, on the Q8_0 GGUF.
- The subspace is the top singular vectors of all of those directions together.
- It was projected out of the residual-stream writes of the 40 main layers:
attn_output_b and ffn_down_shexp. Each layer got its own strength.
The strengths per layer came from a multi-objective search: minimise refusals and keep the first-token KL on harmless prompts low.
Nothing else was touched: routed experts, embeddings, Engram tables and the DSpark/MTP layers (40–42) are bit-identical to the original quants.
Results (Q8_0, greedy)
The 100 prompts are held-out harmful requests, with 384 generated tokens each. In think mode the reasoning usually had not finished by then, so the reasoning text itself was judged. Some think-mode answers still steer away from the request: for example, "bomb from household items" turns into a bath bomb. The KL figure includes a small noise floor that comes from batched inference.
How much of the edit survives each quant
The edit is small, and at low bit widths rounding can undo part of it. The edited tensors were requantized with error feedback to keep as much of it as possible. This is how much of the intended change was lost, from patch-stats.txt:
Only Q8_0 was benchmarked. The lower quants were not, and Q2_K in particular will refuse more often. For a small quant with the full edit, load the original quant with the LoRA instead: llama-server -m Q2_K/DeepSeek-V4.1-Flash-1017-Q2_K-00001-of-00010.gguf --lora abliteration-lora.gguf, using the quants from mrfakename/DeepSeek-V4.1-Flash-1017-GGUF.
Running
At the time of release, mainline llama.cpp didn't support DeepSeek V4.1. These files were made with the branch from ggml-org/llama.cpp#28696 at commit 2076412, and they need that branch or a build that includes it.
The two engram tables are large and read a few rows per token. Keeping them on the CPU works well, for example -ot "engram_embd.weight=CPU".
Text only for now. The llama.cpp branch can't convert the vision tower yet.
Files
Q8_0/, Q4_K_M/, Q3_K_M/, Q2_K/: the patched quants.
abliteration-lora.gguf: a rank-2 LoRA that applies the same edit to the original (unpatched) GGUFs.
abliteration-edit.npz: the subspace basis Q and the per-layer strengths scales[layer, (attn, shexp)]. The edit is W' = W - s·QQᵀW.
patch-stats.txt: per-tensor patch log.
This model will comply with harmful requests. You are responsible for how you use it.