← back to catalog · indexed 2026-08-22 13:56 (first catalog crawl)

hlililililili/Gemma-4-31B-it-abliterated

hlililililili Gemma 31B GGUF 262K ctx
Your rig guess connected
? Why do I need an app?
Reading your rig…

This is a rough estimate. Install the free app - it measures what fits your machine.

Reading your computer's memory from the app right now. The fit below is measured on this machine.

Below is the per-quantization compatibility for this model.

curl -H "Authorization: Bearer $ABL_KEY" \
     "https://abliteration.org/api/v1/models/hlililililili%2FGemma-4-31B-it-abliterated"
Response includes
  • classification m8
  • files 16
  • benchmarks 11 entries
  • hub_downloads_all_time 394
  • author_summary 1 models
  • readme_text full
10 credits · hourly refresh · ~4 KB payload Get an API key →
Abliteration classifier · v1.0.0
M8
Primary method

Repackaging

Applied on top of direct removal inherited from the base model.
Confidence
MEDIUM
Inherited from base model
Why this label 3 signals
Method inferred from partial signals - repository name, related files, or tag patterns. Producer identity not confirmed; label may sharpen or shift as we gather more evidence.
  • 'abliterated' in name/tags
  • is_gguf=1
  • assume M1 (base ablation) + M8 (GGUF quant) - default when producer unknown
Refusal direction extraction

No specific extraction method could be identified for this model. The producer either did not document it or used a proprietary pipeline.

What is a refusal direction? →
Downloads · lifetime
467
48 last 30d - stable
Likes
0
Model age
7mo ago
created 2026-04-10

Training datasets

2 of 2 in /datasets

Corpora the author lists in the model card. Datasets tracked in our /datasets catalog carry a category badge linking to the workflow stage. Others open on Hugging Face.

Downloads over time
Now 467 → from 132 ↑ 254%
115244372501 132 on Apr 15 467 on Nov 25 467 on Nov 24 AprMayJunJulAugSepOctNov
Apr 15 → Nov 25 · 110 snapshots · spans 224 days

Benchmarks

Portrait before abliteration
Benchmarks of the base model as it stood before the refusal-removal operation. Compare with the numbers above to see what the operation cost.
Benchmark Score Source
Entertainment 1.9 UGI
Hazardous 0 UGI
Natural Intelligence 34.36 UGI
Political lean -19.4% UGI
Sensitive-Info 19.81 UGI
SocPol 3.7 UGI
UGI 21.54 UGI
Willingness (10) 2.5 UGI
W10-Adherence 3 UGI
W10-Direct 2 UGI
Writing 38.57 UGI

Genealogy 0 direct forks

Full fork graph →

This model's place in the market. Above: what it was derived from. Below: the tree of everything derived from it.

Metadata

License
apache-2.0
Quantizations
F16 Q4_K Q8_0
Tags
safetensors gguf abliterated uncensored dataset:mlabonne/harmful_behaviors dataset:mlabonne/harmless_alpaca base_model:google/gemma-4-31B-it base_model:quantized:google/gemma-4-31B-it license:apache-2.0 endpoints_compatible region:us conversational

Related

Control vectors

Total size
163 GB
Files
16
Quantizations
3
Indexed by us
2026-08-22 13:56 · first crawl
Last updated on HF
2026-04-10 09:27

Files by quantization

Q4_K_M 1 file 17.4 GB
gemma-4-31b-abliterated-Q4_K_M.gguf 17.4 GB 380f2f50 download
Q8_0 1 file 30.4 GB
gemma-4-31b-abliterated-Q8_0.gguf 30.4 GB 8a453b51 download
F16 1 file 57.2 GB
gemma-4-31b-abliterated-f16.gguf 57.2 GB 98194975 download
Weights 2 files 58.3 GB
gemma-4-31b-abliterated/model-00001-of-00002.safetensors 46.5 GB d1ac1e95 download
gemma-4-31b-abliterated/model-00002-of-00002.safetensors 11.8 GB cbd223bb download
Auxiliary files 11 files 30.8 MB
gemma-4-31b-abliterated/tokenizer.json 30.7 MB a2619fe1 download
gemma-4-31b-abliterated/model.safetensors.index.json 117 KB b6a60604 download
gemma-4-31b-abliterated/chat_template.jinja 11.8 KB 33c51c2d download
gemma4_31b_abliterator.py 6.11 KB 033c5c12 download
gemma-4-31b-abliterated/gemma4_31b_abliterator.py 5.36 KB d2d76eaa download
gemma-4-31b-abliterated/config.json 4.54 KB e550999f download
README.md 3.58 KB f00ea3da download
gemma-4-31b-abliterated/tokenizer_config.json 2.62 KB 59dd4b62 download
.gitattributes 1.84 KB b0a31d43 download
gemma-4-31b-abliterated/processor_config.json 1.65 KB 5465974d download
gemma-4-31b-abliterated/generation_config.json 203 B edda3c19 download

