SohaibAbdoAhmed/smollm2-glaive-fc-best-adapter
029
SmolLM2-1.7B-Instruct Fine-Tuned for Function Calling (QLoRA)
This is the best performing LoRA adapter for HuggingFaceTB/SmolLM2-1.7B-Instruct fine-tuned on the glaiveai/glaive-function-calling-v2 dataset.
How to Use
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)