peft-fine-tuning

Train low-rank adapters for parameter-efficient fine-tuning of large language models.

Updated May 4, 2026
One-click install
npx skills add https://github.com/JamesFincher/gengar --skill peft-fine-tuning-jamesfincher
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: peft-fine-tuning
Source: https://github.com/JamesFincher/gengar/tree/main/optional-skills/mlops/peft
Command: npx skills add https://github.com/JamesFincher/gengar --skill peft-fine-tuning-jamesfincher

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires peft, transformers, torch, bitsandbytes, accelerate, datasets, trl, optimum, vllm, and includes references (resource) components.

What problem does it solve?

Fine-tuning large language models is often too expensive in GPU memory and compute to iterate quickly, especially when you need domain adaptation without training the full model.

Core Features & Use Cases

  • Parameter-efficient fine-tuning (PEFT): Train a tiny fraction of parameters using adapter methods like LoRA and QLoRA instead of updating all weights.
  • LoRA and QLoRA workflows: Use LoRA for general adapter tuning and QLoRA when GPU memory is the primary constraint by combining PEFT with 4-bit quantization.
  • Adapter management patterns: Save and load adapter-only weights, merge adapters for deployment, and support multi-adapter switching for serving multiple tasks from one base model.

Use case example: You want to adapt a 70B instruction model to your specific support domain but only have a single ~24GB GPU; use QLoRA to train adapters efficiently, then deploy by merging for lower runtime overhead.

Quick Start

Run LoRA or QLoRA training to create an adapter for your base model, then save the adapter weights for later loading and inference.

Frequently Asked Questions about peft-fine-tuning

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I fine-tune a 70B LLM on a single 24GB GPU?

Merge LoRA adapter weights into the base model for lower runtime overhead during inference, or load adapter-only weights to support multi-adapter switching for serving multiple tasks from one base model.

What is the difference between LoRA and QLoRA for adapter training?

LoRA trains low-rank adapters for general parameter-efficient fine-tuning, while QLoRA applies 4-bit quantization via bitsandbytes to drastically reduce GPU memory usage when training large models on constrained hardware.

Can I use bitsandbytes with PEFT for 4-bit quantized training?

Yes, PEFT integrates with bitsandbytes and Transformers to enable 4-bit quantized training, allowing you to apply QLoRA workflows for memory-optimized domain adaptation of large language models.

How do I deploy multiple fine-tuned adapters for different tasks?

You can support multi-adapter switching to serve multiple tasks from one base model by saving and loading adapter-only weights, or merge adapters into the base model for deployment with lower runtime overhead.