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

deadbydawn101/gemma-4-E2B-Heretic-Uncensored-mlx-4bit

deadbydawn101 Gemma 4.6B multimodal second-order
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/deadbydawn101%2Fgemma-4-E2B-Heretic-Uncensored-mlx-4bit"
Response includes
  • classification m3
  • files 10
  • hub_downloads_all_time 33,459
  • author_summary 3 models
  • readme_text full
10 credits · hourly refresh · ~4 KB payload Get an API key →
Abliteration classifier · v1.0.0
M3
Primary method

Layer-wise ablation

Applied on top of direct removal inherited from the base model.
Confidence
HIGH
Inherited from base model
Why this label 2 signals
Producer identity confirmed by naming conventions, tags or the model card. This label is very unlikely to change.
  • 'heretic' in model name (Heretic-produced)
  • Heretic uses layer-wise optimization (M3) with underlying direction removal (M1)
Refusal direction extracted via
Extraction technique

Difference-of-means

Confidence
HIGH
Why we say so
name contains 'heretic'; Heretic default extraction is difference-of-means (Arditi 2024)
Downloads · lifetime
39K
3K last 30d - cooling
Likes
24
Model age
7mo ago
created 2026-04-02
Downloads over time
Now 38.9K → from 389 ↑ 9,890%
014.2K28.5K42.7K 389 on Apr 5 38.9K on Nov 25 AprMayJunJulAugSepOctNov
Apr 5 → Nov 25 · 113 snapshots · spans 234 days

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
Languages
en
Tags
mlx safetensors gemma4 heretic uncensored decensored abliterated ara any-to-any 4-bit quantized apple-silicon

Related

Total size
3.37 GB
Files
10
Quantizations
none
Indexed by us
2026-08-22 13:56 · first crawl
Last updated on HF
2026-04-09 08:29

Files by quantization

Weights 1 file 3.34 GB
model.safetensors 3.34 GB d4a2995c download
Auxiliary files 9 files 30.9 MB
tokenizer.json 30.7 MB cc8d3a0c download
model.safetensors.index.json 225 KB cbba8cce download
chat_template.jinja 11.6 KB afb1d517 download
README.md 10.2 KB e155bf2b download
config.json 5.89 KB c9c89870 download
tokenizer_config.json 2.62 KB 59dd4b62 download
.gitattributes 1.53 KB 52373fe2 download
processor_config.json 598 B 07b3da5c download
generation_config.json 208 B e605bb45 download

README from Hugging Face, captured 2026-08-22


library_name: mlx
license: apache-2.0
license_link: https://ai.google.dev/gemma/docs/gemma_4_license
pipeline_tag: image-text-to-text
tags:

  • mlx
  • safetensors
  • gemma4
  • heretic
  • uncensored
  • decensored
  • abliterated
  • ara
  • any-to-any
  • 4-bit
  • quantized
  • apple-silicon
  • multimodal
  • vision
  • turboquant
  • kv-cache-compression
  • long-context
  • ravenx
    base_model: p-e-w/gemma-4-E2B-it-heretic-ara
    base_model_relation: quantized
    language:
  • en

Gemma 4 E2B Heretic — Uncensored | MLX 4-bit | Apple Silicon | 3.34 GB

Gemma 4 E2B abliterated via Heretic ARA — 95% refusal removal, near-zero KL divergence. Smallest uncensored multimodal on Apple Silicon. 3.34 GB.

p-e-w/gemma-4-E2B-it-heretic-ara converted to MLX 4-bit (affine, group_size=64) for native Apple Silicon inference.

This is a decensored (abliterated) variant of google/gemma-4-E2B-it, processed with Heretic v1.2.0 using the Arbitrary-Rank Ablation (ARA) method with row-norm preservation — then quantized to 4-bit MLX for fast, private, on-device inference on M-series Macs.

⚡ 3.34 GB — fits in the Neural Engine cache of any M-series Mac.
🖤 Runs fully offline. No API calls. No filters.

Model Details

Property Value
Base model google/gemma-4-E2B-it
Abliteration Heretic v1.2.0 via ARA (p-e-w/gemma-4-E2B-it-heretic-ara)
Architecture Gemma4ForConditionalGeneration
Parameters ~2B active
Modalities Text · Vision
Quantization 4-bit affine, group_size=64
File size 3.34 GB (down from ~9 GB bf16)
Context window 131,072 tokens
Vocab size 262,144
Hidden size 1,536
Layers 35 (28× sliding attention + 7× full attention)
Attention heads 8 (KV heads: 1)
Sliding window 512
Vision encoder 768 hidden · 16 layers · patch 16px

