Data engineering & quality

Retrieve Similar Fund Names Without Merging Different Share Classes

Compare character and actual dense candidate retrieval, then expose the share-class conflicts that a high similarity score cannot resolve.

Funds & Asset ManagementIndependent technical study

Source case: Coupang. The article separates the published design from the data, methods and observations in this local experiment.

The wrong neighbour can look like a successful match

A reference-data analyst receives an abbreviated instrument name without an ISIN. Finding the right fund family is insufficient: an accumulating class and a distributing class can share almost every word. Linking the wrong class could attach a later price or distribution record to the wrong instrument. The useful output is a small, explainable candidate set with unresolved identity questions.

Coupang’s 1 July 2022 engineering article, CSV row 674, addresses duplicate retail catalogue items. It reframes matching as candidate search, comparing Elasticsearch with separate image and text embedding indexes using FAISS. A downstream binary matcher evaluates returned pairs. The article assumes satisfactory embeddings and explicitly excludes their training. Its transferable idea is to distinguish candidate coverage from pairwise identity, rather than make one similarity score answer both questions.

Study reconstruction separating direct identifier lookup and parallel candidate search from explicit share-class checks and source review.Open full-size diagram (opens in a new tab)

Study reconstruction: the candidate-versus-identity boundary, adapted to fund reference data. This is an independent design, not Coupang's architecture diagram.

Design reference: Coupang Engineering, 1 July 2022

Make the near-neighbours real and the invented inputs visible

The reference side contains thirteen public, issuer-documented share classes across five ETF families. It is a byte-identical copy of the earlier Next Gate Tech case’s source snapshot, with the parent SHA retained. Each record links to its issuer and identifies which fields were manually transcribed on 26 November 2026. No earlier embeddings are reused.

The public classes provide realistic hard negatives: eight Vanguard records form accumulating/distributing pairs; five iShares bond classes vary in currency, income treatment and hedging label. Eight Vanguard hedging fields remain undocumented. The experiment does not convert those nulls into “unhedged.” For iShares, not_labelled_hedged preserves the recorded naming label rather than asserting a universal financial interpretation.

Eighteen new supplier inputs are authored development fixtures. Ten have an intended target fixed before embedding. Eight separately exercise missing attributes, absent coverage and identifier handling. Fourteen omit IDs and enter retrieval; four supplied-ID cases bypass it. These descriptions are neither observed feed aliases nor independent held-out annotations.

Two current issuer spot-checks help explain the schema. Vanguard’s All-World page shows the same ISIN across listing currencies. The iShares USD hedged class page separately identifies class currency, income and ISIN. A EUR exchange listing therefore cannot silently become a EUR share-class assertion. These checks do not constitute a fresh audit of every catalogue entry.

Compare representations before adding a matching model

Both methods search exactly the same thirteen documents: issuer, fund name and class label. They receive the same query name. ISINs, typed constraints and reference targets are excluded from both text representations, so an identifier token cannot make retrieval appear smarter than it is.

The inexpensive baseline uses word-boundary character trigrams through five-grams, sublinear term frequency and smoothed IDF fitted only on catalogue documents. L2-normalized cosine rewards shared fragments despite punctuation, abbreviations and minor spelling errors. It cannot reliably connect “five hundred large US companies” with a named index or distinguish every paraphrased distribution policy.

The alternative makes two actual local Nomic v1.5 embedding calls: thirteen documents and fourteen query names. It uses the model’s retrieval prefixes, disables truncation and retains all 768-dimensional vectors. Exact cosine over thirteen vectors is sufficient. Adding FAISS here would introduce index machinery without demonstrating a scale problem; there is no image encoder, pair-classifier training or approximate search.

The primary comparison ranks the full catalogue before inspecting class attributes. A second control filters by explicit attributes before applying the candidate budget, while retaining the same scores and vectors. This reveals whether a missing target is a representation problem or simply budget consumed by known incompatible neighbours.

For a candidate-restricted selector, final correctness depends on both target coverage and choosing correctly when the target is present. Raising recall helps the first term; it cannot establish the second. This lab measures candidate coverage and deterministic attribute compatibility separately, rather than reporting a fabricated end-to-end matching rate.

