FAILURE MAP
← Case archive

FA-85916 / Game economy crafting balance / Open access

Banner pity counter: First soft pity pull uses base rate · case 01

The advertised first soft-pity pull gets no boosted rate.

Verified by executionVariant 1 · 8 checks per implementationDownload source bundle ↓JSON ↗

ROOT CAUSE

The soft-pity boundary is strict, skipping pull 74.

VERIFIED REPAIR

Restore `if n >= 74:` at the soft pity start step.

Unsuccessful approach: Moving the boundary to pull 80 delays the ramp even further.

Case contract

Each roll is 0..999. Pull number n = pity+1. Top-rarity rate is 6 per mille, plus 50*(n-73) from n >= 74 (soft pity); n >= 90 always hits. On a hit pity resets to 0; the item is featured ("F") if guarantee is set or the roll is even, otherwise lost ("L") and the guarantee is set; a featured hit clears the guarantee. Misses ("-") set pity = n.

Why this case matters

Game economies leak or destroy currency when one crafting or pricing rule is off by one boundary, rounding stage or state update; the defect is observable in exact integer outcomes.

1 / The failure

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json

N = 1
observations = []
def solve(rolls, state):
    pity = state['pity']
    guarantee = state['guarantee']
    out = []
    for r in rolls:
        n = pity + 1
        rate = 6
        if n > 74:
            rate += 50 * (n - 73)
        if n >= 90 or r < rate:
            pity = 0
            if guarantee or r % 2 == 0:
                out.append('F')
                guarantee = False
            else:
                out.append('L')
                guarantee = True
        else:
            pity = n
            out.append('-')
    return {'results': ''.join(out), 'pity': pity, 'guarantee': guarantee}
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
cases = [[('regression soft pity start #1',
   [[50, 38, 898, 817, 564, 877, 22, 812, 15, 0, 190], {'pity': 73, 'guarantee': True}],
   {'results': 'F--------F-', 'pity': 1, 'guarantee': False}),
  ('regression soft pity start #2',
   [[43, 52, 75, 813, 828, 669, 557, 11, 855, 17, 999, 899, 730, 13, 836, 14, 713],
    {'pity': 72, 'guarantee': True}],
   {'results': '-F---------------', 'pity': 15, 'guarantee': False}),
  ('partial repair boundary #1',
   [[507, 965, 27, 525, 851], {'pity': 73, 'guarantee': True}],
   {'results': '--F--', 'pity': 2, 'guarantee': False}),
  ('partial repair boundary #2',
   [[815, 889, 39, 873, 939, 933, 908, 992, 421, 939, 821, 53, 12, 40, 8, 884, 975, 551, 967, 39],
    {'pity': 63, 'guarantee': True}],
   {'results': '-----------F--------', 'pity': 8, 'guarantee': False}),
  ('hard pity pull #1',
   [[999, 999], {'pity': 89, 'guarantee': False}],
   {'results': 'L-', 'pity': 1, 'guarantee': True}),
  ('first soft pity pull #1',
   [[100, 3], {'pity': 73, 'guarantee': True}],
   {'results': '-F', 'pity': 0, 'guarantee': False}),
  ('lost fifty fifty then featured #1',
   [[1, 999, 0], {'pity': 10, 'guarantee': False}],
   {'results': 'L-F', 'pity': 0, 'guarantee': False}),
  ('control #1',
   [[15, 31, 302, 259, 332, 886, 12, 851, 55, 45, 6, 903, 946, 869, 725], {'pity': 88, 'guarantee': True}],
   {'results': 'F--------------', 'pity': 14, 'guarantee': False})],
 [('regression soft pity start #1',
   [[55, 51, 37, 985, 339, 849, 34, 33, 811, 935, 6, 3], {'pity': 66, 'guarantee': False}],
   {'results': '-------L---F', 'pity': 0, 'guarantee': False}),
  ('regression soft pity start #2',
   [[52, 34, 15, 820, 60, 952, 28, 17, 954, 687, 731, 3, 889, 15, 985, 37], {'pity': 71, 'guarantee': False}],
   {'results': '--L--------F----', 'pity': 4, 'guarantee': False}),
  ('partial repair boundary #1',
   [[18, 16, 60, 53, 197, 713, 972, 933], {'pity': 75, 'guarantee': True}],
   {'results': 'F-------', 'pity': 7, 'guarantee': False}),
  ('partial repair boundary #2',
   [[54, 849, 304, 44], {'pity': 72, 'guarantee': True}],
   {'results': '---F', 'pity': 0, 'guarantee': False}),
  ('lost fifty fifty then featured #1',
   [[1, 999, 0], {'pity': 10, 'guarantee': False}],
   {'results': 'L-F', 'pity': 0, 'guarantee': False}),
  ('hard pity pull #1',
   [[999, 999], {'pity': 89, 'guarantee': False}],
   {'results': 'L-', 'pity': 1, 'guarantee': True}),
  ('control #1',
   [[15, 31, 302, 259, 332, 886, 12, 851, 55, 45, 6, 903, 946, 869, 725], {'pity': 88, 'guarantee': True}],
   {'results': 'F--------------', 'pity': 14, 'guarantee': False}),
  ('control #2',
   [[480, 489, 823, 13, 936, 776, 44, 409, 26, 974, 9, 54, 911, 804, 433, 47, 942, 847],
    {'pity': 89, 'guarantee': True}],
   {'results': 'F-----------------', 'pity': 17, 'guarantee': False})],
 [('regression soft pity start #1',
   [[32, 1], {'pity': 73, 'guarantee': False}],
   {'results': 'FL', 'pity': 0, 'guarantee': True}),
  ('regression soft pity start #2',
   [[875, 20, 11, 41, 521, 27, 780, 997, 455, 927, 244, 830, 270, 917, 57, 59, 17, 51],
    {'pity': 72, 'guarantee': False}],
   {'results': '-F----------------', 'pity': 16, 'guarantee': False}),
  ('partial repair boundary #1',
   [[346, 740, 973, 629, 933, 35, 831, 930, 214, 969, 923], {'pity': 73, 'guarantee': False}],
   {'results': '-----L-----', 'pity': 5, 'guarantee': True}),
  ('partial repair boundary #2',
   [[977, 15, 30, 31, 556, 481, 841, 29, 15, 723, 44, 251, 24], {'pity': 73, 'guarantee': True}],
   {'results': '-F-----------', 'pity': 11, 'guarantee': False}),
  ('first soft pity pull #1',
   [[100, 3], {'pity': 73, 'guarantee': True}],
   {'results': '-F', 'pity': 0, 'guarantee': False}),
  ('lost fifty fifty then featured #1',
   [[1, 999, 0], {'pity': 10, 'guarantee': False}],
   {'results': 'L-F', 'pity': 0, 'guarantee': False}),
  ('control #1',
   [[480, 489, 823, 13, 936, 776, 44, 409, 26, 974, 9, 54, 911, 804, 433, 47, 942, 847],
    {'pity': 89, 'guarantee': True}],
   {'results': 'F-----------------', 'pity': 17, 'guarantee': False}),
  ('control #2',
   [[922, 571, 11, 40, 49, 776, 996, 952, 946, 14, 108, 822, 888, 25], {'pity': 84, 'guarantee': False}],
   {'results': '-L------------', 'pity': 12, 'guarantee': True})],
 [('regression soft pity start #1',
   [[25, 15, 19, 2, 45, 34, 523, 824, 29, 272, 697], {'pity': 72, 'guarantee': True}],
   {'results': '-F-F-------', 'pity': 7, 'guarantee': False}),
  ('regression soft pity start #2',
   [[35, 814, 40, 956, 3, 418, 44, 36, 812, 906, 868, 800, 42, 866, 926], {'pity': 73, 'guarantee': True}],
   {'results': 'F---L----------', 'pity': 10, 'guarantee': True}),
  ('partial repair boundary #1',
   [[54, 861, 805, 816, 40, 902, 32, 646, 847, 32, 80, 234, 148, 476, 13], {'pity': 72, 'guarantee': True}],
   {'results': '----F----------', 'pity': 10, 'guarantee': False}),
  ('regression soft pity start #3',
   [[50, 38, 898, 817, 564, 877, 22, 812, 15, 0, 190], {'pity': 73, 'guarantee': True}],
   {'results': 'F--------F-', 'pity': 1, 'guarantee': False}),
  ('hard pity pull #1',
   [[999, 999], {'pity': 89, 'guarantee': False}],
   {'results': 'L-', 'pity': 1, 'guarantee': True}),
  ('first soft pity pull #1',
   [[100, 3], {'pity': 73, 'guarantee': True}],
   {'results': '-F', 'pity': 0, 'guarantee': False}),
  ('control #1', [[911], {'pity': 73, 'guarantee': True}], {'results': '-', 'pity': 74, 'guarantee': True}),
  ('control #2',
   [[18, 973, 5], {'pity': 72, 'guarantee': False}],
   {'results': '--L', 'pity': 0, 'guarantee': True})],
 [('regression soft pity start #1',
   [[633, 19, 988, 444, 13, 683, 926, 9, 362, 59, 866, 928, 889, 983, 202, 35, 13],
    {'pity': 72, 'guarantee': True}],
   {'results': '-F---------------', 'pity': 15, 'guarantee': False}),
  ('regression soft pity start #2',
   [[50, 974, 37, 32, 926, 934, 26, 44, 6, 977, 12, 958, 725, 30, 653], {'pity': 73, 'guarantee': False}],
   {'results': 'F--------------', 'pity': 14, 'guarantee': False}),
  ('partial repair boundary #1',
   [[984, 954, 47, 297, 21, 192, 35, 1, 87, 521, 965, 945, 130, 990], {'pity': 72, 'guarantee': True}],
   {'results': '--F----L------', 'pity': 6, 'guarantee': True}),
  ('partial repair boundary #2',
   [[891, 307, 20, 907, 30, 974, 462, 957, 860, 624, 42, 985, 46], {'pity': 73, 'guarantee': False}],
   {'results': '--F----------', 'pity': 10, 'guarantee': False}),
  ('lost fifty fifty then featured #1',
   [[1, 999, 0], {'pity': 10, 'guarantee': False}],
   {'results': 'L-F', 'pity': 0, 'guarantee': False}),
  ('hard pity pull #1',
   [[999, 999], {'pity': 89, 'guarantee': False}],
   {'results': 'L-', 'pity': 1, 'guarantee': True}),
  ('control #1',
   [[935, 90, 29, 166, 937, 997, 903, 315, 848, 1, 893, 36, 218, 730, 858, 726, 972, 10],
    {'pity': 89, 'guarantee': True}],
   {'results': 'F--------L--------', 'pity': 8, 'guarantee': True}),
  ('control #2',
   [[4, 155, 441, 951, 967, 353, 21], {'pity': 68, 'guarantee': False}],
   {'results': 'F------', 'pity': 6, 'guarantee': False})]]
