This model is a 42.73% smaller version of intfloat/multilingual-e5-large, optimized for Nepali through vocabulary reduction using the trimming method.
The original model has a vocabulary of 250,037 tokens. The trimmed model retains 16,384 tokens, significantly reducing model size and memory requirements.
The trimmed model is expected to perform similarly to the original model for the selected language domain, particularly Nepali. However, performance may degrade for other languages because tokens that are less common in the selected languages were removed from the vocabulary.
Model Statistics
Metric
Original
Trimmed
Reduction
Vocabulary size
250,037 tokens
16,384 tokens
93.44%
Model parameters
559,890,432
320,665,600
42.73%
Source Model
The full-precision weights used for these GGUF conversions come from:
This repository contains the following GGUF variants:
File
Quantization
Description
multilingual-e5-large-nep-fp16.gguf
FP16
Full-precision GGUF conversion
multilingual-e5-large-nep-Q8_0.gguf
Q8_0
8-bit quantization
multilingual-e5-large-nep-Q6_K.gguf
Q6_K
6-bit K-quantization
multilingual-e5-large-nep-Q4_K_M.gguf
Q4_K_M
4-bit K-quantization
The FP16 GGUF is converted from the Hugging Face model weights. The quantized versions are derived from the FP16 GGUF using llama.cpp.
Intended Use
This model is intended primarily for:
Nepali semantic search
Nepali document retrieval
RAG systems
Multilingual embedding experiments
Vector similarity search
Local embedding inference
Because vocabulary trimming was targeted toward Nepali, results for languages outside the selected language domain may be lower than the original multilingual-e5-large.
Usage
Hugging Face Sentence Transformers
For the original Hugging Face model:
python
1from sentence_transformers import SentenceTransformer
23model = SentenceTransformer(4"alphaedge-ai/multilingual-e5-large-nep-16384"5)67query ="My query in Nepali"89documents =[10"Chunk in Nepali",11"Chunk in Nepali",12"Chunk in Nepali",13]1415query_embeddings = model.encode_query(query)16document_embeddings = model.encode_document(documents)1718print(query_embeddings.shape)19print(document_embeddings.shape)2021similarities = model.similarity(22 query_embeddings,23 document_embeddings
24)2526print(similarities)
GGUF
These files are intended for GGUF-compatible inference engines such as llama.cpp.
1Hugging Face Model
2 |
3 v
4XLM-RoBERTa / E5
5 |
6 v
7GGUF FP16
8 |
9 +----> Q8_0
10 |
11 +----> Q6_K
12 |
13 +----> Q4_K_M
Important Note
The GGUF conversion requires tokenizer compatibility with the XLM-RoBERTa tokenizer used by the source model.
The source tokenizer does not contain precompiled_charsmap in its tokenizer.json. The llama.cpp conversion code was therefore adjusted to handle the missing field during conversion.
This repository contains the resulting GGUF files and should not be considered a replacement for the original Hugging Face model.
Credits
Multilingual E5
The underlying embedding architecture is based on Multilingual E5.
bibtex
1@article{wang2024multilingual,
2 title={Multilingual E5 Text Embeddings: A Technical Report},
3 author={Wang, Liang and Yang, Nan and Huang, Xiaolong and Yang, Linjun and Majumder, Rangan and Wei, Furu},
4 journal={arXiv preprint arXiv:2402.05672},
5 year={2024}
6}
Trimming Method
The vocabulary trimming approach is described in:
bibtex
1@misc{hf_blogpost_trimming,
2 title={Introduction to Trimming},
3 author={Loïck BOURDOIS and Tom AARSEN and Bram VANROY and Christopher AKIKI and Woojun JUNG and Manuel ROMERO and Prithiv SAKTHI},
4 year={2026},
5 url={https://huggingface.co/blog/lbourdois/introduction-to-trimming},
6}