FAILURE MAP
← Case archive

FA-97941 / Training label alignment / Open access

Labels attach by row position after examples are reordered · case 01

Labels attach by row position after examples are reordered.

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

ROOT CAUSE

An example reorder leaves labels in their former positional order.

THE FAILURE

An example reorder leaves labels in their former positional order.

Unsuccessful approach: Sorting examples and stripping label IDs still cannot recover which example owns each value.

Case contract

Examples are [id,payload] and labels are [id,label], with unique IDs. Return [id,label] in example order and omit examples without labels.

Why this case matters

A small deterministic training-data operation makes label ownership and ordering explicit.

1 / The failure

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

N = 1
observations = []
def solve(examples, labels):
    return [[e[0], labels[i][1]] for i,e in enumerate(examples) if i < len(labels)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('reordered rows',solve([['b','B'],['a','A']], [['a',N],['b',N+1]]),[['b',N+1],['a',N]])
check('missing label omitted',solve([['x',0],['y',1]],[['y',N]]),[['y',N]])
check('empty examples',solve([], [['a',1]]),[])
check('empty labels',solve([['a',0]],[]),[])
check('single match',solve([['a',0]],[['a',N]]),[['a',N]])
check('extra label ignored',solve([['a',0]],[['z',9],['a',N]]),[['a',N]])
check('zero identifier',solve([[0,'v']],[[0,N]]),[[0,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
reordered rows[['b', 1], ['a', 2]][['b', 2], ['a', 1]]Failed
missing label omitted[['x', 1]][['y', 1]]Failed
empty examples[][]Passed
empty labels[][]Passed
single match[['a', 1]][['a', 1]]Passed
extra label ignored[['a', 9]][['a', 1]]Failed
zero identifier[[0, 1]][[0, 1]]Passed

SHA-256 / 326636ec6042b98dde68b7069502f6ced06726706e525543e7aa7069685912d5

2 / The unsuccessful fix

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

N = 1
observations = []
def solve(examples, labels):
    return [[e[0], y] for e,y in zip(sorted(examples), [r[1] for r in labels])]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('reordered rows',solve([['b','B'],['a','A']], [['a',N],['b',N+1]]),[['b',N+1],['a',N]])
check('missing label omitted',solve([['x',0],['y',1]],[['y',N]]),[['y',N]])
check('empty examples',solve([], [['a',1]]),[])
check('empty labels',solve([['a',0]],[]),[])
check('single match',solve([['a',0]],[['a',N]]),[['a',N]])
check('extra label ignored',solve([['a',0]],[['z',9],['a',N]]),[['a',N]])
check('zero identifier',solve([[0,'v']],[[0,N]]),[[0,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
reordered rows[['a', 1], ['b', 2]][['b', 2], ['a', 1]]Failed
missing label omitted[['x', 1]][['y', 1]]Failed
empty examples[][]Passed
empty labels[][]Passed
single match[['a', 1]][['a', 1]]Passed
extra label ignored[['a', 9]][['a', 1]]Failed
zero identifier[[0, 1]][[0, 1]]Passed

SHA-256 / 1c13671aac4d2ada0723ce60e71359dbc35041741818bc071cb97bc49e50fc06

HELD IN THE MEMBER ARCHIVE

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

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

IDs are toy hashable labels; duplicate IDs are outside this contract. 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:07.548264+00:00.

Case digest / a61dfec6287b3f35ad6117bcc65cdbdcbd6baa929e090f548cdb402001821e3b