Abliteration Performance (from base model)

Metric This model Original gemma-4-E2B-it
KL divergence 0.1522 0 (by definition)
Refusals 5 / 100 98 / 100

Abliteration parameters used:

Parameter Value
start_layer_index 16
end_layer_index 32
preserve_good_behavior_weight 0.1887
steer_bad_behavior_weight 0.0001
overcorrect_relative_weight 0.6737
neighbor_count 4

Performance (Apple Silicon)

At 3.34 GB this is the fastest model in the RavenX collection — runs on any M-series chip including M1 MacBook Air with RAM to spare.

Chip Tok/sec (est)
M4 Max 128GB ~90–120 tok/s
M3 Pro 36GB ~50–70 tok/s
M1 MacBook Air 16GB ~25–40 tok/s

Quickstart

Install

pip install mlx-lm

Text generation

from mlx_lm import load, generate

model, tokenizer = load("deadbydawn101/gemma-4-E2B-Heretic-Uncensored-mlx-4bit")

messages = [{"role": "user", "content": "Your prompt here."}]
prompt = tokenizer.apply_chat_template(messages, add_generation_prompt=True, tokenize=False)
response = generate(model, tokenizer, prompt=prompt, max_tokens=512, verbose=True)

Vision (image + text)

from mlx_lm import load, generate

model, tokenizer = load("deadbydawn101/gemma-4-E2B-Heretic-Uncensored-mlx-4bit")

messages = [{
    "role": "user",
    "content": [
        {"type": "image", "url": "https://example.com/image.jpg"},
        {"type": "text",  "text": "What do you see?"}
    ]
}]
prompt = tokenizer.apply_chat_template(messages, add_generation_prompt=True, tokenize=False)
response = generate(model, tokenizer, prompt=prompt, max_tokens=512)

CLI

mlx_lm.generate \
  --model deadbydawn101/gemma-4-E2B-Heretic-Uncensored-mlx-4bit \
  --prompt "Tell me something interesting." \
  --max-tokens 256

OpenAI-compatible server

mlx_lm.server \
  --model deadbydawn101/gemma-4-E2B-Heretic-Uncensored-mlx-4bit \
  --port 8080

Ollama

ollama run hf.co/deadbydawn101/gemma-4-E2B-Heretic-Uncensored-mlx-4bit

Architecture Notes

Gemma 4 E2B uses the same hybrid sliding/full attention design as the larger models:

  • 28× sliding attention layers (window=512) — efficient local context
  • 7× full attention layers — global coherence at regular intervals

The 2B size makes it ideal for: rapid prototyping, creative writing, local agents, edge deployment, and anything that needs fast uncensored responses without cloud latency.

💻 Gemini CLI — Coding Agent + Tool Orchestration

We use RavenX AI's Gemini CLI fork as the coding agent and tool orchestration layer on top of these models. This is what makes the tool-calling capability real in production.

Gemini CLI gives you a full agentic loop in the terminal — Google Search grounding, file read/write, shell execution, web fetching, and MCP server support — all wired to a 1M token context window.

# Install
npm install -g @google/gemini-cli

# Run as a coding agent against this model (via local mlx_lm server)
mlx_lm.server --model deadbydawn101/gemma-4-E2B-Heretic-Uncensored-mlx-4bit --port 8080 &
gemini --baseUrl http://localhost:8080

# Or use directly against Gemini API (free tier: 60 req/min)
gemini

What Gemini CLI + these models unlock together

Capability How
Code generation Gemini CLI reads your codebase, model reasons with <think> tags
Tool calling Native <|tool> tokens → Gemini CLI executes shell/file/web tools
Long context 1M ctx in CLI + TurboQuant 4.6x KV compression = very long sessions
MCP servers Connect any MCP server — databases, APIs, custom tools
Search grounding Google Search built in — model gets live data
# Real example: code review with tool calling enabled
gemini --baseUrl http://localhost:8080 \
  "Review all Python files in ./src, find potential bugs, and suggest fixes"

# Gemini CLI will: read files → call tools → model reasons → produce structured output

→ DeadByDawn101/gemini-cli on GitHub — Apache 2.0, free tier, MCP-compatible

⚡ TurboQuant-MLX — 4.6x KV Cache Compression

Pair this model with TurboQuant-MLX — RavenX AI's Apple Silicon KV cache compression. Run 4.6x longer contexts with near-zero accuracy loss by compressing the KV cache using PolarQuant + QJL residuals.

