vietnamese-embedding
is the Embedding Model for Vietnamese language. This model is a specialized sentence-embedding trained specifically for the Vietnamese language, leveraging the robust capabilities of PhoBERT, a pre-trained language model based on the RoBERTa architecture.
The model utilizes PhoBERT to encode Vietnamese sentences into a 768-dimensional vector space, facilitating a wide range of applications from semantic search to text clustering. The embeddings capture the nuanced meanings of Vietnamese sentences, reflecting both the lexical and contextual layers of the language.
The model underwent a rigorous four-stage training and fine-tuning process, each tailored to enhance its ability to generate precise and contextually relevant sentence embeddings for the Vietnamese language. Below is an outline of these stages:
Method: Trained using the
SimCSE approach
which employs a supervised contrastive learning framework. The model was optimized using
Triplet Loss
to effectively learn from high-quality annotated sentence pairs.
Method: Continued fine-tuning using Multi-Negative Ranking Loss. This stage focused on improving the model's ability to discern and rank nuanced differences in sentence semantics.
Stage 3: Continued Fine-tuning for Semantic Textual Similarity on STS Benchmark
Method: Fine-tuning specifically for the semantic textual similarity benchmark using Siamese BERT-Networks configured with the 'sentence-transformers' library. This stage honed the model's precision in capturing semantic similarity across various types of Vietnamese texts.
Method: Employed an advanced strategy using
Augmented SBERT
with Pair Sampling Strategies, integrating both Cross-Encoder and Bi-Encoder models. This stage further refined the embeddings by enriching the training data dynamically, enhancing the model's robustness and accuracy in understanding and processing complex Vietnamese language constructs.
from sentence_transformers import SentenceTransformer
from pyvi.ViTokenizer import tokenize
sentences = ["Hà Nội là thủ đô của Việt Nam", "Đà Nẵng là thành phố du lịch"]
tokenizer_sent = [tokenize(sent) for sent in sentences]
model = SentenceTransformer('dangvantuan/vietnamese-embedding')
embeddings = model.encode(tokenizer_sent)
print(embeddings)
@article{reimers2019sentence,
title={Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks},
author={Nils Reimers, Iryna Gurevych},
journal={https://arxiv.org/abs/1908.10084},
year={2019}
}
@article{martin2020camembert,
title={CamemBERT: a Tasty French Language Mode},
author={Martin, Louis and Muller, Benjamin and Su{\'a}rez, Pedro Javier Ortiz and Dupont, Yoann and Romary, Laurent and de la Clergerie, {\'E}ric Villemonte and Seddah, Djam{\'e} and Sagot, Beno{\^\i}t},
journal={Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics},
year={2020}
}
@article{thakur2020augmented,
title={Augmented SBERT: Data Augmentation Method for Improving Bi-Encoders for Pairwise Sentence Scoring Tasks},
author={Thakur, Nandan and Reimers, Nils and Daxenberger, Johannes and Gurevych, Iryna},
journal={arXiv e-prints},
pages={arXiv--2010},
year={2020}
Runs of dangvantuan vietnamese-embedding on huggingface.co
4.9K
Total runs
-167
24-hour runs
-281
3-day runs
-362
7-day runs
-6.2K
30-day runs
More Information About vietnamese-embedding huggingface.co Model
vietnamese-embedding huggingface.co is an AI model on huggingface.co that provides vietnamese-embedding's model effect (), which can be used instantly with this dangvantuan vietnamese-embedding model. huggingface.co supports a free trial of the vietnamese-embedding model, and also provides paid use of the vietnamese-embedding. Support call vietnamese-embedding model through api, including Node.js, Python, http.
vietnamese-embedding huggingface.co is an online trial and call api platform, which integrates vietnamese-embedding's modeling effects, including api services, and provides a free online trial of vietnamese-embedding, you can try vietnamese-embedding online for free by clicking the link below.
dangvantuan vietnamese-embedding online free url in huggingface.co:
vietnamese-embedding is an open source model from GitHub that offers a free installation service, and any user can find vietnamese-embedding on GitHub to install. At the same time, huggingface.co provides the effect of vietnamese-embedding install, users can directly use vietnamese-embedding installed effect in huggingface.co for debugging and trial. It also supports api for free installation.
vietnamese-embedding install url in huggingface.co: