FAILURE MAP
← Case archive

FA-97841 / Dataset split isolation / Open access

Dataset split: one group appears on both sides · case 01

one group appears on both sides.

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

ROOT CAUSE

The implementation uses row position to decide which mapped-train rows enter training, so members of one group can land on different sides.

THE FAILURE

The implementation uses row position to decide which mapped-train rows enter training, so members of one group can land on different sides.

Unsuccessful approach: The repair forces the first row into training even when its group is mapped to validation.

Case contract

Rows are [id,group]. Return IDs assigned to train under the supplied group->side map; unknown groups are validation.

Why this case matters

This toy split allocator makes membership rules explicit for reproducible evaluation fixtures.

1 / The failure

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

N = 1
observations = []
def solve(rows, sides):
    return [i for j,(i,g) in enumerate(rows) if sides.get(g,'validation')=='train' and j%2==0]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('same group',solve([['a','g'],['b','g']],{'g':'train'}),['a','b'])
check('validation group',solve([['a','h']],{'h':'validation'}),[])
check('unknown defaults validation',solve([['a','z']],{}),[])
check('interleaved groups',solve([['a','g'],['b','h'],['c','g']],{'g':'train','h':'validation'}),['a','c'])
check('empty',solve([] ,{'g':'train'}),[])
check('singleton train',solve([['x','g']],{'g':'train'}),['x'])
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
same group['a']['a', 'b']Failed
validation group[][]Passed
unknown defaults validation[][]Passed
interleaved groups['a', 'c']['a', 'c']Passed
empty[][]Passed
singleton train['x']['x']Passed

SHA-256 / 57b4af207308f53e4c5fee25dcc8ab28b91d91e8017d76e8aa207a81bc634887

2 / The unsuccessful fix

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

N = 1
observations = []
def solve(rows, sides):
    return [i for i,g in rows if sides.get(g,'validation')=='train' or i==rows[0][0]]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('same group',solve([['a','g'],['b','g']],{'g':'train'}),['a','b'])
check('validation group',solve([['a','h']],{'h':'validation'}),[])
check('unknown defaults validation',solve([['a','z']],{}),[])
check('interleaved groups',solve([['a','g'],['b','h'],['c','g']],{'g':'train','h':'validation'}),['a','c'])
check('empty',solve([] ,{'g':'train'}),[])
check('singleton train',solve([['x','g']],{'g':'train'}),['x'])
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
same group['a', 'b']['a', 'b']Passed
validation group['a'][]Failed
unknown defaults validation['a'][]Failed
interleaved groups['a', 'c']['a', 'c']Passed
empty[][]Passed
singleton train['x']['x']Passed

SHA-256 / a3d387e254531d13bb596cb7a9ba69aeebf71679010c35fab7a5ecebbd5a90ca

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

Inputs are small in-memory records with self-contained contracts; no claim is made about production sampling quality. 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:06.689096+00:00.

Case digest / 66ecb4d0a0eaabdf571eb61931591470c32c9b00f96ee8f0570b58085aa29c60