多任务少资源:针对基于大语言模型系统中资源优化的路由策略综述
Doing More with Less: A Survey on Routing Strategies for Resource Optimisation in Large Language Model-Based Systems
AI总结:
本文综述了基于大语言模型系统的路由策略,旨在通过优化资源利用提高效率和性能。
摘要:
基于大语言模型(LLM)的系统,即包含LLM作为核心组件的互联元素,如对话代理,通常设计为单体、静态架构,依赖单一通用目的LLM处理所有用户查询。然而,这些系统可能效率低下,因为不同的查询可能需要不同的推理级别、领域知识或预处理。虽然通用型LLM(如GPT-4o、Claude-Sonnet)在广泛任务上表现良好,但可能产生显著的财务、能源和计算成本。这些成本可能对简单的查询来说不成比例,导致不必要的资源利用。因此,可以采用路由机制将查询路由到更合适的组件,如较小或专门的模型,从而提高效率并优化资源消耗。本文综述旨在提供基于LLM系统的路由策略的全面概述。具体而言,它回顾了何时、为何以及如何将路由整合到LLM流程中以提高效率、可扩展性和性能。我们定义了优化的目标,如成本最小化和性能最大化,并讨论了路由在LLM工作流程中的时机,即在生成之前或之后发生。我们还详细介绍了各种实现策略,包括基于相似性的、监督的、基于强化学习的和生成方法。实际考虑因素如工业应用和当前限制也被探讨,如标准化路由实验、考虑非财务成本以及设计适应性策略。通过将路由正式化为性能-成本优化问题,本文综述提供了工具和方向,以指导未来适应性低成本LLM系统的研究和开发。
英文摘要:
Large Language Model (LLM)-based systems, i.e. interconnected elements that include an LLM as a central component, such as conversational agents, are usually designed with monolithic, static architectures that rely on a single, general-purpose LLM to handle all user queries. However, these systems may be inefficient as different queries may require different levels of reasoning, domain knowledge or pre-processing. While generalist LLMs (e.g. GPT-4o, Claude-Sonnet) perform well across a wide range of tasks, they may incur significant financial, energy and computational costs. These costs may be disproportionate for simpler queries, resulting in unnecessary resource utilisation. A routing mechanism can therefore be employed to route queries to more appropriate components, such as smaller or specialised models, thereby improving efficiency and optimising resource consumption. This survey aims to provide a comprehensive overview of routing strategies in LLM-based systems. Specifically, it reviews when, why, and how routing should be integrated into LLM pipelines to improve efficiency, scalability, and performance. We define the objectives to optimise, such as cost minimisation and performance maximisation, and discuss the timing of routing within the LLM workflow, whether it occurs before or after generation. We also detail the various implementation strategies, including similarity-based, supervised, reinforcement learning-based, and generative methods. Practical considerations such as industrial applications and current limitations are also examined, like standardising routing experiments, accounting for non-financial costs, and designing adaptive strategies. By formalising routing as a performance-cost optimisation problem, this survey provides tools and directions to guide future research and development of adaptive low-cost LLM-based systems.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。