一种用于优化AI工作负载的声明式系统
A Declarative System for Optimizing AI Workloads
AI总结:
本文提出Palimpzest声明式系统,通过成本优化框架自动选择模型、推理方法和硬件,在运行时、成本和数据质量间取得最佳权衡,实现AI分析查询的高效处理。
摘要:
数据管理系统的一个长期目标一直是构建能够以经济高效的方式对大规模非结构化数据语料库计算定量洞察的系统。直到最近,从公司文档中提取事实、从科学论文中提取数据、或从图像和视频语料库中提取指标,仍然困难且昂贵。如今的模型可以高精度地完成这些任务。然而,想要回答一个实质性的AI驱动查询的程序员,必须编排大量的模型、提示词和数据操作。即使对于单个查询,程序员也必须做出大量决策,例如模型的选择、正确的推理方法、最具成本效益的推理硬件、理想的提示词设计等等。最优的决策集合会随着查询的变化以及快速演变的技术格局而变化。在本文中,我们提出了Palimpzest,一个允许任何人仅通过用声明式语言定义查询来处理AI驱动的分析查询的系统。该系统使用其成本优化框架来实现具有运行时、财务成本和输出数据质量之间最佳权衡的查询计划。我们描述了AI驱动分析任务的工作负载、Palimpzest使用的优化方法以及原型系统本身。我们在法律发现、房地产搜索和医学模式匹配任务上评估了Palimpzest。我们表明,即使是我们简单的原型也提供了一系列有吸引力的计划,其中包括一个比基线方法快3.3倍且便宜2.9倍的计划,同时还提供了更好的数据质量。启用并行性后,Palimpzest可以生成相对于单线程GPT-4基线最高达90.3倍加速且成本降低9.1倍的计划,同时获得的F1分数在基线的83.5%以内。这些都不需要用户额外的工作。
英文摘要:
A long-standing goal of data management systems has been to build systems which can compute quantitative insights over large corpora of unstructured data in a cost-effective manner. Until recently, it was difficult and expensive to extract facts from company documents, data from scientific papers, or metrics from image and video corpora. Today's models can accomplish these tasks with high accuracy. However, a programmer who wants to answer a substantive AI-powered query must orchestrate large numbers of models, prompts, and data operations. For even a single query, the programmer has to make a vast number of decisions such as the choice of model, the right inference method, the most cost-effective inference hardware, the ideal prompt design, and so on. The optimal set of decisions can change as the query changes and as the rapidly-evolving technical landscape shifts. In this paper we present Palimpzest, a system that enables anyone to process AI-powered analytical queries simply by defining them in a declarative language. The system uses its cost optimization framework to implement the query plan with the best trade-offs between runtime, financial cost, and output data quality. We describe the workload of AI-powered analytics tasks, the optimization methods that Palimpzest uses, and the prototype system itself. We evaluate Palimpzest on tasks in Legal Discovery, Real Estate Search, and Medical Schema Matching. We show that even our simple prototype offers a range of appealing plans, including one that is 3.3x faster and 2.9x cheaper than the baseline method, while also offering better data quality. With parallelism enabled, Palimpzest can produce plans with up to a 90.3x speedup at 9.1x lower cost relative to a single-threaded GPT-4 baseline, while obtaining an F1-score within 83.5% of the baseline. These require no additional work by the user.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。