{"abstract":"A yarn at exactly 18 wpi is classed as dk.","category":"Knitting and sewing pattern grading","checks":8,"contract":"Strands held together combine as 1/sqrt(sum(1/wpi^2)), rounded half-up to 0.1. Classify the rounded value: >=30 lace, >=18 fingering, >=14 dk, >=11 worsted, >=8 bulky, else super bulky. Empty -> \"error: no strands\". Return [wpi, class].","evaluation_group":"w2-knitting_and_sewing_pattern_grading-held-strands","failed_approach":"A one-wpi slack pulls 17.x wpi into fingering.","family":"w2-knitting_and_sewing_pattern_grading-held-strands-band-threshold","id":"FA-97756","implementations":{"attempt":{"sha256":"d727f687f07b4d593315909aa9cc2a4fdd0d5f5e5275c87a3a4f59702a05d3c3","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nfrom fractions import Fraction\nN = 1\nobservations = []\ndef solve(wpis):\n    BANDS = [(30, 'lace'), (18, 'fingering'), (14, 'dk'), (11, 'worsted'), (8, 'bulky'), (0, 'super bulky')]\n    if not wpis:\n        return 'error: no strands'\n    eff = 1 / math.sqrt(sum(1 / (w * w) for w in wpis))\n    eff = math.floor(eff * 10 + 0.5) / 10\n    for lim, name in BANDS:\n        if eff + 1 > lim:\n            return [eff, name]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[['single fingering', [[20]], [20.0, 'fingering']], ['two dk strands', [[14, 14]], [9.9, 'bulky']],\n  ['empty', [[]], 'error: no strands'], ['regression: band threshold', [[18, 9]], [8.0, 'bulky']],\n  ['repair check: band threshold', [[18, 8]], [7.3, 'super bulky']],\n  ['generated control 1', [[9]], [9.0, 'bulky']],\n  ['generated control 2', [[8, 24, 16]], [6.9, 'super bulky']],\n  ['generated control 3', [[18, 16]], [12.0, 'worsted']]],\n [['two dk strands', [[14, 14]], [9.9, 'bulky']], ['empty', [[]], 'error: no strands'],\n  ['band edge', [[18]], [18.0, 'fingering']], ['regression: band threshold', [[11]], [11.0, 'worsted']],\n  ['repair check: band threshold', [[35, 14, 16]], [10.1, 'bulky']],\n  ['generated control 1', [[8, 16, 12]], [6.1, 'super bulky']], ['generated control 2', [[16]], [16.0, 'dk']],\n  ['generated control 3', [[11, 16]], [9.1, 'bulky']]],\n [['empty', [[]], 'error: no strands'], ['band edge', [[18]], [18.0, 'fingering']],\n  ['single fingering', [[20]], [20.0, 'fingering']], ['regression: band threshold', [[8]], [8.0, 'bulky']],\n  ['repair check: band threshold', [[8, 30, 18]], [7.1, 'super bulky']],\n  ['generated control 1', [[14, 35, 24]], [11.4, 'worsted']], ['generated control 2', [[16]], [16.0, 'dk']],\n  ['generated control 3', [[35]], [35.0, 'lace']]],\n [['band edge', [[18]], [18.0, 'fingering']], ['single fingering', [[20]], [20.0, 'fingering']],\n  ['two dk strands', [[14, 14]], [9.9, 'bulky']], ['regression: band threshold', [[8]], [8.0, 'bulky']],\n  ['repair check: band threshold', [[24, 8]], [7.6, 'super bulky']],\n  ['generated control 1', [[]], 'error: no strands'], ['generated control 2', [[11, 30, 24]], [9.5, 'bulky']],\n  ['generated control 3', [[30, 24, 9]], [8.1, 'bulky']]],\n [['single fingering', [[20]], [20.0, 'fingering']], ['two dk strands', [[14, 14]], [9.9, 'bulky']],\n  ['empty', [[]], 'error: no strands'], ['regression: band threshold', [[11]], [11.0, 'worsted']],\n  ['repair check: band threshold', [[30, 11]], [10.3, 'bulky']],\n  ['generated control 1', [[16, 30]], [14.1, 'dk']],\n  ['generated control 2', [[14, 8, 8]], [5.2, 'super bulky']],\n  ['generated control 3', [[20, 9, 12]], [6.8, 'super bulky']]]]\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":"3b489c9733c5dace476fee2efd4d49e67d8afbfac3218c53d6a73acc4851ceef","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nfrom fractions import Fraction\nN = 1\nobservations = []\ndef solve(wpis):\n    BANDS = [(30, 'lace'), (18, 'fingering'), (14, 'dk'), (11, 'worsted'), (8, 'bulky'), (0, 'super bulky')]\n    if not wpis:\n        return 'error: no strands'\n    eff = 1 / math.sqrt(sum(1 / (w * w) for w in wpis))\n    eff = math.floor(eff * 10 + 0.5) / 10\n    for lim, name in BANDS:\n        if eff > lim:\n            return [eff, name]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[['single fingering', [[20]], [20.0, 'fingering']], ['two dk strands', [[14, 14]], [9.9, 'bulky']],\n  ['empty', [[]], 'error: no strands'], ['regression: band threshold', [[18, 9]], [8.0, 'bulky']],\n  ['repair check: band threshold', [[18, 8]], [7.3, 'super bulky']],\n  ['generated control 1', [[9]], [9.0, 'bulky']],\n  ['generated control 2', [[8, 24, 16]], [6.9, 'super bulky']],\n  ['generated control 3', [[18, 16]], [12.0, 'worsted']]],\n [['two dk strands', [[14, 14]], [9.9, 'bulky']], ['empty', [[]], 'error: no strands'],\n  ['band edge', [[18]], [18.0, 'fingering']], ['regression: band threshold', [[11]], [11.0, 'worsted']],\n  ['repair check: band threshold', [[35, 14, 16]], [10.1, 'bulky']],\n  ['generated control 1', [[8, 16, 12]], [6.1, 'super bulky']], ['generated control 2', [[16]], [16.0, 'dk']],\n  ['generated control 3', [[11, 16]], [9.1, 'bulky']]],\n [['empty', [[]], 'error: no strands'], ['band edge', [[18]], [18.0, 'fingering']],\n  ['single fingering', [[20]], [20.0, 'fingering']], ['regression: band threshold', [[8]], [8.0, 'bulky']],\n  ['repair check: band threshold', [[8, 30, 18]], [7.1, 'super bulky']],\n  ['generated control 1', [[14, 35, 24]], [11.4, 'worsted']], ['generated control 2', [[16]], [16.0, 'dk']],\n  ['generated control 3', [[35]], [35.0, 'lace']]],\n [['band edge', [[18]], [18.0, 'fingering']], ['single fingering', [[20]], [20.0, 'fingering']],\n  ['two dk strands', [[14, 14]], [9.9, 'bulky']], ['regression: band threshold', [[8]], [8.0, 'bulky']],\n  ['repair check: band threshold', [[24, 8]], [7.6, 'super bulky']],\n  ['generated control 1', [[]], 'error: no strands'], ['generated control 2', [[11, 30, 24]], [9.5, 'bulky']],\n  ['generated control 3', [[30, 24, 9]], [8.1, 'bulky']]],\n [['single fingering', [[20]], [20.0, 'fingering']], ['two dk strands', [[14, 14]], [9.9, 'bulky']],\n  ['empty', [[]], 'error: no strands'], ['regression: band threshold', [[11]], [11.0, 'worsted']],\n  ['repair check: band threshold', [[30, 11]], [10.3, 'bulky']],\n  ['generated control 1', [[16, 30]], [14.1, 'dk']],\n  ['generated control 2', [[14, 8, 8]], [5.2, 'super bulky']],\n  ['generated control 3', [[20, 9, 12]], [6.8, 'super bulky']]]]\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"},"fixed":{"sha256":"69958d45fc1050bd2bbb3ee506899d33e59bfbe2b0f06cf36ef1a62f3992dd51","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nfrom fractions import Fraction\nN = 1\nobservations = []\ndef solve(wpis):\n    BANDS = [(30, 'lace'), (18, 'fingering'), (14, 'dk'), (11, 'worsted'), (8, 'bulky'), (0, 'super bulky')]\n    if not wpis:\n        return 'error: no strands'\n    eff = 1 / math.sqrt(sum(1 / (w * w) for w in wpis))\n    eff = math.floor(eff * 10 + 0.5) / 10\n    for lim, name in BANDS:\n        if eff >= lim:\n            return [eff, name]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[['single fingering', [[20]], [20.0, 'fingering']], ['two dk strands', [[14, 14]], [9.9, 'bulky']],\n  ['empty', [[]], 'error: no strands'], ['regression: band threshold', [[18, 9]], [8.0, 'bulky']],\n  ['repair check: band threshold', [[18, 8]], [7.3, 'super bulky']],\n  ['generated control 1', [[9]], [9.0, 'bulky']],\n  ['generated control 2', [[8, 24, 16]], [6.9, 'super bulky']],\n  ['generated control 3', [[18, 16]], [12.0, 'worsted']]],\n [['two dk strands', [[14, 14]], [9.9, 'bulky']], ['empty', [[]], 'error: no strands'],\n  ['band edge', [[18]], [18.0, 'fingering']], ['regression: band threshold', [[11]], [11.0, 'worsted']],\n  ['repair check: band threshold', [[35, 14, 16]], [10.1, 'bulky']],\n  ['generated control 1', [[8, 16, 12]], [6.1, 'super bulky']], ['generated control 2', [[16]], [16.0, 'dk']],\n  ['generated control 3', [[11, 16]], [9.1, 'bulky']]],\n [['empty', [[]], 'error: no strands'], ['band edge', [[18]], [18.0, 'fingering']],\n  ['single fingering', [[20]], [20.0, 'fingering']], ['regression: band threshold', [[8]], [8.0, 'bulky']],\n  ['repair check: band threshold', [[8, 30, 18]], [7.1, 'super bulky']],\n  ['generated control 1', [[14, 35, 24]], [11.4, 'worsted']], ['generated control 2', [[16]], [16.0, 'dk']],\n  ['generated control 3', [[35]], [35.0, 'lace']]],\n [['band edge', [[18]], [18.0, 'fingering']], ['single fingering', [[20]], [20.0, 'fingering']],\n  ['two dk strands', [[14, 14]], [9.9, 'bulky']], ['regression: band threshold', [[8]], [8.0, 'bulky']],\n  ['repair check: band threshold', [[24, 8]], [7.6, 'super bulky']],\n  ['generated control 1', [[]], 'error: no strands'], ['generated control 2', [[11, 30, 24]], [9.5, 'bulky']],\n  ['generated control 3', [[30, 24, 9]], [8.1, 'bulky']]],\n [['single fingering', [[20]], [20.0, 'fingering']], ['two dk strands', [[14, 14]], [9.9, 'bulky']],\n  ['empty', [[]], 'error: no strands'], ['regression: band threshold', [[11]], [11.0, 'worsted']],\n  ['repair check: band threshold', [[30, 11]], [10.3, 'bulky']],\n  ['generated control 1', [[16, 30]], [14.1, 'dk']],\n  ['generated control 2', [[14, 8, 8]], [5.2, 'super bulky']],\n  ['generated control 3', [[20, 9, 12]], [6.8, 'super bulky']]]]\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-held-strands-band-threshold","generated_at":"2026-09-29T14:52:35.276664+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Knitters hold yarns double to substitute a heavier weight and need the combined wraps per inch.","repair":"Use inclusive lower bounds.","root_cause":"Band lower bounds are exclusive.","sha256":"b553a18f4da4336de169f8ba15471fb9c98a71ffd0d1526721ba85651cecaeee","title":"Held-together yarn weight estimator: band threshold · case 01","variant":1,"variant_policy":"Five numbered records share a model and may reuse boundary fixtures.","verification":{"attempt":{"elapsed_ms":45.261,"exit_code":1,"observations":[{"actual":[20.0,"fingering"],"check":"single fingering","expected":[20.0,"fingering"],"passed":true},{"actual":[9.9,"bulky"],"check":"two dk strands","expected":[9.9,"bulky"],"passed":true},{"actual":"error: no strands","check":"empty","expected":"error: no strands","passed":true},{"actual":[8.0,"bulky"],"check":"regression: band threshold","expected":[8.0,"bulky"],"passed":true},{"actual":[7.3,"bulky"],"check":"repair check: band threshold","expected":[7.3,"super bulky"],"passed":false},{"actual":[9.0,"bulky"],"check":"generated control 1","expected":[9.0,"bulky"],"passed":true},{"actual":[6.9,"super bulky"],"check":"generated control 2","expected":[6.9,"super bulky"],"passed":true},{"actual":[12.0,"worsted"],"check":"generated control 3","expected":[12.0,"worsted"],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"single fingering\", \"actual\": [20.0, \"fingering\"], \"expected\": [20.0, \"fingering\"], \"passed\": true}, {\"check\": \"two dk strands\", \"actual\": [9.9, \"bulky\"], \"expected\": [9.9, \"bulky\"], \"passed\": true}, {\"check\": \"empty\", \"actual\": \"error: no strands\", \"expected\": \"error: no strands\", \"passed\": true}, {\"check\": \"regression: band threshold\", \"actual\": [8.0, \"bulky\"], \"expected\": [8.0, \"bulky\"], \"passed\": true}, {\"check\": \"repair check: band threshold\", \"actual\": [7.3, \"bulky\"], \"expected\": [7.3, \"super bulky\"], \"passed\": false}, {\"check\": \"generated control 1\", \"actual\": [9.0, \"bulky\"], \"expected\": [9.0, \"bulky\"], \"passed\": true}, {\"check\": \"generated control 2\", \"actual\": [6.9, \"super bulky\"], \"expected\": [6.9, \"super bulky\"], \"passed\": true}, {\"check\": \"generated control 3\", \"actual\": [12.0, \"worsted\"], \"expected\": [12.0, \"worsted\"], \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":46.621,"exit_code":1,"observations":[{"actual":[20.0,"fingering"],"check":"single fingering","expected":[20.0,"fingering"],"passed":true},{"actual":[9.9,"bulky"],"check":"two dk strands","expected":[9.9,"bulky"],"passed":true},{"actual":"error: no strands","check":"empty","expected":"error: no strands","passed":true},{"actual":[8.0,"super bulky"],"check":"regression: band threshold","expected":[8.0,"bulky"],"passed":false},{"actual":[7.3,"super bulky"],"check":"repair check: band threshold","expected":[7.3,"super bulky"],"passed":true},{"actual":[9.0,"bulky"],"check":"generated control 1","expected":[9.0,"bulky"],"passed":true},{"actual":[6.9,"super bulky"],"check":"generated control 2","expected":[6.9,"super bulky"],"passed":true},{"actual":[12.0,"worsted"],"check":"generated control 3","expected":[12.0,"worsted"],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"single fingering\", \"actual\": [20.0, \"fingering\"], \"expected\": [20.0, \"fingering\"], \"passed\": true}, {\"check\": \"two dk strands\", \"actual\": [9.9, \"bulky\"], \"expected\": [9.9, \"bulky\"], \"passed\": true}, {\"check\": \"empty\", \"actual\": \"error: no strands\", \"expected\": \"error: no strands\", \"passed\": true}, {\"check\": \"regression: band threshold\", \"actual\": [8.0, \"super bulky\"], \"expected\": [8.0, \"bulky\"], \"passed\": false}, {\"check\": \"repair check: band threshold\", \"actual\": [7.3, \"super bulky\"], \"expected\": [7.3, \"super bulky\"], \"passed\": true}, {\"check\": \"generated control 1\", \"actual\": [9.0, \"bulky\"], \"expected\": [9.0, \"bulky\"], \"passed\": true}, {\"check\": \"generated control 2\", \"actual\": [6.9, \"super bulky\"], \"expected\": [6.9, \"super bulky\"], \"passed\": true}, {\"check\": \"generated control 3\", \"actual\": [12.0, \"worsted\"], \"expected\": [12.0, \"worsted\"], \"passed\": true}], \"passed\": false}\n"},"fixed":{"elapsed_ms":42.469,"exit_code":0,"observations":[{"actual":[20.0,"fingering"],"check":"single fingering","expected":[20.0,"fingering"],"passed":true},{"actual":[9.9,"bulky"],"check":"two dk strands","expected":[9.9,"bulky"],"passed":true},{"actual":"error: no strands","check":"empty","expected":"error: no strands","passed":true},{"actual":[8.0,"bulky"],"check":"regression: band threshold","expected":[8.0,"bulky"],"passed":true},{"actual":[7.3,"super bulky"],"check":"repair check: band threshold","expected":[7.3,"super bulky"],"passed":true},{"actual":[9.0,"bulky"],"check":"generated control 1","expected":[9.0,"bulky"],"passed":true},{"actual":[6.9,"super bulky"],"check":"generated control 2","expected":[6.9,"super bulky"],"passed":true},{"actual":[12.0,"worsted"],"check":"generated control 3","expected":[12.0,"worsted"],"passed":true}],"passed":true,"stderr":"","stdout":"{\"observations\": [{\"check\": \"single fingering\", \"actual\": [20.0, \"fingering\"], \"expected\": [20.0, \"fingering\"], \"passed\": true}, {\"check\": \"two dk strands\", \"actual\": [9.9, \"bulky\"], \"expected\": [9.9, \"bulky\"], \"passed\": true}, {\"check\": \"empty\", \"actual\": \"error: no strands\", \"expected\": \"error: no strands\", \"passed\": true}, {\"check\": \"regression: band threshold\", \"actual\": [8.0, \"bulky\"], \"expected\": [8.0, \"bulky\"], \"passed\": true}, {\"check\": \"repair check: band threshold\", \"actual\": [7.3, \"super bulky\"], \"expected\": [7.3, \"super bulky\"], \"passed\": true}, {\"check\": \"generated control 1\", \"actual\": [9.0, \"bulky\"], \"expected\": [9.0, \"bulky\"], \"passed\": true}, {\"check\": \"generated control 2\", \"actual\": [6.9, \"super bulky\"], \"expected\": [6.9, \"super bulky\"], \"passed\": true}, {\"check\": \"generated control 3\", \"actual\": [12.0, \"worsted\"], \"expected\": [12.0, \"worsted\"], \"passed\": true}], \"passed\": true}\n"}},"verified":true,"visibility":"public"}