低秩适配(Low-Rank Adaptation, LoRA)已成为大语言模型(Large Language Models, LLMs)主流的参数高效微调(Parameter-Efficient Fine-Tuning, PEFT)方法,它在显著降低GPU显存占用的同时,能在下游任务上保持具备竞争力的微调模型质量。尽管有这些优势,我们发现现有LoRA微调系统存在两个关键低效问题:第一,由于大激活张量上存在冗余内存访问,会产生大量运行时开销;第二,这类系统未能利用在同一组GPU上、共享同一基座模型的多个独立LoRA适配器并行微调的机会,导致错失减少流水线气泡、优化通信重叠、提升GPU负载均衡等性能增益。\n为解决这些问题,我们提出了LoRAFusion——一种面向LLMs的高效LoRA微调系统。在算子层面,我们提出了一种图拆分方法,可融合访存受限型操作,该设计消除了不必要的内存访问,同时保留了计算受限型通用矩阵乘法(GEMM)的性能,且不会引入重计算或同步开销。在调度层面,LoRAFusion提出了一种适用于多任务微调的自适应批处理算法:它首先将LoRA适配器分组,有意错开不同任务的批处理执行时机,随后在每组内求解装箱问题,以生成均衡的、感知依赖关系的微批次。实验结果显示,与Megatron-LM相比,LoRAFusion的端到端加速比最高达1.96倍(平均1.47倍);与当前最先进的多LoRA微调系统mLoRA相比,性能提升最高达1.46倍(平均1.29倍)。我们的融合算子性能提升最高达1.39倍(平均1.27倍),可直接作为即插即用组件替换现有LoRA系统中的对应模块。我们已在https://github.com/CentML/lorafusion 开源LoRAFusion。
英文摘要:
Low-Rank Adaptation (LoRA) has become the leading Parameter-Efficient Fine-Tuning (PEFT) method for Large Language Models (LLMs), as it significantly reduces GPU memory usage while maintaining competitive fine-tuned model quality on downstream tasks. Despite these benefits, we identify two key inefficiencies in existing LoRA fine-tuning systems. First, they incur substantial runtime overhead due to redundant memory accesses on large activation tensors. Second, they miss the opportunity to concurrently fine-tune multiple independent LoRA adapters that share the same base model on the same set of GPUs. This leads to missed performance gains such as reduced pipeline bubbles, better communication overlap, and improved GPU load balance.
To address these issues, we introduce LoRAFusion, an efficient LoRA fine-tuning system for LLMs. At the kernel level, we propose a graph-splitting method that fuses memory-bound operations. This design eliminates unnecessary memory accesses and preserves the performance of compute-bound GEMMs without incurring the cost of recomputation or synchronization. At the scheduling level, LoRAFusion introduces an adaptive batching algorithm for multi-job fine-tuning. It first splits LoRA adapters into groups to intentionally stagger batch execution across jobs, and then solves a bin-packing problem within each group to generate balanced, dependency-aware microbatches. LoRAFusion achieves up to $1.96\times$ ($1.47\times$ on average) end-to-end speedup compared to Megatron-LM, and up to $1.46\times$ ($1.29\times$ on average) improvement over mLoRA, the state-of-the-art multi-LoRA fine-tuning system. Our fused kernel achieves up to $1.39\times$ ($1.27\times$ on average) kernel performance improvement and can directly serve as a plug-and-play replacement in existing LoRA systems. We open-source LoRAFusion at https://github.com/CentML/lorafusion.
Safe Pruning LoRA: Robust Distance-Guided Pruning for Safety Alignment in Adaptation of LLMs
School of Electronics and Computer Science, University of Southampton, UK(索姆塞特大学电子与计算机科学学院);Department of Computer Science, University of Liverpool, UK(利弗pool大学计算机科学系)
Tensor Train Low-rank Approximation (TT-LoRA): Democratizing AI with Accelerated LLMs
Theoretical Division, Los Alamos National Laboratory(洛斯阿拉莫斯国家实验室理论分部);Advanced Research in Cyber Systems, Los Alamos National Laboratory(洛斯阿拉莫斯国家实验室网络系统高级研究分部);University of Texas at Arlington(德克萨斯大学阿灵顿分校)
How Relevance Emerges: Interpreting LoRA Fine-Tuning in Reranking LLMs
Center for Intelligent Information Retrieval, Manning College of Information and Computer Sciences, University of Massachusetts Amherst(智能信息检索中心,信息与计算机科学学院,马萨诸塞大学阿姆赫斯特分校)
R-LoRA: Randomized Multi-Head LoRA for Efficient Multi-Task Learning
School of Artificial Intelligence, Jilin University(吉林大学人工智能学院);Engineering Research Center of Knowledge-Driven Human-Machine Intelligence, MOE, China(知识驱动人机智能工程研究中心,教育部,中国);International Center of Future Science, Jilin University(未来科学国际中心,吉林大学)
LoRA Fine-Tuning Without GPUs: A CPU-Efficient Meta-Generation Framework for LLMs
Department of Mathematics, McMaster University, Hamilton, Canada(麦斯特大学数学系);Vector Institute, Toronto, Canada(向量研究所);University of Oxford, Oxford, United Kingdom(牛津大学)
Uncertainty quantification in fine-tuned LLMs using LoRA ensembles
Stockholm University Department of Physics(斯德哥尔摩大学物理系);Department of Mathematical Sciences(数学科学系);Chalmers university of technology & University of Gothenburg(楚德勒斯技术大学及哥德堡大学);VERSES Research Lab(VERSES研究实验室)
Less is More: Extreme Gradient Boost Rank-1 Adaption for Efficient Finetuning of LLMs
Nanyang Technological University(南洋理工大学);The Chinese University of Hong Kong(香港中文大学);Data61;CSIRO(联邦科学与工业研究组织);Tsinghua University(清华大学);Australian National University(澳大利亚国立大学)
Enhancing LLMs for Graph Tasks via Graph-aware LoRA Generation
State Key Lab. of AI Safety, Institute of Computing Technology, Chinese Academy of Sciences(中国科学院计算技术研究所人工智能安全国家重点实验室);University of Chinese Academy of Sciences(中国科学院大学);DAMO Academy, Alibaba Group(阿里巴巴集团达摩院)