[论文解读] Language Models Enable Simple Systems for Generating Structured Views of Heterogeneous Data Lakes
论文提出 Evaporate,一种原型系统,利用大语言模型从异构数据湖中生成结构化视图,比较直接提取、代码合成,以及以弱监督集成实现高质量、低成本且文档处理呈现次线性性能。
A long standing goal of the data management community is to develop general, automated systems that ingest semi-structured documents and output queryable tables without human effort or domain specific customization. Given the sheer variety of potential documents, state-of-the art systems make simplifying assumptions and use domain specific training. In this work, we ask whether we can maintain generality by using large language models (LLMs). LLMs, which are pretrained on broad data, can perform diverse downstream tasks simply conditioned on natural language task descriptions. We propose and evaluate EVAPORATE, a simple, prototype system powered by LLMs. We identify two fundamentally different strategies for implementing this system: prompt the LLM to directly extract values from documents or prompt the LLM to synthesize code that performs the extraction. Our evaluations show a cost-quality tradeoff between these two approaches. Code synthesis is cheap, but far less accurate than directly processing each document with the LLM. To improve quality while maintaining low cost, we propose an extended code synthesis implementation, EVAPORATE-CODE+, which achieves better quality than direct extraction. Our key insight is to generate many candidate functions and ensemble their extractions using weak supervision. EVAPORATE-CODE+ not only outperforms the state-of-the art systems, but does so using a sublinear pass over the documents with the LLM. This equates to a 110x reduction in the number of tokens the LLM needs to process, averaged across 16 real-world evaluation settings of 10k documents each.
研究动机与目标
- 证明通用的LLM在不进行领域专门训练的情况下,能够从多样的半结构化文档中生成结构化视图。
- 比较构建这些视图的两种实现策略(直接提取 vs. 代码合成)。
- 引入 Evaporate-Code+,通过对大量合成函数的弱监督来提高提取质量。
- 量化跨多个数据集和模型的成本-质量权衡和可扩展性。
提出的方法
- 定义一个形式化任务:输入一组半结构化文档,输出具有属性及每篇文档记录的表格。
- 在16个真实世界场景中评估 Evaporate-Direct(LLM 直接提取数值)与 Evaporate-Code(LLM 合成可重复使用的提取代码)。
- 展示 Evaporate-Code+ 通过大量候选函数和弱监督来进行集合提取并提高准确性。
- 对属性定义进行小样本的模式合成,并生成大量候选提取函数,然后用定制的弱监督算法进行聚合。
- 通过将模式发现与对整套文档集的提取解耦,展示次线性LLM处理性能。
- 使用来自三家LLM提供商的四个模型来评估性能,以证实鲁棒性。

实验结果
研究问题
- RQ1一个通用、以提示驱动的LLM系统是否能够在不进行领域专门训练的情况下,从异质文档生成结构化视图?
- RQ2直接提取与代码合成这两种方法在该任务上的成本与质量权衡是什么?
- RQ3在大量合成函数上的弱监督集成是否能在保持低成本的同时提升提取质量?
- RQ4在不同的LLM提供商和文档类型之间,结果的鲁棒性如何?
主要发现
- Evaporate-Direct 在某些场景下能够达到竞争性质量,但由于对数据湖规模的线性Token处理,扩展性较差。
- Evaporate-Code 通过对小样本文档进行模式定义并合成提取函数,实现了次线性成本,但初始质量低于直接提取。
- Evaporate-Code+ 通过弱监督在各场景的平均对F1分数达到67.5,相较 Evaporate-Direct 提升12.1点。
- Evaporate-Code+ 相较于 Evaporate-Direct,在预定义模式下提取性能平均提升22%。
- 在每个数据湖的10k文档上,该方法将LLM处理的Token数量减少约110倍。
- 结果在来自三家LLM提供商的四个模型上得到验证,Evaporate-Direct 与 Evaporate-Code+ 的相对质量保持一致的趋势。

阅读本论文
在 Nubint 阅读器中打开原文,边读边就任意段落提问。
在 Nubint 中阅读本论文本解读由 AI 根据论文原文生成,引用前请核对原文。