Pankaj8922 commited on
Commit
05b0237
·
verified ·
1 Parent(s): 9a03237

Fine-tune bert-medium on high-quality NLI subset

Browse files
Files changed (1) hide show
  1. final/README.md +70 -0
final/README.md ADDED
@@ -0,0 +1,70 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ language: en
3
+ license: apache-2.0
4
+ tags:
5
+ - text-classification
6
+ - zero-shot-classification
7
+ - nli
8
+ datasets:
9
+ - Pankaj8922/nli-high-quality-balanced
10
+ base_model: prajjwal1/bert-medium
11
+ metrics:
12
+ - accuracy
13
+ - f1
14
+ model-index:
15
+ - name: bert-medium-nli
16
+ results:
17
+ - task:
18
+ type: text-classification
19
+ name: Natural Language Inference
20
+ dataset:
21
+ name: Pankaj8922/nli-high-quality-balanced
22
+ type: Pankaj8922/nli-high-quality-balanced
23
+ metrics:
24
+ - type: accuracy
25
+ value: 0.8373
26
+ name: Test Accuracy
27
+ - type: f1
28
+ value: 0.8372
29
+ name: Test F1 (macro)
30
+ ---
31
+
32
+ # bert-medium-nli
33
+
34
+ Fine-tuned [`prajjwal1/bert-medium`](https://huggingface.co/prajjwal1/bert-medium) for natural language
35
+ inference (entailment / neutral / contradiction), intended for use as a zero-shot
36
+ text classification model via the entailment trick (hypothesis = "This text is
37
+ about {label}.").
38
+
39
+ Trained on [`Pankaj8922/nli-high-quality-balanced`](https://huggingface.co/datasets/Pankaj8922/nli-high-quality-balanced), a
40
+ combined and filtered subset of MNLI, SNLI, FEVER-NLI, and ANLI:
41
+ annotator-agreement filtered, deduplicated, teacher-confidence filtered,
42
+ hypothesis-only artifact filtered, and class-balanced.
43
+
44
+ ## Results
45
+
46
+ | Split | Accuracy | F1 (macro) | Precision (macro) | Recall (macro) |
47
+ |---|---|---|---|---|
48
+ | Validation | 0.8389 | 0.8389 | 0.8389 | 0.8389 |
49
+ | Test | 0.8373 | 0.8372 | 0.8372 | 0.8373 |
50
+
51
+ ## Training details
52
+
53
+ - Base model: `prajjwal1/bert-medium`
54
+ - Epochs: 3
55
+ - Batch size: 64 (train), 128 (eval)
56
+ - Learning rate: 5e-05
57
+ - Max sequence length: 256
58
+
59
+ ## Labels
60
+
61
+ - 0: entailment
62
+ - 1: neutral
63
+ - 2: contradiction
64
+
65
+ ## Intended use / limitations
66
+
67
+ This is a small (~41M parameter) model, so its ceiling on zero-shot performance
68
+ against novel, unseen label sets is lower than larger NLI-tuned checkpoints
69
+ (e.g. DeBERTa-v3-base or -large variants). Best suited for fast inference or
70
+ resource-constrained settings rather than maximum accuracy.