FAILURE MAP
← Case archive

FA-99511 / Vector retrieval ranking / Open access

Vector retrieval: A repeated source dominates every selected result · case 01

A repeated source dominates every selected result.

Verified by executionVariant 1 · 6 checks per implementationDownload source bundle ↓JSON ↗

ROOT CAUSE

The selector truncates by score without tracking source ownership.

THE FAILURE

The selector truncates by score without tracking source ownership.

Unsuccessful approach: Skipping every row from the first source also discards that source’s best candidate.

Case contract

Rows [id,score,source]; greedily choose highest score with at most one per source.

Why this case matters

An offline vector retrieval toy model isolates one ranking contract from embedding generation, storage, and serving.

1 / The failure

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json

N = 1
observations = []
def solve(rows, k):
    return [r[0] for r in sorted(rows,key=lambda r:(-r[1],r[0]))[:k]]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
rows=[['a',N+3,'x'],['b',N+2,'x'],['c',N+1,'y'],['d',N,'z']]
check('source diversity',solve(rows,3),['a','c','d'])
check('best from source',solve([['b',4,'x'],['a',5,'x'],['c',3,'y']],2),['a','c'])
check('limit one',solve(rows,1),['a'])
check('empty',solve([],N),[])
check('k zero',solve(rows,0),[])
check('all one source',solve([['a',3,'x'],['b',2,'x']],2),['a'])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
source diversity['a', 'b', 'c']['a', 'c', 'd']Failed
best from source['a', 'b']['a', 'c']Failed
limit one['a']['a']Passed
empty[][]Passed
k zero[][]Passed
all one source['a', 'b']['a']Failed

SHA-256 / 67117992bc9bf034134d98b0fe6ff54406428dcdb9e374d1277376eff49a141b

2 / The unsuccessful fix

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json

N = 1
observations = []
def solve(rows, k):
    return [r[0] for r in sorted(rows,key=lambda r:(-r[1],r[0])) if r[2] != rows[0][2]][:k]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
rows=[['a',N+3,'x'],['b',N+2,'x'],['c',N+1,'y'],['d',N,'z']]
check('source diversity',solve(rows,3),['a','c','d'])
check('best from source',solve([['b',4,'x'],['a',5,'x'],['c',3,'y']],2),['a','c'])
check('limit one',solve(rows,1),['a'])
check('empty',solve([],N),[])
check('k zero',solve(rows,0),[])
check('all one source',solve([['a',3,'x'],['b',2,'x']],2),['a'])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
source diversity['c', 'd']['a', 'c', 'd']Failed
best from source['c']['a', 'c']Failed
limit one['c']['a']Failed
empty[][]Passed
k zero[][]Passed
all one source[]['a']Failed

SHA-256 / 611939cff1f6243d78dc402cd0bc6a70bb82c7bbe485f2c60b006f08b64b84f9

HELD IN THE MEMBER ARCHIVE

The verified repair and its recorded checks are member-only.

This mechanism has 6 recorded checks per implementation. The open-access tier publishes the failure and the unsuccessful fix; the repaired source that passes every check, and the observations that prove it, are available to members.

Every case sharing this mechanism uses the same contract and the same repair, so this one record is held back for all of them.

Member access is invitation-based. Sign in with your invited account to inspect the repair.

Sign in to the archive ↗

Verification & scope

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.

Observations recorded using Python 3.12.14 at 2026-09-30T16:48:24.913008+00:00.

Case digest / 266170bc3a41b0a3ab16df7dff81131c30478bd79a906fd327bf7fa6eab7eb06