COGNANO/VHHCorpus-2M
Viewer • Updated • 2.04M • 77 • 1
How to use COGNANO/VHHBERT with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("fill-mask", model="COGNANO/VHHBERT") # Load model directly
from transformers import AutoTokenizer, AutoModelForMaskedLM
tokenizer = AutoTokenizer.from_pretrained("COGNANO/VHHBERT")
model = AutoModelForMaskedLM.from_pretrained("COGNANO/VHHBERT")# Load model directly
from transformers import AutoTokenizer, AutoModelForMaskedLM
tokenizer = AutoTokenizer.from_pretrained("COGNANO/VHHBERT")
model = AutoModelForMaskedLM.from_pretrained("COGNANO/VHHBERT")VHHBERT is a RoBERTa-based model pre-trained on two million VHH sequences in VHHCorpus-2M. VHHBERT has the same model parameters as RoBERTaBASE, except that it used positional embeddings with a length of 185 to cover the maximum sequence length of 179 in VHHCorpus-2M. Further details on VHHBERT are described in our paper "A SARS-CoV-2 Interaction Dataset and VHH Sequence Corpus for Antibody Language Models.”
The model and tokenizer can be loaded using the transformers library.
from transformers import BertTokenizer, RobertaModel
tokenizer = BertTokenizer.from_pretrained("COGNANO/VHHBERT")
model = RobertaModel.from_pretrained("COGNANO/VHHBERT")
If you use VHHBERT in your research, please cite the following paper.
@inproceedings{tsuruta2024sars,
title={A {SARS}-{C}o{V}-2 Interaction Dataset and {VHH} Sequence Corpus for Antibody Language Models},
author={Hirofumi Tsuruta and Hiroyuki Yamazaki and Ryota Maeda and Ryotaro Tamura and Akihiro Imura},
booktitle={Advances in Neural Information Processing Systems 37},
year={2024}
}
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("fill-mask", model="COGNANO/VHHBERT")