Table of Contents
Fetching ...

Sigma: A dataset for text-to-code semantic parsing with statistical analysis

Saleh Almohaimeed, Shenyang Liu, May Alsofyani, Saad Almohaimeed, Liqiang Wang

TL;DR

The paper addresses the limitation of existing semantic parsing datasets that focus on SQL-like representations and lack robust statistical analysis capabilities. It introduces SIGMA, a cross-domain dataset with 6,000 natural-language questions over 160 databases, each paired with Python code labels that implement 44 patterns (40 statistical patterns plus 4 SQL-like patterns) and a built-in Python executor for execution-based evaluation. It evaluates three baselines—LGESQL, SLSQL, and SmBoP—with enhancements such as ELECTRA pretraining and T5-assisted decoding, finding that LGESQL with ELECTRA achieves the highest structure accuracy at 83.37%, while SmBoP with GraPPa and T5 reaches 76.38% execution accuracy. The work demonstrates the feasibility and value of text-to-code semantic parsing for statistical data exploration, offering a new benchmark and practical tools for developing models capable of cross-domain, structure-aware, and synonym-robust code generation.

Abstract

In the domain of semantic parsing, significant progress has been achieved in Text-to-SQL and question-answering tasks, both of which focus on extracting information from data sources in their native formats. However, the inherent constraints of their formal meaning representations, such as SQL programming language or basic logical forms, hinder their ability to analyze data from various perspectives, such as conducting statistical analyses. To address this limitation and inspire research in this field, we design SIGMA, a new dataset for Text-to-Code semantic parsing with statistical analysis. SIGMA comprises 6000 questions with corresponding Python code labels, spanning across 160 databases. Half of the questions involve query types, which return information in its original format, while the remaining 50% are statistical analysis questions, which perform statistical operations on the data. The Python code labels in our dataset cover 4 types of query types and 40 types of statistical analysis patterns. We evaluated the SIGMA dataset using three different baseline models: LGESQL, SmBoP, and SLSQL. The experimental results show that the LGESQL model with ELECTRA outperforms all other models, achieving 83.37% structure accuracy. In terms of execution accuracy, the SmBoP model, when combined with GraPPa and T5, reaches 76.38%.

Sigma: A dataset for text-to-code semantic parsing with statistical analysis

TL;DR

The paper addresses the limitation of existing semantic parsing datasets that focus on SQL-like representations and lack robust statistical analysis capabilities. It introduces SIGMA, a cross-domain dataset with 6,000 natural-language questions over 160 databases, each paired with Python code labels that implement 44 patterns (40 statistical patterns plus 4 SQL-like patterns) and a built-in Python executor for execution-based evaluation. It evaluates three baselines—LGESQL, SLSQL, and SmBoP—with enhancements such as ELECTRA pretraining and T5-assisted decoding, finding that LGESQL with ELECTRA achieves the highest structure accuracy at 83.37%, while SmBoP with GraPPa and T5 reaches 76.38% execution accuracy. The work demonstrates the feasibility and value of text-to-code semantic parsing for statistical data exploration, offering a new benchmark and practical tools for developing models capable of cross-domain, structure-aware, and synonym-robust code generation.

Abstract

In the domain of semantic parsing, significant progress has been achieved in Text-to-SQL and question-answering tasks, both of which focus on extracting information from data sources in their native formats. However, the inherent constraints of their formal meaning representations, such as SQL programming language or basic logical forms, hinder their ability to analyze data from various perspectives, such as conducting statistical analyses. To address this limitation and inspire research in this field, we design SIGMA, a new dataset for Text-to-Code semantic parsing with statistical analysis. SIGMA comprises 6000 questions with corresponding Python code labels, spanning across 160 databases. Half of the questions involve query types, which return information in its original format, while the remaining 50% are statistical analysis questions, which perform statistical operations on the data. The Python code labels in our dataset cover 4 types of query types and 40 types of statistical analysis patterns. We evaluated the SIGMA dataset using three different baseline models: LGESQL, SmBoP, and SLSQL. The experimental results show that the LGESQL model with ELECTRA outperforms all other models, achieving 83.37% structure accuracy. In terms of execution accuracy, the SmBoP model, when combined with GraPPa and T5, reaches 76.38%.

Paper Structure

This paper contains 21 sections, 1 figure, 3 tables.

Figures (1)

  • Figure 1: The overall architecture of our text-to-code task. The questions and the schema tables and columns are the inputs for the models, while the Python code labels are the outputs of the models. To verify the results, the Python code can be executed using the built-in Python executer and results will be presented.