From a DataFrame
to a prediction.
Your table. A foundation model. A predictor you can reuse.
Start with Python you already know.
Illustrative workflow. No request runs in this page.
Fit uploads your table to your private workspace and waits for remote preparation. Prediction executes remotely. Your fitted predictor stays reusable after this Python session ends.
Your first prediction
Python 3.11–3.13 · SDK 0.7.0
python -m pip install 'welt-client @ https://github.com/ergodic-ai/welt-python/releases/download/v0.7.0/welt_client-0.7.0-py3-none-any.whl'
In Account, enable Allow writes, fits and predictions. Keep the key in local secret configuration or use the hidden Python prompt below.
Set your key safely in Python
import getpass
import os
if not os.environ.get("WELT_API_KEY"):
os.environ["WELT_API_KEY"] = getpass.getpass("Welt API key (hidden): ")
Sample data and imports · included in Copy
import numpy as np
import pandas as pd
from welt import Classifier
rng = np.random.default_rng(9)
values = rng.normal(size=(160, 4))
train = pd.DataFrame(values[:128], columns=["a", "b", "c", "d"])
train["label"] = np.where(values[:128, 0] + 0.5 * values[:128, 1] > 0,
"positive", "negative")
query = pd.DataFrame(values[128:], columns=["a", "b", "c", "d"])
model = Classifier(model="tabicl-v2", random_state=9)
model.fit(train, target="label")
predictions = model.predict(query)
print(type(predictions).__name__, predictions.shape)
ndarray (32,) — one class label per query row, in order.Expected type and shape; actual labels come from the model.
Sample data and imports · included in Copy
import numpy as np
import pandas as pd
from welt import Regressor
rng = np.random.default_rng(42)
values = rng.normal(size=(160, 4))
weights = rng.normal(size=4)
train = pd.DataFrame(values[:128], columns=["a", "b", "c", "d"])
train["target"] = values[:128] @ weights + rng.normal(scale=0.05, size=128)
query = pd.DataFrame(values[128:], columns=["a", "b", "c", "d"])
model = Regressor(model="tabicl-v2", random_state=42)
model.fit(train, target="target")
predictions = model.predict(query)
print(type(predictions).__name__, predictions.shape)
ndarray (32,) — one finite point in target units per row.Expected type and shape; no calibrated intervals or accuracy claim.
Created datasets and predictors remain in your workspace. A local timeout leaves work running; reconnect by job ID.
Declare the target, match the columns, and predict on new rows.
Keep the fitted identity. Predict again without uploading training data.
Clear, runnable examples for prediction, research and native discovery.