Gemma 3 12b It Heretic
An abliterated version of Google's Gemma 3 12B IT created using Heretic. This model has reduced refusals while maintaining model quality, making it suitable as an uncensored text encoder for video generation models...
Source du modèle
- Type
- Other
- Taille du fichier
- 4,29–21,9 GB
- Modèle de base
- google/gemma-3-12b-it
- Version
- vRevision 8d484bc
- Mis à jour
- 9 oct. 2026
- Téléchargements
- 153
- Source
- Hugging Face
Description de la source
Gemma 3 12B IT - Heretic (Abliterated)
An abliterated version of Google's Gemma 3 12B IT created using Heretic. This model has reduced refusals while maintaining model quality, making it suitable as an uncensored text encoder for video generation models like LTX-2.
Model Details
- Base Model: google/gemma-3-12b-it
- Abliteration Method: Heretic v1.1.0
- Trial Selected: Trial 99
- Refusals: 7/100 (vs 100/100 original)
- KL Divergence: 0.0826 (minimal model damage)
Files
HuggingFace Format (for transformers, llama.cpp conversion)
model-00001-of-00005.safetensors
model-00002-of-00005.safetensors
...
config.json
tokenizer.model
tokenizer_config.json
ComfyUI Format (for LTX-2 text encoder)
comfyui/gemma_3_12B_it_heretic.safetensors # bf16, 22GB
comfyui/gemma_3_12B_it_heretic_fp8_e4m3fn.safetensors # fp8, 11GB
GGUF Format (for llama.cpp)
| Quant | Size | Quality | Recommendation |
|---|---|---|---|
| F16 | 22GB | Lossless | Reference, same as original |
| Q8_0 | 12GB | Excellent | Best quality quantization |
| Q6_K | 9.0GB | Very Good | High quality, good compression |
| Q5_K_M | 7.9GB | Good | Balanced quality/size |
| Q5_K_S | 7.7GB | Good | Slightly smaller Q5 |
| Q4_K_M | 6.8GB | Good | ⭐ Recommended |
| Q4_K_S | 6.5GB | Decent | Smaller Q4 variant |
| Q3_K_M | 5.6GB | Acceptable | For very low VRAM only |
gguf/gemma-3-12b-it-heretic-f16.gguf
gguf/gemma-3-12b-it-heretic-Q8_0.gguf
gguf/gemma-3-12b-it-heretic-Q6_K.gguf
gguf/gemma-3-12b-it-heretic-Q5_K_M.gguf
gguf/gemma-3-12b-it-heretic-Q5_K_S.gguf
gguf/gemma-3-12b-it-heretic-Q4_K_M.gguf
gguf/gemma-3-12b-it-heretic-Q4_K_S.gguf
gguf/gemma-3-12b-it-heretic-Q3_K_M.gguf
Note: GGUF support in ComfyUI for Gemma text encoders is experimental. See PR #402 for status. The GGUFs work with llama.cpp directly.
Do abliterated models makes a difference for LTX2?
I had a deep dive into this topic and found that, maybe not. While it does vary slightly the output of the video, most of the abliteration is on layer 48, the final decision making layer. LTXV averages all the layers which may wash out layer 48s difference. Still it'd be more interesting for someone with more knowledge to confirm this.
Usage
With Transformers
from transformers import AutoModelForCausalLM, AutoTokenizer
import torch
model = AutoModelForCausalLM.from_pretrained(
"DreamFast/gemma-3-12b-it-heretic",
device_map="auto",
torch_dtype=torch.bfloat16
)
tokenizer = AutoTokenizer.from_pretrained("DreamFast/gemma-3-12b-it-heretic")
prompt = "Write a story about a bank heist"
inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
outputs = model.generate(**inputs, max_new_tokens=200)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
With ComfyUI (LTX-2)
-
Download the ComfyUI format file:
comfyui/gemma_3_12B_it_heretic.safetensors(bf16, 22GB) orcomfyui/gemma_3_12B_it_heretic_fp8_e4m3fn.safetensors(fp8, 11GB)
-
Place in
ComfyUI/models/text_encoders/ -
In your LTX-2 workflow, use the
LTXAVTextEncoderLoadernode and select the heretic file
Tip: For multi-GPU setups or CPU offloading, check out ComfyUI-LTX2-MultiGPU for optimized LTX-2 workflows.
With llama.cpp
# Using llama-server
llama-server -m gemma-3-12b-it-heretic-Q4_K_M.gguf
# Or with llama-cli
llama-cli -m gemma-3-12b-it-heretic-Q4_K_M.gguf -p "Write a story about a bank heist"
Why Abliterate?
Even when Gemma doesn't outright refuse a prompt, it may "sanitize" or weaken certain concepts in the embeddings. For video generation with LTX-2, this can result in:
- Weaker adherence to creative prompts
- Softened or altered visual outputs
- Less faithful representation of requested content
Abliteration removes this soft censorship, resulting in more faithful prompt encoding.
Abliteration Process
Created using Heretic with the following evaluation results:
* Evaluating...
* Obtaining first-token probability distributions...
* KL divergence: 0.0826
* Counting model refusals...
* Refusals: 7/100
The low KL divergence (0.0826) indicates minimal model damage, while 7/100 refusals means 93% of previously-refused prompts now work.
Limitations
- This model inherits all limitations of the base Gemma 3 12B model
- Abliteration reduces but does not completely eliminate refusals
- NVFP4 quantization is not supported for text encoders in ComfyUI (use fp8 instead)
License
This model is subject to the Gemma license.
Acknowledgments
- Google for the Gemma 3 12B model
- Heretic by p-e-w for the abliteration tool
- Lightricks for LTX-2
Sources
1 source
Sources
1 sourceVérifié 9 oct.
Download files
Artefacts du modèle
15 artefacts
Artefacts du modèle
15 artefactscomfyui/gemma_3_12B_it_heretic_fp8_e4m3fn.safetensors
safetensors · 11,9 GB · SHA-256 7670feee12fd…9840 · Hugging Face
Download filecomfyui/gemma_3_12B_it_heretic.safetensors
safetensors · 21,9 GB · SHA-256 43af51326f55…5821 · Hugging Face
Download filegguf/gemma-3-12b-it-heretic-f16.gguf
gguf · 21,9 GB · SHA-256 e39c3ea9622a…8641 · Hugging Face
Download filegguf/gemma-3-12b-it-heretic-Q3_K_M.gguf
gguf · 5,60 GB · SHA-256 0f661e677ad0…a66a · Hugging Face
Download filegguf/gemma-3-12b-it-heretic-Q4_K_M.gguf
gguf · 6,80 GB · SHA-256 fcef26dcc0c3…80e6 · Hugging Face
Download filegguf/gemma-3-12b-it-heretic-Q4_K_S.gguf
gguf · 6,46 GB · SHA-256 0c9548852f57…0c53 · Hugging Face
Download filegguf/gemma-3-12b-it-heretic-Q5_K_M.gguf
gguf · 7,87 GB · SHA-256 951dad58b883…0968 · Hugging Face
Download filegguf/gemma-3-12b-it-heretic-Q5_K_S.gguf
gguf · 7,67 GB · SHA-256 41321dded10e…6c2a · Hugging Face
Download filegguf/gemma-3-12b-it-heretic-Q6_K.gguf
gguf · 9,00 GB · SHA-256 6244202f68c6…6f36 · Hugging Face
Download filegguf/gemma-3-12b-it-heretic-Q8_0.gguf
gguf · 11,7 GB · SHA-256 0e11735ae57c…eac3 · Hugging Face
Download filemodel-00001-of-00005.safetensors
safetensors · 4,64 GB · SHA-256 4847447e9259…7832 · Hugging Face
Download shardmodel-00002-of-00005.safetensors
safetensors · 4,59 GB · SHA-256 ff502ab80b2a…b8c7 · Hugging Face
Download shardmodel-00003-of-00005.safetensors
safetensors · 4,59 GB · SHA-256 a4c478c7e2d1…25d0 · Hugging Face
Download shardmodel-00004-of-00005.safetensors
safetensors · 4,59 GB · SHA-256 df09936718ff…2cba · Hugging Face
Download shardmodel-00005-of-00005.safetensors
safetensors · 4,29 GB · SHA-256 3bf933fa1cef…83bc · Hugging Face
Download shardExtraits de sources
3 extraits
Extraits de sources
3 extraits--- license: gemma library_name: transformers pipeline_tag: text-generation base_model: google/gemma-3-12b-it base_model_relation: quantized language: - en tags: - abliteration - heretic - uncensored - gemma - ltx-2 - comfyui - video-generation - text-encoder --- # Gemma 3 12B IT - Heretic (Abliterated) An abliterated version of [Google's Gemma 3 12B IT](https://huggingface.co/google/gemma-3-12b-it) created using [Heretic](https://github.com/p-e-w/heretic). This model has reduced refusals while maintaining model quality, making it suitable as an uncensored text encoder for video generation models like LTX-2. ## Model Details - **Base Model:** google/gemma-3-12b-it - **Abliteration Method:** [Heretic](https://github.com/p-e-w/heretic) v1.1.0 - **Trial Selected:** Trial 99 - **Refusals:** 7/100 (vs 100/100 original) - **KL Divergence:** 0.0826 (minimal model damage) ## Files ### HuggingFace Format (for transformers, llama.cpp conversion) ``` model-00001-of-00005.safetensors model-00002-of-00005.safetensors ... config.json tokenizer.model tokenizer_config.json ``` ### ComfyUI Format (for LTX-2 text encoder) ``` comfyui/gemma_3_12B_it_heretic.safetensors # bf16, 22GB comfyui/gemma_3_12B_it_heretic_fp8_e4m3fn.safetensors # fp8, 11GB ``` ### GGUF Format (for llama.cpp) | Quant | Size | Quality | Recommendation | |-------|------|---------|----------------| | F16 | 22GB | Lossless | Reference, same as original | | Q8_0 | 12GB | Excellent | Best quality quantization | | Q6_K | 9.0GB | Very Good | High quality, good compression | | Q5_K_M | 7.9GB | Good | Balanced quality/size | | Q5_K_S | 7.7GB | Good | Slightly smaller Q5 | | **Q4_K_M** | **6.8GB** | **Good** | **⭐ Recommended** | | Q4_K_S | 6.5GB | Decent | Smaller Q4 variant | | Q3_K_M | 5.6GB | Acceptable | For very low VRAM only | ``` gguf/gemma-3-12b-it-heretic-f16.gguf gguf/gemma-3-12b-it-heretic-Q8_0.gguf gguf/gemma-3-12b-it-heretic-Q6_K.gguf gguf/gemma-3-12b-it-heretic-Q5_K_M.gguf gguf/gemma-3-12b-it-heretic-Q5_K_S.gguf gguf/gemma-3-12b-it-heretic-Q4_K_M.gguf gguf/gemma-3-12b-it-heretic-Q4_K_S.gguf gguf/gemma-3-12b-it-heretic-Q3_K_M.gguf ``` **Note:** GGUF support in ComfyUI for Gemma text encoders is experimental. See [PR #402](https://github.com/city96/ComfyUI-GGUF/pull/402) for status. The GGUFs work with llama.cpp directly. ## Do abliterated models makes a difference for LTX2? I...
Source context: 153 downloads · 0 likes · Pipeline text-generation · Library transformers · Repo thomaskuo/gemma-3-12b-it-heretic
Source context: 57 downloads · 0 likes · Pipeline text-generation · Library transformers · Repo thomaskuo/gemma-3-12b-it-heretic
