323  trl(1) - Kailash Tool Reference

323.1 trl

trl - Hugging Face TRL — RL training for transformers.

Layer OPS
Category o-05-ai-engineering-sdks-dev-env
Safety class safe
Licence Apache-2.0
Upstream github.com/huggingface/trl

323.1.1 NAME

trl - Hugging Face TRL — RL training for transformers.

323.1.2 SYNOPSIS & usage

Derived from the upstream README at generation time; verify against --help where the tool is installed.

pip install trl
pip install git+https://github.com/huggingface/trl.git

323.1.3 DESCRIPTION (upstream)

⚡ Up to 6.9× longer sequences on the same GPU: SFT, DPO, KTO, GRPO and RLOO now score tokens with a fused LM head by default. At 8k tokens that is 52% to 82% less peak VRAM. TRL is a cutting-edge library designed for post-training foundation models using advanced techniques like Supervised Fine-Tuning (SFT), Group Relative Policy Optimization (GRPO), and Direct Preference Optimization (DPO). Built on top of the 🤗 Transformers ecosystem, TRL supports a variety of model architectures and modalities, and can be scaled-up across various hardware setups. - Trainers: Various fine-tun

323.1.4 SEE ALSO


ref: pin - verified 2026-10-14