Skip to main content
A numeric target and the same two calls. predict returns a plain Python list of floats, row-aligned with the frame you passed in. task="regression" is doing real work in that snippet. Without it, quality is read as a set of classes — the reason is further down.

Prediction intervals

Passing quantiles= changes the return type. You get a pandas DataFrame with a prediction column, the mean, plus one column per level you asked for. Levels are yours to choose. [0.1, 0.5, 0.9] gives an 80% band; [0.05, 0.95] gives a wider one and a more cautious lower edge.

The column labels are strings

The columns are named from the levels the engine echoes back, and they arrive as strings. A float key raises KeyError, which is the first thing most people hit. Keep the levels in one place and stringify at the point of use.

An interval is a decision, a point is not

A single number tells you what to expect. A band tells you what to commit to, which is usually the question you actually have.
  • Plan to the median. result["0.5"] is the level to order, staff or forecast against.
  • Buffer with the upper level. The gap between 0.5 and 0.9 is what a stockout or an overrun costs you, priced.
  • Gate on the lower level. Act only where the pessimistic end still clears your bar.

wait=False does not give you the DataFrame

predict(wait=False, quantiles=[...]) returns a raw handle. The DataFrame is assembled after the wait, so with wait=False you assemble it yourself.
quantiles= is regression-only. On a classification task the call raises ValueError before anything is submitted.

A small-integer target becomes classification

The task is inferred from your target column. An integer target with 20 or fewer distinct values is treated as classification, whatever you meant by it. quality runs 3 to 8. A units-sold count, a 1-to-5 rating and a 0/1 flag land the same way, silently, with no warning:
Check task_ after any fit where the target is a whole number. It is the single most likely surprise in the SDK.

Evaluation returns RMSE

Regression returns one metric, RMSE, in the units of your target. There is no MAE and no R² — the engine does not compute them. At 10,000 rows or fewer the split is k-fold; above it, a single holdout. Both are covered in Evaluating accuracy.

When this will not help

  • The target is time-indexed. Row-wise predict has no notion of order — see Forecast.
  • You need calibrated intervals. The quantiles are the engine’s, and nothing here guarantees a stated coverage rate on your data.
  • The signal lives in free text. Text and dates are ordinal-encoded; the model sees shared values, not meaning.

Before you ship

  • task_ read back after fit, not assumed.
  • Quantile columns keyed by string, everywhere.
  • The decision written down as a level, not a point.
  • evaluate() run once, on the labeled table you fit on.

Next