for label, args, expected in cases[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 fixtureActualExpectedOutcome
regression soft pity start #1{'guarantee': False, 'pity': 1, 'results': '-F-------F-'}{'guarantee': False, 'pity': 1, 'results': 'F--------F-'}Failed
regression soft pity start #2{'guarantee': False, 'pity': 14, 'results': '--F--------------'}{'guarantee': False, 'pity': 15, 'results': '-F---------------'}Failed
partial repair boundary #1{'guarantee': False, 'pity': 2, 'results': '--F--'}{'guarantee': False, 'pity': 2, 'results': '--F--'}Passed
partial repair boundary #2{'guarantee': False, 'pity': 8, 'results': '-----------F--------'}{'guarantee': False, 'pity': 8, 'results': '-----------F--------'}Passed
hard pity pull #1{'guarantee': True, 'pity': 1, 'results': 'L-'}{'guarantee': True, 'pity': 1, 'results': 'L-'}Passed
first soft pity pull #1{'guarantee': False, 'pity': 0, 'results': '-F'}{'guarantee': False, 'pity': 0, 'results': '-F'}Passed
lost fifty fifty then featured #1{'guarantee': False, 'pity': 0, 'results': 'L-F'}{'guarantee': False, 'pity': 0, 'results': 'L-F'}Passed
control #1{'guarantee': False, 'pity': 14, 'results': 'F--------------'}{'guarantee': False, 'pity': 14, 'results': 'F--------------'}Passed

SHA-256 / 1283cf5c70ffb84f1b49df4c61e3e430e66bb00d0d5f7f0a09aa4a43db873cb1

2 / The unsuccessful fix

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json

N = 1
observations = []
def solve(rolls, state):
    pity = state['pity']
    guarantee = state['guarantee']
    out = []
    for r in rolls:
        n = pity + 1
        rate = 6
        if n >= 80:
            rate += 50 * (n - 73)
        if n >= 90 or r < rate:
            pity = 0
            if guarantee or r % 2 == 0:
                out.append('F')
                guarantee = False
            else:
                out.append('L')
                guarantee = True
        else:
            pity = n
            out.append('-')
    return {'results': ''.join(out), 'pity': pity, 'guarantee': guarantee}
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
cases = [[('regression soft pity start #1',
   [[50, 38, 898, 817, 564, 877, 22, 812, 15, 0, 190], {'pity': 73, 'guarantee': True}],
   {'results': 'F--------F-', 'pity': 1, 'guarantee': False}),
  ('regression soft pity start #2',
   [[43, 52, 75, 813, 828, 669, 557, 11, 855, 17, 999, 899, 730, 13, 836, 14, 713],
    {'pity': 72, 'guarantee': True}],
   {'results': '-F---------------', 'pity': 15, 'guarantee': False}),
  ('partial repair boundary #1',
   [[507, 965, 27, 525, 851], {'pity': 73, 'guarantee': True}],
   {'results': '--F--', 'pity': 2, 'guarantee': False}),
  ('partial repair boundary #2',
   [[815, 889, 39, 873, 939, 933, 908, 992, 421, 939, 821, 53, 12, 40, 8, 884, 975, 551, 967, 39],
    {'pity': 63, 'guarantee': True}],
   {'results': '-----------F--------', 'pity': 8, 'guarantee': False}),
  ('hard pity pull #1',
   [[999, 999], {'pity': 89, 'guarantee': False}],
   {'results': 'L-', 'pity': 1, 'guarantee': True}),
  ('first soft pity pull #1',
   [[100, 3], {'pity': 73, 'guarantee': True}],
   {'results': '-F', 'pity': 0, 'guarantee': False}),
  ('lost fifty fifty then featured #1',
   [[1, 999, 0], {'pity': 10, 'guarantee': False}],
   {'results': 'L-F', 'pity': 0, 'guarantee': False}),
  ('control #1',
   [[15, 31, 302, 259, 332, 886, 12, 851, 55, 45, 6, 903, 946, 869, 725], {'pity': 88, 'guarantee': True}],
   {'results': 'F--------------', 'pity': 14, 'guarantee': False})],
 [('regression soft pity start #1',
   [[55, 51, 37, 985, 339, 849, 34, 33, 811, 935, 6, 3], {'pity': 66, 'guarantee': False}],
   {'results': '-------L---F', 'pity': 0, 'guarantee': False}),
  ('regression soft pity start #2',
   [[52, 34, 15, 820, 60, 952, 28, 17, 954, 687, 731, 3, 889, 15, 985, 37], {'pity': 71, 'guarantee': False}],
   {'results': '--L--------F----', 'pity': 4, 'guarantee': False}),
  ('partial repair boundary #1',
   [[18, 16, 60, 53, 197, 713, 972, 933], {'pity': 75, 'guarantee': True}],
   {'results': 'F-------', 'pity': 7, 'guarantee': False}),
  ('partial repair boundary #2',
   [[54, 849, 304, 44], {'pity': 72, 'guarantee': True}],
   {'results': '---F', 'pity': 0, 'guarantee': False}),
  ('lost fifty fifty then featured #1',
   [[1, 999, 0], {'pity': 10, 'guarantee': False}],
   {'results': 'L-F', 'pity': 0, 'guarantee': False}),
  ('hard pity pull #1',
   [[999, 999], {'pity': 89, 'guarantee': False}],
   {'results': 'L-', 'pity': 1, 'guarantee': True}),
  ('control #1',
   [[15, 31, 302, 259, 332, 886, 12, 851, 55, 45, 6, 903, 946, 869, 725], {'pity': 88, 'guarantee': True}],
   {'results': 'F--------------', 'pity': 14, 'guarantee': False}),
  ('control #2',
   [[480, 489, 823, 13, 936, 776, 44, 409, 26, 974, 9, 54, 911, 804, 433, 47, 942, 847],
    {'pity': 89, 'guarantee': True}],
   {'results': 'F-----------------', 'pity': 17, 'guarantee': False})],
 [('regression soft pity start #1',
   [[32, 1], {'pity': 73, 'guarantee': False}],
   {'results': 'FL', 'pity': 0, 'guarantee': True}),
  ('regression soft pity start #2',
   [[875, 20, 11, 41, 521, 27, 780, 997, 455, 927, 244, 830, 270, 917, 57, 59, 17, 51],
    {'pity': 72, 'guarantee': False}],
   {'results': '-F----------------', 'pity': 16, 'guarantee': False}),
  ('partial repair boundary #1',
   [[346, 740, 973, 629, 933, 35, 831, 930, 214, 969, 923], {'pity': 73, 'guarantee': False}],
   {'results': '-----L-----', 'pity': 5, 'guarantee': True}),
  ('partial repair boundary #2',
   [[977, 15, 30, 31, 556, 481, 841, 29, 15, 723, 44, 251, 24], {'pity': 73, 'guarantee': True}],
   {'results': '-F-----------', 'pity': 11, 'guarantee': False}),
  ('first soft pity pull #1',
   [[100, 3], {'pity': 73, 'guarantee': True}],
   {'results': '-F', 'pity': 0, 'guarantee': False}),
  ('lost fifty fifty then featured #1',
   [[1, 999, 0], {'pity': 10, 'guarantee': False}],
   {'results': 'L-F', 'pity': 0, 'guarantee': False}),
  ('control #1',
   [[480, 489, 823, 13, 936, 776, 44, 409, 26, 974, 9, 54, 911, 804, 433, 47, 942, 847],
    {'pity': 89, 'guarantee': True}],
   {'results': 'F-----------------', 'pity': 17, 'guarantee': False}),
  ('control #2',
   [[922, 571, 11, 40, 49, 776, 996, 952, 946, 14, 108, 822, 888, 25], {'pity': 84, 'guarantee': False}],
   {'results': '-L------------', 'pity': 12, 'guarantee': True})],
 [('regression soft pity start #1',
   [[25, 15, 19, 2, 45, 34, 523, 824, 29, 272, 697], {'pity': 72, 'guarantee': True}],
   {'results': '-F-F-------', 'pity': 7, 'guarantee': False}),
  ('regression soft pity start #2',
   [[35, 814, 40, 956, 3, 418, 44, 36, 812, 906, 868, 800, 42, 866, 926], {'pity': 73, 'guarantee': True}],
   {'results': 'F---L----------', 'pity': 10, 'guarantee': True}),
  ('partial repair boundary #1',
   [[54, 861, 805, 816, 40, 902, 32, 646, 847, 32, 80, 234, 148, 476, 13], {'pity': 72, 'guarantee': True}],
   {'results': '----F----------', 'pity': 10, 'guarantee': False}),
  ('regression soft pity start #3',
   [[50, 38, 898, 817, 564, 877, 22, 812, 15, 0, 190], {'pity': 73, 'guarantee': True}],
   {'results': 'F--------F-', 'pity': 1, 'guarantee': False}),
  ('hard pity pull #1',
   [[999, 999], {'pity': 89, 'guarantee': False}],
   {'results': 'L-', 'pity': 1, 'guarantee': True}),
  ('first soft pity pull #1',
   [[100, 3], {'pity': 73, 'guarantee': True}],
   {'results': '-F', 'pity': 0, 'guarantee': False}),
  ('control #1', [[911], {'pity': 73, 'guarantee': True}], {'results': '-', 'pity': 74, 'guarantee': True}),
  ('control #2',
   [[18, 973, 5], {'pity': 72, 'guarantee': False}],
   {'results': '--L', 'pity': 0, 'guarantee': True})],
 [('regression soft pity start #1',
   [[633, 19, 988, 444, 13, 683, 926, 9, 362, 59, 866, 928, 889, 983, 202, 35, 13],
    {'pity': 72, 'guarantee': True}],
   {'results': '-F---------------', 'pity': 15, 'guarantee': False}),
  ('regression soft pity start #2',
   [[50, 974, 37, 32, 926, 934, 26, 44, 6, 977, 12, 958, 725, 30, 653], {'pity': 73, 'guarantee': False}],
   {'results': 'F--------------', 'pity': 14, 'guarantee': False}),
  ('partial repair boundary #1',
   [[984, 954, 47, 297, 21, 192, 35, 1, 87, 521, 965, 945, 130, 990], {'pity': 72, 'guarantee': True}],
   {'results': '--F----L------', 'pity': 6, 'guarantee': True}),
  ('partial repair boundary #2',
   [[891, 307, 20, 907, 30, 974, 462, 957, 860, 624, 42, 985, 46], {'pity': 73, 'guarantee': False}],
   {'results': '--F----------', 'pity': 10, 'guarantee': False}),
  ('lost fifty fifty then featured #1',
   [[1, 999, 0], {'pity': 10, 'guarantee': False}],
   {'results': 'L-F', 'pity': 0, 'guarantee': False}),
  ('hard pity pull #1',
   [[999, 999], {'pity': 89, 'guarantee': False}],
   {'results': 'L-', 'pity': 1, 'guarantee': True}),
  ('control #1',
   [[935, 90, 29, 166, 937, 997, 903, 315, 848, 1, 893, 36, 218, 730, 858, 726, 972, 10],
    {'pity': 89, 'guarantee': True}],
   {'results': 'F--------L--------', 'pity': 8, 'guarantee': True}),
  ('control #2',
   [[4, 155, 441, 951, 967, 353, 21], {'pity': 68, 'guarantee': False}],
   {'results': 'F------', 'pity': 6, 'guarantee': False})]]
for label, args, expected in cases[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 fixtureActualExpectedOutcome
regression soft pity start #1{'guarantee': False, 'pity': 1, 'results': '------F--F-'}{'guarantee': False, 'pity': 1, 'results': 'F--------F-'}Failed
regression soft pity start #2{'guarantee': False, 'pity': 9, 'results': '-------F---------'}{'guarantee': False, 'pity': 15, 'results': '-F---------------'}Failed
partial repair boundary #1{'guarantee': True, 'pity': 78, 'results': '-----'}{'guarantee': False, 'pity': 2, 'results': '--F--'}Failed
partial repair boundary #2{'guarantee': False, 'pity': 0, 'results': '-------------------F'}{'guarantee': False, 'pity': 8, 'results': '-----------F--------'}Failed
hard pity pull #1{'guarantee': True, 'pity': 1, 'results': 'L-'}{'guarantee': True, 'pity': 1, 'results': 'L-'}Passed
first soft pity pull #1{'guarantee': False, 'pity': 0, 'results': '-F'}{'guarantee': False, 'pity': 0, 'results': '-F'}Passed
lost fifty fifty then featured #1{'guarantee': False, 'pity': 0, 'results': 'L-F'}{'guarantee': False, 'pity': 0, 'results': 'L-F'}Passed
control #1{'guarantee': False, 'pity': 14, 'results': 'F--------------'}{'guarantee': False, 'pity': 14, 'results': 'F--------------'}Passed

SHA-256 / 5d95deaaff73208280a897f84948edd4cf132ab1696058d7504312af090217d5

3 / The verified repair

Exit 0
"""Failure Map reference implementation. Python standard library only."""
import json

N = 1
observations = []
def solve(rolls, state):
    pity = state['pity']
    guarantee = state['guarantee']
    out = []
    for r in rolls:
        n = pity + 1
        rate = 6
        if n >= 74:
            rate += 50 * (n - 73)
        if n >= 90 or r < rate:
            pity = 0
            if guarantee or r % 2 == 0:
                out.append('F')
                guarantee = False
            else:
                out.append('L')
                guarantee = True
        else:
            pity = n
            out.append('-')
    return {'results': ''.join(out), 'pity': pity, 'guarantee': guarantee}
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
cases = [[('regression soft pity start #1',
   [[50, 38, 898, 817, 564, 877, 22, 812, 15, 0, 190], {'pity': 73, 'guarantee': True}],
   {'results': 'F--------F-', 'pity': 1, 'guarantee': False}),
  ('regression soft pity start #2',
   [[43, 52, 75, 813, 828, 669, 557, 11, 855, 17, 999, 899, 730, 13, 836, 14, 713],
    {'pity': 72, 'guarantee': True}],
   {'results': '-F---------------', 'pity': 15, 'guarantee': False}),
  ('partial repair boundary #1',
   [[507, 965, 27, 525, 851], {'pity': 73, 'guarantee': True}],
   {'results': '--F--', 'pity': 2, 'guarantee': False}),
  ('partial repair boundary #2',
   [[815, 889, 39, 873, 939, 933, 908, 992, 421, 939, 821, 53, 12, 40, 8, 884, 975, 551, 967, 39],
    {'pity': 63, 'guarantee': True}],
   {'results': '-----------F--------', 'pity': 8, 'guarantee': False}),
  ('hard pity pull #1',
   [[999, 999], {'pity': 89, 'guarantee': False}],
   {'results': 'L-', 'pity': 1, 'guarantee': True}),
  ('first soft pity pull #1',
   [[100, 3], {'pity': 73, 'guarantee': True}],
   {'results': '-F', 'pity': 0, 'guarantee': False}),
  ('lost fifty fifty then featured #1',
   [[1, 999, 0], {'pity': 10, 'guarantee': False}],
   {'results': 'L-F', 'pity': 0, 'guarantee': False}),
  ('control #1',
   [[15, 31, 302, 259, 332, 886, 12, 851, 55, 45, 6, 903, 946, 869, 725], {'pity': 88, 'guarantee': True}],
   {'results': 'F--------------', 'pity': 14, 'guarantee': False})],
 [('regression soft pity start #1',
   [[55, 51, 37, 985, 339, 849, 34, 33, 811, 935, 6, 3], {'pity': 66, 'guarantee': False}],
   {'results': '-------L---F', 'pity': 0, 'guarantee': False}),
  ('regression soft pity start #2',
   [[52, 34, 15, 820, 60, 952, 28, 17, 954, 687, 731, 3, 889, 15, 985, 37], {'pity': 71, 'guarantee': False}],
   {'results': '--L--------F----', 'pity': 4, 'guarantee': False}),
  ('partial repair boundary #1',
   [[18, 16, 60, 53, 197, 713, 972, 933], {'pity': 75, 'guarantee': True}],
   {'results': 'F-------', 'pity': 7, 'guarantee': False}),
  ('partial repair boundary #2',
   [[54, 849, 304, 44], {'pity': 72, 'guarantee': True}],
   {'results': '---F', 'pity': 0, 'guarantee': False}),
  ('lost fifty fifty then featured #1',
   [[1, 999, 0], {'pity': 10, 'guarantee': False}],
   {'results': 'L-F', 'pity': 0, 'guarantee': False}),
  ('hard pity pull #1',
   [[999, 999], {'pity': 89, 'guarantee': False}],
   {'results': 'L-', 'pity': 1, 'guarantee': True}),
  ('control #1',
   [[15, 31, 302, 259, 332, 886, 12, 851, 55, 45, 6, 903, 946, 869, 725], {'pity': 88, 'guarantee': True}],
   {'results': 'F--------------', 'pity': 14, 'guarantee': False}),
  ('control #2',
   [[480, 489, 823, 13, 936, 776, 44, 409, 26, 974, 9, 54, 911, 804, 433, 47, 942, 847],
    {'pity': 89, 'guarantee': True}],
   {'results': 'F-----------------', 'pity': 17, 'guarantee': False})],
 [('regression soft pity start #1',
   [[32, 1], {'pity': 73, 'guarantee': False}],
   {'results': 'FL', 'pity': 0, 'guarantee': True}),
  ('regression soft pity start #2',
   [[875, 20, 11, 41, 521, 27, 780, 997, 455, 927, 244, 830, 270, 917, 57, 59, 17, 51],
    {'pity': 72, 'guarantee': False}],
   {'results': '-F----------------', 'pity': 16, 'guarantee': False}),
  ('partial repair boundary #1',
   [[346, 740, 973, 629, 933, 35, 831, 930, 214, 969, 923], {'pity': 73, 'guarantee': False}],
   {'results': '-----L-----', 'pity': 5, 'guarantee': True}),
  ('partial repair boundary #2',
   [[977, 15, 30, 31, 556, 481, 841, 29, 15, 723, 44, 251, 24], {'pity': 73, 'guarantee': True}],
   {'results': '-F-----------', 'pity': 11, 'guarantee': False}),
  ('first soft pity pull #1',
   [[100, 3], {'pity': 73, 'guarantee': True}],
   {'results': '-F', 'pity': 0, 'guarantee': False}),
  ('lost fifty fifty then featured #1',
   [[1, 999, 0], {'pity': 10, 'guarantee': False}],
   {'results': 'L-F', 'pity': 0, 'guarantee': False}),
  ('control #1',
   [[480, 489, 823, 13, 936, 776, 44, 409, 26, 974, 9, 54, 911, 804, 433, 47, 942, 847],
    {'pity': 89, 'guarantee': True}],
   {'results': 'F-----------------', 'pity': 17, 'guarantee': False}),
  ('control #2',
   [[922, 571, 11, 40, 49, 776, 996, 952, 946, 14, 108, 822, 888, 25], {'pity': 84, 'guarantee': False}],
   {'results': '-L------------', 'pity': 12, 'guarantee': True})],
 [('regression soft pity start #1',
   [[25, 15, 19, 2, 45, 34, 523, 824, 29, 272, 697], {'pity': 72, 'guarantee': True}],
   {'results': '-F-F-------', 'pity': 7, 'guarantee': False}),
  ('regression soft pity start #2',
   [[35, 814, 40, 956, 3, 418, 44, 36, 812, 906, 868, 800, 42, 866, 926], {'pity': 73, 'guarantee': True}],
   {'results': 'F---L----------', 'pity': 10, 'guarantee': True}),
  ('partial repair boundary #1',
   [[54, 861, 805, 816, 40, 902, 32, 646, 847, 32, 80, 234, 148, 476, 13], {'pity': 72, 'guarantee': True}],
   {'results': '----F----------', 'pity': 10, 'guarantee': False}),
  ('regression soft pity start #3',
   [[50, 38, 898, 817, 564, 877, 22, 812, 15, 0, 190], {'pity': 73, 'guarantee': True}],
   {'results': 'F--------F-', 'pity': 1, 'guarantee': False}),
  ('hard pity pull #1',
   [[999, 999], {'pity': 89, 'guarantee': False}],
   {'results': 'L-', 'pity': 1, 'guarantee': True}),
  ('first soft pity pull #1',
   [[100, 3], {'pity': 73, 'guarantee': True}],
   {'results': '-F', 'pity': 0, 'guarantee': False}),
  ('control #1', [[911], {'pity': 73, 'guarantee': True}], {'results': '-', 'pity': 74, 'guarantee': True}),
  ('control #2',
   [[18, 973, 5], {'pity': 72, 'guarantee': False}],
   {'results': '--L', 'pity': 0, 'guarantee': True})],
 [('regression soft pity start #1',
   [[633, 19, 988, 444, 13, 683, 926, 9, 362, 59, 866, 928, 889, 983, 202, 35, 13],
    {'pity': 72, 'guarantee': True}],
   {'results': '-F---------------', 'pity': 15, 'guarantee': False}),
  ('regression soft pity start #2',
   [[50, 974, 37, 32, 926, 934, 26, 44, 6, 977, 12, 958, 725, 30, 653], {'pity': 73, 'guarantee': False}],
   {'results': 'F--------------', 'pity': 14, 'guarantee': False}),
  ('partial repair boundary #1',
   [[984, 954, 47, 297, 21, 192, 35, 1, 87, 521, 965, 945, 130, 990], {'pity': 72, 'guarantee': True}],
   {'results': '--F----L------', 'pity': 6, 'guarantee': True}),
  ('partial repair boundary #2',
   [[891, 307, 20, 907, 30, 974, 462, 957, 860, 624, 42, 985, 46], {'pity': 73, 'guarantee': False}],
   {'results': '--F----------', 'pity': 10, 'guarantee': False}),
  ('lost fifty fifty then featured #1',
   [[1, 999, 0], {'pity': 10, 'guarantee': False}],
   {'results': 'L-F', 'pity': 0, 'guarantee': False}),
  ('hard pity pull #1',
   [[999, 999], {'pity': 89, 'guarantee': False}],
   {'results': 'L-', 'pity': 1, 'guarantee': True}),
  ('control #1',
   [[935, 90, 29, 166, 937, 997, 903, 315, 848, 1, 893, 36, 218, 730, 858, 726, 972, 10],
    {'pity': 89, 'guarantee': True}],
   {'results': 'F--------L--------', 'pity': 8, 'guarantee': True}),
  ('control #2',
   [[4, 155, 441, 951, 967, 353, 21], {'pity': 68, 'guarantee': False}],
   {'results': 'F------', 'pity': 6, 'guarantee': False})]]
for label, args, expected in cases[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 fixtureActualExpectedOutcome
regression soft pity start #1{'guarantee': False, 'pity': 1, 'results': 'F--------F-'}{'guarantee': False, 'pity': 1, 'results': 'F--------F-'}Passed
regression soft pity start #2{'guarantee': False, 'pity': 15, 'results': '-F---------------'}{'guarantee': False, 'pity': 15, 'results': '-F---------------'}Passed
partial repair boundary #1{'guarantee': False, 'pity': 2, 'results': '--F--'}{'guarantee': False, 'pity': 2, 'results': '--F--'}Passed
partial repair boundary #2{'guarantee': False, 'pity': 8, 'results': '-----------F--------'}{'guarantee': False, 'pity': 8, 'results': '-----------F--------'}Passed
hard pity pull #1{'guarantee': True, 'pity': 1, 'results': 'L-'}{'guarantee': True, 'pity': 1, 'results': 'L-'}Passed
first soft pity pull #1{'guarantee': False, 'pity': 0, 'results': '-F'}{'guarantee': False, 'pity': 0, 'results': '-F'}Passed
lost fifty fifty then featured #1{'guarantee': False, 'pity': 0, 'results': 'L-F'}{'guarantee': False, 'pity': 0, 'results': 'L-F'}Passed
control #1{'guarantee': False, 'pity': 14, 'results': 'F--------------'}{'guarantee': False, 'pity': 14, 'results': 'F--------------'}Passed

SHA-256 / ead912155075c234634bceb41c53446694e01b3733a6c73431090ab3192b3cdc

Verification & scope

Deterministic toy contract stipulated for this model; integer or exact arithmetic only, not a reproduction of any specific game engine. 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:50:44.820182+00:00.

Case digest / 69ad69792962546b1b706fcc6621ad4767ed859671eacdd2f6437430d6a5bb0f