Five candidates recover more targets, with more work left to do

Actual candidate coverage on ten authored aliases: character TF-IDF recovers six, seven and seven targets at budgets one, three and five; Nomic recovers seven, eight and ten.Open full-size figure (opens in a new tab)
Actual offline replay of newly recorded embeddings. The denominator is ten author-intended singleton queries, not the eighteen-input suite or a fund-provider population.

At candidate budgets one, three and five, character retrieval finds 6, 7 and 7 intended targets; Nomic finds 7, 8 and 10. Dense retrieval earns a limited role here: it recovers vocabulary variation that this character representation misses. Increasing the budget from three to five also increases the evidence a reviewer must inspect. No timing or operational-cost advantage is inferred.

Consider S03: “Vanguard five hundred large US companies ETF reinvesting distributions.” Both methods first return the distributing S&P 500 class, IE00B3XXRP09. The authored target is its accumulating neighbour, IE00BFMXXD54, at character rank seven and dense rank five. The top result identifies the strategy while missing the income treatment.

The separately asserted income=accumulating rejects that first candidate. Filtering before ranking makes the intended class first under both methods for S03. Across all ten target inputs, however, filtered top-one results are only 7/10 and 8/10. Income and currency cannot distinguish All-World from Emerging Markets when both offer compatible classes.

Each method’s first three lists contain eighteen incompatible candidates out of thirty inspected candidates on these ten queries. That is wasted candidate budget, not eighteen actual merges. Five bond inputs become singleton eligible sets after their metadata filters; crediting those filtered outcomes entirely to semantic understanding would overstate the model’s contribution.

Compatibility narrows a search; it does not create an identifier

The core comparison has three outcomes for an asserted attribute: equal, conflict or undocumented. It never interprets missing evidence as verified equality. The source of a field matters: in this experiment, supplier metadata is explicitly authored input, not a fact certified by the service.

Actual attribute comparison: retain unknowns and explicit conflictsPython13 lines
def compare_fields(query, record):
    """Explicit assertions only; a missing recorded attribute cannot verify a claim."""
    unknown = set(query["fields"]) - set(FIELDS)
    if unknown:
        raise ValueError(f"Unsupported metadata: {sorted(unknown)}")
    checks = []
    for field, asserted in query["fields"].items():
        if asserted is None:
            continue
        actual = record.get(field)
        state = "undocumented" if actual is None else "equal" if asserted == actual else "conflict"
        checks.append({"field": field, "asserted": asserted, "recorded": actual, "state": state})
    return checks

The service routes a supplied ISIN directly to the registry. A known ID with consistent supplied fields returns an identified record. Conflicting metadata stays in identifier review; an unregistered ID returns no match within the declared catalogue. Neither path substitutes a more similar instrument name.

Without an ID, even one compatible candidate remains a review proposal. R02, for example, supplies USD and accumulating but omits hedging. Two bond classes remain possible. Asking for the missing class evidence is more useful than presenting a tiny cosine difference as confidence.

R04 is deliberately less comfortable: an invented Baltic microcap name still retrieves real neighbours, some compatible with its asserted fields. The implementation cannot prove that the name is outside its universe. It preserves candidate review and never fills an ISIN. An out-of-catalogue identifier can be rejected by exact lookup; an out-of-catalogue name requires evidence the nearest-neighbour machinery does not possess.

Deliver an investigation packet, then decide what deserves deployment

For a Luxembourg fund-data team, the useful handoff would preserve the original supplier identifier and name, source timestamp, candidate IDs, attribute comparisons and issuer links. A reviewer could request a missing income or hedging field, confirm a source-backed identity, or leave the record unmatched. The local program produces the comparisons; a persistent workbench, source ingestion and approved security-master write are proposed integration boundaries.

The next evaluation should use genuinely unseen supplier aliases, group related share classes together when designing splits, and record both missed identities and wrong-class proposals. It should also separate missing attributes from incorrect supplied attributes: filtering on a confidently wrong field can remove the true class before retrieval. A name-derived value must not quietly masquerade as independent metadata.

