LOB-Bench: Benchmarking Generative AI for Finance - an Application to Limit Order Book Data

Peer Nagy, Sascha Frey, Kang Li, Bidipta Sarkar, Svitlana Vyetrenko, Stefan Zohren, Ani Calinescu, Jakob N. Foerster · OpenReview

Abstract

While financial data presents one of the most challenging and interesting sequence modelling tasks due to high noise, heavy tails, and strategic interactions, progress in this area has been hindered by the lack of consensus on quantitative evaluation paradigms. To address this, we present LOB-Bench, a benchmark, implemented in python, designed to evaluate the quality and realism of generative message-by-order data for limit order books (LOB) in the LOBSTER format. Our framework measures distributional differences in conditional and unconditional statistics between generated and real LOB data, supporting flexible multivariate statistical evaluation. The benchmark also includes features commonly used LOB statistics such as spread, order book volumes, order imbalance, and message inter-arrival times, along with scores from a trained discriminator network. Lastly, LOB-Bench contains "market impact metrics", i.e. the cross-correlations and price response functions for specific events in the data. We benchmark generative autoregressive state-space models, a (C)GAN, as well as a parametric LOB model and find that the autoregressive GenAI approach beats traditional model classes.

Introduction

In the world of high-frequency finance, the Limit Order Book (LOB) is the ultimate record of supply and demand. Generating realistic synthetic LOB data is a "holy grail" for researchers because it allows for testing trading algorithms and market designs without risking real capital. However, evaluating these generative models is notoriously difficult. Financial data is characterized by extreme noise, heavy tails (rare but massive events), and strategic agent interactions. Historically, researchers relied on "stylized facts"—qualitative checks to see if a model's output looks like real market behavior. Furthermore, standard machine learning metrics like cross-entropy only measure how well a model predicts the next step, failing to capture how small errors compound and cause the model to "derail" during long-term autonomous generation.

Methodology

LOB-Bench introduces a multi-layered quantitative approach to evaluation. The framework uses "aggregator functions" to project high-dimensional LOB data into one-dimensional subspaces (like bid-ask spread or order imbalance). It then calculates the $L_1$ and Wasserstein-1 distances between the real and generated distributions.

The LOB-Bench framework projects high-dimensional sequences into 1D subspaces for distributional and conditional evaluation.

To ensure models capture dynamic relationships, LOB-Bench evaluates statistics conditioned on other variables—for example, checking if the distribution of ask volume correctly shifts based on the current spread. It also measures "market impact" through response functions, testing if a model understands the causal "physics" of the market. Finally, the authors train a dedicated discriminator (a CNN-Attention hybrid) to distinguish between real and synthetic trajectories. This serves as a "worst-case" metric: if a discriminator can easily spot the fake data, the model hasn't truly captured the underlying data distribution.

Experimental Setup

The benchmark utilizes data in the widely used LOBSTER format, focusing on Alphabet Inc. (GOOG) and Intel Corporation (INTC) stock data from 2022 and 2023. Several model classes were benchmarked: LOBS5 (an autoregressive state-space model), (C)GANs, RWKV (4 and 6), and a traditional parametric stochastic baseline.

Results and Discussion

The benchmarking results reveal that modern autoregressive GenAI approaches, specifically LOBS5, significantly outperform traditional parametric models and GANs in reproducing complex market impact curves and distributional statistics.

Quantitative comparison of L1 and Wasserstein distances for INTC and GOOG, highlighting the superior performance of the LOBS5 model.

Key insights from the evaluation include:

  • The Autoregressive Trap: The study quantifies "model derailment," where a model's performance degrades the further it predicts into the future. Even models that look perfect on a "next-token" basis can collapse into unrealistic states after a few hundred messages.
  • LOBS5 Dominance: The LOBS5 model achieved the lowest overall error scores across both $L_1$ and Wasserstein metrics for GOOG and INTC. It was also the only model able to faithfully reproduce expected response functions for small-tick stocks like GOOG.
  • Discriminators as the Ultimate Bar: Even when a model's basic statistics matched the real data, the trained discriminator could often still identify synthetic data with high accuracy (ROC of 0.83 for GOOG). This suggests that GenAI models are still missing subtle, higher-order correlations present in real markets.
  • Tokenization Matters: The RWKV models, which use standard byte-pair encoding, struggled more than LOBS5, suggesting that the specific way we "tokenize" financial messages is critical for model performance.

Conclusion and Future Work

While LOB-Bench provides a rigorous framework for evaluation, historical data cannot truly tell us how a market would react to a novel strategy (the "counterfactual" problem). Future work will focus on scaling models beyond 35 million parameters to address the derailment issue, training discriminators on "noisy" real data to create more nuanced realism scores, and extending the benchmark to handle correlations between different stocks or asset classes.

Summary updated

Abstract

While financial data presents one of the most challenging and interesting sequence modelling tasks due to high noise, heavy tails, and strategic interactions, progress in this area has been hindered by the lack of consensus on quantitative evaluation paradigms. To address this, we present LOB-Bench, a benchmark, implemented in python, designed to evaluate the quality and realism of generative message-by-order data for limit order books (LOB) in the LOBSTER format. Our framework measures distributional differences in conditional and unconditional statistics between generated and real LOB data, supporting flexible multivariate statistical evaluation. The benchmark also includes features commonly used LOB statistics such as spread, order book volumes, order imbalance, and message inter-arrival times, along with scores from a trained discriminator network. Lastly, LOB-Bench contains "market impact metrics", i.e. the cross-correlations and price response functions for specific events in the data. We benchmark generative autoregressive state-space models, a (C)GAN, as well as a parametric LOB model and find that the autoregressive GenAI approach beats traditional model classes.
BibTeX
@inproceedings{nagy2025lob,
  author = {Peer Nagy and Sascha Frey and Kang Li and Bidipta Sarkar and Svitlana Vyetrenko and Stefan Zohren and Ani Calinescu and Jakob N. Foerster},
  title = {{LOB-Bench: Benchmarking Generative AI for Finance - an Application to Limit Order Book Data}},
  booktitle = {International Conference on Machine Learning},
  year = {2025},
  url = {https://openreview.net/forum?id=CXPpYJpYXQ},
}
Figure