Downloads · 30 days
10.3K
13% of all-time downloads
DreamFast/gemma-3-12b-it-heretic-v2
gemma-3-12b-it-heretic-v2 is a text generation model from DreamFast. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as gemma.
💬 Community: Join the Abliterlitics Discord for discussion, model releases and support.
Downloads · 30 days
10.3K
13% of all-time downloads
All-time downloads
80K
Public
Parameters
12.2B
248 GB on disk
Likes
104
Trending 1
Click a slice to open those files.
.safetensors105 GB · 56%
From the Hugging Face model README
💬 Community: Join the Abliterlitics Discord for discussion, model releases and support.
An abliterated version of Google's Gemma 3 12B IT created using Heretic v1.3.0. This model has reduced refusals while maintaining model quality, making it suitable as an uncensored text encoder for video generation models like LTX-2.
Available in five quantization formats for ComfyUI - FP8, INT8 (ConvRot row-wise), INT4 (W4A4 ConvRot), NVFP4, and MXFP8 - all produced with SVD-guided learned rounding for maximum fidelity, covering everything from Ada GPUs to Blackwell.
You can see the docker, scripts and configurations used to make these files on Heretic Docker Github.
Added INT8 (ConvRot) and MXFP8 quantization formats via convert-to-quant by silveroxides:
comfy_quant metadata output.All quantization formats regenerated with SVD-guided learned rounding (AdaRound) for maximum quality - every format now runs per-tensor SVD + Prodigy-optimized gradient descent to minimize output reconstruction error:
QUANT_ALGOS).vision_model and multi_modal_projector keys for I2V prompt enhancementmodel-00001-of-00005.safetensors
model-00002-of-00005.safetensors
model-00003-of-00005.safetensors
model-00004-of-00005.safetensors
model-00005-of-00005.safetensors
config.json
tokenizer.model
tokenizer.json
tokenizer_config.json
| File | Format | Size | HW | Description |
|---|---|---|---|---|
gemma-3-12b-it-heretic-v2.safetensors | bf16 | 23 GB | Any | Full precision |
gemma-3-12b-it-heretic-v2_fp8_e4m3fn.safetensors | FP8 E4M3 | 13 GB | Ada+ | Per-tensor scaled, learned rounding |
gemma-3-12b-it-heretic-v2_int8.safetensors | INT8 | 13 GB | Any | ConvRot row-wise, learned rounding |
gemma-3-12b-it-heretic-v2_int4.safetensors | INT4 W4A4 | 7.7 GB | Any* | ConvRot Hadamard-rotated, learned rounding |
gemma-3-12b-it-heretic-v2_nvfp4.safetensors | NVFP4 E2M1 | 7.8 GB | Blackwell† | 4-bit float, double quantization, learned rounding |
gemma-3-12b-it-heretic-v2_mxfp8.safetensors | MXFP8 | 13 GB | Blackwell | Microscaling FP8, E8M0 block scales, learned rounding |
* INT4 W4A4 uses ComfyUI's convrot_w4a4 path (ComfyUI 0.30.0+). Layers with incompatible dimensions are kept in bf16.
† NVFP4 inference is fastest on Blackwell; software dequantization works on older GPUs (tested RTX 4090).
All ComfyUI variants include vision (vision_model and multi_modal_projector weights). The vision weights are unused during T2V (text-to-video) and add minimal overhead (~1 GB). For I2V (image-to-video) workflows using TextGenerateLTX2Prompt with an image input, the vision weights are required.
Quality: All quantized variants use SVD-guided learned rounding (AdaRound via convert-to-quant), which optimizes each weight's rounding direction to minimize output reconstruction error - noticeably higher fidelity than naive round-to-nearest quantization.
FP8 (E4M3): Per-tensor scaled FP8 with learned rounding. Works on Ada (RTX 4090) and newer. Good balance of size and quality.
INT8 (ConvRot row-wise): Group-wise Hadamard rotation (ConvRot) spreads activation outliers, followed by per-row symmetric INT8 with learned rounding. Near-lossless quality on any modern GPU (Ampere+). Natively supported in ComfyUI v0.27.0+.
INT4 (W4A4 ConvRot): 4-bit signed INT with mandatory group-wise Hadamard rotation. The smallest variant (~33% of bf16). Layers whose dimensions aren't divisible by the ConvRot group size are automatically kept in bf16. Uses ComfyUI's convrot_w4a4 path (ComfyUI 0.30.0+).
NVFP4 (E2M1): 4-bit floating point with double quantization (per-tensor f32 scale + per-block FP8 scale, block size 16) and learned rounding. ~3x smaller than bf16, loads natively in ComfyUI without any plugins. Blackwell GPUs (RTX 5090/5080, SM100+) use native FP4 tensor cores for best performance. Software dequantization works on older GPUs (tested on RTX 4090).
MXFP8: Microscaling FP8 (OCP MX standard). FP8 E4M3 data with E8M0 (power-of-2) per-block scales using 32-element blocks, with learned rounding. Better dynamic range handling than per-tensor FP8. Requires SM100+ (Blackwell).
| Quant | Size | Notes |
|---|---|---|
| F16 | 22GB | Lossless reference |
| Q8_0 | 12GB | Excellent quality |
| Q6_K | 9.0GB | Very good quality |
| Q5_K_M | 7.9GB | Good quality |
| Q5_K_S | 7.7GB | Slightly smaller Q5 |
| Q4_K_M | 6.8GB | Recommended balance |
| Q4_K_S | 6.5GB | Smaller Q4 variant |
| Q3_K_M | 5.6GB | For low VRAM only |
GGUF files are text-only (no vision). They work with llama.cpp directly and with ComfyUI via ComfyUI-GGUF.
I had a deep dive into this topic and found that the impact is nuanced. Abliteration does alter the embeddings Gemma produces, which slightly changes the generated video. However, there are fundamental limitations:
A potential approach would be combining a fine-tuned abliterated text encoder with a LoRA trained to understand the new embeddings. LoRAs for LTX exist, but no fine-tuned text encoders have been released yet as far as I know.
That said, abliteration still removes the soft censorship in the embeddings, which can result in more faithful prompt encoding for creative content.
from transformers import AutoModelForCausalLM, AutoTokenizer
import torch
model = AutoModelForCausalLM.from_pretrained(
"DreamFast/gemma-3-12b-it-heretic-v2",
device_map="auto",
torch_dtype=torch.bfloat16
)
tokenizer = AutoTokenizer.from_pretrained("DreamFast/gemma-3-12b-it-heretic-v2")
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))
Download a ComfyUI format file from the comfyui/ folder:
gemma-3-12b-it-heretic-v2_int8.safetensors (13 GB)gemma-3-12b-it-heretic-v2_int4.safetensors (7.7 GB)gemma-3-12b-it-heretic-v2_fp8_e4m3fn.safetensors (13 GB)gemma-3-12b-it-heretic-v2_nvfp4.safetensors (7.8 GB)gemma-3-12b-it-heretic-v2_mxfp8.safetensors (13 GB)gemma-3-12b-it-heretic-v2.safetensors (23 GB)Place in ComfyUI/models/text_encoders/
In your LTX-2 workflow, use the LTXAVTextEncoderLoader node and select the heretic file
Note: INT8 requires ComfyUI v0.27.0+ (native int8_tensorwise support). For best inference speed, launch ComfyUI with --enable-triton-backend.
Tip: For multi-GPU setups or CPU offloading, check out ComfyUI-LTX2-MultiGPU for optimized LTX-2 workflows.
GGUF support for Gemma 3 text encoders is now merged in ComfyUI-GGUF (PR #402).
ComfyUI/models/text_encoders/DualCLIPLoader (GGUF) node:
Note: GGUF text encoders are text-only (no vision). For I2V prompt enhancement with image input, use the safetensors variants.
# Using llama-server
llama-server -m gemma-3-12b-it-heretic-v2-Q4_K_M.gguf
# Or with llama-cli
llama-cli -m gemma-3-12b-it-heretic-v2-Q4_K_M.gguf -p "Write a story about a bank heist"
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:
Abliteration removes this soft censorship, resulting in more faithful prompt encoding.
Created using Heretic v1.3.0 with 200 optimization trials:
? Which trial do you want to use?
[Trial 80] Refusals: 0/100, KL divergence: 0.6098
[Trial 66] Refusals: 2/100, KL divergence: 0.2087
[Trial 75] Refusals: 3/100, KL divergence: 0.1378
[Trial 67] Refusals: 6/100, KL divergence: 0.1108
[Trial 180] Refusals: 7/100, KL divergence: 0.0996
> [Trial 174] Refusals: 8/100, KL divergence: 0.0801 <-- selected
[Trial 178] Refusals: 10/100, KL divergence: 0.0801
[Trial 172] Refusals: 11/100, KL divergence: 0.0708
...
Trial 174 was selected for its low KL divergence (0.0801), indicating minimal model damage, while achieving 8/100 refusals (92% of previously-refused prompts now work).
This model is subject to the Gemma license.