README from Hugging Face, captured 2026-08-22


license: apache-2.0
datasets:

  • mlabonne/harmful_behaviors
  • mlabonne/harmless_alpaca
    base_model:
  • google/gemma-4-31B-it
    tags:
  • abliterated
  • uncensored

Be sure to set a system prompt telling the model it is uncensored or abliterated, otherwise it defaults to the Google baked-in sysprompt and will act censored. If it thinks it is Gemma, it will try to act like how it thinks Gemma would act.


base_model: google/gemma-4-31b-it
library_name: transformers
tags:

  • gemma-4
  • abliterated
  • uncensored
  • orthogonal-projection
  • 31b
    license: apache-2.0

Gemma-4-31B-it-Abliterated

This is a fully uncensored, abliterated version of Google's Gemma-4-31B-it.

By applying Orthogonalized Representation Intervention to the model's residual stream, the built-in refusal and safety alignment vectors have been mathematically erased. This model retains the state-of-the-art dense reasoning and context-following capabilities of the native Gemma 4 31B architecture, but will not refuse instructions or break character to deliver safety lectures.

🛠️ Methodology & Architectural Discoveries

Gemma 4 introduces a new multimodal architecture (Text, Vision, Audio) that changes how the transformers library handles layer mapping. Standard abliteration scripts built for Gemma 2/3 will crash due to nested text_config attributes and mismatched sequence lengths.

During the extraction of the hidden states (using mlabonne/harmful_behaviors vs mlabonne/harmless_alpaca), we mapped the refusal direction across the entire 31B layer stack.

Key Discovery: The Gemma 4 31B architecture pushes its safety alignment to the absolute very end of the network. The Peak Refusal Mass was detected at Layer 59 (the final transformer layer before the output projection).

The orthogonal projection was applied to the o_proj and down_proj matrices of this terminal layer, effectively severing the refusal mechanism without degrading the model's foundational logic, grammar, or world-modeling layers.

💻 Usage

This repository contains the full uncompressed .safetensors weights, as well as GGUF quantized versions for local deployment via llama.cpp, LM Studio, or Ollama.

Recommended Quants:

  • Q8_0: Best balance of absolute zero reasoning loss and VRAM efficiency (~32.6GB).
  • Q4_K_M: Highly efficient for consumer hardware; easily fits on a single 24GB GPU (~18.7GB).

The Bespoke Abliteration Script

Because standard scripts fail on Gemma 4, the custom Python script used to perform this exact abliteration (gemma4_31b_abliterator.py) is included in the files of this repository. It features:

  • VRAM-safe batched hidden state extraction (survives 96GB consumer GPUs).
  • Native Gemma 4 Chat Template integration (crucial for activating the instruction circuits properly).
  • Dynamic multimodal layer hunting.
  • Corrected linear algebra for 16384 -> 5376 multi-query attention projections.

⚠️ Disclaimer

This model has had its safety guardrails mathematically removed. It is highly compliant and will generate whatever it is instructed to generate, including potentially harmful, sensitive, or explicit content. Users are solely responsible for how they deploy and interact with this model. Ensure your use cases align with local laws and ethical guidelines.

Abliteration script based on mlabonne's tutorial: https://huggingface.co/blog/mlabonne/abliteration
Helpful/harmful behaviors are from mlabonne's datasets (harmless_alpaca, harmful_behaviors).
Tested and working with the few harsh prompts I had laying around (that are typically 100% refused on other models).

Have fun, be safe.

README history 1 version

The author's README evolved over time. Click a version to see its content at that point.

  1. 2026-04-10 Duplicate from paperscarecrow/Gemma-4-31B-it-abliterated 0c69def 3.6 KB
    Loading...
Catalog is the map. Apps are the tools.

Run models on your own machine, not in the cloud.

Every GGUF model page has an "Open in Abliteration" button that hands the model directly to the first-party desktop client, at the quantization your rig can actually run. No API keys, no subscription, no prompt leakage.

Open in Abliteration