arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2605.28760cs.LG
收藏

LLM零阶微调是一种推理工作负载

Inference-Native Zeroth-Order Optimization for LLMs

Zelin Li, Caiwen Ding

AI总结:

本文发现LLM零阶微调是推理主导的工作负载,通过将其重复评分阶段在服务运行时中执行,实现了8.13倍加速,并保持了高精度。

摘要:

零阶(ZO)微调对大型语言模型具有吸引力,因为它用前向目标评估替代了反向传播。然而,现有实现仍在传统训练循环内执行ZO算法,尽管其主要工作是重复评分附近参数状态。这造成了工作负载-运行时不匹配:算法要求结构化的推理式评分,而系统暴露出一系列碎片化的训练循环步骤。我们表明LLM ZO微调是一种推理主导的工作负载,并通过服务运行时执行其重复评分阶段。在OPT-13B SST-2上,得到的vLLM执行路径在匹配的LoRA-only设置下,完成20k步LoZO运行仅需估计0.51训练小时,而官方LoZO基线需要4.15小时,实现了8.13倍加速,同时达到0.922的最终评估准确率和0.931的最终全验证准确率。在OPT-1.3B到OPT-13B的核心步长扩展实验中,相同的运行时重组带来了2.34倍至7.72倍的加速。一个MeZO风格的高秩因子分解实验表明,相同的运行时范式可以跟踪类似MeZO的损失轨迹,同时运行速度提升高达2.55倍。更广泛地说,将ZO更新表示为动态适配器状态,为推理时训练提供了一条实用路径,其中轻量级适配可以像推理工作负载一样调度,而不是作为单独的训练任务。

英文摘要:

Zeroth-order (ZO) methods train large language models using only forward passes, yet common ZO execution paths perform substantial work beyond what the algorithm itself requires. To remove this extra execution overhead, we present Infer-ZO, which separates the evaluations required by the algorithm from how they are executed, allowing them to reuse existing inference-engine optimizations. After removing inherited execution work, a complete Infer-ZO step on Qwen3-14B adds only 1.16% wall-clock time over matched inference, bringing ZO execution close to its fundamental inference workload. With Infer-ZO, ZO evaluations run at near-inference cost with frozen base weights and can share GPU batches with ordinary inference requests. In co-serving experiments, foreground and background throughput remain within 1-3% of the corresponding background-request baseline. Across 15 Qwen3, Llama, and OPT models, Infer-ZO achieves 2.10x-9.94x end-to-end step speedups over released LoZO. Code is available at https://github.com/playeriv65/zo-vllm.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