Efficient Few-Shot Learning Without Prompts
Paper
•
2209.11055
•
Published
•
4
This is a SetFit model that can be used for Text Classification. This SetFit model uses jhu-clsp/mmBERT-base as the Sentence Transformer embedding model. A LogisticRegression instance is used for classification.
The model has been trained using an efficient few-shot learning technique that involves:
| Label | Accuracy |
|---|---|
| all | 0.9992 |
First install the SetFit library:
pip install setfit
Then you can load this model and run inference.
from setfit import SetFitModel
# Download from the 🤗 Hub
model = SetFitModel.from_pretrained("johnpaulbin/toxicity-setfit-4-large")
# Run inference
preds = model("add me for gifts")
| Training set | Min | Median | Max |
|---|---|---|---|
| Word count | 1 | 4.5954 | 81 |
| Label | Training Sample Count |
|---|---|
| not toxic | 8589 |
| toxic | 4455 |
| Epoch | Step | Training Loss | Validation Loss |
|---|---|---|---|
| 0.0006 | 1 | 0.3232 | - |
| 0.0307 | 50 | 0.2699 | - |
| 0.0613 | 100 | 0.2104 | - |
| 0.0920 | 150 | 0.113 | - |
| 0.1226 | 200 | 0.0829 | - |
| 0.1533 | 250 | 0.0521 | - |
| 0.1839 | 300 | 0.0439 | - |
| 0.2146 | 350 | 0.0314 | - |
| 0.2452 | 400 | 0.0292 | - |
| 0.2759 | 450 | 0.0215 | - |
| 0.3066 | 500 | 0.018 | - |
| 0.3372 | 550 | 0.0172 | - |
| 0.3679 | 600 | 0.0119 | - |
| 0.3985 | 650 | 0.0113 | - |
| 0.4292 | 700 | 0.0082 | - |
| 0.4598 | 750 | 0.0098 | - |
| 0.4905 | 800 | 0.0075 | - |
| 0.5212 | 850 | 0.0073 | - |
| 0.5518 | 900 | 0.0061 | - |
| 0.5825 | 950 | 0.0052 | - |
| 0.6131 | 1000 | 0.0044 | - |
| 0.6438 | 1050 | 0.0058 | - |
| 0.6744 | 1100 | 0.0055 | - |
| 0.7051 | 1150 | 0.0054 | - |
| 0.7357 | 1200 | 0.0041 | - |
| 0.7664 | 1250 | 0.0049 | - |
| 0.7971 | 1300 | 0.0057 | - |
| 0.8277 | 1350 | 0.004 | - |
| 0.8584 | 1400 | 0.004 | - |
| 0.8890 | 1450 | 0.0039 | - |
| 0.9197 | 1500 | 0.0036 | - |
| 0.9503 | 1550 | 0.0038 | - |
| 0.9810 | 1600 | 0.0037 | - |
| 1.0 | 1631 | - | 0.0021 |
@article{https://doi.org/10.48550/arxiv.2209.11055,
doi = {10.48550/ARXIV.2209.11055},
url = {https://arxiv.org/abs/2209.11055},
author = {Tunstall, Lewis and Reimers, Nils and Jo, Unso Eun Seo and Bates, Luke and Korat, Daniel and Wasserblat, Moshe and Pereg, Oren},
keywords = {Computation and Language (cs.CL), FOS: Computer and information sciences, FOS: Computer and information sciences},
title = {Efficient Few-Shot Learning Without Prompts},
publisher = {arXiv},
year = {2022},
copyright = {Creative Commons Attribution 4.0 International}
}
Base model
jhu-clsp/mmBERT-base