arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2312.08361cs.LGcs.DC
收藏

互联网环境下大语言模型的分布式推理与微调

Distributed Inference and Fine-tuning of Large Language Models Over The Internet

Yandex(扬德克斯);University of Washington(华盛顿大学);Hugging Face(抱抱脸);Yandex School of Data Analysis(扬德克斯数据分析学院)

Alexander Borzunov, Max Ryabinin, Artem Chumachenko, Dmitry Baranchuk, Tim Dettmers, Younes Belkada, Pavel Samygin, Colin Raffel

AI总结:

针对大语言模型运行硬件门槛高的问题,提出容错推理算法与负载均衡协议,构建去中心化系统Petals,可利用互联网分布式闲置资源高效运行超大规模LLM,速度显著优于卸载方案。

摘要:

大语言模型(LLM)在众多自然语言处理任务中颇具效用,且性能随规模提升而增强,目前性能最优的开源模型参数量已超过500亿。然而,运行这类500亿参数以上的模型需要高端硬件,导致大多数研究人员难以使用。本研究探讨了大语言模型的低成本推理与微调方法,对比了本地与分布式策略。我们观察到,参数量足够大的模型(500亿+)甚至能在消费级网络的地理分布式设备上高效运行,这意味着可通过整合多个研究团队与志愿者的闲置计算资源,实现大语言模型的高效运行。我们解决了两个未决问题:(1)若任意设备可能突然断开连接,如何可靠地执行推理与微调;(2)如何在硬件配置不均、可随时加入和退出的设备之间划分大语言模型。为此,我们开发了专用的容错推理算法与负载均衡协议,可自动分配设备以最大化系统总吞吐量。我们在Petals——一个可在互联网上运行Llama 2(70B)与BLOOM(176B)的去中心化系统中验证了这些算法,其交互式生成速度比卸载方案最高快10倍。我们在模拟环境与横跨两大洲的真实场景中评估了系统性能。

英文摘要:

Large language models (LLMs) are useful in many NLP tasks and become more capable with size, with the best open-source models having over 50 billion parameters. However, using these 50B+ models requires high-end hardware, making them inaccessible to most researchers. In this work, we investigate methods for cost-efficient inference and fine-tuning of LLMs, comparing local and distributed strategies. We observe that a large enough model (50B+) can run efficiently even on geodistributed devices in a consumer-grade network. This could allow running LLM efficiently by pooling together idle compute resources of multiple research groups and volunteers. We address two open problems: (1) how to perform inference and fine-tuning reliably if any device can disconnect abruptly and (2) how to partition LLMs between devices with uneven hardware, joining and leaving at will. In order to do that, we develop special fault-tolerant inference algorithms and load-balancing protocols that automatically assign devices to maximize the total system throughput. We showcase these algorithms in Petals - a decentralized system that runs Llama 2 (70B) and BLOOM (176B) over the Internet up to 10x faster than offloading for interactive generation. We evaluate the performance of our system in simulated conditions and a real-world setup spanning two continents.

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

↑