{"abstract":"terminal score omits the end-marker contribution.","category":"Beam search bookkeeping","checks":6,"contract":"Given parent score and token deltas, return cumulative scores for all transitions including EOS exactly once.","contract_signature":"parent, deltas","evaluation_group":"beam-eos_score","failed_approach":"Adding the end-marker score twice over-penalizes completed paths.","family":"w3-beam-search-bookkeeping-eos-score-accounting","id":"FA-98466","implementations":{"attempt":{"sha256":"638deffdefc5ca4de43c956c7d67111ae8fe42b873c6ee381143e257caa0e727","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(parent, deltas):\n    return [parent+2*d for d in deltas]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('terminal delta',solve(-N,[-1,-2]),[-N-1,-N-2])\ncheck('zero delta',solve(0,[0]),[0])\ncheck('positive toy delta',solve(N,[2]),[N+2])\ncheck('no transitions',solve(N,[]),[])\ncheck('mixed transitions',solve(-1,[-N,0]),[-N-1,-1])\ncheck('repeated equal scores',solve(-N,[-N,-N]),[-2*N,-2*N])\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":"c59d32364a30c1273ab39f1c7a534ce90b15a26db34a658de92e74f48fd2310c","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(parent, deltas):\n    return [parent+d for d in deltas if d!=0]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('terminal delta',solve(-N,[-1,-2]),[-N-1,-N-2])\ncheck('zero delta',solve(0,[0]),[0])\ncheck('positive toy delta',solve(N,[2]),[N+2])\ncheck('no transitions',solve(N,[]),[])\ncheck('mixed transitions',solve(-1,[-N,0]),[-N-1,-1])\ncheck('repeated equal scores',solve(-N,[-N,-N]),[-2*N,-2*N])\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":"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.","method":"Deterministic executable model with adversarial boundary fixtures.","provenance":{"created_by":"Failure Map","dependencies":"Python standard library","family":"w3-beam-search-bookkeeping-eos-score-accounting","generated_at":"2026-09-30T16:48:13.239210+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Beam decoders rely on consistent hypothesis state while expanding and ranking candidates.","root_cause":"The completion transition is recorded without its token log score.","sha256":"24668cf40a2f80d9965be3429ce44207bc9169226816d46d8435801a66e308ec","title":"Beam search: terminal score omits the end-marker contribution · case 01","variant":1,"variant_policy":"The fixture code references N, supplied as 1 through 5. Fixed boundary checks may repeat. These records share one mechanism and must remain together in evaluation splits.","verified":true,"visibility":"public","verification":{"attempt":{"elapsed_ms":28.951,"exit_code":1,"observations":[{"actual":[-3,-5],"check":"terminal delta","expected":[-2,-3],"passed":false},{"actual":[0],"check":"zero delta","expected":[0],"passed":true},{"actual":[5],"check":"positive toy delta","expected":[3],"passed":false},{"actual":[],"check":"no transitions","expected":[],"passed":true},{"actual":[-3,-1],"check":"mixed transitions","expected":[-2,-1],"passed":false},{"actual":[-3,-3],"check":"repeated equal scores","expected":[-2,-2],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"terminal delta\", \"actual\": [-3, -5], \"expected\": [-2, -3], \"passed\": false}, {\"check\": \"zero delta\", \"actual\": [0], \"expected\": [0], \"passed\": true}, {\"check\": \"positive toy delta\", \"actual\": [5], \"expected\": [3], \"passed\": false}, {\"check\": \"no transitions\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"mixed transitions\", \"actual\": [-3, -1], \"expected\": [-2, -1], \"passed\": false}, {\"check\": \"repeated equal scores\", \"actual\": [-3, -3], \"expected\": [-2, -2], \"passed\": false}], \"passed\": false}\n"},"broken":{"elapsed_ms":26.482,"exit_code":1,"observations":[{"actual":[-2,-3],"check":"terminal delta","expected":[-2,-3],"passed":true},{"actual":[],"check":"zero delta","expected":[0],"passed":false},{"actual":[3],"check":"positive toy delta","expected":[3],"passed":true},{"actual":[],"check":"no transitions","expected":[],"passed":true},{"actual":[-2],"check":"mixed transitions","expected":[-2,-1],"passed":false},{"actual":[-2,-2],"check":"repeated equal scores","expected":[-2,-2],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"terminal delta\", \"actual\": [-2, -3], \"expected\": [-2, -3], \"passed\": true}, {\"check\": \"zero delta\", \"actual\": [], \"expected\": [0], \"passed\": false}, {\"check\": \"positive toy delta\", \"actual\": [3], \"expected\": [3], \"passed\": true}, {\"check\": \"no transitions\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"mixed transitions\", \"actual\": [-2], \"expected\": [-2, -1], \"passed\": false}, {\"check\": \"repeated equal scores\", \"actual\": [-2, -2], \"expected\": [-2, -2], \"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."}}