Images are not automatically the next improvement. A shared issuer logo or fund-family graphic is unlikely to distinguish these classes. Better source-backed class metadata may be more valuable than another embedding modality. A trained pair matcher would need reviewed positive and near-negative pairs, including wrong currency and income classes; this study supplies no evidence that such a model is necessary yet.

My adoption boundary is therefore narrow: retain the lexical baseline, investigate dense candidates where vocabulary differs, and prefer verified identifiers over either similarity score. The observed dense coverage gain justifies further data collection, while the wrong first suggestions explain why candidate generation must remain separate from entity linking.

Inspect all eighteen inputs, recorded rankings and reproduction details

Recorded experiment

What the experiment actually shows

Authored development aliases over 13 public classes. Candidate recall is not match accuracy.

Data and comparison boundary

Methods compared

Character TF–IDF
Catalogue-fitted 3–5 character grams, sublinear TF, smoothed IDF and cosine.
Actual Nomic v1.5
Same name/class text, retrieval prefixes, 768-dimensional vectors; no ISIN or expected IDs in model payload.
Typed comparison
Explicit attributes checked after top3; a filter-before-ranking control uses the same scores. Known ID never fuzzy-replaced.

Recorded findings

Character candidate recall @1 / 3 / 5
6/10 / 7/10 / 7/10

The denominator contains only ten authored singleton intentions.

Nomic candidate recall @1 / 3 / 5
7/10 / 8/10 / 10/10

More candidate coverage at k5, not a measured correct-merge rate.

Top3 incompatible candidates
18/30 for each method

Same count, different individual candidates; explicit class metadata rules out these neighbours in the ten diagnostic inputs.

Inspect a recorded example

S01 — Typo and abbreviated income label
Input

{ "id": "S01", "title": "Typo and abbreviated income label", "name": "Vangrd FTSE All Wrld USD Acc", "fields": { "issuer": "Vanguard", "share_class_currency": "USD", "income": "accumulating" }, "isin": null, "origin": "authored supplier variation; not an observed feed record" }

Baseline output

{ "route": "candidate_retrieval", "top5": [ { "id": "IE00BK5BQT80", "score": 0.646579854 }, { "id": "IE00B3RBWM25", "score": 0.588993123 }, { "id": "IE00BK5BQV03", "score": 0.342939421 }, { "id": "IE00BKX55T58", "score": 0.30137902 }, { "id": "IE00BK5BR733", "score": 0.269145723 } ], "typed_comparison": { "state": "candidate_review", "id": null, "candidates": [ { "id": "IE00BK5BQT80", "checks": [ { "field": "issuer", "asserted": "Vanguard", "recorded": "Vanguard", "state": "equal" }, { "field": "share_class_currency", "asserted": "USD", "recorded": "USD", "state": "equal" }, { "field": "income", "asserted": "accumulating", "recorded": "accumulating", "state": "equal" } ], "compatible": true }, { "id": "IE00B3RBWM25", "checks": [ { "field": "issuer", "asserted": "Vanguard", "recorded": "Vanguard", "state": "equal" }, { "field": "share_class_currency", "asserted": "USD", "recorded": "USD", "state": "equal" }, { "field": "income", "asserted": "accumulating", "recorded": "distributing", "state": "conflict" } ], "compatible": false }, { "id": "IE00BK5BQV03", "checks": [ { "field": "issuer", "asserted": "Vanguard", "recorded": "Vanguard", "state": "equal" }, { "field": "share_class_currency", "asserted": "USD", "recorded": "USD", "state": "equal" }, { "field": "income", "asserted": "accumulating", "recorded": "accumulating", "state": "equal" } ], "compatible": true } ], "compatible_in_corpus": [ "IE00BK5BQT80", "IE00BFMXXD54", "IE00BK5BQV03", "IE00BK5BR733" ], "budget_exhausted": false, "auto_merge": false } }

Candidate output

