A Benchmark and Framework for Evaluating Next Action Predictions in Spreadsheets
Tejas Agrawal 1 Vu Le 2 Sumit Gulwani 2 Gust Verbruggen 3 predict(history, state)
arXiv:2606.13802v1 [cs.SE] 11 Jun 2026
Abstract 1
Predictive code completion greatly accelerates how quickly developers work. In spreadsheets, despite being much more common, such autocompletion features are virtually non-existent. To address this gap, we introduce a benchmark for systems that observe a sequence of user actions in a spreadsheet and predict future actions. Two challenges are (1) the absence of edit histories in public spreadsheet corpora and (2) the complex space of spreadsheet actions (spatial, temporal, composite). To address (1), we manually curate 52 sequences of 12K actions that recreate spreadsheets from public corpora, seeded by parametrized heuristics and LLM refinement. To address (2), we propose an online evaluation that expects a prediction after each user action, accepts or rejects that prediction, updates the future actions upon acceptance, and repeats this until the target spreadsheet is obtained. We use multiple baseline predictors (including zero-shot LLMs, fine-tuned SLMs, and classical models) and analyze different properties that our benchmark teaches us, including but not limited to: properties of saved actions and false positives, efficiency, effect of user profiles, effect of triggers, and effect of context.
History and current state
3
font(B2:D4, bold, true) border(B2:D2, top, thick)
2
Future and target state border(B2:D2, bottom, thick) border(B4:D4, bottom, thick) fill(C3:D3, green)
Predicted actions and state border(B2:D2, bottom, thick) border(B4:D4, bottom, thick) fill(C3:C4, green)
Precision: 7/8 Saved: 1
4
New future (accept) fill(D3, green) fill(C4, empty)
5
New future (reject) border(B4:D4, bottom, thick) fill(C3:D3, green)
Figure 1. One step of the online evaluation on a synthetic example. ⃝ 1 The history (so far) produces the current state. ⃝ 2 The remain3 Given the ing future actions would produce the target state. ⃝ history and current state, the system predicts three actions: two borders that match the future, and a fill that targets the wrong cell. At the (cell, property) level this gives precision 7/8; if accepted, the user would save one action overall (see below). The system 4 accepts or ⃝ 5 rejects the prediction. On accept, then either ⃝ the future is updated to remove operations the prediction already satisfied (the two borders) and a new fill(C4, empty) is prepended to undo the wrongly-coloured cell, leaving two actions instead of three. On reject, the future is unchanged and evaluation continues with the next user step.
1. Introduction
tem observes the user performing a sequence of these lowlevel actions and then suggests the next actions to speed up the spreadsheet authoring process. This work thus bridges the gap between two emerging areas: code auto-completion and the rapid rise in developer productivity, and spreadsheet productivity and the rise of agents for spreadsheet authoring.
Creating visually interesting spreadsheets requires typically hundreds of simple UI actions like selecting relevant ranges and clicking buttons to enter data or apply formatting. We introduce the first benchmarking dataset and framework for predictive auto-completion in spreadsheets, where the sys-
Code auto-completion has drastically evolved in recent years. Early symbolic systems would observe users making changes and use small programs to suggest repetitive edits to the rest of the file, like Blue-Pencil (Miltner et al., 2019). With the rise of transformers architectures, full lines of code could now be suggested from potentially noisy existing code (Svyatkovskiy et al., 2020). As models became more pow-
1 Microsoft, Bangalore, India 2 Microsoft, Redmond, USA Microsoft, Keerbergen, Belgium. Correspondence to: Tejas Agrawal <[email protected]>, Gust Verbruggen <[email protected]>. 3
Proceedings of the 43 rd International Conference on Machine Learning, Seoul, South Korea. PMLR 306, 2026. Copyright 2026 by the author(s).
1
Evaluating Next Action Prediction Systems for Spreadsheets
erful, so would their suggestions: modern coding assistants can suggest multiple functions in a pure auto-completion setting (Mastropaolo et al., 2023).
at fixed time steps: (1) suggestions change the state that the model (and user) continues from, so errors can compound and later predictions depend on earlier ones; (2) the model cannot re-suggest the same easy actions and still appear accurate under stepwise scoring; and (3) the system is tested on revising or repairing its own prior suggestions. Example 1. An example of a single iteration is shown in Figure 1. In this hypothetical prediction, the two border actions are correct and the fill is partially correct, for a total (per-cell) precision of 7/8. Because one correction operation is added to the new future to remove the wrong fill, the user saves one action.
In spreadsheets, early assistants would auto-complete columns that could be derived from other columns, most notably FlashFill (Gulwani, 2011; Cambronero et al., 2023). Other assistants suggest formulas after the user explicitly signals the intent that they want a formula (Chen et al., 2021). Because of the complex interaction surface of spreadsheets, two dimensions of cells with stylistic properties, spreadsheet suggestions are constrained to very specific scenarios. More recently, the main focus for spreadsheet suggestions are agents that solve problems based on natural language intent (Ma et al., 2024; Li et al., 2023). For routine edits and repetitive patterns, the effort of invoking the assistive tool, formulating prompts, and waiting for responses exceeds the cost of direct manipulation, leading users to default to manual editing (Vaithilingam et al., 2022; Liang et al., 2025).
Our framework then computes different metrics at different levels (per simulation, per prediction, per action) that allow targeted improvement of action prediction systems. We use multiple solvers as baseline prediction systems (such as zeroshot LLMs, finetuned SLMs, and some classical machine learning models) to highlight what we can learn using these metrics. For example, more powerful models save more actions than weaker models (33% on GPT-5 with reasoning versus 18% on GPT-5 mini) and fine-tuned 360M-parameter models match GPT-5 (both at 27%). This indicates that the task is learnable. Low-precision acceptance heuristics yield negative savings (−19%), confirming that abstention based on net user benefit is crucial. Being able to predict at each action saves more actions (27%) than after every four actions (17%), indicating that good triggers or cheaper models are worth investigating. Section 5 describes many more insights.
To the best of our knowledge, there is no work on generalized action suggestions for spreadsheets. One potential reason is that evaluating predictive assistants in spreadsheets is challenging for various reasons. First, as opposed to detailed version histories for code, there only exist very high-level corpora of spreadsheets as they evolve over time (Dou et al., 2016). Second, whereas each individual action (like coloring a cell or adding a border) is simple, different actions happen at (and affect) different parts of the spreadsheet in potentially many different orders, without a clear trigger of when to make a prediction. A potential solution is teacher-forced offline evaluation, where the system is always given the correct next state and each prediction is checked independently against a fixed target.
In summary, we make the following contributions • Benchmark dataset. We curate a dataset of 52 spreadsheet creation trajectories totaling 11,907 operations, each one validated by humans.
We address the first challenge by manually curating sequences of user actions from static workbooks, using a combination of heuristics and large language models for heuristic seeding to motivate diversity. Our dataset consists of 52 high-quality trajectories of workbooks being created from start to finish, each having between 35 and 821 steps with an average of 229 steps, for 11,907 steps in total.
• Online evaluation. We propose an evaluation framework that evaluates systems end-to-end by modeling user acceptance behavior, dynamically adapting ground-truth trajectories after predictions, and computing metrics that capture real-world utility.
We address the second challenge by proposing an online evaluation, instead of a static “given x, predict y”. At each iteration, the system to be evaluated is given the past n actions and predicts a sequence of zero or more actions. Based on properties of the prediction, that prediction is either accepted or rejected. If accepted, the sequence of future actions is updated, for example, to remove successful actions and add actions that undo wrong moves. If rejected, the next user action is added to the history and the next iteration starts with n+1 actions. This procedure is repeated until either there are no actions left to do (final spreadsheet obtained) or a threshold is reached. Our online evaluation has three advantages over a teacher-forced offline evaluation
• Design insights. We demonstrate our dataset and framework using baselines to show how these metrics allow targeted improvement of predictive assistants for spreadsheets. and release artifacts at www.github.com/Tej-55/NAPE.
2. Benchmarks Each benchmark consists of a sequence of parametrized actions that a user takes to build a final workbook from scratch. Table 1 lists the supported actions. 2
Evaluating Next Action Prediction Systems for Spreadsheets
input(d, v) merge(d) format(d, f) fill(d, c) font(d, p, v) border(d, s, v) align(d, t, v) paste(d, s, m) autofill(d, s)
Explanation Enter v (value or matrix) at location d. Merge range d. Set number format f at range d. Set background fill color c at range d. Set font property p ∈ {bold, italic, size, color, underline, name} to v at d. Set border on side s ∈ {left, right, top, bottom, outside, all} to style v at d. Set text property t ∈ {horizontal, vertical, orientation, wrap} to v at d. Paste m ∈ {style, value, both} from s to d. Auto-fill range d from source s.