{"abstract":"Student targets use teacher class indices directly.","category":"Training label alignment","checks":8,"contract":"Map each teacher index through teacher_classes to the matching student_classes index; missing names or invalid indices yield -1.","contract_signature":"teacher_indices, teacher_classes, student_classes","evaluation_group":"training-label-alignment-cross-vocabulary-class-translation","failed_approach":"Clamping teacher indices to the student range converts invalid classes into plausible labels.","family":"w3-training-label-alignment-teacher-student-class-map","id":"FA-98011","implementations":{"attempt":{"sha256":"631cb4c73847abf6be8e31ea5e4beac1bb56be6d96789aa02a3bc4832222e0a2","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(teacher_indices, teacher_classes, student_classes):\n    return [min(i,len(student_classes)-1) if student_classes and i>=0 else -1 for i in teacher_indices]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('different order',solve([0,1],['cat','dog'],['dog','cat']),[1,0])\ncheck('missing student class',solve([0],['bird'],['cat']),[-1])\ncheck('invalid teacher index',solve([3,-1],['a','b'],['a']),[-1,-1])\ncheck('empty batch',solve([],['a'],['a']),[])\ncheck('same singleton',solve([0],['x'],['x']),[0])\ncheck('mixed mapping',solve([2,0,1],['a','b','c'],['c','a']),[0,1,-1])\ncheck('empty student',solve([0],['a'],[]),[-1])\ncheck('variant vocabulary order',solve([0,1],['label'+str(N),'base'],['base','label'+str(N)]),[1,0])\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":"ec8738ef760146e5ec6d2bbcc8c2d23b91bff3404c6413405bdc7b71c513951f","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(teacher_indices, teacher_classes, student_classes):\n    return [i if 0<=i<len(student_classes) else -1 for i in teacher_indices]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('different order',solve([0,1],['cat','dog'],['dog','cat']),[1,0])\ncheck('missing student class',solve([0],['bird'],['cat']),[-1])\ncheck('invalid teacher index',solve([3,-1],['a','b'],['a']),[-1,-1])\ncheck('empty batch',solve([],['a'],['a']),[])\ncheck('same singleton',solve([0],['x'],['x']),[0])\ncheck('mixed mapping',solve([2,0,1],['a','b','c'],['c','a']),[0,1,-1])\ncheck('empty student',solve([0],['a'],[]),[-1])\ncheck('variant vocabulary order',solve([0,1],['label'+str(N),'base'],['base','label'+str(N)]),[1,0])\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":"Class vocabularies contain unique names; indices are integers. 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-teacher-student-class-map","generated_at":"2026-09-30T16:48:08.407453+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 teacher and student class vocabularies use different index assignments.","sha256":"95f8e24823b447478b8cb95cf02f879735c1f7a550b56f09146c4164dd42c942","title":"Student targets use teacher class indices directly · 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.782,"exit_code":1,"observations":[{"actual":[0,1],"check":"different order","expected":[1,0],"passed":false},{"actual":[0],"check":"missing student class","expected":[-1],"passed":false},{"actual":[0,-1],"check":"invalid teacher index","expected":[-1,-1],"passed":false},{"actual":[],"check":"empty batch","expected":[],"passed":true},{"actual":[0],"check":"same singleton","expected":[0],"passed":true},{"actual":[1,0,1],"check":"mixed mapping","expected":[0,1,-1],"passed":false},{"actual":[-1],"check":"empty student","expected":[-1],"passed":true},{"actual":[0,1],"check":"variant vocabulary order","expected":[1,0],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"different order\", \"actual\": [0, 1], \"expected\": [1, 0], \"passed\": false}, {\"check\": \"missing student class\", \"actual\": [0], \"expected\": [-1], \"passed\": false}, {\"check\": \"invalid teacher index\", \"actual\": [0, -1], \"expected\": [-1, -1], \"passed\": false}, {\"check\": \"empty batch\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"same singleton\", \"actual\": [0], \"expected\": [0], \"passed\": true}, {\"check\": \"mixed mapping\", \"actual\": [1, 0, 1], \"expected\": [0, 1, -1], \"passed\": false}, {\"check\": \"empty student\", \"actual\": [-1], \"expected\": [-1], \"passed\": true}, {\"check\": \"variant vocabulary order\", \"actual\": [0, 1], \"expected\": [1, 0], \"passed\": false}], \"passed\": false}\n"},"broken":{"elapsed_ms":26.572,"exit_code":1,"observations":[{"actual":[0,1],"check":"different order","expected":[1,0],"passed":false},{"actual":[0],"check":"missing student class","expected":[-1],"passed":false},{"actual":[-1,-1],"check":"invalid teacher index","expected":[-1,-1],"passed":true},{"actual":[],"check":"empty batch","expected":[],"passed":true},{"actual":[0],"check":"same singleton","expected":[0],"passed":true},{"actual":[-1,0,1],"check":"mixed mapping","expected":[0,1,-1],"passed":false},{"actual":[-1],"check":"empty student","expected":[-1],"passed":true},{"actual":[0,1],"check":"variant vocabulary order","expected":[1,0],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"different order\", \"actual\": [0, 1], \"expected\": [1, 0], \"passed\": false}, {\"check\": \"missing student class\", \"actual\": [0], \"expected\": [-1], \"passed\": false}, {\"check\": \"invalid teacher index\", \"actual\": [-1, -1], \"expected\": [-1, -1], \"passed\": true}, {\"check\": \"empty batch\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"same singleton\", \"actual\": [0], \"expected\": [0], \"passed\": true}, {\"check\": \"mixed mapping\", \"actual\": [-1, 0, 1], \"expected\": [0, 1, -1], \"passed\": false}, {\"check\": \"empty student\", \"actual\": [-1], \"expected\": [-1], \"passed\": true}, {\"check\": \"variant vocabulary order\", \"actual\": [0, 1], \"expected\": [1, 0], \"passed\": false}], \"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."}}