arXiv:2604.15646cs.CL2026-04ACL被引 1

让医生越用越准的癌症临床数据查询工具,自动学习改进。

FD-NL2SQL: Feedback-Driven Clinical NL2SQL that Improves with Use

论文配图:FD-NL2SQL: Feedback-Driven Clinical NL2SQL that Improves with Use
图 1 · 摘自论文原文
  • 用自然语言提问,系统拆解问题并检索相似专家例句生成准确SQL。
  • 医生修改结果或系统自动生成有效变体,持续扩充高质量例句库。
  • 适合临床研究者快速查询癌症试验数据,无需掌握复杂SQL语法。

临床医生在探索癌症试验数据库时,常需对生物标志物、终点、干预措施和时间等多条件进行临时查询,但编写SQL需要了解数据模式。我们演示了基于反馈驱动的临床NL2SQL助手FD-NL2SQL,适用于基于SQLite的癌症数据库。给定自然语言问题,具备模式感知能力的大型语言模型(LLM)将其分解为谓词级子问题,通过句子嵌入检索语义相似的专家验证过的NL2SQL示例,并结合分解结果、检索示例和数据模式生成可执行的SQL,最后进行有效性检查。为实现持续改进,系统引入两种更新信号:(i) 医生对生成的SQL进行编辑并确认后,加入示例库;(ii) 轻量级基于逻辑的SQL增强,通过单原子变异(如操作符或列变更)生成新版本,仅保留返回非空结果的变体。第二个LLM为被接受的变体生成对应的自然语言问题与谓词分解,无需额外标注即可自动扩展示例库。演示界面展示分解、检索、合成与执行结果,支持交互式优化与持续进化。

原文摘要 · Abstract (English)

Clinicians exploring oncology trial repositories often need ad-hoc, multi-constraint queries over biomarkers, endpoints, interventions, and time, yet writing SQL requires schema expertise. We demo FD-NL2SQL, a feedback-driven clinical NL2SQL assistant for SQLite-based oncology databases. Given a natural-language question, a schema-aware LLM decomposes it into predicate-level sub-questions, retrieves semantically similar expert-verified NL2SQL exemplars via sentence embeddings, and synthesizes executable SQL conditioned on the decomposition, retrieved exemplars, and schema, with post-processing validity checks. To improve with use, FD-NL2SQL incorporates two update signals: (i) clinician edits of generated SQL are approved and added to the exemplar bank; and (ii) lightweight logic-based SQL augmentation applies a single atomic mutation (e.g., operator or column change), retaining variants only if they return non-empty results. A second LLM generates the corresponding natural-language question and predicate decomposition for accepted variants, automatically expanding the exemplar bank without additional annotation. The demo interface exposes decomposition, retrieval, synthesis, and execution results to support interactive refinement and continuous improvement.

NL2SQL临床数据反馈学习大模型

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