Skip to main content
ByEliott Kalfon

TabPFN Quickstart

Use TabPFN’s pretrained model with scikit-learn’s fit / predict workflow. Start with the hosted API; try local inference at the end. TabPFN pretraining on synthetic datasets and prediction on unseen data

Setup

Install the client, local package, and example dependencies.

Authenticate

Sign in at Prior Labs, accept the license, and copy your API key into a Colab secret named TABPFN_TOKEN. Enable notebook access to that secret.

Classification

Split the German credit dataset, then evaluate held-out predictions with ROC AUC and accuracy. fit supplies context to the pretrained model without updating its weights.

Regression

Predict diabetes progression and report mean squared error, mean absolute error, and R².

Run locally

Switch the import to tabpfn to run inference on your machine. The first use downloads model weights; a GPU is recommended for this example.