Downloads · 30 days
9
20% of all-time downloads
SohaibAbdoAhmed/smollm2-glaive-fc-best-adapter
smollm2-glaive-fc-best-adapter is a text generation model from SohaibAbdoAhmed. Use it when you need the model to write or continue text. It is set up for peft.
This is the best performing LoRA adapter for HuggingFaceTB/SmolLM2-1.7B-Instruct fine-tuned on the glaiveai/glaive-function-calling-v2 dataset.
Downloads · 30 days
9
20% of all-time downloads
All-time downloads
44
Public
Repo size
72.4 MB
Likes
0
Public
Click a slice to open those files.
.safetensors72.4 MB · 95%
From the Hugging Face model README
This is the best performing LoRA adapter for HuggingFaceTB/SmolLM2-1.7B-Instruct fine-tuned on the glaiveai/glaive-function-calling-v2 dataset.
import torch
from transformers import AutoModelForCausalLM, AutoTokenizer
from peft import PeftModel
base_model_id = "HuggingFaceTB/SmolLM2-1.7B-Instruct"
adapter_repo_id = "SohaibAbdoAhmed/smollm2-glaive-fc-best-adapter"
tokenizer = AutoTokenizer.from_pretrained(adapter_repo_id)
base_model = AutoModelForCausalLM.from_pretrained(
base_model_id,
torch_dtype=torch.bfloat16,
device_map="auto"
)
model = PeftModel.from_pretrained(base_model, adapter_repo_id)