Skip to content
View OpenActuarial's full-sized avatar

Block or report OpenActuarial

Block user

Prevent this user from interacting with your repositories and sending you notifications. Learn more about blocking users.

You must be logged in to block users.

Maximum 250 characters. Please don’t include any personal information such as legal names or email addresses. Markdown is supported. This note will only be visible to you.
Report abuse

Contact GitHub support about this user’s behavior. Learn more about reporting abuse.

Report abuse
openactuarial/README.md

OpenActuarial

Open-source actuarial tooling for Python — a small, composable ecosystem for experience analysis, pricing, loss modeling, and capital, organized around a shared core.

📚 Documentation: openactuarial.org · License: MIT


The ecosystem

Package What it does Install
actuarialpy Experience analysis and the shared core — per-exposure and loss-ratio metrics, trend, completion, seasonality, credibility, financial mathematics (time value of money), and exposure. ratingmodels builds directly on it. pip install actuarialpy
ratingmodels Group rate build-up and indication — manual and experience rating, an auditable build-up engine, GLM relativities, retention gross-up, and renewal. pip install ratingmodels
lossmodels Loss-distribution modeling — severity and frequency fitting, and aggregate loss. pip install lossmodels
extremeloss Extreme-value tail estimation — peaks-over-threshold / GPD and large-claim loading. pip install extremeloss
risksim Portfolio Monte Carlo simulation and risk measures. pip install risksim

How they compose

Left to right, the packages trace one analysis — experience, pricing, loss, tail, and capital:

flowchart LR
    AP["actuarialpy<br/>experience"]:::core
    RM["ratingmodels<br/>pricing"]
    LM["lossmodels<br/>loss"]
    EL["extremeloss<br/>tail"]
    RS["risksim<br/>capital"]
    AP --> RM --> LM --> EL --> RS
    classDef core fill:#eaf2ff,stroke:#3a6ea5,stroke-width:2px,color:#1a1a1a
Loading

The arrows are the analytical sequence, not install requirements. actuarialpy is the shared core — credibility, trend, financial math, and exposure live there once — and ratingmodels builds directly on it. lossmodels, extremeloss, and risksim install independently (extremeloss can optionally integrate lossmodels for severity splicing). Dependencies stay light throughout: numpy and pandas, with scipy where the loss and tail work needs it.

A workflow across the ecosystem

Credibility comes from the core; the rate build-up and indication come from ratingmodels — the two compose directly:

import actuarialpy as ap
import ratingmodels as rm

# core: credibility for the group's own experience
z = ap.limited_fluctuation_z(exposure=96_000, full_credibility_standard=120_000)

# pricing: build the manual rate, blend against experience, and indicate
manual = rm.ManualRate(base_loss_cost=480, factors={"area": 1.05, "industry": 0.97})

indication = rm.RateIndication(
    experience_loss_cost=512,
    manual_loss_cost=manual.loss_cost(),
    credibility=z,
    current_rate=560,
    target_loss_ratio=0.85,
)

indication.indicated_rate_change()       # the indicated rate change
indication.rate_change_decomposition()   # an auditable explanation of why it moved

Getting started

Install any package with pip (above). Each has its own guide and full API reference at openactuarial.org.

License

All packages are released under the MIT License.

Popular repositories Loading

  1. lossmodels lossmodels Public

    Actuarial loss modeling in Python: severity, frequency, aggregate loss, fitted distributions, and insurance loss analytics.

    Python 1

  2. risksim risksim Public

    Portfolio Monte Carlo risk simulation in Python for insurance risk, aggregate loss, capital modeling, and risk measures.

    Python

  3. extremeloss extremeloss Public

    Extreme-value tail-risk estimation in Python: peaks-over-threshold, GPD fitting, rare-event analysis, and large-claim loading.

    Python

  4. actuarialpy actuarialpy Public

    Core actuarial analysis tools for Python: experience analysis, PMPM metrics, trend, completion, seasonality, credibility, exposure, and TVM.

    Python

  5. docs docs Public

    Documentation site for the OpenActuarial Python ecosystem: actuarialpy, ratingmodels, lossmodels, extremeloss, and risksim.

    Makefile

  6. openactuarial openactuarial Public

    Open-source actuarial tooling for Python: experience analysis, pricing/rating, loss modeling, risk simulation, and tail-risk methods.