FA-63291 / Insurance premium rating / Open access
Renewal rate capping transition: Caps chain from the uncapped indication · case 01
Phase-in steps jump because the next cap is measured from the indicated premium.
ROOT CAUSE
prev is set to the indicated premium instead of the charged premium.
THE FAILURE
prev is set to the indicated premium instead of the charged premium.
Unsuccessful approach: Chaining from charged premium only after coverage changes still uses indications otherwise.
Case contract
Input prior premium (0 = new business), up/down caps per mille, years [[indicated or None for a lapse, coverage_changed]]. A lapse outputs None and the next year is new business. New business or coverage changes charge the indicated premium; otherwise charge the indicated premium clamped to [prev*(1-down), prev*(1+up)] with bounds rounded half-up, where prev is last year's charged premium.
Why this case matters
Transition caps limit renewal disruption and must chain from what was actually charged.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
import math
from fractions import Fraction
N = 1
observations = []
def solve(x):
prev=x['prior']; out=[]
for ind,changed in x['years']:
if ind is None:
out.append(None); prev=0; continue
if changed or prev==0:
cur=ind
else:
hi=math.floor(Fraction(prev*(1000+x['up']),1000)+Fraction(1,2))
lo=math.floor(Fraction(prev*(1000-x['down']),1000)+Fraction(1,2))
cur=max(lo,min(hi,ind))
out.append(cur); prev=ind
return out
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['large increase phased in', {'prior': 141166, 'up': 110, 'down': 50, 'years': [[282332, False], [282332, False], [282332, False]]}, [156694, 173930, 193062]], ['large decrease capped', {'prior': 141166, 'up': 110, 'down': 50, 'years': [[70583, False], [70583, False]]}, [134108, 127403]], ['coverage change exempt then capped', {'prior': 141166, 'up': 110, 'down': 50, 'years': [[282332, True], [423498, False]]}, [282332, 313389]], ['new business exempt', {'prior': 0, 'up': 110, 'down': 50, 'years': [[141166, False], [282332, False]]}, [141166, 156694]], ['lapse restarts as new business', {'prior': 141166, 'up': 110, 'down': 50, 'years': [[141166, False], [None, False], [423498, False]]}, [141166, None, 423498]], ['within caps', {'prior': 141166, 'up': 110, 'down': 50, 'years': [[142166, False], [140166, False]]}, [142166, 140166]], ['mixed history', {'prior': 141166, 'up': 110, 'down': 50, 'years': [[172018, False], [166564, False], [197332, False], [213340, False]]}, [156694, 166564, 184886, 205223]]], [['large increase phased in', {'prior': 81917, 'up': 120, 'down': 50, 'years': [[163834, False], [163834, False], [163834, False]]}, [91747, 102757, 115088]], ['large decrease capped', {'prior': 81917, 'up': 120, 'down': 50, 'years': [[40958, False], [40958, False]]}, [77821, 73930]], ['coverage change exempt then capped', {'prior': 81917, 'up': 120, 'down': 50, 'years': [[163834, True], [245751, False]]}, [163834, 183494]], ['new business exempt', {'prior': 0, 'up': 120, 'down': 50, 'years': [[81917, False], [163834, False]]}, [81917, 91747]], ['lapse restarts as new business', {'prior': 81917, 'up': 120, 'down': 50, 'years': [[81917, False], [None, False], [245751, False]]}, [81917, None, 245751]], ['within caps', {'prior': 81917, 'up': 120, 'down': 50, 'years': [[82917, False], [80917, False]]}, [82917, 80917]], ['mixed history', {'prior': 81917, 'up': 120, 'down': 50, 'years': [[92584, False], [202024, False], [62931, True], [150823, False]]}, [91747, 102757, 62931, 70483]]], [['large increase phased in', {'prior': 140363, 'up': 130, 'down': 50, 'years': [[280726, False], [280726, False], [280726, False]]}, [158610, 179229, 202529]], ['large decrease capped', {'prior': 140363, 'up': 130, 'down': 50, 'years': [[70181, False], [70181, False]]}, [133345, 126678]], ['coverage change exempt then capped', {'prior': 140363, 'up': 130, 'down': 50, 'years': [[280726, True], [421089, False]]}, [280726, 317220]], ['new business exempt', {'prior': 0, 'up': 130, 'down': 50, 'years': [[140363, False], [280726, False]]}, [140363, 158610]], ['lapse restarts as new business', {'prior': 140363, 'up': 130, 'down': 50, 'years': [[140363, False], [None, False], [421089, False]]}, [140363, None, 421089]], ['within caps', {'prior': 140363, 'up': 130, 'down': 50, 'years': [[141363, False], [139363, False]]}, [141363, 139363]], ['mixed history', {'prior': 140363, 'up': 130, 'down': 50, 'years': [[224001, True], [54488, False], [53043, False], [82834, False]]}, [224001, 212801, 202161, 192053]]], [['large increase phased in', {'prior': 131425, 'up': 140, 'down': 50, 'years': [[262850, False], [262850, False], [262850, False]]}, [149825, 170801, 194713]], ['large decrease capped', {'prior': 131425, 'up': 140, 'down': 50, 'years': [[65712, False], [65712, False]]}, [124854, 118611]], ['coverage change exempt then capped', {'prior': 131425, 'up': 140, 'down': 50, 'years': [[262850, True], [394275, False]]}, [262850, 299649]], ['new business exempt', {'prior': 0, 'up': 140, 'down': 50, 'years': [[131425, False], [262850, False]]}, [131425, 149825]], ['lapse restarts as new business', {'prior': 131425, 'up': 140, 'down': 50, 'years': [[131425, False], [None, False], [394275, False]]}, [131425, None, 394275]], ['within caps', {'prior': 131425, 'up': 140, 'down': 50, 'years': [[132425, False], [130425, False]]}, [132425, 130425]], ['mixed history', {'prior': 131425, 'up': 140, 'down': 50, 'years': [[105255, True], [201448, True], [175992, True], [84220, False]]}, [105255, 201448, 175992, 167192]]], [['large increase phased in', {'prior': 129003, 'up': 150, 'down': 50, 'years': [[258006, False], [258006, False], [258006, False]]}, [148353, 170606, 196197]], ['large decrease capped', {'prior': 129003, 'up': 150, 'down': 50, 'years': [[64501, False], [64501, False]]}, [122553, 116425]], ['coverage change exempt then capped', {'prior': 129003, 'up': 150, 'down': 50, 'years': [[258006, True], [387009, False]]}, [258006, 296707]], ['new business exempt', {'prior': 0, 'up': 150, 'down': 50, 'years': [[129003, False], [258006, False]]}, [129003, 148353]], ['lapse restarts as new business', {'prior': 129003, 'up': 150, 'down': 50, 'years': [[129003, False], [None, False], [387009, False]]}, [129003, None, 387009]], ['within caps', {'prior': 129003, 'up': 150, 'down': 50, 'years': [[130003, False], [128003, False]]}, [130003, 128003]], ['mixed history', {'prior': 129003, 'up': 150, 'down': 50, 'years': [[151965, False], [114334, False], [235286, False], [180318, True]]}, [148353, 140935, 162075, 180318]]]]
for label, args, expected in fixtures[N-1]:
check(label, solve(args), expected)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| large increase phased in | [156694, 282332, 282332] | [156694, 173930, 193062] | Failed |
| large decrease capped | [134108, 70583] | [134108, 127403] | Failed |
| coverage change exempt then capped | [282332, 313389] | [282332, 313389] | Passed |
| new business exempt | [141166, 156694] | [141166, 156694] | Passed |
| lapse restarts as new business | [141166, None, 423498] | [141166, None, 423498] | Passed |
| within caps | [142166, 140166] | [142166, 140166] | Passed |
| mixed history | [156694, 166564, 184886, 213340] | [156694, 166564, 184886, 205223] | Failed |
SHA-256 / a71d4def3860e00bcbf7a19406e859e4993a9d8203c696fd049e1247ce99eb38
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
import math
from fractions import Fraction
N = 1
observations = []
def solve(x):
prev=x['prior']; out=[]
for ind,changed in x['years']:
if ind is None:
out.append(None); prev=0; continue
if changed or prev==0:
cur=ind
else:
hi=math.floor(Fraction(prev*(1000+x['up']),1000)+Fraction(1,2))
lo=math.floor(Fraction(prev*(1000-x['down']),1000)+Fraction(1,2))
cur=max(lo,min(hi,ind))
out.append(cur); prev=cur if changed else ind
return out
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['large increase phased in', {'prior': 141166, 'up': 110, 'down': 50, 'years': [[282332, False], [282332, False], [282332, False]]}, [156694, 173930, 193062]], ['large decrease capped', {'prior': 141166, 'up': 110, 'down': 50, 'years': [[70583, False], [70583, False]]}, [134108, 127403]], ['coverage change exempt then capped', {'prior': 141166, 'up': 110, 'down': 50, 'years': [[282332, True], [423498, False]]}, [282332, 313389]], ['new business exempt', {'prior': 0, 'up': 110, 'down': 50, 'years': [[141166, False], [282332, False]]}, [141166, 156694]], ['lapse restarts as new business', {'prior': 141166, 'up': 110, 'down': 50, 'years': [[141166, False], [None, False], [423498, False]]}, [141166, None, 423498]], ['within caps', {'prior': 141166, 'up': 110, 'down': 50, 'years': [[142166, False], [140166, False]]}, [142166, 140166]], ['mixed history', {'prior': 141166, 'up': 110, 'down': 50, 'years': [[172018, False], [166564, False], [197332, False], [213340, False]]}, [156694, 166564, 184886, 205223]]], [['large increase phased in', {'prior': 81917, 'up': 120, 'down': 50, 'years': [[163834, False], [163834, False], [163834, False]]}, [91747, 102757, 115088]], ['large decrease capped', {'prior': 81917, 'up': 120, 'down': 50, 'years': [[40958, False], [40958, False]]}, [77821, 73930]], ['coverage change exempt then capped', {'prior': 81917, 'up': 120, 'down': 50, 'years': [[163834, True], [245751, False]]}, [163834, 183494]], ['new business exempt', {'prior': 0, 'up': 120, 'down': 50, 'years': [[81917, False], [163834, False]]}, [81917, 91747]], ['lapse restarts as new business', {'prior': 81917, 'up': 120, 'down': 50, 'years': [[81917, False], [None, False], [245751, False]]}, [81917, None, 245751]], ['within caps', {'prior': 81917, 'up': 120, 'down': 50, 'years': [[82917, False], [80917, False]]}, [82917, 80917]], ['mixed history', {'prior': 81917, 'up': 120, 'down': 50, 'years': [[92584, False], [202024, False], [62931, True], [150823, False]]}, [91747, 102757, 62931, 70483]]], [['large increase phased in', {'prior': 140363, 'up': 130, 'down': 50, 'years': [[280726, False], [280726, False], [280726, False]]}, [158610, 179229, 202529]], ['large decrease capped', {'prior': 140363, 'up': 130, 'down': 50, 'years': [[70181, False], [70181, False]]}, [133345, 126678]], ['coverage change exempt then capped', {'prior': 140363, 'up': 130, 'down': 50, 'years': [[280726, True], [421089, False]]}, [280726, 317220]], ['new business exempt', {'prior': 0, 'up': 130, 'down': 50, 'years': [[140363, False], [280726, False]]}, [140363, 158610]], ['lapse restarts as new business', {'prior': 140363, 'up': 130, 'down': 50, 'years': [[140363, False], [None, False], [421089, False]]}, [140363, None, 421089]], ['within caps', {'prior': 140363, 'up': 130, 'down': 50, 'years': [[141363, False], [139363, False]]}, [141363, 139363]], ['mixed history', {'prior': 140363, 'up': 130, 'down': 50, 'years': [[224001, True], [54488, False], [53043, False], [82834, False]]}, [224001, 212801, 202161, 192053]]], [['large increase phased in', {'prior': 131425, 'up': 140, 'down': 50, 'years': [[262850, False], [262850, False], [262850, False]]}, [149825, 170801, 194713]], ['large decrease capped', {'prior': 131425, 'up': 140, 'down': 50, 'years': [[65712, False], [65712, False]]}, [124854, 118611]], ['coverage change exempt then capped', {'prior': 131425, 'up': 140, 'down': 50, 'years': [[262850, True], [394275, False]]}, [262850, 299649]], ['new business exempt', {'prior': 0, 'up': 140, 'down': 50, 'years': [[131425, False], [262850, False]]}, [131425, 149825]], ['lapse restarts as new business', {'prior': 131425, 'up': 140, 'down': 50, 'years': [[131425, False], [None, False], [394275, False]]}, [131425, None, 394275]], ['within caps', {'prior': 131425, 'up': 140, 'down': 50, 'years': [[132425, False], [130425, False]]}, [132425, 130425]], ['mixed history', {'prior': 131425, 'up': 140, 'down': 50, 'years': [[105255, True], [201448, True], [175992, True], [84220, False]]}, [105255, 201448, 175992, 167192]]], [['large increase phased in', {'prior': 129003, 'up': 150, 'down': 50, 'years': [[258006, False], [258006, False], [258006, False]]}, [148353, 170606, 196197]], ['large decrease capped', {'prior': 129003, 'up': 150, 'down': 50, 'years': [[64501, False], [64501, False]]}, [122553, 116425]], ['coverage change exempt then capped', {'prior': 129003, 'up': 150, 'down': 50, 'years': [[258006, True], [387009, False]]}, [258006, 296707]], ['new business exempt', {'prior': 0, 'up': 150, 'down': 50, 'years': [[129003, False], [258006, False]]}, [129003, 148353]], ['lapse restarts as new business', {'prior': 129003, 'up': 150, 'down': 50, 'years': [[129003, False], [None, False], [387009, False]]}, [129003, None, 387009]], ['within caps', {'prior': 129003, 'up': 150, 'down': 50, 'years': [[130003, False], [128003, False]]}, [130003, 128003]], ['mixed history', {'prior': 129003, 'up': 150, 'down': 50, 'years': [[151965, False], [114334, False], [235286, False], [180318, True]]}, [148353, 140935, 162075, 180318]]]]
for label, args, expected in fixtures[N-1]:
check(label, solve(args), expected)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| large increase phased in | [156694, 282332, 282332] | [156694, 173930, 193062] | Failed |
| large decrease capped | [134108, 70583] | [134108, 127403] | Failed |
| coverage change exempt then capped | [282332, 313389] | [282332, 313389] | Passed |
| new business exempt | [141166, 156694] | [141166, 156694] | Passed |
| lapse restarts as new business | [141166, None, 423498] | [141166, None, 423498] | Passed |
| within caps | [142166, 140166] | [142166, 140166] | Passed |
| mixed history | [156694, 166564, 184886, 213340] | [156694, 166564, 184886, 205223] | Failed |
SHA-256 / 1e17086f059001a44d184a435600b39d1cb5a70f93f28cdd9e1e96bfa411e464
HELD IN THE MEMBER ARCHIVE
The verified repair and its recorded checks are member-only.
This mechanism has 7 recorded checks per implementation. The open-access tier publishes the failure and the unsuccessful fix; the repaired source that passes every check, and the observations that prove it, are available to members.
Every case sharing this mechanism uses the same contract and the same repair, so this one record is held back for all of them.
Member access is invitation-based. Sign in with your invited account to inspect the repair.
Sign in to the archive ↗Verification & scope
A deterministic bounded teaching model of a stipulated toy rating contract. Amounts are integer cents and factors exact rationals; it makes no claim of conformance with any filed rating plan, bureau manual or jurisdiction. This reproducer isolates one failure mechanism. Results cover the supplied fixtures. Variants within a family share a test contract and should remain grouped when constructing evaluation splits. Related mechanisms with a shared evaluation_group must also remain together; these controlled models are not independent production incidents.
Observations recorded using Python 3.12.14 at 2026-09-29T14:47:13.102580+00:00.
Case digest / 7a4cc5832d8eccbb6f415510a2edff48c1fdec75443a1be834773a131bf3f4a6