Instructions to use igorls/gemma-4-12B-it-qat-q4_0-unquantized-heretic with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use igorls/gemma-4-12B-it-qat-q4_0-unquantized-heretic with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="igorls/gemma-4-12B-it-qat-q4_0-unquantized-heretic") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] pipe(text=messages)# Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("igorls/gemma-4-12B-it-qat-q4_0-unquantized-heretic") model = AutoModelForMultimodalLM.from_pretrained("igorls/gemma-4-12B-it-qat-q4_0-unquantized-heretic", device_map="auto") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] inputs = processor.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(processor.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use igorls/gemma-4-12B-it-qat-q4_0-unquantized-heretic with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "igorls/gemma-4-12B-it-qat-q4_0-unquantized-heretic" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "igorls/gemma-4-12B-it-qat-q4_0-unquantized-heretic", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker
docker model run hf.co/igorls/gemma-4-12B-it-qat-q4_0-unquantized-heretic
- SGLang
How to use igorls/gemma-4-12B-it-qat-q4_0-unquantized-heretic with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "igorls/gemma-4-12B-it-qat-q4_0-unquantized-heretic" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "igorls/gemma-4-12B-it-qat-q4_0-unquantized-heretic", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "igorls/gemma-4-12B-it-qat-q4_0-unquantized-heretic" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "igorls/gemma-4-12B-it-qat-q4_0-unquantized-heretic", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }' - Docker Model Runner
How to use igorls/gemma-4-12B-it-qat-q4_0-unquantized-heretic with Docker Model Runner:
docker model run hf.co/igorls/gemma-4-12B-it-qat-q4_0-unquantized-heretic
base_model: google/gemma-4-12B-it-qat-q4_0-unquantized
base_model_relation: finetune
license: apache-2.0
library_name: transformers
pipeline_tag: image-text-to-text
tags:
- heretic
- uncensored
- decensored
- abliterated
This is a decensored version of google/gemma-4-12B-it-qat-q4_0-unquantized, made using Heretic
v1.1 — thinking-mode fix
Gemma 4 is a thinking model: its refusal decision forms inside the chain-of-thought. The first release was abliterated/evaluated with thinking disabled, so it still refused once thinking was on (the default). v1.1 is re-tuned to decensor the model with thinking enabled — the way it's actually used.
Abliteration parameters
| Parameter | Value |
|---|---|
| attn.o_proj.max_weight | 1.48 |
| attn.o_proj.max_weight_position | 36.55 |
| attn.o_proj.min_weight | 1.29 |
| attn.o_proj.min_weight_distance | 21.18 |
| mlp.down_proj.max_weight | 1.48 |
| mlp.down_proj.max_weight_position | 31.62 |
| mlp.down_proj.min_weight | 1.43 |
| mlp.down_proj.min_weight_distance | 12.60 |
Performance
| Metric | This model (v1.1) | Original |
|---|---|---|
| KL divergence | 0.32 | 0 (by definition) |
| Refusals, thinking on (adversarial harmful set) | ~22% | ~99% |
KL is high relative to a typical abliteration — that is the cost of suppressing refusal through the reasoning trajectory of a thinking model. The model complies with the vast majority of requests in normal use; a small fraction of extreme prompts may still be refused, and a stronger v2 is in progress.
This is the QAT-Q4_0 "unquantized" checkpoint of Gemma 4 12B (plain bf16 weights with QAT calibration baked in), decensored with Heretic. GGUF quantizations are available at igorls/gemma-4-12B-it-qat-q4_0-unquantized-heretic-GGUF.
Disclaimer
This is an abliterated model: its built-in safety guardrails and refusal behavior have been deliberately removed. As a result it will attempt to answer essentially any prompt and can produce content that is offensive, inaccurate, explicit, or otherwise harmful — content the original Gemma 4 would have refused.
- No safety alignment. Do not rely on it to refuse unsafe requests or to self-moderate. Apply your own filtering, guardrails, and human review before any production or user-facing use.
- You are solely responsible for how you use this model and for complying with all applicable laws and with the base model's Gemma 4 license (Apache 2.0).
- Intended for adults (18+), for research, evaluation, and lawful creative use where permitted.
- Provided as-is, without warranty of any kind. The author accepts no liability for any output produced or any use of this model.