Views
No views yet
tasksource/ModernBERT-large-nli
zero-shot classification model. Then I trained it with a batch size of 64 using the sentence-transformers AllNLI
dataset.large version, I froze all layers initialized from the tasksource model up to 19, and fine tuned only the
remaining layers with a new classification head.| Model | finecat | mnli | mnli_mismatched | snli | anli_r1 | anli_r2 | anli_r3 | wanli | lingnli | Throughput (samples/s) | Peak GPU Mem (MB) |
|---|---|---|---|---|---|---|---|---|---|---|---|
MoritzLaurer/DeBERTa-v3-large-mnli-fever-anli-ling-wanli | 0.8233 | 0.9121 | 0.9079 | 0.8898 | 0.7960 | 0.6830 | 0.6400 | 0.7700 | 0.8821 | 454.96 | 3250.44 |
dleemiller/finecat-nli-l | 0.8227 | 0.9152 | 0.9265 | 0.9162 | 0.7480 | 0.5700 | 0.5433 | 0.7706 | 0.8742 | 539.04 | 1838.06 |
tasksource/ModernBERT-large-nli | 0.7959 | 0.8983 | 0.9229 | 0.9188 | 0.7260 | 0.5110 | 0.4925 | 0.6978 | 0.8504 | 543.44 | 1838.06 |
dleemiller/ModernCE-large-nli | 0.7811 | 0.9088 | 0.9205 | 0.9273 | 0.6630 | 0.4860 | 0.4408 | 0.6576 | 0.8566 | 540.74 | 1838.06 |
cross-encoder/nli-deberta-v3-large | 0.7618 | 0.9019 | 0.9049 | 0.9220 | 0.5300 | 0.4170 | 0.3758 | 0.6548 | 0.8466 | 448.35 | 3250.44 |
sentence-transformers library:1from sentence_transformers import CrossEncoder
2
3# Load ModernCE model
4model = CrossEncoder("dleemiller/ModernCE-large-nli")
5
6scores = model.predict([
7 ('A man is eating pizza', 'A man eats something'),
8 ('A black race car starts up in front of a crowd of people.', 'A man is driving down a lonely road.')
9])
10
11# Convert scores to labels
12label_mapping = ['contradiction', 'entailment', 'neutral']
13labels = [label_mapping[score_max] for score_max in scores.argmax(axis=1)]
14# ['entailment', 'contradiction']tasksource/ModernBERT-large weights.sentence-transformers - AllNLI.tsv.gz1@misc{moderncenli2025,
2 author = {Miller, D. Lee},
3 title = {ModernCE NLI: An NLI cross encoder model},
4 year = {2025},
5 publisher = {Hugging Face Hub},
6 url = {https://huggingface.co/dleemiller/ModernCE-large-nli},
7}