Downloads · 30 days
33
55% of all-time downloads
hsilvosa/bne-biencoder-entity-linker
bne-biencoder-entity-linker is a sentence similarity model from hsilvosa. Use it when you need a score for how close two texts are. It is set up for sentence-transformers. The card lists the license as cc-by-4.0.
This model is a high-performance Spanish Bi-Encoder fine-tuned on the Biblioteca Nacional de España (BNE) Linked Data dataset (260 million RDF triples). It maps unstructured text mentions of historical authors, litera…
Downloads · 30 days
33
55% of all-time downloads
All-time downloads
60
Public
Parameters
110M
439 MB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors439 MB · 100%
From the Hugging Face model README
This model is a high-performance Spanish Bi-Encoder fine-tuned on the Biblioteca Nacional de España (BNE) Linked Data dataset (260 million RDF triples). It maps unstructured text mentions of historical authors, literary works, and library subjects to 768-dimensional normalized dense vectors for vector search and entity disambiguation to stable BNE URIs.
| Metric | Score | Description |
|---|---|---|
| Recall@1 | 0.9920 | Top-1 disambiguation accuracy to target BNE URI |
| Recall@5 | 0.9970 | Top-5 candidate retrieval coverage |
| Recall@10 | 0.9990 | Top-10 candidate retrieval coverage |
| MRR | 0.9943 | Mean Reciprocal Rank across entity retrieval |
| NDCG@5 | 0.9948 | Normalized Discounted Cumulative Gain at rank 5 |
dccuchile/bert-base-spanish-wwm-cased (BETO)hsilvosa/bne-linked-data (1.35M owl:sameAs authority links, BNE authority titles, and bibliographic metadata)MultipleNegativesRankingLoss (MNRL)from sentence_transformers import SentenceTransformer
from sklearn.metrics.pairwise import cosine_similarity
# Load model directly from Hugging Face Hub or local path
model = SentenceTransformer("hsilvosa/bne-biencoder-entity-linker")
# Encode queries and candidate entities
query_embeddings = model.encode(["Miguel de Cervantes Saavedra", "Cantar de mio Cid"])
entity_embeddings = model.encode(["Cervantes Saavedra, Miguel de (1547-1616)", "Cantar de mio Cid. Poema épico"])
similarities = cosine_similarity(query_embeddings, entity_embeddings)
print("Similarity scores:", similarities)
This model is designed for entity linking, disambiguation, and semantic retrieval over Spanish historical, literary, and bibliographic resources.