CoolFace
Modelpublic

alrolo3/splade-v3-spanish-vllm

sourceHugging Facecc-by-nc-sa-4.0updated 2mo agoView on Hugging Face
2likes123downloads
Model Card

SPLADE-v3 Spanish

SPLADE-v3 Spanish is a Spanish-adapted sparse encoder based on `naver/splade-v3`. It produces 30,522-dimensional sparse vectors over the BERT WordPiece vocabulary for lexical-semantic retrieval with dot-product scoring.

The model is intended for retrieval systems that need SPLADE-style sparse representations with stronger Spanish coverage while preserving competitive English retrieval behavior.

Model Details

  • —Model type: sentence_transformers.SparseEncoder
  • —Base model: naver/splade-v3
  • —Architecture: BertForMaskedLM with SpladePooling
  • —Pooling: SPLADE max pooling with ReLU activation
  • —Embedding dimension: 30,522
  • —Similarity function: dot product
  • —Serving sequence length: up to 512 tokens
  • —Training sequence length: 384 tokens
  • —Languages: Spanish and English
  • —Weights: model.safetensors
  • —License: cc-by-nc-sa-4.0

Intended Use

Use this model to encode queries and documents into sparse vectors for search, ranking, and retrieval-augmented generation pipelines. It is especially suited for Spanish or bilingual Spanish-English retrieval where sparse lexical matching and semantic term expansion are useful.

This model is not a generative language model and should not be used for text generation. It should be evaluated in the target retrieval stack before production deployment, especially when domain vocabulary, latency, or index size constraints are important.

Usage

python
from sentence_transformers import SparseEncoder

model = SparseEncoder("alrolo3/splade-v3-spanish-vllm")

queries = ["Que es el Camembert de Normandia?"]
documents = [
    "Camembert de Normandia is a soft cow's milk cheese from Normandy.",
    "The Japanese writing system uses kanji, hiragana, and katakana.",
]

query_embeddings = model.encode_query(queries, convert_to_sparse_tensor=True)
doc_embeddings = model.encode_document(documents, convert_to_sparse_tensor=True)

scores = model.similarity(query_embeddings, doc_embeddings)
print(scores)

For retrieval, encode queries with encode_query, encode corpus passages with encode_document, and score them with sparse dot product.

Training

The model was adapted from naver/splade-v3 using contrastive training on Spanish retrieval data.

Training datasets:

  • —hotchpotch/mmarco-hard-negatives-reranker-filtered
  • —Config: spanish-hard-negatives-7
  • —Split: train
  • —sentence-transformers/miracl
  • —Config: es-triplet-100
  • —Split: train

Training setup:

  • —Stage: contrastive adaptation
  • —Max steps: 500
  • —Per-device train batch size: 64
  • —Gradient accumulation steps: 4
  • —Learning rate: 2.5e-7
  • —Warmup ratio: 0.03
  • —Weight decay: 0.01
  • —Query regularizer weight: 5e-5
  • —Document regularizer weight: 3e-5
  • —Batch sampler: no duplicates
  • —Multi-dataset sampler: round robin
  • —Seed: 44

The repository includes data_args.json, training_args.json, and model_args.json with the exported training metadata.

Evaluation

Exact sparse retrieval benchmark:

ModelMS MARCO dev MRR@10BEIR-13 avg nDCG@10
splade-v3-spanish0.40010.5206
naver/splade-v30.40260.5158

The benchmark used full corpora, top_k=10, max_seq_length=256, and no document or query caps.

Triplet evaluation on MIRACL hard-negative examples:

ModelDatasetAccuracy@1MRR
splade-v3-spanishMIRACL English0.73690.8370
naver/splade-v3MIRACL English0.72480.8296
splade-v3-spanishMIRACL Spanish0.72380.8286
BAAI/bge-m3MIRACL Spanish0.72270.8264

Repository Contents

  • —model.safetensors: model weights
  • —config.json: transformer configuration
  • —modules.json: Sentence Transformers module layout
  • —1_SpladePooling/config.json: SPLADE pooling configuration
  • —tokenizer.json, tokenizer_config.json, special_tokens_map.json, vocab.txt: tokenizer files
  • —data_args.json, training_args.json, model_args.json: exported training metadata

Limitations

This model was optimized for sparse retrieval, especially Spanish retrieval. Results can vary across domains, languages, tokenization patterns, and retrieval infrastructure. Evaluate it with the same indexing, scoring, and candidate generation setup used in your application.

The model inherits the non-commercial ShareAlike license from the base model. Downstream use must respect cc-by-nc-sa-4.0.