FAILURE MAP
← Case archive

FA-98526 / Beam search bookkeeping / Open access

Beam search: completed paths are expanded again as live beams · case 01

completed paths are expanded again as live beams.

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

ROOT CAUSE

A combined hypothesis list is fed back to expansion without excluding terminal rows.

THE FAILURE

A combined hypothesis list is fed back to expansion without excluding terminal rows.

Unsuccessful approach: Dropping terminal rows entirely prevents them from appearing among results.

Case contract

Rows [id,score,done]; return IDs of active rows only.

Why this case matters

Beam decoders rely on consistent hypothesis state while expanding and ranking candidates.

1 / The failure

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

N = 1
observations = []
def solve(rows):
    return [r[0] for r in rows]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('terminal excluded',solve([['a',N,True],['b',N,False]]),['b'])
check('all finished',solve([['a',1,True]]),[])
check('all live',solve([['x',0,False],['y',-N,False]]),['x','y'])
check('empty active list',solve([]),[])
check('finished among live',solve([['f',0,True],['l',-1,False]]),['l'])
check('zero score live',solve([[str(N),0,False]]),[str(N)])
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
terminal excluded['a', 'b']['b']Failed
all finished['a'][]Failed
all live['x', 'y']['x', 'y']Passed
empty active list[][]Passed
finished among live['f', 'l']['l']Failed
zero score live['1']['1']Passed

SHA-256 / a9cc97bd64d77b335f56610e71cf900840bb815d41fe109b1db245cb3ef4fe3a

2 / The unsuccessful fix

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

N = 1
observations = []
def solve(rows):
    return [r[0] for r in rows if not r[2] and r[1]>0]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('terminal excluded',solve([['a',N,True],['b',N,False]]),['b'])
check('all finished',solve([['a',1,True]]),[])
check('all live',solve([['x',0,False],['y',-N,False]]),['x','y'])
check('empty active list',solve([]),[])
check('finished among live',solve([['f',0,True],['l',-1,False]]),['l'])
check('zero score live',solve([[str(N),0,False]]),[str(N)])
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
terminal excluded['b']['b']Passed
all finished[][]Passed
all live[]['x', 'y']Failed
empty active list[][]Passed
finished among live[]['l']Failed
zero score live[]['1']Failed

SHA-256 / 0cfd25b50ae9b23476e33198bfea9e4197685b92cc393aa54cf4e45f740be599

HELD IN THE MEMBER ARCHIVE

The verified repair and its recorded checks are member-only.

This mechanism has 6 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

This is a finite toy beam-state contract and makes no claim about neural model quality or production decoding. 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-30T16:48:14.106829+00:00.

Case digest / 30c33db2f1ba9083c41457084a3d2fac370057b33393137c65e47abe57be508e