{"abstract":"Batch sampler selection is ignored when labels are paired.","category":"Training label alignment","checks":7,"contract":"Given examples and labels of equal length plus selected indices, return paired rows in index order.","contract_signature":"examples, labels, indices","evaluation_group":"training-label-alignment-shared-index-batch-selection","failed_approach":"Sorting selected indices repairs membership but changes the sampler-requested order.","family":"w3-training-label-alignment-batch-label-cardinality","id":"FA-98001","implementations":{"attempt":{"sha256":"e0cf9325e2f261c728841c99d01f3e2308b207b8029db6f065f2c83b13c9b12b","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(examples, labels, indices):\n    return [[examples[i],labels[i]] for i in sorted(indices)]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('nonprefix subset',solve(list(range(N+2)),[10+i for i in range(N+2)],[N+1,0]),[[N+1,N+11],[0,10]])\ncheck('reverse selection',solve(['a','b'],[1,2],[1,0]),[['b',2],['a',1]])\ncheck('empty selection',solve(['x'],[N],[]),[])\ncheck('empty batch',solve([],[],[]),[])\ncheck('single selected',solve(['x','y'],[0,N],[1]),[['y',N]])\ncheck('repeated index',solve(['x'],[N],[0,0]),[['x',N],['x',N]])\ncheck('full ordered selection',solve([1,2,3],[4,5,6],[0,1,2]),[[1,4],[2,5],[3,6]])\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":"7ef086ae2b79a8c3d8bc9d0ea497d97526174edb2c6ae4c4c7ba372790a3199e","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(examples, labels, indices):\n    return [[examples[i],labels[i]] for i in range(len(examples))]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('nonprefix subset',solve(list(range(N+2)),[10+i for i in range(N+2)],[N+1,0]),[[N+1,N+11],[0,10]])\ncheck('reverse selection',solve(['a','b'],[1,2],[1,0]),[['b',2],['a',1]])\ncheck('empty selection',solve(['x'],[N],[]),[])\ncheck('empty batch',solve([],[],[]),[])\ncheck('single selected',solve(['x','y'],[0,N],[1]),[['y',N]])\ncheck('repeated index',solve(['x'],[N],[0,0]),[['x',N],['x',N]])\ncheck('full ordered selection',solve([1,2,3],[4,5,6],[0,1,2]),[[1,4],[2,5],[3,6]])\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":"Indices are valid positions; examples and labels have equal length. 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-training-label-alignment-batch-label-cardinality","generated_at":"2026-09-30T16:48:08.406732+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"A small deterministic training-data operation makes label ownership and ordering explicit.","root_cause":"The pairing routine receives a selected-index list but emits rows from the full batch.","sha256":"fb275633fff10849c6afb94ee597dcc840e9251b16d48fcd974d660eeb6b78b0","title":"Batch sampler selection is ignored when labels are paired · 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":26.038,"exit_code":1,"observations":[{"actual":[[0,10],[2,12]],"check":"nonprefix subset","expected":[[2,12],[0,10]],"passed":false},{"actual":[["a",1],["b",2]],"check":"reverse selection","expected":[["b",2],["a",1]],"passed":false},{"actual":[],"check":"empty selection","expected":[],"passed":true},{"actual":[],"check":"empty batch","expected":[],"passed":true},{"actual":[["y",1]],"check":"single selected","expected":[["y",1]],"passed":true},{"actual":[["x",1],["x",1]],"check":"repeated index","expected":[["x",1],["x",1]],"passed":true},{"actual":[[1,4],[2,5],[3,6]],"check":"full ordered selection","expected":[[1,4],[2,5],[3,6]],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"nonprefix subset\", \"actual\": [[0, 10], [2, 12]], \"expected\": [[2, 12], [0, 10]], \"passed\": false}, {\"check\": \"reverse selection\", \"actual\": [[\"a\", 1], [\"b\", 2]], \"expected\": [[\"b\", 2], [\"a\", 1]], \"passed\": false}, {\"check\": \"empty selection\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"empty batch\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"single selected\", \"actual\": [[\"y\", 1]], \"expected\": [[\"y\", 1]], \"passed\": true}, {\"check\": \"repeated index\", \"actual\": [[\"x\", 1], [\"x\", 1]], \"expected\": [[\"x\", 1], [\"x\", 1]], \"passed\": true}, {\"check\": \"full ordered selection\", \"actual\": [[1, 4], [2, 5], [3, 6]], \"expected\": [[1, 4], [2, 5], [3, 6]], \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":28.228,"exit_code":1,"observations":[{"actual":[[0,10],[1,11],[2,12]],"check":"nonprefix subset","expected":[[2,12],[0,10]],"passed":false},{"actual":[["a",1],["b",2]],"check":"reverse selection","expected":[["b",2],["a",1]],"passed":false},{"actual":[["x",1]],"check":"empty selection","expected":[],"passed":false},{"actual":[],"check":"empty batch","expected":[],"passed":true},{"actual":[["x",0],["y",1]],"check":"single selected","expected":[["y",1]],"passed":false},{"actual":[["x",1]],"check":"repeated index","expected":[["x",1],["x",1]],"passed":false},{"actual":[[1,4],[2,5],[3,6]],"check":"full ordered selection","expected":[[1,4],[2,5],[3,6]],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"nonprefix subset\", \"actual\": [[0, 10], [1, 11], [2, 12]], \"expected\": [[2, 12], [0, 10]], \"passed\": false}, {\"check\": \"reverse selection\", \"actual\": [[\"a\", 1], [\"b\", 2]], \"expected\": [[\"b\", 2], [\"a\", 1]], \"passed\": false}, {\"check\": \"empty selection\", \"actual\": [[\"x\", 1]], \"expected\": [], \"passed\": false}, {\"check\": \"empty batch\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"single selected\", \"actual\": [[\"x\", 0], [\"y\", 1]], \"expected\": [[\"y\", 1]], \"passed\": false}, {\"check\": \"repeated index\", \"actual\": [[\"x\", 1]], \"expected\": [[\"x\", 1], [\"x\", 1]], \"passed\": false}, {\"check\": \"full ordered selection\", \"actual\": [[1, 4], [2, 5], [3, 6]], \"expected\": [[1, 4], [2, 5], [3, 6]], \"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."}}