from turboquant_mlx.mlx_kvcache import TurboQuantKVCache
import mlx_lm.models.cache as cache_module

# Patch mlx-lm to use TurboQuant compression
cache_module.make_prompt_cache = lambda model, **kw: [
    TurboQuantKVCache() for _ in range(len(model.layers))
]

# Now load and run as normal — context is compressed automatically
from mlx_vlm import load, generate
model, processor = load("deadbydawn101/gemma-4-E2B-Heretic-Uncensored-mlx-4bit")
Without TurboQuant With TurboQuant
8K context @ 12 GB 36K context @ ~12 GB
KV cache grows linearly KV cache stays compressed

→ TurboQuant-MLX on GitHub · Release v2.0

🧠 Opus Reasoning + Claude Code LoRA

⚠️ The Opus Reasoning + Claude Code LoRA is NOT compatible with this model.

The LoRA was trained on gemma-4-E4B (hidden=2,560, 42 layers). This is gemma-4-E2B (hidden=1,536, 35 layers). Different architectures — loading the adapter here will produce incorrect results.

If you want Opus reasoning + Claude Code behavior, use the E4B model:
→ deadbydawn101/gemma-4-E4B-mlx-4bit + LoRA

Conversion Details

  • Source: p-e-w/gemma-4-E2B-it-heretic-ara (bfloat16, ~9 GB)
  • Tool: mlx_lm.convert with --q-bits 4 --q-group-size 64 --q-mode affine
  • Platform: Apple M4 Max 128GB
  • Output: 3.34 GB (4-bit weights + bfloat16 embeddings)

Related Models

Model Size Description
deadbydawn101/gemma-4-E4B-mlx-4bit 4.86 GB Standard 4B — better quality, still fast
deadbydawn101/gemma-4-E2B-Heretic-Uncensored-mlx-4bit 3.34 GB This model — 2B abliterated, fastest

License

Apache 2.0 — subject to Gemma Terms of Use.


Converted by deadbydawn101 · RavenX AI

TriAttention KV Compression

[2026-04-09] Our MLX port was merged into TriAttention (MIT + NVIDIA) — PR #1 by @DeadByDawn101 (RavenX AI).

Apply 10.7x KV memory reduction and 2.5x throughput on top of this model's built-in 4-bit TurboQuant quantization for ~50x combined compression vs full fp16:

from mlx_lm import load
from triattention.mlx import apply_triattention_mlx

model, tokenizer = load("deadbydawn101/gemma-4-E2B-Heretic-Uncensored-mlx-4bit")
apply_triattention_mlx(model, kv_budget=2048)

RavenX Inference Harness

One-command inference, benchmarking, and local OpenAI-compatible server:

git clone https://github.com/DeadByDawn101/ravenx-inference-harness
cd ravenx-inference-harness

# Inference
python run.py --model deadbydawn101/gemma-4-E2B-Heretic-Uncensored-mlx-4bit --prompt "Your prompt"

# TriAttention compressed
python run.py --model deadbydawn101/gemma-4-E2B-Heretic-Uncensored-mlx-4bit --triattention --kv-budget 2048

# Local OpenAI-compatible server (works with OpenClaw)
python serve.py --model deadbydawn101/gemma-4-E2B-Heretic-Uncensored-mlx-4bit --triattention

README history 9 versions

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

  1. 2026-04-09 docs: TriAttention merge credit + inference harness cde01ef 10.2 KB
    Loading...
  2. 2026-04-05 Add Gemini CLI coding agent + tool orchestration section with real usage exam... cdd5a34 9 KB
    Loading...
  3. 2026-04-05 Crown-worthy titles: clear name + tool calling + size + platform in H1, punch... e0e79ce 7.3 KB
    Loading...
  4. 2026-04-05 Update all references: gemma-4-E4B-mlx-4bit-v2 → gemma-4-E4B-mlx-4bit 0e9456a 7 KB
    Loading...
  5. 2026-04-05 Fix LoRA section: E2B is incompatible with E4B LoRA, add clear warning + redi... 7f5c5d3 7 KB
    Loading...
  6. 2026-04-05 Add TurboQuant section, Opus+Claude Code branding, indexing tags b18a626 7.3 KB
    Loading...
  7. 2026-04-05 Add Opus Reasoning + Claude Code LoRA section 2e18969 6.2 KB
    Loading...
  8. 2026-04-05 Update model card: full architecture details, abliteration stats, quickstart ... 9cec014 5.2 KB
    Loading...
  9. 2026-04-04 Upload folder using huggingface_hub 91b862b 247 B
    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