arXiv:2608.13384cs.IRcs.DB2026-08

让无结构文档像数据库一样被精准查询,提升企业数据处理效率。

Structure then Query: Enabling Precise Analytical Queries over Unstructured Documents

论文配图:Structure then Query: Enabling Precise Analytical Queries over Unstructured Documents
图 1 · 摘自论文原文
  • 先构建分层注释索引,将杂乱文本转为可快速检索的结构化数据。
  • 在三个真实数据集上平均准确率达0.87,复杂多跳查询表现最优。
  • 适合需要高精度分析的企业级文档系统,尤其擅长推理类任务。

无结构文档占企业与网络数据的绝大多数。随着大语言模型(LLMs)的发展,研究者开始尝试将文本分析如数据库操作般进行。然而,主流检索方法仍依赖基于向量相似性的模糊匹配,难以实现精确信息获取与结构化分析。为此,AnnoIndex提出两个核心组件:一是注释索引(Annotation Index),通过SchemaLoop模块从原始语料自动生成分层注释模式,并用轻量级语言模型提取具体值,将分散的非结构化文本转化为可物化的结构化索引,避免向量相似性黑箱匹配,并将属性提取成本摊销至一次性构建阶段;二是结构化查询引擎,将用户问题编译为基于SQL扩展的执行计划,优先使用注释索引进行精确文档过滤,再按成本升序逐步应用提取操作,仅对极小部分需深度语义理解的文档调用LLM。提取结果回填至注释索引,降低未来查询成本。在三个真实数据集上的实验表明,AnnoIndex持续优于最先进基线,平均F1得分为0.87,且在复杂多跳连接与渐进式推理查询中保持稳健性能。

原文摘要 · Abstract (English)

Unstructured documents constitute the majority of enterprise and web data. With the rapid development of large language models(LLMs), researchers have started to build data systems that analyze unstructured textual documents like operating on databases. However, because mainstream retrieval methods still relies on fuzzy matching based on vector similarity, accurately obtaining information and performing structured analysis and reasoning remains a major challenge. To address these limitations, AnnoIndex introduces two core fundamental components. The first is Annotation Index. The system uses a module called SchemaLoop to automatically create hierarchical annotation schemas from the raw corpus, and then uses lightweight language model to extract specific values. It turns scattered unstructured text into a materialized, structured index that enables low-cost filtering and querying. The annotation index avoids the black-box matching of vector similarity and amortizes attribute extraction costs from online queries to a one-time build. The second innovation is a Structured Query Engine. It compiles user questions into execution plans based on SQL extension. It first uses the Annotation Index for precise documents filtering, then gradually applies extraction operations in ascending order of cost, resorting to LLMs only for the remaining minimal fraction of the corpus that require deep semantic understanding. The extracted attributions are merged into the annotation index, reducing the cost of future queries. Experiments on three real-world datasets demonstrate that AnnoIndex consistently outperforms state-of-the-art baselines, achieving the highest average F1 score (0.87) while maintaining robust performance on complex multi-hop join and progressive reasoning queries.

文档分析结构化查询大模型应用数据系统

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。