Exact MeSH Linking: Qwen Embedding and Reranking

Wide embedding retrieval and deep pairwise reranking produce one exact MeSH identifier.

RI.MV.007·Maintained reference·Revised 2026-08-06

Exact MeSH linking splits the work into a fast wide pass and a slow careful pass. Qwen, a family of open language models, first scores the whole candidate set quickly. A Qwen reranker then reads only the strongest query-candidate pairs in detail. A gradient-boosted model, which blends many signals into one score, combines those model scores with plain rule-based evidence.

embeddingrerankinggradient-boosted modelexact identifier

Inference path: Wide retrieval before deep verification

query → tokenizer → 500 frequency candidates → Qwen embeddings → ranking model top 20 → Qwen reranker → exact MeSH identifier
StageInputOutputJob
TokenizerRaw queryTokensPreserve phrases and identifiers.
RetrieverTokens500 IDsMaximize recall.
EmbeddingQuery and texts500 similaritiesMeasure meaning efficiently.
Ranking modelAll featuresTop 20Combine evidence.
RerankerTwenty pairsFinal IDRead pairs jointly.

Model roles: Embedding and reranking are different jobs

500 retrieved and embedded
20 pairs reranked
1 exact identifier returned

One pair: Similarity and correctness are separate questions

The query supplies clinical, financial, or regulatory language. Candidate text combines the preferred term, entry terms, scope note, and hierarchy path. Embedding asks whether both texts occupy similar semantic space. Reranking asks whether this exact pair is correct.

Training: Same records with different examples and losses

ExampleConstructionPurpose
Positive pairRecord text plus an assigned descriptorLearn exact label associations
Hard negativeHigh frequency candidate not assigned to the recordSeparate plausible errors
Source groupPubMed and ClinicalTrials retained separatelyExpose source-specific evaluation

Combining evidence: Rule-based and semantic signals meet before verification

  • Lexical inputs include overlap, phrases, acronyms, and frequency rank.
  • Corpus inputs include source prevalence and support.
  • Structural inputs include hierarchy coordinates and branch evidence.
  • Semantic inputs include base, fine-tuned, and source-aware similarities.
  • The reranker score can become a final-stage feature where required.