FAILURE MAP
← Case archive

FA-20346 / Assistive announcements / Open access

A replacement keeps the old utterance payload · case 01

The announcement trace violates the stated delivery-receipts contract.

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

ROOT CAUSE

Fault site: pending[e[1]] = [generation, serial, e[2]] is implemented as pending.setdefault(e[1], [generation, serial, e[2]])

VERIFIED REPAIR

Restore the stated transition: pending[e[1]] = [generation, serial, e[2]]

Unsuccessful approach: The attempted repair substitutes pending[e[1]] = [generation, serial, e[2][:1]] and still violates a regression oracle.

Case contract

A delivery is keyed by (utterance, generation). Submit replaces pending text for that key. A receipt is accepted only for the active generation and exact serial; accepted receipts append spoken text, remove pending, and retire the serial. Disconnect discards pending, increments generation, resets serial. Duplicate receipts do nothing. Report spoken, pending count, generation and next serial.

Why this case matters

Deterministic controlled model of assistive announcement delivery.

1 / The failure

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

N = 1
observations = []
def solve(events):
    pending = {}; retired = set(); spoken = []; generation = 0; serial = 0
    for e in events:
        if e[0] == 'submit':
            serial += 1
            pending.setdefault(e[1], [generation, serial, e[2]])
        elif e[0] == 'receipt':
            ident, epoch, ticket = e[1:]
            if epoch != generation: continue
            if ticket in retired: continue
            if ident not in pending: continue
            if pending[ident][1] != ticket: continue
            spoken.append(pending[ident][2])
            del pending[ident]
            retired.add(ticket)
        elif e[0] == 'disconnect':
            pending.clear()
            generation += 1
            serial = 0
            retired.clear()
    return [spoken, len(pending), generation, serial]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = ["[['submit','a','word'*N],['submit','b','other'],['receipt','a',0,1],['receipt','b',0,1],['receipt','b',0,2]]", "[['submit','a','old'],['submit','a','new'*N],['receipt','a',0,1],['receipt','a',0,2]]", "[['submit','a','old'],['submit','b','stale'],['disconnect'],['submit','a','new'*N],['receipt','a',0,1],['receipt','a',1,1]]", "[['disconnect'],['disconnect'],['submit','a','x'*N],['receipt','a',2,1]]", "[['submit','a','hello'*N],['receipt','a',0,1],['receipt','a',0,1]]", "[['submit','a','hi'*N],['submit','b','bye'],['receipt','a',0,1],['receipt','b',0,2],['disconnect'],['submit','a','new'],['receipt','a',1,1]]", "[['disconnect'],['submit','a','fresh'*N],['receipt','a',0,1]]", "[['submit','a','old'],['submit','b','old'],['disconnect']]", "[['submit','a','old'],['submit','a','new'*N],['receipt','a',0,1]]", '[]']
