Skip to main content

SuperGLM

CI codecov Python 3.12+

Penalised GLMs and GAM-style pricing models for insurance. SuperGLM combines explicit feature specs, exact REML, large-n discrete REML, solver-backed monotone splines, actuarial validation tooling, and deployable fitted estimators for Poisson, Gamma, NB2, Tweedie, Binomial, Gaussian, and Gaussian or Gamma location–scale models.

Install

pip install superglm

Interactive Plotly charts are optional: pip install "superglm[plotting]". The browser model editor is included.

Fit a pricing model

from superglm import Categorical, Numeric, Spline, SuperGLM

features = {
    "DrivAge": Spline(kind="ps", k=14, knot_strategy="quantile_rows"),
    "VehAge": Spline(kind="cr", k=10, knot_strategy="quantile_rows"),
    "BonusMalus": Spline(kind="cr", k=12, knot_strategy="quantile_tempered"),
    "Area": Categorical(base="most_exposed"),
    "LogDensity": Numeric(),
}
model = SuperGLM(family="poisson", features=features)
model.fit_reml(train_df, y_train, sample_weight=exposure_train)
print(model.summary())

REML chooses the smoothness of every spline. Monotone and curvature constraints are enforced inside the fit. SuperLSS fits location, scale and shape parameters together for severity and distributional work.

Documentation

Licence

MIT. Free for everyone, commercial use included.

Metadata

Release files for superglm 0.43.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for superglm 0.43.0
File Size Uploaded Provenance Actions
superglm-0.43.0.tar.gz 2.8 MB With provenance Details for superglm-0.43.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for superglm 0.43.0
File Interpreter ABI Platform Actions
superglm-0.43.0-py3-none-any.whl Python 3 none any Details for superglm-0.43.0-py3-none-any.whl

Total release size: 6.0 MB

Release files / superglm-0.43.0.tar.gz

Download URL superglm-0.43.0.tar.gz
Size 2.8 MB
Tags Source
SHA-256 checksum
How to use checksums
5a2de9e5edcd061c8c94d22576ab2b110c236817c07ceefcaf7c6c44c45f9e44
BLAKE2b-256 checksum
How to use checksums
85a0e03dc7e6a5682a146e6f1ce92527f24672d592799daf8a149bff1bbbac9c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 10, 2026.

Transparency log

Release files / superglm-0.43.0-py3-none-any.whl

Download URL superglm-0.43.0-py3-none-any.whl
Size 3.2 MB
Tags Python 3
SHA-256 checksum
How to use checksums
c9e7df4853e20662501b2775f8dab11839b221d28035b0ef3090b7ac9f5c9021
BLAKE2b-256 checksum
How to use checksums
26dc100ad2e8a7038a3d75cfc72f5775803bb17f21747c23bf7f4619c47fada6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 10, 2026.

Transparency log

Security for superglm 0.43.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for superglm-0.43.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 10, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.43.0 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page