arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2409.13757cs.CL

LLM的高效混合推理:基于奖励的Token建模与选择性云端辅助

Efficient Hybrid Inference for LLMs: Reward-Based Token Modelling with Selective Cloud Assistance

Bud Ecosystem Inc(巴德生态系统公司)

Adarsh MS, Jithin VG, Ditto PS

AI总结:

本文提出一种基于奖励机制的LLM与SLM混合推理方法,通过评估SLM预测token的奖励分数动态决定是否请求云端LLM辅助,在大幅降低云端调用成本的同时维持了响应质量。

摘要:

大型语言模型(LLMs)以其在一系列自然语言处理任务中的卓越性能而闻名,但其部署伴随着高昂的计算和财务成本。另一方面,可以部署在较低成本边缘设备上的较小语言模型(SLMs),则难以匹敌其大型对应模型的性能。本文提出了一种新颖的混合推理方法,该方法利用两种模型类型的优势,同时最小化对昂贵的基于云端的LLMs的依赖。与将整个查询路由到SLM或云端LLM的现有方法不同,我们的方法引入了一种基于奖励的机制,以在token生成期间动态确定云端LLM的参与。具体而言,SLM预测的每个token都会根据奖励分数进行评估,仅当该分数低于某个阈值时,才会咨询云端LLM以协助预测下一个token。这种方法不仅减少了发往云端LLM的流量,从而降低了成本,而且还允许根据奖励分数阈值对响应质量进行灵活控制。实验结果表明,我们的方法显著减少了云端LLM的使用,且对整体响应质量的影响最小,为部署高性能语言模型提供了一种具有成本效益的解决方案。

英文摘要:

Large language models (LLMs) are known for their exceptional performance across a range of natural language processing tasks, but their deployment comes at a high computational and financial cost. On the other hand, smaller language models (SLMs), which can be deployed on lower-cost edge devices, struggle to match the performance of their larger counterparts. This paper presents a novel hybrid inference approach that leverages the strengths of both model types while minimizing reliance on costly cloud-based LLMs. Unlike existing methods that route entire queries to either an SLM or a cloud LLM, our approach introduces a reward-based mechanism to dynamically determine the involvement of the cloud LLM during token generation. Specifically, each token predicted by the SLM is evaluated against a reward score, and only when this score falls below a certain threshold is the cloud LLM consulted for assistance in the next token prediction. This method not only reduces the traffic to the cloud LLM, thereby lowering costs, but also allows for flexible control over response quality depending on the reward score threshold. Experimental results demonstrate that our approach significantly reduces cloud LLM usage with minimal impact on overall response quality, offering a cost-effective solution for deploying high-performance language models

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

↑