expected = {1: [[['word', 'other'], 0, 0, 2], [['new'], 0, 0, 2], [['new'], 0, 1, 1], [['x'], 0, 2, 1], [['hello'], 0, 0, 1], [['hi', 'bye', 'new'], 0, 1, 1], [[], 1, 1, 1], [[], 0, 1, 0], [[], 1, 0, 2], [[], 0, 0, 0]], 2: [[['wordword', 'other'], 0, 0, 2], [['newnew'], 0, 0, 2], [['newnew'], 0, 1, 1], [['xx'], 0, 2, 1], [['hellohello'], 0, 0, 1], [['hihi', 'bye', 'new'], 0, 1, 1], [[], 1, 1, 1], [[], 0, 1, 0], [[], 1, 0, 2], [[], 0, 0, 0]], 3: [[['wordwordword', 'other'], 0, 0, 2], [['newnewnew'], 0, 0, 2], [['newnewnew'], 0, 1, 1], [['xxx'], 0, 2, 1], [['hellohellohello'], 0, 0, 1], [['hihihi', 'bye', 'new'], 0, 1, 1], [[], 1, 1, 1], [[], 0, 1, 0], [[], 1, 0, 2], [[], 0, 0, 0]], 4: [[['wordwordwordword', 'other'], 0, 0, 2], [['newnewnewnew'], 0, 0, 2], [['newnewnewnew'], 0, 1, 1], [['xxxx'], 0, 2, 1], [['hellohellohellohello'], 0, 0, 1], [['hihihihi', 'bye', 'new'], 0, 1, 1], [[], 1, 1, 1], [[], 0, 1, 0], [[], 1, 0, 2], [[], 0, 0, 0]], 5: [[['wordwordwordwordword', 'other'], 0, 0, 2], [['newnewnewnewnew'], 0, 0, 2], [['newnewnewnewnew'], 0, 1, 1], [['xxxxx'], 0, 2, 1], [['hellohellohellohellohello'], 0, 0, 1], [['hihihihihi', 'bye', 'new'], 0, 1, 1], [[], 1, 1, 1], [[], 0, 1, 0], [[], 1, 0, 2], [[], 0, 0, 0]]}[N]
for i, expression in enumerate(fixtures):
    check("trace-"+str(i+1), solve(eval(expression)), expected[i])
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
trace-1[['word', 'other'], 0, 0, 2][['word', 'other'], 0, 0, 2]Passed
trace-2[['old'], 0, 0, 2][['new'], 0, 0, 2]Failed
trace-3[['new'], 0, 1, 1][['new'], 0, 1, 1]Passed
trace-4[['x'], 0, 2, 1][['x'], 0, 2, 1]Passed
trace-5[['hello'], 0, 0, 1][['hello'], 0, 0, 1]Passed
trace-6[['hi', 'bye', 'new'], 0, 1, 1][['hi', 'bye', 'new'], 0, 1, 1]Passed
trace-7[[], 1, 1, 1][[], 1, 1, 1]Passed
trace-8[[], 0, 1, 0][[], 0, 1, 0]Passed
trace-9[['old'], 0, 0, 2][[], 1, 0, 2]Failed
trace-10[[], 0, 0, 0][[], 0, 0, 0]Passed

SHA-256 / 88da8273955f80b1c0ccc9a6b9c2001a5f2b2645302d98891dfd128f83be0ea7

2 / The unsuccessful fix

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

N = 1
observations = []
def solve(events):
    pending = {}; retired = set(); spoken = []; generation = 0; serial = 0
    for e in events:
        if e[0] == 'submit':
            serial += 1
            pending[e[1]] = [generation, serial, e[2][:1]]
        elif e[0] == 'receipt':
            ident, epoch, ticket = e[1:]
            if epoch != generation: continue
            if ticket in retired: continue
            if ident not in pending: continue
            if pending[ident][1] != ticket: continue
            spoken.append(pending[ident][2])
            del pending[ident]
            retired.add(ticket)
        elif e[0] == 'disconnect':
            pending.clear()
            generation += 1
            serial = 0
            retired.clear()
    return [spoken, len(pending), generation, serial]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = ["[['submit','a','word'*N],['submit','b','other'],['receipt','a',0,1],['receipt','b',0,1],['receipt','b',0,2]]", "[['submit','a','old'],['submit','a','new'*N],['receipt','a',0,1],['receipt','a',0,2]]", "[['submit','a','old'],['submit','b','stale'],['disconnect'],['submit','a','new'*N],['receipt','a',0,1],['receipt','a',1,1]]", "[['disconnect'],['disconnect'],['submit','a','x'*N],['receipt','a',2,1]]", "[['submit','a','hello'*N],['receipt','a',0,1],['receipt','a',0,1]]", "[['submit','a','hi'*N],['submit','b','bye'],['receipt','a',0,1],['receipt','b',0,2],['disconnect'],['submit','a','new'],['receipt','a',1,1]]", "[['disconnect'],['submit','a','fresh'*N],['receipt','a',0,1]]", "[['submit','a','old'],['submit','b','old'],['disconnect']]", "[['submit','a','old'],['submit','a','new'*N],['receipt','a',0,1]]", '[]']
