Viewing v4.0.0rc6 · release candidate · v3 stable / main · v4 preview / next

DEVKIT · THE CORE LAYER

Build StatLine into yours.

The public Python library is your DevKit. Load data, map fields, and score a row or a batch inside the bot, notebook, dashboard, or service you're already writing.

Import the public API

Start with load_dataset and score. The public interface exposes adapter discovery, loading, mapping, and scoring without requiring the app or Gateway.

Choose predictable outputs

Use row or batch mode explicitly in application code. Request particular profiles or output fields when the consumer needs a smaller result.

Keep your interface

StatLine handles the scoring model. Your code handles the product around it: persistence, presentation, integrations, and decisions.

PYTHON LIBRARY
from statline import load_dataset, score

rows = load_dataset('EBA_Elevate302/eba_players_gp3_plus.csv')
results = score('eba.players', rows, mode='batch', weights='pri')

ranked = sorted(zip(rows, results),
    key=lambda pair: (-pair[1]['pri'], -pair[1]['pri_raw']))
for row, result in ranked[:3]:
    print(row['PLAYER'], result['pri'])
Core has an enforced import boundary from App and Gateway. Start with the library; add the capabilities you need.
TYPED PUBLIC APIPYTHON >=3.10,<3.15