{"abstract":"A superwash sweater grows 10% after the first wash.","category":"Knitting and sewing pattern grading","checks":8,"contract":"A swatch of sts x rows measured before and after washing. Use post-wash dimensions: cast on = half-up target_w*sts/w_post; rows = target_h*rows/h_post rounded to the nearest even number (ties up); width change % = (w_post/w_pre - 1)*100 half-up to 0.1. Return [cast_on, rows, width_change].","contract_signature":"sts, rows, w_pre, w_post, h_pre, h_post, target_w, target_h","evaluation_group":"w2-knitting_and_sewing_pattern_grading-post-wash-gauge","failed_approach":"Averaging pre and post widths still bakes in half of the growth.","family":"w2-knitting_and_sewing_pattern_grading-post-wash-gauge-post-wash-width","id":"FA-97716","implementations":{"attempt":{"sha256":"97eeefdedfc1301ab96eddaabf85091e52578a2c7b1c93cac75fc47b04711e67","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nfrom fractions import Fraction\nN = 1\nobservations = []\ndef solve(sts, rows, w_pre, w_post, h_pre, h_post, target_w, target_h):\n    wpo = Fraction(w_post)\n    hpo = Fraction(h_post)\n    cast = math.floor(target_w * sts / ((wpo + Fraction(w_pre)) / 2) + Fraction(1, 2))\n    rr = target_h * rows / hpo\n    row_count = 2 * math.floor(rr / 2 + Fraction(1, 2))\n    change = (wpo / Fraction(w_pre) - 1) * 100\n    return [cast, row_count, math.floor(change * 10 + Fraction(1, 2)) / 10]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[['no change', [20, 28, '10', '10', '10', '10', 50, 45], [100, 126, 0.0]],\n  ['growth', [22, 30, '10', '11', '10', '10.4', 50, 60], [100, 174, 10.0]],\n  ['shrink', [24, 32, '10.5', '9.5', '10.2', '9', 40, 30], [101, 106, -9.5]],\n  ['regression: post-wash width', [20, 40, '10.5', '11', '10', '9.5', 50, 45], [91, 190, 4.8]],\n  ['repair check: post-wash width', [22, 28, '10.5', '9.5', '10.2', '10', 50, 30], [116, 84, -9.5]],\n  ['generated control 1', [22, 28, '10', '10.8', '10.2', '10.4', 50, 60], [102, 162, 8.0]],\n  ['generated control 2', [24, 30, '10', '11', '10.2', '10.4', 40, 30], [87, 86, 10.0]],\n  ['generated control 3', [22, 30, '10', '9.5', '10.2', '10', 40, 45], [93, 136, -5.0]]],\n [['growth', [22, 30, '10', '11', '10', '10.4', 50, 60], [100, 174, 10.0]],\n  ['shrink', [24, 32, '10.5', '9.5', '10.2', '9', 40, 30], [101, 106, -9.5]],\n  ['no change', [20, 28, '10', '10', '10', '10', 50, 45], [100, 126, 0.0]],\n  ['regression: post-wash width', [20, 32, '10', '9.5', '10.2', '9', 50, 45], [105, 160, -5.0]],\n  ['repair check: post-wash width', [24, 32, '10.5', '10.8', '10.2', '10', 40, 60], [89, 192, 2.9]],\n  ['generated control 1', [30, 32, '10.5', '10.5', '10', '9', 55, 60], [157, 214, 0.0]],\n  ['generated control 2', [30, 28, '10.5', '10.5', '10', '9.5', 50, 45], [143, 132, 0.0]],\n  ['generated control 3', [20, 32, '10', '10', '10.2', '10', 55, 60], [110, 192, 0.0]]],\n [['shrink', [24, 32, '10.5', '9.5', '10.2', '9', 40, 30], [101, 106, -9.5]],\n  ['no change', [20, 28, '10', '10', '10', '10', 50, 45], [100, 126, 0.0]],\n  ['growth', [22, 30, '10', '11', '10', '10.4', 50, 60], [100, 174, 10.0]],\n  ['regression: post-wash width', [22, 32, '10', '11', '10.2', '10', 50, 30], [100, 96, 10.0]],\n  ['repair check: post-wash width', [24, 30, '10', '10.8', '10', '10', 40, 30], [89, 90, 8.0]],\n  ['generated control 1', [24, 32, '10.5', '10.5', '10', '9.5', 55, 60], [126, 202, 0.0]],\n  ['generated control 2', [20, 32, '10.5', '9.5', '10', '10', 55, 45], [116, 144, -9.5]],\n  ['generated control 3', [20, 32, '10', '9.5', '10', '10', 55, 30], [116, 96, -5.0]]],\n [['no change', [20, 28, '10', '10', '10', '10', 50, 45], [100, 126, 0.0]],\n  ['growth', [22, 30, '10', '11', '10', '10.4', 50, 60], [100, 174, 10.0]],\n  ['shrink', [24, 32, '10.5', '9.5', '10.2', '9', 40, 30], [101, 106, -9.5]],\n  ['regression: post-wash width', [24, 28, '10', '9.5', '10.2', '10', 40, 60], [101, 168, -5.0]],\n  ['repair check: post-wash width', [30, 30, '10.5', '9.5', '10', '10', 40, 60], [126, 180, -9.5]],\n  ['generated control 1', [24, 30, '10', '10.5', '10.2', '10.4', 40, 45], [91, 130, 5.0]],\n  ['generated control 2', [30, 32, '10.5', '11', '10.2', '10', 50, 60], [136, 192, 4.8]],\n  ['generated control 3', [22, 28, '10.5', '11', '10.2', '9', 55, 60], [110, 186, 4.8]]],\n [['growth', [22, 30, '10', '11', '10', '10.4', 50, 60], [100, 174, 10.0]],\n  ['shrink', [24, 32, '10.5', '9.5', '10.2', '9', 40, 30], [101, 106, -9.5]],\n  ['no change', [20, 28, '10', '10', '10', '10', 50, 45], [100, 126, 0.0]],\n  ['regression: post-wash width', [22, 40, '10.5', '11', '10', '9', 55, 30], [110, 134, 4.8]],\n  ['repair check: post-wash width', [20, 28, '10', '9.5', '10', '10', 55, 45], [116, 126, -5.0]],\n  ['generated control 1', [20, 30, '10.5', '11', '10', '10', 40, 30], [73, 90, 4.8]],\n  ['generated control 2', [24, 40, '10.5', '10', '10', '9', 40, 30], [96, 134, -4.8]],\n  ['generated control 3', [24, 40, '10.5', '11', '10.2', '10.4', 55, 60], [120, 230, 4.8]]]]\nfor label, args, expected in fixtures[N - 1]:\n    check(label, solve(*args), expected)\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":"0e8955426d01fd4d14292358fe1d0d96d1e1ce761afb820f0b2f961b55973add","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nfrom fractions import Fraction\nN = 1\nobservations = []\ndef solve(sts, rows, w_pre, w_post, h_pre, h_post, target_w, target_h):\n    wpo = Fraction(w_post)\n    hpo = Fraction(h_post)\n    cast = math.floor(target_w * sts / Fraction(w_pre) + Fraction(1, 2))\n    rr = target_h * rows / hpo\n    row_count = 2 * math.floor(rr / 2 + Fraction(1, 2))\n    change = (wpo / Fraction(w_pre) - 1) * 100\n    return [cast, row_count, math.floor(change * 10 + Fraction(1, 2)) / 10]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[['no change', [20, 28, '10', '10', '10', '10', 50, 45], [100, 126, 0.0]],\n  ['growth', [22, 30, '10', '11', '10', '10.4', 50, 60], [100, 174, 10.0]],\n  ['shrink', [24, 32, '10.5', '9.5', '10.2', '9', 40, 30], [101, 106, -9.5]],\n  ['regression: post-wash width', [20, 40, '10.5', '11', '10', '9.5', 50, 45], [91, 190, 4.8]],\n  ['repair check: post-wash width', [22, 28, '10.5', '9.5', '10.2', '10', 50, 30], [116, 84, -9.5]],\n  ['generated control 1', [22, 28, '10', '10.8', '10.2', '10.4', 50, 60], [102, 162, 8.0]],\n  ['generated control 2', [24, 30, '10', '11', '10.2', '10.4', 40, 30], [87, 86, 10.0]],\n  ['generated control 3', [22, 30, '10', '9.5', '10.2', '10', 40, 45], [93, 136, -5.0]]],\n [['growth', [22, 30, '10', '11', '10', '10.4', 50, 60], [100, 174, 10.0]],\n  ['shrink', [24, 32, '10.5', '9.5', '10.2', '9', 40, 30], [101, 106, -9.5]],\n  ['no change', [20, 28, '10', '10', '10', '10', 50, 45], [100, 126, 0.0]],\n  ['regression: post-wash width', [20, 32, '10', '9.5', '10.2', '9', 50, 45], [105, 160, -5.0]],\n  ['repair check: post-wash width', [24, 32, '10.5', '10.8', '10.2', '10', 40, 60], [89, 192, 2.9]],\n  ['generated control 1', [30, 32, '10.5', '10.5', '10', '9', 55, 60], [157, 214, 0.0]],\n  ['generated control 2', [30, 28, '10.5', '10.5', '10', '9.5', 50, 45], [143, 132, 0.0]],\n  ['generated control 3', [20, 32, '10', '10', '10.2', '10', 55, 60], [110, 192, 0.0]]],\n [['shrink', [24, 32, '10.5', '9.5', '10.2', '9', 40, 30], [101, 106, -9.5]],\n  ['no change', [20, 28, '10', '10', '10', '10', 50, 45], [100, 126, 0.0]],\n  ['growth', [22, 30, '10', '11', '10', '10.4', 50, 60], [100, 174, 10.0]],\n  ['regression: post-wash width', [22, 32, '10', '11', '10.2', '10', 50, 30], [100, 96, 10.0]],\n  ['repair check: post-wash width', [24, 30, '10', '10.8', '10', '10', 40, 30], [89, 90, 8.0]],\n  ['generated control 1', [24, 32, '10.5', '10.5', '10', '9.5', 55, 60], [126, 202, 0.0]],\n  ['generated control 2', [20, 32, '10.5', '9.5', '10', '10', 55, 45], [116, 144, -9.5]],\n  ['generated control 3', [20, 32, '10', '9.5', '10', '10', 55, 30], [116, 96, -5.0]]],\n [['no change', [20, 28, '10', '10', '10', '10', 50, 45], [100, 126, 0.0]],\n  ['growth', [22, 30, '10', '11', '10', '10.4', 50, 60], [100, 174, 10.0]],\n  ['shrink', [24, 32, '10.5', '9.5', '10.2', '9', 40, 30], [101, 106, -9.5]],\n  ['regression: post-wash width', [24, 28, '10', '9.5', '10.2', '10', 40, 60], [101, 168, -5.0]],\n  ['repair check: post-wash width', [30, 30, '10.5', '9.5', '10', '10', 40, 60], [126, 180, -9.5]],\n  ['generated control 1', [24, 30, '10', '10.5', '10.2', '10.4', 40, 45], [91, 130, 5.0]],\n  ['generated control 2', [30, 32, '10.5', '11', '10.2', '10', 50, 60], [136, 192, 4.8]],\n  ['generated control 3', [22, 28, '10.5', '11', '10.2', '9', 55, 60], [110, 186, 4.8]]],\n [['growth', [22, 30, '10', '11', '10', '10.4', 50, 60], [100, 174, 10.0]],\n  ['shrink', [24, 32, '10.5', '9.5', '10.2', '9', 40, 30], [101, 106, -9.5]],\n  ['no change', [20, 28, '10', '10', '10', '10', 50, 45], [100, 126, 0.0]],\n  ['regression: post-wash width', [22, 40, '10.5', '11', '10', '9', 55, 30], [110, 134, 4.8]],\n  ['repair check: post-wash width', [20, 28, '10', '9.5', '10', '10', 55, 45], [116, 126, -5.0]],\n  ['generated control 1', [20, 30, '10.5', '11', '10', '10', 40, 30], [73, 90, 4.8]],\n  ['generated control 2', [24, 40, '10.5', '10', '10', '9', 40, 30], [96, 134, -4.8]],\n  ['generated control 3', [24, 40, '10.5', '11', '10.2', '10.4', 55, 60], [120, 230, 4.8]]]]\nfor label, args, expected in fixtures[N - 1]:\n    check(label, solve(*args), expected)\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":"A deterministic toy contract stated in full here; it is a bounded teaching model, not an authoritative reference or standards implementation. 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":"w2-knitting_and_sewing_pattern_grading-post-wash-gauge-post-wash-width","generated_at":"2026-09-29T14:52:34.854337+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Knitters block swatches because many fibres grow or shrink after washing.","root_cause":"Stitch gauge uses the pre-wash swatch width.","sha256":"ee244e4f2e5273197dad386c1acc5acdcb4ce642c5565fbdb26a6abbf7348b54","title":"Post-wash swatch gauge: post-wash width · case 01","variant":1,"variant_policy":"Five numbered records share a model and may reuse boundary fixtures.","verified":true,"visibility":"public","verification":{"attempt":{"elapsed_ms":42.638,"exit_code":1,"observations":[{"actual":[100,126,0.0],"check":"no change","expected":[100,126,0.0],"passed":true},{"actual":[105,174,10.0],"check":"growth","expected":[100,174,10.0],"passed":false},{"actual":[96,106,-9.5],"check":"shrink","expected":[101,106,-9.5],"passed":false},{"actual":[93,190,4.8],"check":"regression: post-wash width","expected":[91,190,4.8],"passed":false},{"actual":[110,84,-9.5],"check":"repair check: post-wash width","expected":[116,84,-9.5],"passed":false},{"actual":[106,162,8.0],"check":"generated control 1","expected":[102,162,8.0],"passed":false},{"actual":[91,86,10.0],"check":"generated control 2","expected":[87,86,10.0],"passed":false},{"actual":[90,136,-5.0],"check":"generated control 3","expected":[93,136,-5.0],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"no change\", \"actual\": [100, 126, 0.0], \"expected\": [100, 126, 0.0], \"passed\": true}, {\"check\": \"growth\", \"actual\": [105, 174, 10.0], \"expected\": [100, 174, 10.0], \"passed\": false}, {\"check\": \"shrink\", \"actual\": [96, 106, -9.5], \"expected\": [101, 106, -9.5], \"passed\": false}, {\"check\": \"regression: post-wash width\", \"actual\": [93, 190, 4.8], \"expected\": [91, 190, 4.8], \"passed\": false}, {\"check\": \"repair check: post-wash width\", \"actual\": [110, 84, -9.5], \"expected\": [116, 84, -9.5], \"passed\": false}, {\"check\": \"generated control 1\", \"actual\": [106, 162, 8.0], \"expected\": [102, 162, 8.0], \"passed\": false}, {\"check\": \"generated control 2\", \"actual\": [91, 86, 10.0], \"expected\": [87, 86, 10.0], \"passed\": false}, {\"check\": \"generated control 3\", \"actual\": [90, 136, -5.0], \"expected\": [93, 136, -5.0], \"passed\": false}], \"passed\": false}\n"},"broken":{"elapsed_ms":41.722,"exit_code":1,"observations":[{"actual":[100,126,0.0],"check":"no change","expected":[100,126,0.0],"passed":true},{"actual":[110,174,10.0],"check":"growth","expected":[100,174,10.0],"passed":false},{"actual":[91,106,-9.5],"check":"shrink","expected":[101,106,-9.5],"passed":false},{"actual":[95,190,4.8],"check":"regression: post-wash width","expected":[91,190,4.8],"passed":false},{"actual":[105,84,-9.5],"check":"repair check: post-wash width","expected":[116,84,-9.5],"passed":false},{"actual":[110,162,8.0],"check":"generated control 1","expected":[102,162,8.0],"passed":false},{"actual":[96,86,10.0],"check":"generated control 2","expected":[87,86,10.0],"passed":false},{"actual":[88,136,-5.0],"check":"generated control 3","expected":[93,136,-5.0],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"no change\", \"actual\": [100, 126, 0.0], \"expected\": [100, 126, 0.0], \"passed\": true}, {\"check\": \"growth\", \"actual\": [110, 174, 10.0], \"expected\": [100, 174, 10.0], \"passed\": false}, {\"check\": \"shrink\", \"actual\": [91, 106, -9.5], \"expected\": [101, 106, -9.5], \"passed\": false}, {\"check\": \"regression: post-wash width\", \"actual\": [95, 190, 4.8], \"expected\": [91, 190, 4.8], \"passed\": false}, {\"check\": \"repair check: post-wash width\", \"actual\": [105, 84, -9.5], \"expected\": [116, 84, -9.5], \"passed\": false}, {\"check\": \"generated control 1\", \"actual\": [110, 162, 8.0], \"expected\": [102, 162, 8.0], \"passed\": false}, {\"check\": \"generated control 2\", \"actual\": [96, 86, 10.0], \"expected\": [87, 86, 10.0], \"passed\": false}, {\"check\": \"generated control 3\", \"actual\": [88, 136, -5.0], \"expected\": [93, 136, -5.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."}}