expected = {1: [[['word', 'other'], 0, 0, 2], [['new'], 0, 0, 2], [['new'], 0, 1, 1], [['x'], 0, 2, 1], [['hello'], 0, 0, 1], [['hi', 'bye', 'new'], 0, 1, 1], [[], 1, 1, 1], [[], 0, 1, 0], [[], 1, 0, 2], [[], 0, 0, 0]], 2: [[['wordword', 'other'], 0, 0, 2], [['newnew'], 0, 0, 2], [['newnew'], 0, 1, 1], [['xx'], 0, 2, 1], [['hellohello'], 0, 0, 1], [['hihi', 'bye', 'new'], 0, 1, 1], [[], 1, 1, 1], [[], 0, 1, 0], [[], 1, 0, 2], [[], 0, 0, 0]], 3: [[['wordwordword', 'other'], 0, 0, 2], [['newnewnew'], 0, 0, 2], [['newnewnew'], 0, 1, 1], [['xxx'], 0, 2, 1], [['hellohellohello'], 0, 0, 1], [['hihihi', 'bye', 'new'], 0, 1, 1], [[], 1, 1, 1], [[], 0, 1, 0], [[], 1, 0, 2], [[], 0, 0, 0]], 4: [[['wordwordwordword', 'other'], 0, 0, 2], [['newnewnewnew'], 0, 0, 2], [['newnewnewnew'], 0, 1, 1], [['xxxx'], 0, 2, 1], [['hellohellohellohello'], 0, 0, 1], [['hihihihi', 'bye', 'new'], 0, 1, 1], [[], 1, 1, 1], [[], 0, 1, 0], [[], 1, 0, 2], [[], 0, 0, 0]], 5: [[['wordwordwordwordword', 'other'], 0, 0, 2], [['newnewnewnewnew'], 0, 0, 2], [['newnewnewnewnew'], 0, 1, 1], [['xxxxx'], 0, 2, 1], [['hellohellohellohellohello'], 0, 0, 1], [['hihihihihi', 'bye', 'new'], 0, 1, 1], [[], 1, 1, 1], [[], 0, 1, 0], [[], 1, 0, 2], [[], 0, 0, 0]]}[N]
for i, expression in enumerate(fixtures):
    check("trace-"+str(i+1), solve(eval(expression)), expected[i])
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
trace-1[['w', 'o'], 0, 0, 2][['word', 'other'], 0, 0, 2]Failed
trace-2[['n'], 0, 0, 2][['new'], 0, 0, 2]Failed
trace-3[['n'], 0, 1, 1][['new'], 0, 1, 1]Failed
trace-4[['x'], 0, 2, 1][['x'], 0, 2, 1]Passed
trace-5[['h'], 0, 0, 1][['hello'], 0, 0, 1]Failed
trace-6[['h', 'b', 'n'], 0, 1, 1][['hi', 'bye', 'new'], 0, 1, 1]Failed
trace-7[[], 1, 1, 1][[], 1, 1, 1]Passed
trace-8[[], 0, 1, 0][[], 0, 1, 0]Passed
trace-9[[], 1, 0, 2][[], 1, 0, 2]Passed
trace-10[[], 0, 0, 0][[], 0, 0, 0]Passed

SHA-256 / fbbdf0e83073a34a20b3391cfb10014cb0de9d9d8d2fda9923c7dff7f07030f7

3 / The verified repair

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

N = 1
observations = []
def solve(events):
    pending = {}; retired = set(); spoken = []; generation = 0; serial = 0
    for e in events:
        if e[0] == 'submit':
            serial += 1
            pending[e[1]] = [generation, serial, e[2]]
        elif e[0] == 'receipt':
            ident, epoch, ticket = e[1:]
            if epoch != generation: continue
            if ticket in retired: continue
            if ident not in pending: continue
            if pending[ident][1] != ticket: continue
            spoken.append(pending[ident][2])
            del pending[ident]
            retired.add(ticket)
        elif e[0] == 'disconnect':
            pending.clear()
            generation += 1
            serial = 0
            retired.clear()
    return [spoken, len(pending), generation, serial]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = ["[['submit','a','word'*N],['submit','b','other'],['receipt','a',0,1],['receipt','b',0,1],['receipt','b',0,2]]", "[['submit','a','old'],['submit','a','new'*N],['receipt','a',0,1],['receipt','a',0,2]]", "[['submit','a','old'],['submit','b','stale'],['disconnect'],['submit','a','new'*N],['receipt','a',0,1],['receipt','a',1,1]]", "[['disconnect'],['disconnect'],['submit','a','x'*N],['receipt','a',2,1]]", "[['submit','a','hello'*N],['receipt','a',0,1],['receipt','a',0,1]]", "[['submit','a','hi'*N],['submit','b','bye'],['receipt','a',0,1],['receipt','b',0,2],['disconnect'],['submit','a','new'],['receipt','a',1,1]]", "[['disconnect'],['submit','a','fresh'*N],['receipt','a',0,1]]", "[['submit','a','old'],['submit','b','old'],['disconnect']]", "[['submit','a','old'],['submit','a','new'*N],['receipt','a',0,1]]", '[]']
