{"abstract":"Rank fusion starts ranks at zero.","category":"Vector retrieval ranking","checks":6,"contract":"Lists contain unique IDs; fuse by sum 1/(offset+one-based-rank), then ID ties.","contract_signature":"lists, offset","evaluation_group":"vector-retrieval-reciprocal-rank-fusion","failed_approach":"Starting at one but incrementing the denominator again depresses every rank contribution.","family":"w3-vector-retrieval-ranking-reciprocal-rank-fusion","id":"FA-99506","implementations":{"attempt":{"sha256":"06447d43b8a0aa30402e1bd38c022a29d5bfb9f55191209fac192ec3018bc989","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(lists, offset):\n    from fractions import Fraction\n    s={}\n    for xs in lists:\n     for rank,(ident,score) in enumerate(xs,1): s[ident]=s.get(ident,0)+Fraction(1,offset+rank+1)\n    return sorted(s,key=lambda x:(-s[x],x))\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('shared low rank',solve([[['a',1],['b',0]],[['b',1]]],1),['b','a'])\ncheck('offset changes tradeoff',solve([[['a',1],['x',0],['b',0]],[['y',1],['z',0],['b',0]]],1),['a','b','y','x','z'])\ncheck('single list order',solve([[['z',1],['a',9]]],N),['z','a'])\ncheck('empty lists',solve([[],[]],N),[])\ncheck('one item',solve([[['a',0]]],N),['a'])\ncheck('two lists same id',solve([[['a',0]],[['a',0]]],N),['a'])\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":"4c427540c772a638e9f4a77c9ddb517cd66d81cbf224acaec0431793258f895d","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(lists, offset):\n    from fractions import Fraction\n    s={}\n    for xs in lists:\n     for rank,(ident,score) in enumerate(xs): s[ident]=s.get(ident,0)+Fraction(1,offset+rank)\n    return sorted(s,key=lambda x:(-s[x],x))\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('shared low rank',solve([[['a',1],['b',0]],[['b',1]]],1),['b','a'])\ncheck('offset changes tradeoff',solve([[['a',1],['x',0],['b',0]],[['y',1],['z',0],['b',0]]],1),['a','b','y','x','z'])\ncheck('single list order',solve([[['z',1],['a',9]]],N),['z','a'])\ncheck('empty lists',solve([[],[]],N),[])\ncheck('one item',solve([[['a',0]]],N),['a'])\ncheck('two lists same id',solve([[['a',0]],[['a',0]]],N),['a'])\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":"Inputs are small exact toy vectors and scores. No production index, ANN recall, embedding quality, or latency claim is implied. 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-vector-retrieval-ranking-reciprocal-rank-fusion","generated_at":"2026-09-30T16:48:24.915235+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"An offline vector retrieval toy model isolates one ranking contract from embedding generation, storage, and serving.","root_cause":"Enumerating from zero gives the first hit too much reciprocal weight.","sha256":"055048af7d3ef1cefe1b2901ea617a1828694e0707ef48bca3186230e27009c8","title":"Vector retrieval: Rank fusion starts ranks at zero · 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":27.043,"exit_code":1,"observations":[{"actual":["b","a"],"check":"shared low rank","expected":["b","a"],"passed":true},{"actual":["b","a","y","x","z"],"check":"offset changes tradeoff","expected":["a","b","y","x","z"],"passed":false},{"actual":["z","a"],"check":"single list order","expected":["z","a"],"passed":true},{"actual":[],"check":"empty lists","expected":[],"passed":true},{"actual":["a"],"check":"one item","expected":["a"],"passed":true},{"actual":["a"],"check":"two lists same id","expected":["a"],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"shared low rank\", \"actual\": [\"b\", \"a\"], \"expected\": [\"b\", \"a\"], \"passed\": true}, {\"check\": \"offset changes tradeoff\", \"actual\": [\"b\", \"a\", \"y\", \"x\", \"z\"], \"expected\": [\"a\", \"b\", \"y\", \"x\", \"z\"], \"passed\": false}, {\"check\": \"single list order\", \"actual\": [\"z\", \"a\"], \"expected\": [\"z\", \"a\"], \"passed\": true}, {\"check\": \"empty lists\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"one item\", \"actual\": [\"a\"], \"expected\": [\"a\"], \"passed\": true}, {\"check\": \"two lists same id\", \"actual\": [\"a\"], \"expected\": [\"a\"], \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":29.324,"exit_code":1,"observations":[{"actual":["b","a"],"check":"shared low rank","expected":["b","a"],"passed":true},{"actual":["a","y","b","x","z"],"check":"offset changes tradeoff","expected":["a","b","y","x","z"],"passed":false},{"actual":["z","a"],"check":"single list order","expected":["z","a"],"passed":true},{"actual":[],"check":"empty lists","expected":[],"passed":true},{"actual":["a"],"check":"one item","expected":["a"],"passed":true},{"actual":["a"],"check":"two lists same id","expected":["a"],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"shared low rank\", \"actual\": [\"b\", \"a\"], \"expected\": [\"b\", \"a\"], \"passed\": true}, {\"check\": \"offset changes tradeoff\", \"actual\": [\"a\", \"y\", \"b\", \"x\", \"z\"], \"expected\": [\"a\", \"b\", \"y\", \"x\", \"z\"], \"passed\": false}, {\"check\": \"single list order\", \"actual\": [\"z\", \"a\"], \"expected\": [\"z\", \"a\"], \"passed\": true}, {\"check\": \"empty lists\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"one item\", \"actual\": [\"a\"], \"expected\": [\"a\"], \"passed\": true}, {\"check\": \"two lists same id\", \"actual\": [\"a\"], \"expected\": [\"a\"], \"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."}}