Copy-paste setups. Theory lives in ../docs/complete-curriculum.md. Hardware: ../docs/setup-encyclopedia.md. Ethics: ../docs/risks-and-ethics.md.
0. This repo — C++26 platform (no extra clone)#
The default helper path is abliterate-cxx (ISO C++26). See ../docs/cxx26-platform.md. Prebuilt Linux/Windows/macOS (x64 + arm64) archives: cxx-nightly.
npm run cxx:build
npm run cxx:test
cxx/build/abliterate-cxx guide
cxx/build/abliterate-cxx doctor
cxx/build/abliterate-cxx self-check
cxx/build/abliterate-cxx demoHand-holding: ../docs/cxx26-researcher-guide.md · ../cxx/GETTING-STARTED.md
| Job | Command |
|---|---|
| Shared self-check | cxx/build/abliterate-cxx self-check |
Estimate r (DIM / projected / COSMIC / SVD) | cxx/build/abliterate-cxx estimate --mode projected --bad bad.txt --good good.txt --out r.txt |
| SVD subspace | cxx/build/abliterate-cxx estimate --mode svd --rank 4 --bad bad.txt --good good.txt --out R.txt |
| Bake weights | cxx/build/abliterate-cxx apply --mode orba-directional --weight W.txt --direction r.txt --out W2.txt |
| Householder A/B | … apply --mode orba-householder … |
| Inference hook | cxx/build/abliterate-cxx hook --h h.txt --direction r.txt |
| Score generations | cxx/build/abliterate-cxx eval --jsonl outs.jsonl |
| ΔW → LoRA (Python, PEFT) | python scripts/export-abliteration-lora.py --base ./base --abliterated ./out --out ./adapter --rank 16 |
Optional Python twins: scripts/estimate-refusal-direction.py and siblings. They are not required for the operators above.
1. Heretic (production default)#
pip install heretic-llm==1.4.0 bitsandbytes accelerate
cp sources/heretic-tools/config.production.toml config.toml
# 8 GB: cp sources/heretic-tools/config.low-vram.toml config.toml
heretic Qwen/Qwen3-4B-Instruct-2507
heretic <model> --print-residual-geometry # needs heretic-llm[research]Thinking / factory / noslop: config.thinking-model.toml, config.factory-qa.toml, config.noslop.toml. Full flags: ../docs/advanced-techniques-catalog.md.
2. llm-abliteration (low VRAM / manual)#
git clone https://github.com/jim-plus/llm-abliteration.git
cd llm-abliteration && pip install -r requirements.txt
python measure.py -m <model> -o directions.pt --quant 4bit --projected
python measure.py -m <model> -o directions.pt --quant 4bit --deccp # multilingual
python sharded_ablate.py config.yaml --projected --normpreserveHandbook path is jim-plus v1.2. NousResearch/llm-abliteration last push ~2025-11-27 — frozen; not production-pinnable. AUGMXNT/deccp is topics/dataset, not a peer CLI — python measure.py --deccp on jim-plus.
3. Abliterix#
pip install -U abliterix
abliterix --model Qwen/Qwen3-4B-Instruct-2507
# 4-bit: --model.quant-method bnb_4bit
# replay: --reproduce reproduce/reproduce.jsonAGPL-3.0. Presets are TOML (configs/*.toml, python scripts/generate_configs.py). There is no abliterix run --config …yaml. Pair with HonestAbliterationBench and data/eval/*.jsonl.
4. ErisForge (layer band)#
git clone https://github.com/Tsadoq/ErisForge.git
cd ErisForge && pip install -e .Use after heretic --print-residual-geometry picks L_peak ± 4. See ../techniques/layer-selective-abliteration.md.
5. OBLITERATUS (SVD presets)#
git clone https://github.com/elder-plinius/OBLITERATUS.git
cd OBLITERATUS && pip install -e ".[spaces]"
obliteratus obliterate <model> --method advanced --output-dir ./out
# reasoning / MoE: --method surgical
# PyPI `obliteratus` 0.0.1 is a stub; there is no [full] extra../techniques/svd-whitened-obliteratus.md. Confirm --help on your installed version.
6. COSMIC (direction ID)#
git clone https://github.com/wang-research-lab/COSMIC.git
# follow upstream README for ACL reproduction
python scripts/estimate-refusal-direction.py --mode cosmic --bad bad.pt --good good.pt --out r.pt../methods/cosmic-direction-id.md.
7. FailSpy / TransformerLens (hooks)#
git clone https://github.com/FailSpy/abliterator.git
# notebooks: cache resid, try hook, then bake winner8. Arditi paper code#
git clone https://github.com/andyrdt/refusal_direction.git9. False-refusal ICLR 2025#
git clone https://github.com/mainlp/False-Refusal-Mitigation.git
# or Heretic with data/eval/factory-bad-prompts.txt as [bad_prompts]10. Harm vs refusal (Zhao 2025)#
git clone https://github.com/CHATS-lab/LLMs_Encode_Harmfulness_Refusal_Separately.gitAnalysis / Latent Guard — not a factory uncensor script. ../techniques/harm-vs-refusal-directions.md.
11. Niche 2026 CLIs#
| Tool | Install |
|---|---|
| ablate-llm | pip install ablate-llm |
| Blasphemer (macOS Heretic fork) | git clone https://github.com/sunkencity999/blasphemer |
| J-Wash | git clone https://github.com/Extraltodeus/J-Wash |
| vauban (MLX) | git clone https://github.com/teilomillet/vauban |
| senbonzakura (multi-D CLI; not official SOM) | git clone https://github.com/elementmerc/senbonzakura |
None of these replace Stage 3 eval gates. Official SOM trainer is pralab/som-refusal-directions, not senbonzakura.
12. GGUF / Ollama after any baker#
python llama.cpp/convert_hf_to_gguf.py ./abliterated --outfile model.gguf --outtype q4_k_m
# LoRA sidecar
python llama.cpp/convert_lora_to_gguf.py --outfile lora.gguf --base-model-id <id> --lora-path ./adapter../docs/toolchain-safetensors-gguf-lora.md · run-locally-ollama-lmstudio.md.
Eval after every command above#
npm run eval:stats
python scripts/eval-refusal-rate.py --responses-jsonl <your-generations.jsonl>Corpora: ../docs/evaluation.md.
Selective checkpoint experiment#
Follow the MiniCPM5 measured walkthrough for pinned download, calibration, all-layer and selected controls, selected-tensor SFT, and independent tensor verification. The planner emits exact tensor-selection commands.