{ "route": "candidate_retrieval", "top5": [ { "id": "IE00BK5BQT80", "score": 0.660503338 }, { "id": "IE00B3RBWM25", "score": 0.647859225 }, { "id": "IE00BK5BQV03", "score": 0.629177851 }, { "id": "IE00BKX55T58", "score": 0.61609352 }, { "id": "IE00BK5BR733", "score": 0.607621491 } ], "typed_comparison": { "state": "candidate_review", "id": null, "candidates": [ { "id": "IE00BK5BQT80", "checks": [ { "field": "issuer", "asserted": "Vanguard", "recorded": "Vanguard", "state": "equal" }, { "field": "share_class_currency", "asserted": "USD", "recorded": "USD", "state": "equal" }, { "field": "income", "asserted": "accumulating", "recorded": "accumulating", "state": "equal" } ], "compatible": true }, { "id": "IE00B3RBWM25", "checks": [ { "field": "issuer", "asserted": "Vanguard", "recorded": "Vanguard", "state": "equal" }, { "field": "share_class_currency", "asserted": "USD", "recorded": "USD", "state": "equal" }, { "field": "income", "asserted": "accumulating", "recorded": "distributing", "state": "conflict" } ], "compatible": false }, { "id": "IE00BK5BQV03", "checks": [ { "field": "issuer", "asserted": "Vanguard", "recorded": "Vanguard", "state": "equal" }, { "field": "share_class_currency", "asserted": "USD", "recorded": "USD", "state": "equal" }, { "field": "income", "asserted": "accumulating", "recorded": "accumulating", "state": "equal" } ], "compatible": true } ], "compatible_in_corpus": [ "IE00BK5BQT80", "IE00BFMXXD54", "IE00BK5BQV03", "IE00BK5BR733" ], "budget_exhausted": false, "auto_merge": false } }

These are saved results. Switching examples runs no model or external service.

Limits of this experiment

  • Tiny deliberately confusing public snapshot, authored names and intentions; no population or production accuracy.
  • No image encoder, FAISS, trained pair matcher, feed parser or entity merge is implemented.
  • Metadata compatibility is not proof of the fund family. Names outside the catalogue can still retrieve plausible neighbours.
  • Vanguard hedging is undocumented, and listing currency is not share-class currency.
Inspect the recorded provenance
{
  "calls_sha256": "f4269df7b588f1e22e97297b633c18a6ac27be3e4a67426ac8276ab35cf1a0d7",
  "sources_sha256": "16bef51530bf4243795aec4c6bd14191915a2b8a1c24ebfee38ee20d46a0653b",
  "catalog_sha256": "83e1405eb3ca991da41e01ded1ee78dc5f4be44fb1bfef83ee34d2a18942d5ee",
  "queries_sha256": "134481bf5d71a9fe9a00bc05565f0c76c234199f59ebbcbd46441588da5f648b",
  "reference_sha256": "cfebe1d88ffa9a2f59c8d4b73667dfc88e2b4c3366ec4e8a824673f70daf7d00",
  "code_sha256": {
    "core.py": "3441f0b86afcce0263eb905e9b298a005e88191ddafeac79b5a8f5b975f13ae9",
    "run.py": "804eb45b9d25168d8eb8a7fee91286bab03eee1c35edb2d2bf601874059adb94"
  },
  "recorded_at": "2026-12-01T15:32:27.268122+00:00",
  "runtime": {
    "version": "0.40.18"
  },
  "model": {
    "name": "nomic-embed-text:v1.5",
    "model": "nomic-embed-text:v1.5",
    "modified_at": "2026-11-26T12:07:53.568872576+01:00",
    "size": 274302450,
    "digest": "0a109f422b47e3a30ba2b10eca18548e944e8a23073ee3f3e947efcf3c45e59f",
    "details": {
      "parent_model": "",
      "format": "gguf",
      "family": "nomic-bert",
      "families": [
        "nomic-bert"
      ],
      "parameter_size": "137M",
      "quantization_level": "F16",
      "context_length": 2048,
      "embedding_length": 768,
      "runner": "ggml"
    },
    "capabilities": [
      "embedding"
    ]
  },
  "actual_embedding_calls": 2,
  "new_embedded_texts": 27
}

From engineering-lab/coupang-matching, run python3 run.py and python3 verify.py. Both are offline standard-library commands. The thirteen-file allowlist includes the copied public metadata, authored inputs and references, original request/response bodies, actual vectors and deterministic results. The website displays that recording; it does not contact an issuer or merge an instrument.