{"abstract":"After a few years thresholds lag the published cumulative indexation.","category":"Tax bracket computation","checks":8,"contract":"solve(base, factors): base is a list of statutory thresholds; factors are yearly inflation factors (decimal strings). For every year, a threshold is the base times the cumulative product of factors so far, rounded DOWN to a multiple of 50 (indexing always starts again from the unrounded base, never from a previously rounded value). A threshold may never fall below its previous year's value. Return the final-year thresholds.","contract_signature":"base, factors","evaluation_group":"w2-tax_bracket_computation-threshold-inflation-indexing","failed_approach":"Rounding the cumulative factor to four decimals each year still compounds a rounding drift.","family":"w2-tax_bracket_computation-threshold-inflation-indexing-index-from-rounded","id":"FA-62401","implementations":{"attempt":{"sha256":"e8086670d3f7c9f011a2dd480e49724af57cbd85e1edbaf0a04b3eebf09adb75","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nfrom decimal import Decimal, ROUND_HALF_UP, ROUND_HALF_EVEN, ROUND_FLOOR, ROUND_CEILING, ROUND_DOWN\nN = 1\nobservations = []\ndef solve(base, factors):\n    out = []\n    for t in base:\n        cum, prev = Decimal(1), t\n        for f in factors:\n            cum = (cum * Decimal(f)).quantize(Decimal('0.0001'), rounding=ROUND_HALF_EVEN)\n            v = int((t * cum / 50).to_integral_value(rounding=ROUND_FLOOR)) * 50\n            prev = max(prev, v)\n        out.append(prev)\n    return out\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncases = [[('regression index-from-rounded 1', ([10000], ['1.0049', '1.0049']), [10050]),\n  ('regression index-from-rounded 2', ([47150, 100525, 191950], ['1.054', '1.032', '1.028']), [52700, 112400, 214600]),\n  ('partial repair guard 1', ([47150, 47150, 609350], ['0.9826', '1.0776']), [49900, 49900, 645200]),\n  ('partial repair guard 2', ([243725], ['1.0800', '1.0031', '1.0633', '0.9916', '1.0198']), [283900]),\n  ('control: two years', ([10000, 40000], ['1.031', '1.029']), [10600, 42400]),\n  ('control: deflation year', ([10000], ['1.02', '0.97']), [10200]),\n  ('control: unrounded base', ([10025], ['1']), [10025]), ('control: no years', ([11600, 47150], []), [11600, 47150])],\n [('regression index-from-rounded 1', ([10000, 40000], ['1.031', '1.029']), [10600, 42400]),\n  ('regression index-from-rounded 2', ([47150, 47150, 609350], ['0.9826', '1.0776']), [49900, 49900, 645200]),\n  ('partial repair guard 1', ([268354, 243725], ['1.0072', '1.0060']), [271900, 246950]),\n  ('partial repair guard 2', ([609350, 191950, 243725], ['1.0507', '0.9882', '1.0150', '1.0296']),\n   [661150, 208250, 264450]),\n  ('control: unrounded base', ([10025], ['1']), [10025]), ('control: no years', ([11600, 47150], []), [11600, 47150]),\n  ('control: three years', ([47150, 100525, 191950], ['1.054', '1.032', '1.028']), [52700, 112400, 214600]),\n  ('control: small compounding', ([10000], ['1.0049', '1.0049']), [10050])],\n [('regression index-from-rounded 1', ([243725, 11600], ['0.9717', '1.0752']), [254600, 12100]),\n  ('regression index-from-rounded 2', ([102361], ['0.9751', '1.0398']), [103750]),\n  ('partial repair guard 1', ([602498, 11600], ['1.0084', '1.0091']), [613050, 11800]),\n  ('partial repair guard 2', ([609350, 10000, 680541], ['0.9966', '1.0113', '0.9967', '0.9988']),\n   [614100, 10050, 685850]),\n  ('control: two years', ([10000, 40000], ['1.031', '1.029']), [10600, 42400]),\n  ('control: small compounding', ([10000], ['1.0049', '1.0049']), [10050]),\n  ('control: deflation year', ([10000], ['1.02', '0.97']), [10200]),\n  ('control: unrounded base', ([10025], ['1']), [10025])],\n [('regression index-from-rounded 1', ([11600], ['1.0439', '0.9870', '1.0302']), [12300]),\n  ('regression index-from-rounded 2', ([11600], ['0.9966', '1.0602', '1.0714', '1.0361', '1.0508']), [14250]),\n  ('partial repair guard 1', ([609350, 16633, 609350], ['1.0660', '1.0009', '1.0062', '1.0674', '0.9939']),\n   [698250, 19050, 698250]),\n  ('partial repair guard 2', ([697474, 47150], ['0.9883', '1.0237']), [705650, 47700]),\n  ('control: unrounded base', ([10025], ['1']), [10025]), ('control: no years', ([11600, 47150], []), [11600, 47150]),\n  ('control: three years', ([47150, 100525, 191950], ['1.054', '1.032', '1.028']), [52700, 112400, 214600]),\n  ('control: two years', ([10000, 40000], ['1.031', '1.029']), [10600, 42400])],\n [('regression index-from-rounded 1', ([10000, 47150, 191950], ['1.0605', '1.0510', '0.9809', '1.0498']),\n   [11450, 54100, 220300]),\n  ('regression index-from-rounded 2', ([11600, 243725], ['1.0641', '1.0478', '0.9707', '1.0624', '1.0640']),\n   [14150, 298150]),\n  ('partial repair guard 1', ([47150, 100525, 11600], ['1.0430', '1.0034', '0.9845', '0.9761']),\n   [49300, 105200, 12100]),\n  ('partial repair guard 2', ([11600, 609350], ['1.0003', '1.0039', '1.0541', '1.0389', '1.0444']), [13300, 699850]),\n  ('control: two years', ([10000, 40000], ['1.031', '1.029']), [10600, 42400]),\n  ('control: small compounding', ([10000], ['1.0049', '1.0049']), [10050]),\n  ('control: deflation year', ([10000], ['1.02', '0.97']), [10200]),\n  ('control: unrounded base', ([10025], ['1']), [10025])]]\nfor label, args, expected in cases[N - 1]:\n    check(label, solve(*args), expected)\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"},"broken":{"sha256":"c4cd2f5d52a84f04af66f967416655f5b8f4991749f045035fe76c0037d2e685","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nfrom decimal import Decimal, ROUND_HALF_UP, ROUND_HALF_EVEN, ROUND_FLOOR, ROUND_CEILING, ROUND_DOWN\nN = 1\nobservations = []\ndef solve(base, factors):\n    out = []\n    for t in base:\n        cum, prev = Decimal(1), t\n        for f in factors:\n            v = int((prev * Decimal(f) / 50).to_integral_value(rounding=ROUND_FLOOR)) * 50\n            prev = max(prev, v)\n        out.append(prev)\n    return out\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncases = [[('regression index-from-rounded 1', ([10000], ['1.0049', '1.0049']), [10050]),\n  ('regression index-from-rounded 2', ([47150, 100525, 191950], ['1.054', '1.032', '1.028']), [52700, 112400, 214600]),\n  ('partial repair guard 1', ([47150, 47150, 609350], ['0.9826', '1.0776']), [49900, 49900, 645200]),\n  ('partial repair guard 2', ([243725], ['1.0800', '1.0031', '1.0633', '0.9916', '1.0198']), [283900]),\n  ('control: two years', ([10000, 40000], ['1.031', '1.029']), [10600, 42400]),\n  ('control: deflation year', ([10000], ['1.02', '0.97']), [10200]),\n  ('control: unrounded base', ([10025], ['1']), [10025]), ('control: no years', ([11600, 47150], []), [11600, 47150])],\n [('regression index-from-rounded 1', ([10000, 40000], ['1.031', '1.029']), [10600, 42400]),\n  ('regression index-from-rounded 2', ([47150, 47150, 609350], ['0.9826', '1.0776']), [49900, 49900, 645200]),\n  ('partial repair guard 1', ([268354, 243725], ['1.0072', '1.0060']), [271900, 246950]),\n  ('partial repair guard 2', ([609350, 191950, 243725], ['1.0507', '0.9882', '1.0150', '1.0296']),\n   [661150, 208250, 264450]),\n  ('control: unrounded base', ([10025], ['1']), [10025]), ('control: no years', ([11600, 47150], []), [11600, 47150]),\n  ('control: three years', ([47150, 100525, 191950], ['1.054', '1.032', '1.028']), [52700, 112400, 214600]),\n  ('control: small compounding', ([10000], ['1.0049', '1.0049']), [10050])],\n [('regression index-from-rounded 1', ([243725, 11600], ['0.9717', '1.0752']), [254600, 12100]),\n  ('regression index-from-rounded 2', ([102361], ['0.9751', '1.0398']), [103750]),\n  ('partial repair guard 1', ([602498, 11600], ['1.0084', '1.0091']), [613050, 11800]),\n  ('partial repair guard 2', ([609350, 10000, 680541], ['0.9966', '1.0113', '0.9967', '0.9988']),\n   [614100, 10050, 685850]),\n  ('control: two years', ([10000, 40000], ['1.031', '1.029']), [10600, 42400]),\n  ('control: small compounding', ([10000], ['1.0049', '1.0049']), [10050]),\n  ('control: deflation year', ([10000], ['1.02', '0.97']), [10200]),\n  ('control: unrounded base', ([10025], ['1']), [10025])],\n [('regression index-from-rounded 1', ([11600], ['1.0439', '0.9870', '1.0302']), [12300]),\n  ('regression index-from-rounded 2', ([11600], ['0.9966', '1.0602', '1.0714', '1.0361', '1.0508']), [14250]),\n  ('partial repair guard 1', ([609350, 16633, 609350], ['1.0660', '1.0009', '1.0062', '1.0674', '0.9939']),\n   [698250, 19050, 698250]),\n  ('partial repair guard 2', ([697474, 47150], ['0.9883', '1.0237']), [705650, 47700]),\n  ('control: unrounded base', ([10025], ['1']), [10025]), ('control: no years', ([11600, 47150], []), [11600, 47150]),\n  ('control: three years', ([47150, 100525, 191950], ['1.054', '1.032', '1.028']), [52700, 112400, 214600]),\n  ('control: two years', ([10000, 40000], ['1.031', '1.029']), [10600, 42400])],\n [('regression index-from-rounded 1', ([10000, 47150, 191950], ['1.0605', '1.0510', '0.9809', '1.0498']),\n   [11450, 54100, 220300]),\n  ('regression index-from-rounded 2', ([11600, 243725], ['1.0641', '1.0478', '0.9707', '1.0624', '1.0640']),\n   [14150, 298150]),\n  ('partial repair guard 1', ([47150, 100525, 11600], ['1.0430', '1.0034', '0.9845', '0.9761']),\n   [49300, 105200, 12100]),\n  ('partial repair guard 2', ([11600, 609350], ['1.0003', '1.0039', '1.0541', '1.0389', '1.0444']), [13300, 699850]),\n  ('control: two years', ([10000, 40000], ['1.031', '1.029']), [10600, 42400]),\n  ('control: small compounding', ([10000], ['1.0049', '1.0049']), [10050]),\n  ('control: deflation year', ([10000], ['1.02', '0.97']), [10200]),\n  ('control: unrounded base', ([10025], ['1']), [10025])]]\nfor label, args, expected in cases[N - 1]:\n    check(label, solve(*args), expected)\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"}},"limitations":"A deterministic, bounded teaching model with a stipulated toy contract; it makes no claim of conformance to any real regulation, standard, or institution's rules. 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.","method":"Deterministic executable model with adversarial boundary fixtures.","provenance":{"created_by":"Failure Map","dependencies":"Python standard library","family":"w2-tax_bracket_computation-threshold-inflation-indexing-index-from-rounded","generated_at":"2026-09-29T14:47:04.324256+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Tax computations hinge on which slice, threshold, ordering and rounding rule applies at each step; a misplaced boundary silently misstates liabilities.","root_cause":"The factor is applied to last year's rounded threshold instead of the unrounded base.","sha256":"4fcb74d8d51ed7ce11181b81a625861b7663a964ed8ba20db9b8d60e53274f77","title":"Each year indexes the previously rounded threshold · case 01","variant":1,"variant_policy":"Five numbered records share a model and may reuse boundary fixtures.","verified":true,"visibility":"public","verification":{"attempt":{"elapsed_ms":41.072,"exit_code":1,"observations":[{"actual":[10050],"check":"regression index-from-rounded 1","expected":[10050],"passed":true},{"actual":[52700,112400,214600],"check":"regression index-from-rounded 2","expected":[52700,112400,214600],"passed":true},{"actual":[49900,49900,645150],"check":"partial repair guard 1","expected":[49900,49900,645200],"passed":false},{"actual":[283850],"check":"partial repair guard 2","expected":[283900],"passed":false},{"actual":[10600,42400],"check":"control: two years","expected":[10600,42400],"passed":true},{"actual":[10200],"check":"control: deflation year","expected":[10200],"passed":true},{"actual":[10025],"check":"control: unrounded base","expected":[10025],"passed":true},{"actual":[11600,47150],"check":"control: no years","expected":[11600,47150],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"regression index-from-rounded 1\", \"actual\": [10050], \"expected\": [10050], \"passed\": true}, {\"check\": \"regression index-from-rounded 2\", \"actual\": [52700, 112400, 214600], \"expected\": [52700, 112400, 214600], \"passed\": true}, {\"check\": \"partial repair guard 1\", \"actual\": [49900, 49900, 645150], \"expected\": [49900, 49900, 645200], \"passed\": false}, {\"check\": \"partial repair guard 2\", \"actual\": [283850], \"expected\": [283900], \"passed\": false}, {\"check\": \"control: two years\", \"actual\": [10600, 42400], \"expected\": [10600, 42400], \"passed\": true}, {\"check\": \"control: deflation year\", \"actual\": [10200], \"expected\": [10200], \"passed\": true}, {\"check\": \"control: unrounded base\", \"actual\": [10025], \"expected\": [10025], \"passed\": true}, {\"check\": \"control: no years\", \"actual\": [11600, 47150], \"expected\": [11600, 47150], \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":41.474,"exit_code":1,"observations":[{"actual":[10000],"check":"regression index-from-rounded 1","expected":[10050],"passed":false},{"actual":[52600,112350,214550],"check":"regression index-from-rounded 2","expected":[52700,112400,214600],"passed":false},{"actual":[50800,50800,656600],"check":"partial repair guard 1","expected":[49900,49900,645200],"passed":false},{"actual":[286250],"check":"partial repair guard 2","expected":[283900],"passed":false},{"actual":[10550,42350],"check":"control: two years","expected":[10600,42400],"passed":false},{"actual":[10200],"check":"control: deflation year","expected":[10200],"passed":true},{"actual":[10025],"check":"control: unrounded base","expected":[10025],"passed":true},{"actual":[11600,47150],"check":"control: no years","expected":[11600,47150],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"regression index-from-rounded 1\", \"actual\": [10000], \"expected\": [10050], \"passed\": false}, {\"check\": \"regression index-from-rounded 2\", \"actual\": [52600, 112350, 214550], \"expected\": [52700, 112400, 214600], \"passed\": false}, {\"check\": \"partial repair guard 1\", \"actual\": [50800, 50800, 656600], \"expected\": [49900, 49900, 645200], \"passed\": false}, {\"check\": \"partial repair guard 2\", \"actual\": [286250], \"expected\": [283900], \"passed\": false}, {\"check\": \"control: two years\", \"actual\": [10550, 42350], \"expected\": [10600, 42400], \"passed\": false}, {\"check\": \"control: deflation year\", \"actual\": [10200], \"expected\": [10200], \"passed\": true}, {\"check\": \"control: unrounded base\", \"actual\": [10025], \"expected\": [10025], \"passed\": true}, {\"check\": \"control: no years\", \"actual\": [11600, 47150], \"expected\": [11600, 47150], \"passed\": true}], \"passed\": false}\n"}},"member_only":{"stages":["fixed"],"fields":["implementations.fixed","verification.fixed","harness","repair"],"note":"The verified repair, its recorded checks, the repair description, and the scoring harness are available to members."}}