Fill-Mask
Transformers
Safetensors
English
ultrabert
encoder
masked-language-modeling
long-context
custom_code
Instructions to use dmis-lab/UltraBERT-150M with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use dmis-lab/UltraBERT-150M with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("fill-mask", model="dmis-lab/UltraBERT-150M", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForMaskedLM tokenizer = AutoTokenizer.from_pretrained("dmis-lab/UltraBERT-150M", trust_remote_code=True) model = AutoModelForMaskedLM.from_pretrained("dmis-lab/UltraBERT-150M", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
Update README.md
Browse files
README.md
CHANGED
|
@@ -87,8 +87,7 @@ model = AutoModelForSequenceClassification.from_pretrained(
|
|
| 87 |
We recommend starting from the settings used in the paper. For classification: AdamW (β1 0.9, β2 0.98, ε 1e-6), weight decay 0.1, a linear schedule with 5% warm-up, and a learning rate swept over {5e-6,8e-6,1e-5,3e-5,5e-5,8e-5}. For dense retrieval: mean pooling with a contrastive loss and a wider learning-rate sweep of {1e-5,3e-5,5e-5,8e-5,1e-4,2e-4,3e-4,5e-4,8e-4,1e-3}.
|
| 88 |
|
| 89 |
> [!WARNING]
|
| 90 |
-
> 💡 **Note**: UltraBERT consistently prefers lower learning rates than other encoders, by up to 10x. For example, the best learning rates for UltraBERT-150M and UltraBERT-380M are
|
| 91 |
-
|
| 92 |
|
| 93 |
## 📊 Evaluation
|
| 94 |
|
|
|
|
| 87 |
We recommend starting from the settings used in the paper. For classification: AdamW (β1 0.9, β2 0.98, ε 1e-6), weight decay 0.1, a linear schedule with 5% warm-up, and a learning rate swept over {5e-6,8e-6,1e-5,3e-5,5e-5,8e-5}. For dense retrieval: mean pooling with a contrastive loss and a wider learning-rate sweep of {1e-5,3e-5,5e-5,8e-5,1e-4,2e-4,3e-4,5e-4,8e-4,1e-3}.
|
| 88 |
|
| 89 |
> [!WARNING]
|
| 90 |
+
> 💡 **Note**: UltraBERT consistently prefers lower learning rates than other encoders, by up to 10x. For example, on MNLI the best learning rates for UltraBERT-150M and UltraBERT-380M are 1e-5 and 8e-6, respectively, whereas other encoders typically prefer 3e-5 to 5e-5. For dense retrieval, they are 5e-5 and 3e-5, whereas other encoders typically prefer 3e-4 to 5e-4.
|
|
|
|
| 91 |
|
| 92 |
## 📊 Evaluation
|
| 93 |
|