Skip to main content

Browser-based GLM workbench for actuarial pricing

Project description

Atelier

Browser-based GLM workbench for actuarial pricing

Build, fit, diagnose, and iterate on Generalized Linear Models — without leaving your browser.

Python 3.13+ License: EPL-2.0 Powered by rustystats

Atelier Screenshot


Why Atelier?

Actuarial pricing teams deserve modern tooling. Atelier wraps rustystats — a high-performance Rust-backed GLM engine — in a clean, interactive UI designed for the model-building workflow.

  • One commanduv add atel, run atel, and you're in the browser. No Docker, no Node.js, no config files.
  • Fast — Rust-powered fitting is 5–20x faster than statsmodels. Iterate in seconds, not minutes.
  • Visual — Factor charts, actual-vs-expected, lift curves, diagnostics, and model comparison — all live-updating as you build.
  • Transparent — Every model action generates runnable Python code. Copy it, version it, schedule it.
  • Local — Your data never leaves your machine. No accounts, no cloud, no telemetry.

Installation

uv add atelier
# or
pip install atel

Requires Python 3.13+. Installs everything — backend, frontend, engine. No separate build steps.

Quick start

atel                  # starts server, opens browser
atel --port 9000      # custom port
atel --no-browser     # headless / server-only

The atelier command works too - atel is just shorter.


Features

Model building

  • 8 GLM families — Gaussian, Poisson, Binomial, Gamma, Tweedie, Quasi-Poisson, Quasi-Binomial, Negative Binomial
  • Rich term types — categorical, linear, B-splines, natural splines, target encoding, frequency encoding, expressions
  • Monotonic constraints — enforce increasing/decreasing effects on splines and linear terms
  • Interactions — standard product terms, target-encoded interactions, frequency-encoded interactions
  • Regularization — Ridge, Lasso, Elastic Net with cross-validated alpha selection
  • Train/test split — holdout validation with stratified splitting

Diagnostics

  • Factor-level A/E — actual vs expected charts for every factor, fitted or not
  • Score tests — chi-squared significance for candidate factors before fitting
  • Lift charts — Gini, AUC, KS statistics with decile breakdown
  • Calibration — Hosmer-Lemeshow test, decile calibration with confidence intervals
  • Residual analysis — deviance, Pearson, and working residuals
  • VIF & multicollinearity — variance inflation factors with severity coloring
  • Model comparison — side-by-side metrics against a base model

Data exploration

  • Pre-fit analysis — response distribution, zero inflation, overdispersion detection
  • Correlation matrix — numeric correlations and Cramér's V for categoricals
  • Shape detection — automatic recommendations for term types per factor
  • Interaction detection — greedy residual-based search for potential interactions

Workflow

  • Model history — every fit is saved and versioned, compare any two iterations
  • Context menus — right-click factors to change term types, toggle inclusion, reorder
  • Keyboard-driven — search, filter, and navigate without reaching for the mouse
  • Code generation — live Python script panel mirrors your UI actions

How it works

┌─────────────────────────────────────┐
│  Browser (React + TypeScript)       │
│  ┌──────────┬──────────┬──────────┐ │
│  │  Spec    │ Results  │  Code    │ │
│  │  Panel   │  Panel   │  Panel   │ │
│  └──────────┴──────────┴──────────┘ │
│           REST + WebSocket          │
└──────────────┬──────────────────────┘
               │
┌──────────────┴──────────────────────┐
│  Python backend (FastAPI + uvicorn) │
│  ┌────────────────────────────────┐ │
│  │  rustystats (Rust GLM engine)  │ │
│  └────────────────────────────────┘ │
│  Storage: ~/.atelier/ (SQLite)      │
└─────────────────────────────────────┘

Atelier is a single Python package. The React frontend is pre-built and bundled as static assets inside the wheel — no Node.js runtime required. The backend serves the UI and exposes a REST + WebSocket API for model fitting and real-time progress updates.


Development

git clone https://github.com/PricingFrontier/atelier.git
cd atelier
uv sync

# Backend (API server)
uv run atel --no-browser --port 8457

# Frontend (separate terminal, with hot reload)
cd frontend && npm install && npm run dev

Open http://localhost:5173 for the Vite dev server with HMR proxying API requests to the backend.

Running tests

uv run pytest

Building the frontend for production

cd frontend && npm run build
# Output lands in src/atelier/static/

Tech stack

Layer Technology
GLM engine rustystats (Rust)
Backend FastAPI, uvicorn, SQLAlchemy, polars
Frontend React 19, TypeScript, Vite, Tailwind CSS, shadcn/ui
Charts Plotly.js, Recharts
State Zustand
Storage SQLite (via aiosqlite) at ~/.atelier/

License

Eclipse Public License 2.0

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

atel-0.1.0.tar.gz (49.4 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

atel-0.1.0-py3-none-any.whl (243.1 kB view details)

Uploaded Python 3

File details

Details for the file atel-0.1.0.tar.gz.

File metadata

  • Download URL: atel-0.1.0.tar.gz
  • Upload date:
  • Size: 49.4 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.18 {"installer":{"name":"uv","version":"0.9.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for atel-0.1.0.tar.gz
Algorithm Hash digest
SHA256 a5c6762cab14ab2594a07abebb1a8623ccb570a7a43d042234c89a2c1020736f
MD5 c09dd31cc6f7bed3753e53a9b20a28d2
BLAKE2b-256 1db46c9dabbc4608dae946409243a444f23b5b1723b8a9430740413236245827

See more details on using hashes here.

File details

Details for the file atel-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: atel-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 243.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.18 {"installer":{"name":"uv","version":"0.9.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for atel-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 884d8f42b64f1aba27b71c190b11423474188609281b524c0c7ac47b4dbd411e
MD5 889e0e612a0d6bf3696c0f8973df1b3f
BLAKE2b-256 efdfe4cb6b2a54eb8b450199beb006fb291d902c1609a2e1cedab44b5260aa82

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page