Downloads · 30 days
10
8% of all-time downloads
NEldin10/llama-3.2-1B-ft-v0.1-qlora-merged
llama-3.2-1B-ft-v0.1-qlora-merged is a machine learning model from NEldin10. Use it for the machine learning task on the model card, and read the license before you ship it in a product. The card lists the license as apache-2.0.
This model is a fine-tuned version of Llama 3.2 1B specialized for clean, surgical Python code generation. It was trained on 8k high-quality Python examples from the Vezora/Tested-22k-Python-Alpaca dataset.
Downloads · 30 days
10
8% of all-time downloads
All-time downloads
128
Public
Parameters
1.3B
1 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors1 GB · 98%
How the weights are stored.
U81B · 79%
From the Hugging Face model README
This model is a fine-tuned version of Llama 3.2 1B specialized for clean, surgical Python code generation.
It was trained on 8k high-quality Python examples from the Vezora/Tested-22k-Python-Alpaca dataset.
Using a greedy decoding strategy (temperature 0.1), this model demonstrates a significant reasoning jump:
| Model | Pass@1 (Coding Benchmark) |
|---|---|
| Llama 3.2 1B (Base) | 0.0% |
| llama-3.2-1B-ft-v0.1-qlora (Fine-Tuned) | 66.7% |
from transformers import AutoModelForCausalLM, AutoTokenizer
tokenizer = AutoTokenizer.from_pretrained("NEldin10/llama-3.2-1B-ft-v0.1-qlora-merged")
model = AutoModelForCausalLM.from_pretrained("NEldin10/llama-3.2-1B-ft-v0.1-qlora-merged")
prompt = "<|begin_of_text|><|start_header_id|>system<|end_header_id|>\n\nYou are a surgical coding expert.<|eot_id|><|start_header_id|>user<|end_header_id|>\n\nWrite a function to find the GCD of two numbers.<|eot_id|><|start_header_id|>assistant<|end_header_id|>\n\n"
inputs = tokenizer(prompt, return_tensors="pt").to("cuda")
outputs = model.generate(**inputs, max_new_tokens=200)
print(tokenizer.decode(outputs[0]))