Downloads · 30 days
17
30% of all-time downloads
NoorNizar/Phi-4-mini-instruct-WINT4
Phi-4-mini-instruct-WINT4 is a text generation model from NoorNizar. Use it when you need the model to write or continue text. It is set up for transformers.
This model is a 4-bit quantized version of microsoft/Phi-4-mini-instruct "using the llmcompressor library.
Downloads · 30 days
17
30% of all-time downloads
All-time downloads
57
Public
Parameters
4.5B
5.7 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors5.7 GB · 100%
How the weights are stored.
I83.2B · 72%
From the Hugging Face model README
This model is a 4-bit quantized version of microsoft/Phi-4-mini-instruct "using the llmcompressor library.
llmcompressorquant_stage:
quant_modifiers:
QuantizationModifier:
ignore: [lm_head]
config_groups:
group_0:
weights: {num_bits: 4, type: int, symmetric: true, strategy: channel, dynamic: false}
targets: [Linear]
The following table shows the evaluation results on various benchmarks compared to the baseline (non-quantized) model.
| Task | Baseline Metric (10.0% Threshold) | Quantized Metric | Metric Type |
|---|---|---|---|
| winogrande | 0.7545 | 0.6985 | acc,none |
You can load the quantized model and tokenizer using the transformers library:
from transformers import AutoModelForCausalLM, AutoTokenizer
model_id = "NoorNizar/Phi-4-mini-instruct-WINT4"
model = AutoModelForCausalLM.from_pretrained(model_id, device_map="auto")
tokenizer = AutoTokenizer.from_pretrained(model_id)
# Example usage (replace with your specific task)
prompt = "Hello, world!"
inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
outputs = model.generate(**inputs, max_new_tokens=50)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
This model was quantized automatically using a script. Performance and behavior might differ slightly from the original base model.