huggingface-llm-trainer

Train language and vision models with TRL methods on Hugging Face Jobs.

10.9k|724|Updated Nov 24, 2025
One-click install
npx skills add https://github.com/huggingface/skills --skill huggingface-llm-trainer-huggingface
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: huggingface-llm-trainer
Source: https://github.com/huggingface/skills/tree/main/skills/huggingface-llm-trainer
Command: npx skills add https://github.com/huggingface/skills --skill huggingface-llm-trainer-huggingface

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires trl>=0.12.0, peft>=0.7.0, torch>=2.0.0, accelerate>=0.24.0, huggingface_hub>=0.20.0, sentencepiece>=0.1.99, protobuf>=3.20.0, numpy, gguf, and includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve?

This Skill allows users to train or fine-tune language and vision models efficiently, leveraging Hugging Face Jobs infrastructure and TRL (Transformer Reinforcement Learning) methods.

Core Features & Use Cases

  • TRL Training: Supports SFT, DPO, GRPO, and reward modeling training methods.
  • Hugging Face Jobs: Utilizes Hugging Face Jobs for cloud GPU training and model persistence.
  • GGUF Conversion: Converts trained models to GGUF format for local deployment.
  • Use Case: A researcher wants to fine-tune a language model on cloud GPUs without local infrastructure. They can use this Skill to train the model on Hugging Face Jobs, convert it to GGUF, and deploy it locally.

Quick Start

Use the huggingface-llm-trainer skill to train a model on Hugging Face Jobs using the TRL SFT method. For example, to train a model on the 'coco Captions' dataset:

/huggingface-llm-trainer train --dataset coco Captions --method sft

Frequently Asked Questions about huggingface-llm-trainer

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

FAQPage Schema
How do I fine-tune a language model using Hugging Face Jobs and TRL?

To fine-tune a language model using Hugging Face Jobs and TRL, you can use this Skill to automate the end-to-end training process. It supports methods like SFT, DPO, GRPO, and reward modeling on cloud GPUs.

Can I convert a fine-tuned model to GGUF format for local deployment?

Yes, you can convert a fine-tuned model to GGUF format for local deployment. This Skill automates the conversion process after training on Hugging Face Jobs, ensuring your language or vision model is ready for local use.

What training methods are supported by TRL on Hugging Face infrastructure?

TRL on Hugging Face infrastructure supports SFT, DPO, GRPO, and reward modeling training methods. This Skill leverages these Transformer Reinforcement Learning methods to efficiently train or fine-tune your models.

Do I need local GPUs to train language models with Hugging Face Jobs?

No, you do not need local GPUs to train language models with Hugging Face Jobs. This Skill utilizes Hugging Face Jobs infrastructure for cloud GPU training and model persistence, eliminating the need for local hardware.

What Python dependencies are required to train models with TRL and PEFT?

To train models with TRL and PEFT, you need trl>=0.12.0, peft>=0.7.0, torch>=2.0.0, and accelerate>=0.24.0. This Skill also requires access to Hugging Face Hub and Jobs infrastructure for execution.

Can I train vision models on cloud GPUs using Hugging Face infrastructure?

Yes, you can train vision models on cloud GPUs using Hugging Face infrastructure. This Skill provides an end-to-end solution for training both language and vision models using TRL methods, followed by GGUF conversion.