Saved in:
Bibliographic Details
Main Authors: Qu, Ge, Li, Jinyang, Li, Bowen, Qin, Bowen, Huo, Nan, Ma, Chenhao, Cheng, Reynold
Format: Preprint
Published: 2024
Subjects:
Online Access:https://arxiv.org/abs/2405.15307
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866911885896450048
author Qu, Ge
Li, Jinyang
Li, Bowen
Qin, Bowen
Huo, Nan
Ma, Chenhao
Cheng, Reynold
author_facet Qu, Ge
Li, Jinyang
Li, Bowen
Qin, Bowen
Huo, Nan
Ma, Chenhao
Cheng, Reynold
contents Large Language Models (LLMs) driven by In-Context Learning (ICL) have significantly improved the performance of text-to-SQL. Previous methods generally employ a two-stage reasoning framework, namely 1) schema linking and 2) logical synthesis, making the framework not only effective but also interpretable. Despite these advancements, the inherent bad nature of the generalization of LLMs often results in hallucinations, which limits the full potential of LLMs. In this work, we first identify and categorize the common types of hallucinations at each stage in text-to-SQL. We then introduce a novel strategy, Task Alignment (TA), designed to mitigate hallucinations at each stage. TA encourages LLMs to take advantage of experiences from similar tasks rather than starting the tasks from scratch. This can help LLMs reduce the burden of generalization, thereby mitigating hallucinations effectively. We further propose TA-SQL, a text-to-SQL framework based on this strategy. The experimental results and comprehensive analysis demonstrate the effectiveness and robustness of our framework. Specifically, it enhances the performance of the GPT-4 baseline by 21.23% relatively on BIRD dev and it yields significant improvements across six models and four mainstream, complex text-to-SQL benchmarks.
format Preprint
id arxiv_https___arxiv_org_abs_2405_15307
institution arXiv
publishDate 2024
record_format arxiv
spellingShingle Before Generation, Align it! A Novel and Effective Strategy for Mitigating Hallucinations in Text-to-SQL Generation
Qu, Ge
Li, Jinyang
Li, Bowen
Qin, Bowen
Huo, Nan
Ma, Chenhao
Cheng, Reynold
Computation and Language
Large Language Models (LLMs) driven by In-Context Learning (ICL) have significantly improved the performance of text-to-SQL. Previous methods generally employ a two-stage reasoning framework, namely 1) schema linking and 2) logical synthesis, making the framework not only effective but also interpretable. Despite these advancements, the inherent bad nature of the generalization of LLMs often results in hallucinations, which limits the full potential of LLMs. In this work, we first identify and categorize the common types of hallucinations at each stage in text-to-SQL. We then introduce a novel strategy, Task Alignment (TA), designed to mitigate hallucinations at each stage. TA encourages LLMs to take advantage of experiences from similar tasks rather than starting the tasks from scratch. This can help LLMs reduce the burden of generalization, thereby mitigating hallucinations effectively. We further propose TA-SQL, a text-to-SQL framework based on this strategy. The experimental results and comprehensive analysis demonstrate the effectiveness and robustness of our framework. Specifically, it enhances the performance of the GPT-4 baseline by 21.23% relatively on BIRD dev and it yields significant improvements across six models and four mainstream, complex text-to-SQL benchmarks.
title Before Generation, Align it! A Novel and Effective Strategy for Mitigating Hallucinations in Text-to-SQL Generation
topic Computation and Language
url https://arxiv.org/abs/2405.15307