Downloads · 30 days
11
5% of all-time downloads
JongYeop/Mistral-7B-Instruct-v0.2-FP8-W8A8
Mistral-7B-Instruct-v0.2-FP8-W8A8 is a text generation model from JongYeop. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as apache-2.0.
This is an FP8 quantized version of mistralai/Mistral-7B-Instruct-v0.2 using the compressed-tensors quantization method.
Downloads · 30 days
11
5% of all-time downloads
All-time downloads
234
Public
Parameters
7.2B
7.5 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors7.5 GB · 100%
How the weights are stored.
F8_E4M37B · 96%
From the Hugging Face model README
This is an FP8 quantized version of mistralai/Mistral-7B-Instruct-v0.2 using the compressed-tensors quantization method.
This model uses FP8 per-tensor symmetric quantization for both weights and activations:
from transformers import AutoModelForCausalLM, AutoTokenizer
model_id = "JongYeop/Mistral-7B-Instruct-v0.2-FP8-W8A8"
# Load tokenizer
tokenizer = AutoTokenizer.from_pretrained(model_id)
# Load quantized model
model = AutoModelForCausalLM.from_pretrained(
model_id,
device_map="auto",
torch_dtype="auto"
)
# Generate text
messages = [
{"role": "user", "content": "What is machine learning?"}
]
input_ids = tokenizer.apply_chat_template(
messages,
add_generation_prompt=True,
return_tensors="pt"
).to(model.device)
outputs = model.generate(
input_ids,
max_new_tokens=256,
do_sample=True,
temperature=0.7,
top_p=0.9,
)
response = tokenizer.decode(outputs[0][input_ids.shape[-1]:], skip_special_tokens=True)
print(response)
This quantized model is intended for efficient inference with reduced memory footprint while maintaining reasonable performance. It is suitable for:
If you use this model, please cite the original Mistral paper and the compressed-tensors library.
Same as the base model: Apache 2.0