On Finetuning Tabular Foundation Models

Ivan Rubachev, Akim Kotelnikov, Nikolay Kartashev, Artem Babenko · DOI

Introduction

Deep learning (DL) has revolutionized computer vision and natural language processing, yet tabular data—the backbone of most industrial applications—remains dominated by "shallow" gradient-boosted decision trees (GBDTs) like XGBoost. Recently, Tabular Foundation Models (TFMs) such as TabPFN and its successor, TabPFNv2, have emerged as a promising alternative. These models leverage In-Context Learning (ICL), where a Transformer-based architecture makes predictions by processing a "prompt" containing the training data and the test sample in a single forward pass, without updating any weights.

While ICL is powerful for small-scale datasets, it lacks the ability to adapt to the specific nuances of a target domain. In other domains, finetuning is the standard for adaptation. This paper investigates how to effectively finetune tabular foundation models and explores the underlying mechanisms that drive performance improvements when these models move beyond zero-shot ICL.

Adaptation Strategies for TabPFNv2

The researchers evaluated several strategies to adapt TabPFNv2 to new datasets:

  1. Full Finetuning: Updating all 7 million parameters of the model.
  2. Parameter-Efficient Finetuning (PEFT): Utilizing methods like LoRA (Low-Rank Adaptation) or restricting updates to specific components such as LayerNorm, the prediction head, or the final layers.
  3. Numerical Feature Embeddings: Integrating specialized modules to better represent numerical features before they enter the Transformer backbone.

A key finding was that full finetuning is not only the most effective method but also surprisingly efficient, often converging faster than PEFT methods like LoRA. This contradicts some earlier assumptions that partial finetuning might be necessary to prevent overfitting on small tabular datasets.

Performance Benchmarks

The study benchmarked these strategies against a wide array of datasets, including standard academic benchmarks and the more challenging TabReD (Tabular Real-world Datasets) suite, which features temporal shifts and complex feature interactions.

Comparison of adaptation strategies and baselines. Full finetuning (Full FT) and its ensemble (Full FT x5) achieve superior relative improvement over the MLP baseline compared to XGBoost and other DL methods.

As shown in the results, finetuned TabPFNv2 achieves state-of-the-art performance on small-to-medium datasets (up to ~50,000 rows). Notably, ensembling five finetuned models (Full FT x5) provides a significant boost, outperforming both tuned GBDTs and specialized tabular DL architectures like MLP-PLR.

Mechanistic Insights: Attention as Retrieval

Beyond empirical performance, the paper provides a deep dive into why finetuning works for these models. The authors frame TabPFNv2's attention mechanism as a form of retrieval. In this view, the model calculates dot products between "query" representations (test samples) and "key" representations (training samples) to determine which training points should influence the prediction.

Distribution of normalized entropy of attention scores before and after finetuning. Finetuning consistently shifts the distribution toward lower entropy, indicating more concentrated attention on relevant samples.

The analysis reveals that finetuning significantly reduces the entropy of these attention scores. Before finetuning, the model's attention is relatively diffuse. After adaptation, the attention becomes "concentrated" on a smaller subset of highly relevant training samples. Essentially, finetuning refines the model's internal similarity metric, making it a more precise "weighted k-Nearest Neighbor" classifier that aligns its internal representations with the actual target label similarities of the dataset.

Discussion and Limitations

While finetuning establishes TabPFNv2 as a top-tier performer for I.I.D. (Independent and Identically Distributed) data, challenges remain. The model's performance is less stable on datasets with significant temporal shifts—where the data distribution changes over time—compared to some traditional DL baselines.

Furthermore, scalability is a constraint. The current architecture's memory requirements limit finetuning to datasets with roughly 1 million total cells (e.g., 50,000 rows with 20 features) on standard 80GB GPUs. Future work is needed to develop more memory-efficient adaptation techniques and to improve robustness against non-stationary data distributions.

Conclusion

This research demonstrates that full finetuning is the optimal path for adapting tabular foundation models. By refining the model's internal retrieval logic and concentrating its attention on relevant samples, finetuning allows TabPFNv2 to surpass traditional GBDTs on a wide range of tasks, marking a significant step forward for deep learning in the tabular domain.

Summary updated

BibTeX
@misc{rubachev2025finetuning,
  author = {Ivan Rubachev and Akim Kotelnikov and Nikolay Kartashev and Artem Babenko},
  title = {{On Finetuning Tabular Foundation Models}},
  year = {2025},
  eprint = {2506.08982},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2506.08982},
}
Figure