Priyam Alok
Priyam Alok Priyam Alok

Musings on insurance tech, finance
and life

P&C Reserving Model

Published on August 24, 2025

this started out as an end-to-end chain-ladder model on a clean development triangle, working through LDFs, CDFs and IBNR/reserves with python visualizations. from there it turned into ongoing open-source contributions to chainladder-python, the main python library for actuarial reserving (maintained by the CAS).

the work has grown past documentation. it now covers the API reference rendering, the public API surface itself, deprecating stale array backends, and recreating textbook exhibits from Friedland’s Estimating Unpaid Claims Using Basic Techniques as reconciled, doctested examples.

so far i’ve had 18 pull requests merged. the docs work started on an experimental branch, which has since been squashed and promoted into main (twice, most recently via #1126), so everything below now lives on the main line.

documentation and API reference

the goal here was simple: make the core reserving methods readable from the docs alone, without digging through source. if you land on a method, you should see what it does, its signature, and a worked example you can copy.

core API

these touch the public surface of the library, the bits users actually import and call, so they were the ones with the most review back-and-forth.

backend deprecation and cleanup

chainladder carried optional gpu and distributed backends that were mostly unused and hard to maintain. removing them cleanly, behind deprecation warnings rather than sudden breakage, keeps the library lighter without surprising existing users.

Friedland textbook recreations

separate from the API work, i’ve been recreating worked exhibits from Jacqueline Friedland’s Estimating Unpaid Claims Using Basic Techniques (the standard CAS reserving text) as reconciled, doctested chainladder-python examples, so the library’s docs double as a way to learn the methods against a source practicing actuaries already trust.

what i took from it

the docs work taught me the library inside out, which is what made the later core-API, deprecation and Friedland recreation work possible. reading and reviewing a mature reserving codebase, then changing it in a way maintainers will accept, is a different skill from writing your own model from scratch, and that’s the part i value most here. recreating Friedland’s exhibits added another layer: reconciling a maintained library against a fixed textbook answer forces you to be precise about every rounding and estimator choice along the way.

moving forward

i’m keeping at it, working toward a more complete, production-ready chainladder-python. that means more test coverage across the reserving methods, finishing the backend cleanup, working through more Friedland chapters, and getting deeper into the modelling internals rather than the edges.