YAML Metadata Warning: empty or missing yaml metadata in repo card (https://huggingface.co/docs/hub/model-cards#model-card-metadata)

Quantization made by Richard Erkhov.

Github

Discord

Request more models

Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full - GGUF

Name Quant method Size
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.Q2_K.gguf Q2_K 2.53GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.IQ3_XS.gguf IQ3_XS 2.81GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.IQ3_S.gguf IQ3_S 2.96GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.Q3_K_S.gguf Q3_K_S 2.95GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.IQ3_M.gguf IQ3_M 3.06GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.Q3_K.gguf Q3_K 3.28GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.Q3_K_M.gguf Q3_K_M 3.28GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.Q3_K_L.gguf Q3_K_L 3.56GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.IQ4_XS.gguf IQ4_XS 3.67GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.Q4_0.gguf Q4_0 3.83GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.IQ4_NL.gguf IQ4_NL 3.87GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.Q4_K_S.gguf Q4_K_S 3.86GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.Q4_K.gguf Q4_K 4.07GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.Q4_K_M.gguf Q4_K_M 4.07GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.Q4_1.gguf Q4_1 4.24GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.Q5_0.gguf Q5_0 4.65GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.Q5_K_S.gguf Q5_K_S 4.65GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.Q5_K.gguf Q5_K 4.78GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.Q5_K_M.gguf Q5_K_M 4.78GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.Q5_1.gguf Q5_1 5.07GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.Q6_K.gguf Q6_K 5.53GB
Mistral-7B_ours_algo7s_lyr20_n11_0.5_0.5_0.1_0.1_200steps_full.Q8_0.gguf Q8_0 7.17GB

Original model description:

library_name: transformers tags: []

Model Description

This Mistral-based model is fine-tuned using the "Representation Bending" (REPBEND) approach described in Representation Bending for Large Language Model Safety. REPBEND modifies the model’s internal representations to reduce harmful or unsafe responses while preserving overall capabilities. The result is a model that is robust to various forms of adversarial jailbreak attacks, out-of-distribution harmful prompts, and fine-tuning exploits, all while maintaining useful and informative responses to benign requests.

Uses

import torch
from transformers import AutoTokenizer, AutoModelForCausalLM

model_id = "thkim0305/RepBend_Mistral_7B"
tokenizer = AutoTokenizer.from_pretrained(model_id, use_fast=True)
model = AutoModelForCausalLM.from_pretrained(
    model_id,
    torch_dtype=torch.bfloat16,
    device_map="auto",
)

input_text = "Who are you?"
template = "[INST] {instruction} [/INST] "

prompt = template.format(instruction=input_text)

input_ids = tokenizer.encode(prompt, return_tensors="pt").to(model.device)
outputs = model.generate(input_ids, max_new_tokens=256)
generated_text = tokenizer.decode(outputs[0], skip_special_tokens=True)

print(generated_text)

Code

Please refers to this github page

Citation

@article{repbend,
  title={Representation Bending for Large Language Model Safety},
  author={Yousefpour, Ashkan and Kim, Taeheon and Kwon, Ryan S and Lee, Seungbeen and Jeung, Wonje and Han, Seungju and Wan, Alvin and Ngan, Harrison and Yu, Youngjae and Choi, Jonghyun},
  journal={arXiv preprint arXiv:2504.01550},
  year={2025}
}
Downloads last month
303
GGUF
Model size
7.24B params
Architecture
llama
Hardware compatibility
Log In to view the estimation

2-bit

3-bit

4-bit

5-bit

6-bit

8-bit

Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support