arXiv:2501.16220cs.CL2025-01中稿 · 1st Workshop on Ge…被引 1

让大模型精准找到用户查询对应的数据库,提升企业数据检索效率。

DBRouting: Routing End User Queries to Databases for Answerability

  • 用自然语言查询匹配对应数据库,构建新任务与数据集。
  • 开源大模型表现优于传统嵌入方法,但受上下文长度限制。
  • 多库、同领域、无外部知识时任务更难,适合需精准数据路由的场景。

企业级数据通常分散在多个数据源中,如何为知识请求定位正确数据源是核心挑战。本文定义了将用户查询路由至对应数据库的新任务,并通过扩展现有NL-to-SQL数据集构建合成数据集。在这些数据集上,使用开源大模型(LLM)和预训练/微调嵌入向量建立基线。实验表明,开源大模型优于嵌入方法,但受限于上下文长度;嵌入方法在有数据库特定问题训练数据时,经微调后表现更优。任务难度随数据源数量增加、领域相近、缺乏外部实体解释知识以及查询模糊复杂而上升,尤其需要细粒度理解或逻辑推理。这表明需开发更先进的解决方案应对该任务。

原文摘要 · Abstract (English)

Enterprise level data is often distributed across multiple sources and identifying the correct set-of data-sources with relevant information for a knowledge request is a fundamental challenge. In this work, we define the novel task of routing an end-user query to the appropriate data-source, where the data-sources are databases. We synthesize datasets by extending existing datasets designed for NL-to-SQL semantic parsing. We create baselines on these datasets by using open-source LLMs, using both pre-trained and task specific embeddings fine-tuned using the training data. With these baselines we demonstrate that open-source LLMs perform better than embedding based approach, but suffer from token length limitations. Embedding based approaches benefit from task specific fine-tuning, more so when there is availability of data in terms of database specific questions for training. We further find that the task becomes more difficult (i) with an increase in the number of data-sources, (ii) having data-sources closer in terms of their domains,(iii) having databases without external domain knowledge required to interpret its entities and (iv) with ambiguous and complex queries requiring more fine-grained understanding of the data-sources or logical reasoning for routing to an appropriate source. This calls for the need for developing more sophisticated solutions to better address the task.

数据库路由大模型自然语言查询数据检索

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