ST-Raptor: LLM-Powered Semi-Structured Table Question Answering
ST-Raptor 通过使用大语言模型和基于树的结构化方法,实现了对半结构化表格的有效问答。
更新于 2025-12-29。作者:Zirui Tang、Boyu Niu、Xuanhe Zhou、Boxiu Li、Wei Zhou、Jiannan Wang、Guoliang Li、Xinyi Zhang、Fan Wu。
中文摘要
半结构化表格,广泛应用于现实世界的应用(例如,财务报告、医疗记录、交易订单),通常涉及灵活且复杂的布局(例如,分层标题和合并单元格)。这些表格通常依赖人工分析师来解释表格布局并回答相关的自然语言问题,这既昂贵又低效。为了自动化这一过程,现有方法面临着重大挑战。首先,像NL2SQL这样的方法需要将半结构化表格转换为结构化表格,这往往会导致大量信息丢失。其次,像NL2Code和多模态LLM QA这样的方法难以理解半结构化表格的复杂布局,无法准确回答相应的问题。为此,我们提出了ST-Raptor,这是一个基于树的大型语言模型半结构化表格问答框架。首先,我们引入了分层正交树(HO-Tree),这是一种结构化模型,能够捕捉复杂的半结构化表格布局,并附带一个有效的构建树算法。其次,我们定义了一组基本树操作来指导LLM执行常见的问答任务。给定一个用户问题,ST-Raptor将其分解为更简单的子问题,生成相应的树操作管道,并进行操作-表格对齐以确保准确执行管道。第三,我们引入了双阶段验证机制:正向验证检查执行步骤的正确性,而反向验证通过从预测答案重建查询来评估答案的可靠性。为了评估性能,我们提出了SSTQA,这是一个包含764个问题、覆盖102个现实世界半结构化表格的数据集。实验表明,ST-Raptor在答案准确性方面优于九个基线,最多提高了20%。代码可在https://github.com/weAIDB/ST-Raptor上找到。
英文摘要
Semi-structured tables, widely used in real-world applications (e.g., financial reports, medical records, transactional orders), often involve flexible and complex layouts (e.g., hierarchical headers and merged cells). These tables generally rely on human analysts to interpret table layouts and answer relevant natural language questions, which is costly and inefficient. To automate the procedure, existing methods face significant challenges. First, methods like NL2SQL require converting semi-structured tables into structured ones, which often causes substantial information loss. Second, methods like NL2Code and multi-modal LLM QA struggle to understand the complex layouts of semi-structured tables and cannot accurately answer corresponding questions. To this end, we propose ST-Raptor, a tree-based framework for semi-structured table question answering using large language models. First, we introduce the Hierarchical Orthogonal Tree (HO-Tree), a structural model that captures complex semi-structured table layouts, along with an effective algorithm for constructing the tree. Second, we define a set of basic tree operations to guide LLMs in executing common QA tasks. Given a user question, ST-Raptor decomposes it into simpler sub-questions, generates corresponding tree operation pipelines, and conducts operation-table alignment for accurate pipeline execution. Third, we incorporate a two-stage verification mechanism: forward validation checks the correctness of execution steps, while backward validation evaluates answer reliability by reconstructing queries from predicted answers. To benchmark the performance, we present SSTQA, a dataset of 764 questions over 102 real-world semi-structured tables. Experiments show that ST-Raptor outperforms nine baselines by up to 20% in answer accuracy. The code is available at https://github.com/weAIDB/ST-Raptor.
解读
一句话总结
ST-Raptor 通过使用大语言模型和基于树的结构化方法,实现了对半结构化表格的有效问答。
问题1:这篇论文想要解决什么具体问题?
- 问题背景:半结构化表格在现实世界中广泛应用,但通常需要人工分析师来解析表格布局并回答相关问题,这既耗时又低效。
- 现有方案不足:现有方法如 NL2SQL 和 NL2Code 需要将半结构化表格转换为结构化表格,导致信息丢失;多模态 LLM QA 和视觉语言模型在理解半结构化表格的复杂布局方面存在困难。
- 研究目标:提出 ST-Raptor,一个基于树的大语言模型框架,用于半结构化表格问答,以实现自动化和高效的问答过程。
问题2:论文的核心创新点是什么?
- 技术创新:引入了层次正交树 (HO-Tree) 模型来捕捉半结构化表格的复杂布局,并定义了一套基本的树操作来指导 LLM 执行常见的问答任务。
- 方法改进:结合视觉语言模型和启发式规则来构建 HO-Tree,并提出了基于深度优先搜索的算法;设计了问题分解方法和基于列类型的标记策略来提高数据检索准确性;引入了两阶段验证机制以确保答案的准确性和可靠性。
- 优势:与现有方法相比,ST-Raptor 在答案准确性方面提高了高达 20%,能够更好地处理半结构化表格的复杂结构和语义。
问题3:实验结果如何验证了方法的有效性?
- 关键实验:在 SSTQA 数据集上进行了实验,该数据集包含 102 个真实世界半结构化表格和 764 个问题。
- 性能提升:ST-Raptor 在答案准确性方面超过了所有基线,最高提高了 20%。
- 对比结果:与 NL2SQL、GPT-4o、DeepSeekV3、TableLLaMA、TableLLM、ReAcTable、TAT-LLM、TableLLaVA 和 mPLUG-DocOwl1.5 等基线方法相比,ST-Raptor 在三个基准测试中均取得了最佳性能。
问题4:这个研究的实际应用价值是什么?
- 应用场景:金融报告、医疗记录、交易订单等现实世界应用中的半结构化表格问答。
- 实施建议:结合 ST-Raptor 和其他相关技术,可以开发出自动化问答系统,提高工作效率和数据准确性。
- 局限与展望:ST-Raptor 在处理复杂布局和大数据量表格时可能存在性能瓶颈;未来可以探索更先进的模型和算法来进一步提高性能和泛化能力。