Insurance pricing
GLM, GAM or gradient boosting: choosing a pricing model an insurer can defend
The useful question is not which algorithm wins on a leaderboard, but which model a tariff, a regulator and an underwriting team can live with. Our answer is a sequence rather than a choice: a GLM as the benchmark, smooth effects where bands are arbitrary, boosting as a microscope on what the GLM still misses, and the interactions it justifies brought back into a tariff anyone can read.
Start from a GLM: a tariff anyone can read
With a log link and exposure as an offset, a GLM turns every rating factor into a multiplier: a level of the factor raises or lowers the expected cost by a percentage anyone can read. Those relativities translate straight into a rating table, can be explained to an underwriter and documented for a regulator, and their uncertainty comes with the model.
For the number of claims of policy , observed over an exposure , the frequency model our engine fits reads
where is rating factor of the policy, an indicator for a level when the factor is categorical, and the multiplier of that level: the relativity that goes into the rating table. The exposure enters as an offset, with a coefficient fixed at 1, so that twice the exposure means twice the expected claims.
The price of that clarity is that the GLM only sees what it is given. The analyst decides the shape of each effect, and an interaction, a young driver in a powerful car, a breed at a given age, exists in the model only if someone thought to add it. The rest of the sequence is about finding what was not given, without losing the readable tariff.
Frequency and cost apart, Tweedie as a cross-check
Most policies cost nothing in a year and a few cost a lot. We model the two parts separately first: the number of claims with a Poisson GLM, or a negative binomial when claims are over-dispersed, with exposure as an offset, and the average cost per claim with a Gamma GLM weighted by the number of claims. The pure premium is their product. The point is to see which factors drive frequency and which drive cost, a young driver who claims often but cheaply, a vehicle that claims rarely but expensively, and to diagnose each part on its own.
In formulas, for a policy whose rating factors are ,
where is the pure premium per unit of exposure, the expected frequency per unit of exposure from (1), the mean cost of a claim and the total paid on policy . Our engine fits by a Gamma GLM with a log link on the rows with a payment, each weighted by its number of claims ; are the coefficients of that cost model. The product assumes that, given , the number of claims and their amounts are independent: the assumption of the collective model, which we state rather than take for granted.
A Tweedie GLM, a Poisson number of gamma-distributed claims, models the pure premium in one step. It is compact, and it is a natural objective for gradient boosting. With a constant dispersion, though, it makes each factor act on frequency and on cost in a fixed proportion: when a factor raises frequency but lowers cost, its single relativity is a compromise that hides both effects.
The fixed proportion is a property of the Tweedie law, whatever the software that fits it, and it holds only under three assumptions: a power strictly between 1 and 2, a dispersion fixed, the same for every policy per unit of exposure (a policy of exposure then has the dispersion ), and the compound Poisson–Gamma representation: the cost of a policy over one unit of exposure is a Poisson number of claims, of mean , whose amounts are independent and follow a gamma law of mean , so that the pure premium is . Then
where the first statement is the Tweedie variance, the next two say that, once and are fixed, the pure premium alone sets both the frequency and the mean cost, and the last three follow: a factor that multiplies the pure premium by turns and into and , the frequency multiplied by and the mean cost by : always the same split, whatever the factor. Under these assumptions, a factor that raises the frequency and lowers the cost cannot be represented.
So Tweedie is our cross-check, not our explanation. Comparing its relativities with the frequency-severity product shows quickly where they diverge, and each divergence is a question to answer before the tariff is set. Large claims are capped and loaded separately when that is justified; otherwise they can drive the severity model.
Smooth effects where bands are arbitrary
Bands are convenient but arbitrary. A driver of 24 and one of 25 can end up a whole relativity apart while drivers of 25 and 34 pay the same, and on sparse ages at the edges of the portfolio a band averages very different risks. A smooth curve, kept inside the same GLM structure and with a flexibility chosen from the data by cross-validation rather than by eye, follows the risk instead. It can be read directly or discretised into a rating table that tracks it closely: the tariff keeps its multiplicative form, without the jumps.
Boosting as a microscope on the residuals
Gradient boosting finds non-linear effects and interactions nobody specified. As a filed tariff it is hard to carry: thin cells can be fitted too closely, effects that should be monotonic can wobble, and explanations such as SHAP values describe the model after the fact rather than define it. So we use it differently. The boosting model starts from the GLM or smoothed model, its prediction as offset or base score under the same loss, and is fitted on training folds only. What it still finds is, by construction, what the simpler model misses, and it is usually a handful of interactions rather than a new model.
Justified interactions back into the tariff
Each interaction the boosting points to comes back as an explicit term of the GLM, and stays only if it holds on a period the models have not seen, is stable from one year to the next and makes sense to someone who knows the business. The result is still a tariff anyone can read, with the effects the first GLM missed. Boosting earns its place as a detector, and as the final model only where the decision allows it, such as claims triage or retention scoring rather than a filed tariff.
Comparing the candidates fairly
Same data, same exposure, a period none of the models has seen. We measure fit, ranking and level by segment, and we look at where the candidate and the current model disagree and which one the actual claims support. Two further tests matter as much: how stable the relativities are from one year to the next, and how much the new tariff would move each customer’s premium. A model that ranks risks better but moves the premium of a third of the portfolio by 20% is not ready.
In practice
Rating factors with many levels need their own treatment before any of these models; we describe it in our article on clustering categories and apply it in our 74-breed pricing case, where frequency, severity and Tweedie GLMs were fitted on the grouped breeds.
References
E. Ohlsson and B. Johansson (2010), Non-Life Insurance Pricing with Generalized Linear Models, Springer; S. N. Wood (2017), Generalized Additive Models: An Introduction with R, 2nd ed., CRC Press; J. H. Friedman (2001), “Greedy function approximation: a gradient boosting machine”, Annals of Statistics; T. Chen and C. Guestrin (2016), “XGBoost: a scalable tree boosting system”, KDD; S. M. Lundberg and S.-I. Lee (2017), “A unified approach to interpreting model predictions”, NeurIPS; M. V. Wüthrich and M. Merz (2023), Statistical Foundations of Actuarial Learning and its Applications, Springer; B. Jørgensen (1987), “Exponential dispersion models”, Journal of the Royal Statistical Society, Series B; G. K. Smyth and B. Jørgensen (2002), “Fitting Tweedie’s compound Poisson model to insurance claims data: dispersion modelling”, ASTIN Bulletin.
More publications
PublicationsDid it work? Measuring the effect of a decision without fooling yourself
A campaign, a new deductible, a reminder letter: did it change the outcome? Comparing those who received it with those who did not answers a different question. This article shows how we estimate the effect of a decision on observational data, what each estimate assumes, why the usual estimator can fail when the decision is rolled out in waves, what we do when only a few units received it, and how we keep a study of many segments from finding effects that do not exist.
Read the articlePricingStop grouping ages in fives: let the risk draw the classes
Most tariffs still group age, seniority or vehicle power into round bands chosen by hand, and categories with many values, breeds or products, by intuition. The bands rarely fall where the risk changes. Measured on simulated portfolios with a known truth, this article shows where the usual encodings go wrong, then how our engine lets the data draw the classes: compact in risk, precise enough to carry a coefficient, and in a number chosen on data the method has not seen.
Read the articleActuarial modellingClustering high-cardinality categories before a pricing GLM
74 breeds, too many for a stable tariff: making categories comparable with target-oriented K-means instead of dropping them, validated out of sample and in the GLM.
Read the articleLet’s build better decisions together
Tell us about the decision you need to make.
A few lines are enough: your sector, the data you have and what you want to improve. We reply personally with a first view of the approach.
- A few lines are enough
- NDA on request
- Code and documentation handed over


