peft-fine-tuning

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

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

SYSTEM DOCUMENTATION & REQUIREMENTS

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

What problem does it solve?

This Skill helps you fine-tune large language models without paying the full compute and memory cost of updating all parameters.

Core Features & Use Cases

  • Parameter-efficient adapter training: Train under 1% of model parameters using LoRA, QLoRA, and related adapter methods to reduce memory and speed up iteration.
  • Multi-adapter workflows: Create and serve multiple task-specific adapters from one base model, switching adapters at runtime or composing adapters for ensemble behavior.
  • Practical deployment options: Load adapters for inference, merge adapters into the base model for adapter-free serving, and troubleshoot common training/inference issues.

Use case example: You want to adapt a 7B–70B instruction model for a narrow business domain on a single GPU; use LoRA for fast experiments, switch to QLoRA when VRAM is the bottleneck, and then merge the adapter into the base model for efficient deployment.

Quick Start

Use the peft-fine-tuning skill to run LoRA or QLoRA fine-tuning for your target model and dataset, producing a small adapter you can load later or merge for deployment.

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 7B-70B LLM on a single GPU with limited VRAM?

You can fine-tune large language models on limited VRAM by training low-rank adapters with LoRA or QLoRA. This parameter-efficient approach updates under 1% of model parameters, drastically reducing memory costs while adapting instruction models for narrow domains.

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

LoRA trains low-rank adapters to reduce memory during fine-tuning, while QLoRA combines this with 4-bit quantization via bitsandbytes. Switch to QLoRA when VRAM is the bottleneck for 7B-70B models, and use LoRA for faster iteration experiments.

Can I run multi-adapter serving from a single base model?

Yes, multi-adapter workflows allow you to create and serve multiple task-specific adapters from one base model. You can switch adapters at runtime or compose them for ensemble behavior without loading multiple full models into memory.

How do I merge LoRA adapters into a base model for deployment?

You can merge trained adapters directly into the base model for adapter-free serving. This deployment option eliminates the overhead of loading adapters separately during inference, streamlining the production pipeline.

What Huggingface libraries are needed for parameter-efficient fine-tuning?

Parameter-efficient fine-tuning uses the PEFT, transformers, and torch stack. Optional dependencies include bitsandbytes for 4-bit quantization, datasets for data loading, accelerate for distributed training, and trl for reinforcement learning integration.

Does QLoRA with 4-bit quantization work with vllm for inference?

QLoRA trains adapters using 4-bit quantization via bitsandbytes, producing small adapter files. These adapters can be loaded or merged into the base model, preparing them for efficient deployment and inference using frameworks like vllm.