Looking for usage documentation? Check out Classification and KV cache.
TabPFNClassifier.list_available_models
View source model_path.
TabPFNClassifier.create_default_for_version
View source model_path.
ValueError
If version is not a known model version.
TabPFNClassifier.save_model
View source model_id_), the estimator’s hyperparameters, a classifier’s class
labels and the training-set size. No training data is included, nor
api_mode and client_options, which describe how the client talks to
the server: the loading process sets its own.
load_model() turns the record back into a fitted estimator, in a
later run or on another machine. Fitted models are only visible to the
account that created them, so the loading process has to authenticate
with the same account, and they stay usable for as long as the training
data remains on the server (see UserDataClient to delete it).
A model submit_fit() left pending is saved too, as a pending fit, so
that a later run can load it and wait_for_fit(). So is a pending
prediction, one submit_predict() started or predict() stopped
waiting for: a later run can load the model and wait_for_predict(),
for at least a day after the prediction completes, while the server
keeps its result.
NotFittedError
If the model has no fit, completed or pending.
TabPFNClassifier.load_model
View source save_model().
The estimator comes back with the saved hyperparameters and fitted
state, ready to predict() without calling fit(), and with the
default api_mode and client_options: set them on the loaded
estimator to change them. A record from tabpfn-client 0.6 that holds
api_mode loads too, without it. No request is made
here; the first predict() authenticates (like fit() would) and
raises FittedModelNotFoundError if the server no longer has the model.
A record of a fit that was still pending when it was saved comes back
pending, as submit_fit() left it: call wait_for_fit() before
predict(). A record that holds a pending prediction comes back
holding it, for wait_for_predict().
ValueError
If source is not a record written by save_model(),
holds a model of the other task (a regression model loaded into
a classifier), or has parameters this class does not accept,
for instance because a newer tabpfn-client saved it.