What fit gives you back
fit leaves an artifact on our side and binds your client to it. Two attributes describe it.
fit creates a new context with a new id. Fitting twice does not replace the first
context, it leaves two, and there is no endpoint to delete either one.
A context lives 7 days, it is gone
A context lives 7 days from thefit that created it. Predicting against it does not extend
the clock, and there is no way to renew it.
After expiry, a predict raises NotFoundError with code fitted_context_expired, or
fitted_context_not_found if the id was never yours. The fix in both cases is to call fit
again and keep the new id.
Resuming in another process
evaluate()raisesRuntimeError. Evaluation needs the labeled table, and that only exists in the process that calledfit.classes_is unset untilpredict_probaruns. The class list comes back from the engine on that call, not from the context schema.
Three ways you lose the fast path
“predict never re-sends your training table” is true only while a context is bound. When one is not bound,predict uploads the whole training frame with every call and bills it every
time.
Check clf.fitted_context_id_ before you build a scoring loop on it. It is None in three
cases:
- Before any fit. A fresh client has no context, and
predictraisesRuntimeError. This is the one case that tells you. - With
server_context=False. Contexts are off for the whole client. Everypredictships the training table inline, with no warning. - After
fit(wait=False). The call returns aFitHandlebefore the context is ready, so nothing ever binds — not even once the fit succeeds.
What it costs
A context-backed predict bills the rows you score twice — once as input, once as output. FortestRows scored, that is 2 × testRows.
An inline predict bills trainRows + 2 × testRows, so the context is cheaper by exactly your
training table on every call. Full accounting is in
Usage and billing.
What is kept
The rows you upload are purged when the job reaches a terminal state — on failure as well as on success. That covers both training rows and rows to score. The context artifact is a separate thing, derived from your training table, and it persists until the 7-day expiry. The context’s row, including your feature column names, is retained after that. More in Data handling.Next
- How Hollerith works — why there is a context at all
- Errors — the not_found codes in full
- Limits — 200,000 rows per predict, 7-day TTL
- Usage and billing — what each job kind bills