arXiv(opens in a new tab)cs.AISep 2026Cited by 1 paper on PaperVantage

Manuscript Offprint

arXiv:2609.01982

Benchmarking Language Models for Statistical Problem Formulation

Chen Wang, Junzhe Zhao, Xin Cong, Wanlu Deng, Ke Deng

Abstract

Large language models (LLMs) are increasingly used as assistants for statistical and data science work, yet existing evaluations largely assume the analysis target is already specified. In practice, users arrive with informal goals and heterogeneous data, leaving the model to decide what statistical task is implied and which data are relevant. We first formalize this upstream step as Statistical Problem Formulation and decompose it into two subtasks: (1) Statistical Problem Classification and (2) Variable Identification & Role Assignment. We then introduce STAT-FORMBENCH, a benchmark built from five cross-domain statistics textbooks and a data science case library, covering diverse problem types, data representations, and scenario styles. It contains 1,013 samples spanning 20 coarse-grained and 85 fine-grained statistical problem categories. Across 14 open- and closed-source LLMs, the best zero-shot models reach only 72.0 fine-grained classification accuracy and 63.2 variable set overlap. No model performs consistently best across the two subtasks, while enhanced prompting strategies yield only limited or inconsistent gains. We release the benchmark data on Hugging Face at https://huggingface.co/datasets/THU-CongLab/StatFormBench and the evaluation code on GitHub at https://github.com/THU-CongLab/StatFormBench.

1 Introduction

Large language models (LLMs) are increasingly expected to serve as general-purpose assistants for data science and statistical analysis work, helping users inspect datasets, choose analyses, and answer questions grounded in data (Huang et al., 2024; Zhang et al., 2025; Chen et al., 2025). Much of this work assumes that the analysis target has already been made explicit, for example by specifying a prediction task, a hypothesis test, or a modeling objective (Lu et al., 2026; Liu et al., 2024; Huang et al., 2024; Zhang et al., 2025). In practice, however, users often begin with informal goals rather than formal analysis specifications. As illustrated in Figure 1, even a simple practical request may require the model to distinguish the intended hypothesis test from a superficially plausible prediction task. It also needs to determine which data objects are required for that test, rather than treating all available fields as relevant. These implicit choices determine whether the subsequent analysis is statistically valid. We refer to this upstream specification step as statistical problem formulation.

We define Statistical Problem Formulation as the task of mapping an informal, natural-language analysis request to (i) the type of statistical problem it implies and (ii) the relevant data objects together with their analytical roles. These two components correspond to two closely connected decisions. The first, Statistical Problem Classification, determines what type of statistical task a scenario calls for, such as comparing group means, examining associations between variables, or predicting future outcomes. The second, Variable Identification and Role Assignment, determines which data objects are relevant to the task and what analytical role each object plays, such as an independent variable or a dependent variable. Once these decisions have been made, the subsequent choice of statistical methods becomes more constrained. By contrast, formulation itself often depends on interpreting the user's intent, the available data, and the surrounding domain context. Whether LLMs can reliably perform this step remains largely unexplored.

Recent benchmarks have examined LLMs in statistics and data science, covering statistical knowledge and reasoning (Lu et al., 2026; Liu et al., 2024; Su et al., 2025) as well as data science execution (Huang et al., 2024; Zhang et al., 2025; Chen

∗^{*} Equal contribution.

†^{\dagger} Corresponding author.

Figure

Figure 1: Overview of statistical problem formulation. Given a scenario with heterogeneous data, the model must classify the statistical problem type and extract the relevant variables with their roles.

et al., 2025). These studies provide useful evidence about whether LLMs can reason with statistical concepts or carry out specified analyses, but they generally assume that the analysis target is already given or strongly implied. As a result, they do not directly test whether a model can first formulate the statistical task from an informal real-world request.

Evaluating this capability is challenging because formulation differs from standard question answering or task execution in several ways. First, the input is often not written in statistical language: users may describe practical goals with ambiguity, domain-specific wording, and distracting contextual details. Second, the relevant data may be represented in heterogeneous forms, including raw tabular variables, summary statistics such as means and standard deviations, contingency tables, and other structured or semi-structured objects. Third, the target label space is broad and weakly delimited. Deciding whether a scenario calls for comparison, association analysis, prediction, reliability assessment, or another statistical task requires jointly interpreting the user's objective, the data structure, and the domain context. The same problem-level understanding is also needed to separate relevant variables from incidental information and to assign their analytical roles.

To this end, we introduce STATFORMBENCH, a benchmark for statistical problem formulation in realistic, unstructured settings. STATFORMBENCH operationalizes formulation through two

tasks aligned with the decisions above. Statistical Problem Classification asks a model to identify the statistical problem type expressed by a scenario, and Variable Identification & Role Assignment asks it to identify the data objects relevant to the task and assign their analytical roles. The benchmark is constructed from statistics textbook exercises across applied domains and a data science case library reflecting diverse business scenarios, allowing us to cover both controlled pedagogical problems and more open-ended real-world analysis requests. Each sample is built through a unified pipeline that extracts raw triples of question, answer, and data, splits multi-part problems into individual instances, filters for quality, and annotates problem types and variable roles. The problem descriptions are then rewritten into realistic scenario-style language. We evaluate 14 open-source and proprietary LLMs. The best zero-shot fine-grained classification accuracy is 72.0, while the highest variable set overlap is 63.2, with the two results achieved by different models. Fine-grained analysis further shows that performance varies substantially across problem categories and data sources, while standard prompting strategies yield limited and inconsistent gains.

Our contributions are as follows: (1) we are the first to study statistical problem formulation as an evaluation problem for LLMs, decomposing it into statistical problem classification and variable identification & role assignment; (2) we construct the

STATFORMBENCH benchmark covering diverse statistical problem types, data representations, and scenario styles, with samples derived from both textbooks and real-world data science cases; (3) we evaluate 14 open-source and proprietary LLMs, showing that no model performs consistently best across formulation tasks and that current models still struggle to map informal requests to precise statistical formulations regardless of the prompting strategy used.

References (6)

  • suggested_category
  • Exclude model parameters and test statistics (z, p, t, F)
  • When the answer constructs a derived variable from multiple originals, retain all originals and omit the derived one
  • Mathematical Calculation
  • If no variables are needed, output empty JSON
  • : true/false