自然语言处理领域的近期成功导致多个提供商推出大量大语言模型(LLMs)。每种LLM产品具有不同的推理准确率、货币成本和延迟,且其准确率进一步取决于问题的具体措辞(即特定提示)。与此同时,用户通常对回答所有问题的货币预算和延迟有限制,并且他们不知道针对每个问题应选择哪些LLM以满足其准确率和长期预算要求。为了在这一丰富的设计空间中导航,我们提出TREACLE(Thrifty Reasoning via Context-Aware LLM and Prompt Selection,通过上下文感知LLM和提示选择的节俭推理),这是一种强化学习策略,在尊重用户货币成本和延迟约束的同时联合选择模型和提示方案。TREACLE利用问题上下文,包括问题文本嵌入(反映查询的类型或难度)和响应历史(反映先前响应的一致性)来做出智能决策。我们在标准推理数据集(GSM8K、CSQA和LLC)上使用各种LLM和提示进行的评估表明,与基线相比,TREACLE可实现高达85%的成本节省,同时保持高准确率。重要的是,它使用户能够优雅地在准确率与成本之间进行权衡。
英文摘要:
Recent successes in natural language processing have led to the proliferation of large language models (LLMs) by multiple providers. Each LLM offering has different inference accuracy, monetary cost, and latency, and their accuracy further depends on the exact wording of the question (i.e., the specific prompt). At the same time, users often have a limit on monetary budget and latency to answer all their questions, and they do not know which LLMs to choose for each question to meet their accuracy and long term budget requirements. To navigate this rich design space, we propose TREACLE ($\underline{T}$hrifty $\underline{Rea}$soning via $\underline{C}$ontext-Aware $\underline{L}$LM and Prompt S$\underline{e}$lection), a reinforcement learning policy that jointly selects the model and prompting scheme while respecting the user's monetary cost and latency constraints. TREACLE uses the problem context, including question text embeddings (reflecting the type or difficulty of a query) and the response history (reflecting the consistency of previous responses) to make smart decisions. Our evaluations on standard reasoning datasets (GSM8K, CSQA, and LLC) with various LLMs and prompts show that TREACLE enables cost savings of up to 85% compared to baselines, while maintaining high accuracy. Importantly, it provides the user with the ability to gracefully trade off accuracy for cost.
CascadeLedger: Counterfactual Auditing of Information and Resource Integrity in LLM Cascades
School of Artificial Intelligence, University of Chinese Academy of Sciences(中国科学院大学人工智能学院);Institute of Information Engineering, Chinese Academy of Sciences(中国科学院信息工程研究所)
CASCADE: Case-Based Continual Adaptation for Large Language Models During Deployment
School of Artificial Intelligence, Jilin University(吉林大学人工智能学院);Engineering Research Center of Knowledge-Driven Human-Machine Intelligence, Jilin University(吉林大学知识驱动人机智能工程研究中心);International Center of Future Science, Jilin University(吉林大学未来科学国际中心);Department of Informatics, King’s College London(伦敦国王学院信息学院);The Alan Turing Institute(艾伦·图灵研究所);AI Centre, Department of Computer Science, UCL(UCL计算机科学系人工智能中心)
Signed Rescue Routing: Harm-Aware Cascades for Efficient LLM Inference
School of Artificial Intelligence, Beijing Normal University(北京师范大学人工智能学院);School of Information Science and Engineering, Chongqing Jiaotong University(重庆交通大学信息科学与工程学院);School of Computer Science and Technology, Dalian University of Technology(大连理工大学计算机科学与技术学院);School of Computer Science and Technology, Jilin University(吉林大学计算机科学与技术学院)
An efficient algorithm for contextual bandits with knapsacks, and an extension to concave objectives
Columbia University(哥伦比亚大学);Microsoft Research(微软研究院)
考虑了一个具有全局背包约束的多臂强盗问题。在每一轮中,拉动手臂的结果是标量奖励和资源消耗向量,两者都取决于上下文,并且全局背包约束要求每个资源的总消耗低于某个预定预算。学习代理与任意一组上下文相关的策略竞争。这个问题是由Badanidiyuru等人(2014)提出的,他给出了一个计算效率低的算法,但遗憾界接近最优。我们通过推广Agarwal等人(2014)的方法,给出了一个计算效率高的算法,遗憾界略好。我们的算法的计算时间尺度的策略空间的大小几何。这回答了Badanidiyuru et al.(2014)的主要开放问题。我们还将我们的结果扩展到一个变体,其中没有背包约束,但目标是一个任意的Lipschitz凹函数的结果向量的总和。
CASCADE: Contextual Sarcasm Detection in Online Discussion Forums
National University of Singapore(新加坡国立大学);A*STAR(新加坡科技研究局);Indian Institute of Science, Bangalore(班加罗尔印度科学学院);University of Michigan, Ann Arbor(密歇根大学安娜堡分校)
Optimal Contextual Bandits with Knapsacks under Realizability via Regression Oracles
Department of Mathematics, HKUST(香港科技大学数学系);Department of Industrial Engineering and Decision Analytics, HKUST(香港科技大学工业工程与决策分析系);HKUST Shenzhen-Hong Kong Collaborative Innovation Research Institute(香港科技大学深港协同创新研究院)
Budgeted Multi-Source Counterfactual Annotation for Off-Policy Evaluation
Johns Hopkins Carey Business School(约翰斯·霍普金斯凯瑞商学院);International Computer Science Institute(国际计算机科学研究所);Pennsylvania State University(宾夕法尼亚州立大学);Georgia Institute of Technology(佐治亚理工学院)
COBRA-Skills: Contextual Bandit-Guided Evolution for Agent Skill Optimization
The Chinese University of Hong Kong, Shenzhen(香港中文大学(深圳));Tianjin University(天津大学);The Hong Kong University of Science and Technology (Guangzhou)(香港科技大学(广州));National University of Singapore(新加坡国立大学)