TrustSQL: Benchmarking Text-to-SQL Reliability with Penalty-Based Scoring

要約

Text-to-SQL により、ユーザーは自然言語を使用してデータベースと対話できるようになり、情報の検索と合成が簡素化されます。
自然言語の質問を SQL クエリに変換する大規模言語モデル (LLM) の目覚ましい成功にもかかわらず、2 つの主な課題により、広範な導入は依然として制限されています。
まず、text-to-SQL モデルを効果的に使用できるかどうかは、モデルの機能、つまりモデルが正しく回答できる質問の範囲をユーザーが理解しているかどうかにかかっています。
第 2 に、棄権メカニズムが存在しないと、誤った SQL 生成が気づかれずに行われる可能性があり、その結果、モデルの出力に対する信頼が損なわれる可能性があります。
より広範な展開を可能にするには、モデル設計におけるこれらの課題に対処し、モデルの評価を強化してモデルの出力に対する信頼を構築することが重要です。
この目的を達成するために、テキストから SQL への信頼性を評価するように設計された新しい包括的なベンチマークである TrustSQL を紹介します。これは、実行可能な質問に対して正しい SQL クエリを生成し、実行不可能な質問の生成を控えることによって、あらゆる種類の入力質問を正しく処理するモデルの能力として定義されます (
たとえば、スキーマの非互換性や SQL を超える機能が原因です)。
我々は、2 つのモデリング アプローチによる新しいペナルティ ベースのスコアリング メトリックを使用して既存の方法を評価します。(1) SQL ジェネレーターと実行不可能な質問検出器および棄権用の SQL エラー検出器を組み合わせたパイプライン ベースの方法。
(2) タスク全体に単一のモデルを使用する統一手法。
私たちの実験結果は、厳しいペナルティの下で高スコアを達成するには多大な努力が必要であることを明らかにし、より安全な展開のための text-to-SQL モデルの開発に関する新しい視点を提供します。

要約(オリジナル)

Text-to-SQL enables users to interact with databases using natural language, simplifying the retrieval and synthesis of information. Despite the remarkable success of large language models (LLMs) in translating natural language questions into SQL queries, widespread deployment remains limited due to two primary challenges. First, the effective use of text-to-SQL models depends on users’ understanding of the model’s capabilities-the scope of questions the model can correctly answer. Second, the absence of abstention mechanisms can lead to incorrect SQL generation going unnoticed, thereby undermining trust in the model’s output. To enable wider deployment, it is crucial to address these challenges in model design and enhance model evaluation to build trust in the model’s output. To this end, we introduce TrustSQL, a novel comprehensive benchmark designed to evaluate text-to-SQL reliability-defined as a model’s ability to correctly handle any type of input question by generating correct SQL queries for feasible questions and abstaining from generating infeasible ones (e.g., due to schema incompatibility or functionalities beyond SQL). We evaluate existing methods using a novel penalty-based scoring metric with two modeling approaches: (1) pipeline-based methods combining SQL generators with infeasible question detectors and SQL error detectors for abstention; and (2) unified methods using a single model for the entire task. Our experimental results reveal that achieving high scores under severe penalties requires significant effort and provide a new perspective on developing text-to-SQL models for safer deployment.

arxiv情報

著者 Gyubok Lee,Woosog Chay,Seonhee Cho,Edward Choi
発行日 2024-06-14 15:39:28+00:00
arxivサイト arxiv_id(pdf)

提供元, 利用サービス

arxiv.jp, Google

カテゴリー: cs.AI パーマリンク