A Benchmark and Framework for Evaluating Next Action Predictions in Spreadsheets

Tejas Agrawal, Vu Le, Sumit Gulwani, Gust Verbruggen

TL;DR

This paper introduces the first benchmark and "online" evaluation framework for predicting the next sequence of actions in a spreadsheet. By simulating a real-world interaction loop where a user accepts or rejects AI suggestions, the authors demonstrate that fine-tuned small language models (360M parameters) can rival massive models like GPT-5 in saving users significant manual effort.

What Problem Does This Paper Address?

While software engineers have grown accustomed to the "magic" of tools like GitHub Copilot, spreadsheet users—who outnumber programmers by orders of magnitude—are still stuck clicking through menus to apply borders, formatting, and data entry.

The authors identify two major roadblocks preventing a "Copilot for Spreadsheets":

  1. Data Scarcity: Unlike code, which has millions of public Git repositories showing how a file evolved, public spreadsheets are usually "final" versions. We lack the step-by-step edit histories needed to train and test predictive models.
  2. Evaluation Complexity: Spreadsheet actions are multi-dimensional. A single "action" might involve a range (A1:C10), a property (font-weight), and a value (bold). Furthermore, if an AI suggests a block of actions and the user accepts them, the "ground truth" of what the user needs to do next changes dynamically.

Methods

The researchers developed a novel Online Evaluation framework. Instead of a static "predict the next word" test, they created a simulation loop:

  • The Loop: The system observes the user's history, predicts a sequence of actions, and a "simulated user" accepts or rejects them based on a heuristic (e.g., "Does this get me closer to my goal?").
  • Dynamic Ground Truth: If a prediction is accepted but contains a small error (like coloring the wrong cell), the framework automatically injects "undo" or "correction" steps into the future task list. This mimics the real-world cost of a "hallucinating" assistant.

To build the models, they compared three families:

  • Zero-shot LLMs: Large models (GPT-5 variants) prompted to predict actions as text.
  • Fine-tuned SLMs: Small Language Models (SmolLM2 135M/360M) trained specifically on spreadsheet action sequences.
  • Classical ML: N-grams, LSTMs, and XGBoost models.

Datasets

Because no "edit history" corpus existed, the authors created one. They took 52 high-quality public workbooks and "reverse-engineered" their creation. They used a three-stage pipeline:

  1. Symbolic Cold-start: Heuristically generating a basic path to build the sheet.
  2. LLM Refinement: Using an LLM to make those steps look more "human" (e.g., grouping formatting actions).
  3. Human Annotation: The authors manually reviewed and rewrote trajectories to ensure they felt natural.

The result is a dataset of 52 trajectories totaling 11,907 operations, covering everything from data input and merging to complex border styling and number formatting.

Key Insights and Ideas

  • Small Models Punch Above Their Weight: One of the most striking findings is that a 360M parameter model, when fine-tuned on spreadsheet data, performs nearly as well as GPT-5 (26.8% vs 27.4% actions saved). This suggests that specialized, "on-device" models could be highly effective for spreadsheet assistants.
  • Abstention is a Feature: Predicting the wrong thing is worse than predicting nothing. The "ALWAYS" baseline (which accepts every AI suggestion) actually increased the user's workload by 19% because of the effort required to fix errors. Knowing when to stay silent is critical for user trust.
  • The "Burst" Effect: Savings aren't uniform. Most of the time, the AI is wrong or silent, but when it "locks onto" a pattern (like formatting a long table), it can chain 10+ correct actions in a row. These "streaks" are where the real productivity gains happen.
  • Context Saturation: The models benefit from seeing previous actions, but only up to a point. Performance gains largely plateau after providing a history of the last 128 actions.

Key Results

The primary metric used was User Actions Saved (UAS)—the percentage reduction in manual steps needed to finish the spreadsheet.

  • Top Performer: GPT-5 with reasoning (GPT-5-R) achieved the highest UAS at 32.7%.
  • Learnability: The jump from base models to fine-tuned models (e.g., SmolLM2-360M moving from 21.7% to 26.8% UAS) proves that spreadsheet authoring follows predictable patterns that models can learn.
  • Predictability Ceiling: Using an "Oracle" experiment, the authors found that about 68% of spreadsheet actions are theoretically predictable from context, leaving plenty of room for future model improvement.

Limitations and Future Work

  • Scale: While 12,000 actions is a solid start, it is small compared to code-completion datasets. Expanding the diversity of spreadsheets (e.g., more complex financial models or scientific data) is a clear next step.
  • The "Human" in the Loop: The evaluation uses a "simulated" user. Real humans might be more or less forgiving of AI errors, or they might be distracted by frequent suggestions.
  • Triggering: The paper notes that predicting after every action is best for savings but computationally expensive. Finding the "perfect moment" to show a suggestion without being annoying remains an open UI/UX challenge.

The artifacts for this research, including the benchmark and evaluation code, are available at github.com/Tej-55/NAPE.

Summary updated

BibTeX
@inproceedings{agrawal2026benchmark,
  author = {Tejas Agrawal and Vu Le and Sumit Gulwani and Gust Verbruggen},
  title = {{A Benchmark and Framework for Evaluating Next Action Predictions in Spreadsheets}},
  booktitle = {International Conference on Machine Learning},
  year = {2026},
  url = {https://openreview.net/forum?id=NvPgRwURDC},
}
Figure