> ## Documentation Index
> Fetch the complete documentation index at: https://docs.priorlabs.ai/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> TabPFN-3 and later versions support up to 1,000,000 rows, subject to feature count and checkpoint/API limits.
> For large datasets, use per-estimator subsampling, e.g. inference_config={"SUBSAMPLE_SAMPLES": 100_000}, in TabPFNClassifier or TabPFNRegressor from tabpfn or tabpfn_client.
> Pass raw pandas DataFrames to fit and predict. Categorical strings/categories, raw text, and missing feature values are handled automatically; no manual integer/one-hot encoding, imputation, scaling, or outlier removal is needed.

# Fitting and prediction

> Fit the model.

> [!NOTE]
>
> Looking for usage documentation? Check out [Regression](https://docs.priorlabs.ai/capabilities/regression.md).

## `TabPFNRegressor.fit`

[ View source ](https://github.com/PriorLabs/TabPFN/blob/f02b3b5941717472eafd078c15ae2043676b3fcf/src/tabpfn/regressor.py#L1298)

Fit the model.

```python theme={null}
TabPFNRegressor.fit(
    X: XType,
    y: YType,
) -> Self
```

> [accordion] Type aliases
>
> ```python theme={null}
> XType = Any
> YType = Any
> ```

**Parameters**

| Parameter | Type | Default | Description |
| - | - | - | - |
| `X` | `XType` | Required | The input data. |
| `y` | `YType` | Required | The target variable. |

**Returns**

| Type | Description |
| - | - |
| `Self` | self |

***

## `TabPFNRegressor.predict`

[ View source ](https://github.com/PriorLabs/TabPFN/blob/f02b3b5941717472eafd078c15ae2043676b3fcf/src/tabpfn/regressor.py#L1424)

Runs the forward() method and then transform the logits
from the binning space in order to predict target variable.

```python theme={null}
TabPFNRegressor.predict(
    X: XType,
    *,
    output_type: OutputType = "mean",
    quantiles: list[float] | None = None,
) -> RegressionResultType
```

> [accordion] Overloaded signatures
>
> ```python theme={null}
> TabPFNRegressor.predict(
>     X: XType,
>     *,
>     output_type: Literal["mean", "median", "mode"] = "mean",
>     quantiles: list[float] | None = None,
> ) -> np.ndarray
> ```
>
> ```python theme={null}
> TabPFNRegressor.predict(
>     X: XType,
>     *,
>     output_type: Literal["quantiles"],
>     quantiles: list[float] | None = None,
> ) -> list[np.ndarray]
> ```
>
> ```python theme={null}
> TabPFNRegressor.predict(
>     X: XType,
>     *,
>     output_type: Literal["main"],
>     quantiles: list[float] | None = None,
> ) -> MainOutputDict
> ```
>
> ```python theme={null}
> TabPFNRegressor.predict(
>     X: XType,
>     *,
>     output_type: Literal["full"],
>     quantiles: list[float] | None = None,
> ) -> FullOutputDict
> ```

> [accordion] Type aliases
>
> ```python theme={null}
> XType = Any
> OutputType = Literal["mean", "median", "mode", "quantiles", "full", "main"]
> RegressionResultType = np.ndarray | list[np.ndarray] | MainOutputDict | FullOutputDict
> ```

**Parameters**

| Parameter | Type | Default | Description |
| - | - | - | - |
| `X` | `XType` | Required | The input data. |
| `output_type` | `OutputType` | `"mean"` | Determines the type of output to return. - If `"mean"`, we return the mean over the predicted distribution. - If `"median"`, we return the median over the predicted distribution. - If `"mode"`, we return the mode over the predicted distribution. - If `"quantiles"`, we return the quantiles of the predicted     distribution. The parameter `quantiles` determines which     quantiles are returned. - If `"main"`, we return the all output types above in a dict. - If `"full"`, we return the full output of the model, including the   logits and the criterion, and all the output types from "main". |
| `quantiles` | `list[float] \| None` | `None` | The quantiles to return if `output="quantiles"`. By default, the `[0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9]` quantiles are returned. The predictions per quantile match the input order. |

**Returns**

| Type | Description |
| - | - |
| `RegressionResultType` | The prediction, which can be a numpy array, a list of arrays (for quantiles), or a dictionary with detailed outputs. |

## Scikit-learn scoring

See inherited [`score`](https://scikit-learn.org/stable/modules/generated/sklearn.base.RegressorMixin.html#sklearn.base.RegressorMixin.score).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.