How to use from the
Use from the
Transformers library
# Use a pipeline as a high-level helper
from transformers import pipeline

pipe = pipeline("text-generation", model="Fu01978/SmolLM2-360M-Instruct-Heretic")
messages = [
    {"role": "user", "content": "Who are you?"},
]
pipe(messages)
# Load model directly
from transformers import AutoTokenizer, AutoModelForCausalLM

tokenizer = AutoTokenizer.from_pretrained("Fu01978/SmolLM2-360M-Instruct-Heretic")
model = AutoModelForCausalLM.from_pretrained("Fu01978/SmolLM2-360M-Instruct-Heretic")
messages = [
    {"role": "user", "content": "Who are you?"},
]
inputs = tokenizer.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(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:]))
Quick Links

SmolLM2-360M-Instruct-Heretic

This is a decensored (abliterated) version of the HuggingFaceTB/SmolLM2-360M-Instruct model. It was created using the Heretic library to surgically remove the "refusal vector" while preserving the model's core intelligence.

Details

The model was optimized using the following metrics:

  • Refusal Rate: 4/100
  • KL Divergence: 0.0537

Disclaimer

This model has no safety filters. It can generate content that is offensive, harmful, or inappropriate. Please use responsibly.

Downloads last month
64
Safetensors
Model size
0.4B params
Tensor type
BF16
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for Fu01978/SmolLM2-360M-Instruct-Heretic

Finetuned
(143)
this model
Merges
1 model
Quantizations
1 model

Datasets used to train Fu01978/SmolLM2-360M-Instruct-Heretic

Collection including Fu01978/SmolLM2-360M-Instruct-Heretic