expected = {1: [[['word', 'other'], 0, 0, 2], [['new'], 0, 0, 2], [['new'], 0, 1, 1], [['x'], 0, 2, 1], [['hello'], 0, 0, 1], [['hi', 'bye', 'new'], 0, 1, 1], [[], 1, 1, 1], [[], 0, 1, 0], [[], 1, 0, 2], [[], 0, 0, 0]], 2: [[['wordword', 'other'], 0, 0, 2], [['newnew'], 0, 0, 2], [['newnew'], 0, 1, 1], [['xx'], 0, 2, 1], [['hellohello'], 0, 0, 1], [['hihi', 'bye', 'new'], 0, 1, 1], [[], 1, 1, 1], [[], 0, 1, 0], [[], 1, 0, 2], [[], 0, 0, 0]], 3: [[['wordwordword', 'other'], 0, 0, 2], [['newnewnew'], 0, 0, 2], [['newnewnew'], 0, 1, 1], [['xxx'], 0, 2, 1], [['hellohellohello'], 0, 0, 1], [['hihihi', 'bye', 'new'], 0, 1, 1], [[], 1, 1, 1], [[], 0, 1, 0], [[], 1, 0, 2], [[], 0, 0, 0]], 4: [[['wordwordwordword', 'other'], 0, 0, 2], [['newnewnewnew'], 0, 0, 2], [['newnewnewnew'], 0, 1, 1], [['xxxx'], 0, 2, 1], [['hellohellohellohello'], 0, 0, 1], [['hihihihi', 'bye', 'new'], 0, 1, 1], [[], 1, 1, 1], [[], 0, 1, 0], [[], 1, 0, 2], [[], 0, 0, 0]], 5: [[['wordwordwordwordword', 'other'], 0, 0, 2], [['newnewnewnewnew'], 0, 0, 2], [['newnewnewnewnew'], 0, 1, 1], [['xxxxx'], 0, 2, 1], [['hellohellohellohellohello'], 0, 0, 1], [['hihihihihi', 'bye', 'new'], 0, 1, 1], [[], 1, 1, 1], [[], 0, 1, 0], [[], 1, 0, 2], [[], 0, 0, 0]]}[N]
for i, expression in enumerate(fixtures):
    check("trace-"+str(i+1), solve(eval(expression)), expected[i])
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
trace-1[['word', 'other'], 0, 0, 2][['word', 'other'], 0, 0, 2]Passed
trace-2[['new'], 0, 0, 2][['new'], 0, 0, 2]Passed
trace-3[['new'], 0, 1, 1][['new'], 0, 1, 1]Passed
trace-4[['x'], 0, 2, 1][['x'], 0, 2, 1]Passed
trace-5[['hello'], 0, 0, 1][['hello'], 0, 0, 1]Passed
trace-6[['hi', 'bye', 'new'], 0, 1, 1][['hi', 'bye', 'new'], 0, 1, 1]Passed
trace-7[[], 1, 1, 1][[], 1, 1, 1]Passed
trace-8[[], 0, 1, 0][[], 0, 1, 0]Passed
trace-9[[], 1, 0, 2][[], 1, 0, 2]Passed
trace-10[[], 0, 0, 0][[], 0, 0, 0]Passed

SHA-256 / 22dd36c0596f38d0b2a4cbdc0c531fa58c5f44a3a9b9280d55045adee1522a38

Verification & scope

Stipulated bounded policy, not a browser, speech engine, platform API, or standards conformance claim. 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:40:18.034138+00:00.

Case digest / fef2a5169b7b6aa669548b007b7232c9b2736f9dfd994e5e5825c13b26587563