Instructions to use yorko/scibert_scivocab_uncased_long_4096 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use yorko/scibert_scivocab_uncased_long_4096 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("fill-mask", model="yorko/scibert_scivocab_uncased_long_4096")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForMaskedLM tokenizer = AutoTokenizer.from_pretrained("yorko/scibert_scivocab_uncased_long_4096") model = AutoModelForMaskedLM.from_pretrained("yorko/scibert_scivocab_uncased_long_4096", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Commit History
-
Update README.md
16c1dc8 -
Adding `safetensors` variant of this model (#2)
- Adding `safetensors` variant of this model (e6d007647e5e1bbdcaf009f30c488443ff04bf93) Co-authored-by: Safetensors convertbot <SFconvertbot@users.noreply.huggingface.co>60a17d5
-
replace chkpt; update Readme
51c6fab -
initial commit
504460c -
Create README.md
# SciBERT Longformer This is a Lonformer version of the [SciBERT uncased](https://huggingface.co/allenai/scibert_scivocab_uncased) model by Allen AI. It is slower than SciBERT (~2.5x in my benchmarks) but can allow for 8x wider `max_seq_length` (4096 vs. 512) which is handy in case of working with long texts, e.g. scientific full texts. The conversion to Longformer was performed with a [tutorial](https://github.com/allenai/longformer/blob/master/scripts/convert_model_to_long.ipynb) by Allen AI: see a [Google Colab Notebook](https://colab.research.google.com/drive/1NPTnMkeAYOF2MWH3_uJYesuxxdOzxrFn?usp=sharing) by [Yury](https://yorko.github.io/) which closely follows the tutorial. Note: - no additional MLM pretraining of the Longformer was performed, the [collab notebook](https://colab.research.google.com/drive/1NPTnMkeAYOF2MWH3_uJYesuxxdOzxrFn?usp=sharing) stops at step 3, and step 4 is not done. The model can be improved with this additional MLM pretraining, better to d…8209bca -
initial commit
d016e48