FA-98581 / KV cache position mapping / Open access
Beam cache rows follow selected parent beams · case 01
Child beams inherit cache rows in their previous row order.
ROOT CAUSE
The beam selection scores are updated but their parent row indices are ignored.
THE FAILURE
The beam selection scores are updated but their parent row indices are ignored.
Unsuccessful approach: Sorting selected parent IDs loses the decoder’s requested child ordering.
Case contract
Return cache rows for each child in the supplied parent_indices order; parent indices may repeat.
Why this case matters
A small in-memory model makes the cache address contract explicit for a serving component.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(cache_rows, parent_indices):
return list(cache_rows[:len(parent_indices)])
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
rows=[['a'],['b'],['c']]
check('swap parents',solve(rows,[2,0]),[['c'],['a']])
check('duplicate parent',solve(rows,[1,1]),[['b'],['b']])
check('identity',solve(rows,[0,1,2]),rows)
check('reverse',solve(rows,[2,1,0]),[['c'],['b'],['a']])
check('empty children',solve(rows,[]),[])
check('single child',solve(rows,[N%3]),[rows[N%3]])
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 fixture | Actual | Expected | Outcome |
|---|---|---|---|
| swap parents | [['a'], ['b']] | [['c'], ['a']] | Failed |
| duplicate parent | [['a'], ['b']] | [['b'], ['b']] | Failed |
| identity | [['a'], ['b'], ['c']] | [['a'], ['b'], ['c']] | Passed |
| reverse | [['a'], ['b'], ['c']] | [['c'], ['b'], ['a']] | Failed |
| empty children | [] | [] | Passed |
| single child | [['a']] | [['b']] | Failed |
SHA-256 / 64ab9bbf18c6f9c860edc39b4ee90547ca635443ee8d178d6e583b24cfc2bafd
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(cache_rows, parent_indices):
return [cache_rows[i] for i in sorted(parent_indices)]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
rows=[['a'],['b'],['c']]
check('swap parents',solve(rows,[2,0]),[['c'],['a']])
check('duplicate parent',solve(rows,[1,1]),[['b'],['b']])
check('identity',solve(rows,[0,1,2]),rows)
check('reverse',solve(rows,[2,1,0]),[['c'],['b'],['a']])
check('empty children',solve(rows,[]),[])
check('single child',solve(rows,[N%3]),[rows[N%3]])
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 fixture | Actual | Expected | Outcome |
|---|---|---|---|
| swap parents | [['a'], ['c']] | [['c'], ['a']] | Failed |
| duplicate parent | [['b'], ['b']] | [['b'], ['b']] | Passed |
| identity | [['a'], ['b'], ['c']] | [['a'], ['b'], ['c']] | Passed |
| reverse | [['a'], ['b'], ['c']] | [['c'], ['b'], ['a']] | Failed |
| empty children | [] | [] | Passed |
| single child | [['b']] | [['b']] | Passed |
SHA-256 / 4721abff7c40365eb97b58a13d447b883d485918dccb3a464511c2fe745d0bbd
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
These toy integer maps omit tensor layout, concurrency, device memory, and model-specific cache formats. 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.544565+00:00.
Case digest / 535dbf0bf133ef2f630cd10b55d99754c7c72842cee87a4726b01e93b6374e92