metadata
tags:
- setfit
- sentence-transformers
- text-classification
- generated_from_setfit_trainer
widget:
- text: 침대안전가드 침대 안전바 낙상방지 손잡이 난간 난간대 노인 복지용구 장애인 임신부 선물 가구/인테리어>아동/주니어가구>소품가구
- text: 침대 안전 가드 면 보호 랩 물린 가장자리 아기 레일 범퍼 케어 베이비 제품범퍼 울타리 가구/인테리어>아동/주니어가구>소품가구
- text: 일하 안전 영아 교구장 장난감정리함 선반 유아책장 수납함 가구/인테리어>아동/주니어가구>책꽂이
- text: 오운 어린이 침대 프레임 SS 가구/인테리어>아동/주니어가구>침대>일반침대
- text: 시몬스 로피 N32 하드 침대 SS 가구/인테리어>아동/주니어가구>침대>일반침대
metrics:
- accuracy
pipeline_tag: text-classification
library_name: setfit
inference: true
base_model: mini1013/master_domain
model-index:
- name: SetFit with mini1013/master_domain
results:
- task:
type: text-classification
name: Text Classification
dataset:
name: Unknown
type: unknown
split: test
metrics:
- type: accuracy
value: 1
name: Accuracy
SetFit with mini1013/master_domain
This is a SetFit model that can be used for Text Classification. This SetFit model uses mini1013/master_domain 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:
- Fine-tuning a Sentence Transformer with contrastive learning.
- Training a classification head with features from the fine-tuned Sentence Transformer.
Model Details
Model Description
- Model Type: SetFit
- Sentence Transformer body: mini1013/master_domain
- Classification head: a LogisticRegression instance
- Maximum Sequence Length: 512 tokens
- Number of Classes: 14 classes
Model Sources
- Repository: SetFit on GitHub
- Paper: Efficient Few-Shot Learning Without Prompts
- Blogpost: SetFit: Efficient Few-Shot Learning Without Prompts
Model Labels
Label | Examples |
---|---|
5.0 |
|
13.0 |
|
1.0 |
|
11.0 |
|
2.0 |
|
3.0 |
|
6.0 |
|
7.0 |
|
0.0 |
|
10.0 |
|
8.0 |
|
4.0 |
|
12.0 |
|
9.0 |
|
Evaluation
Metrics
Label | Accuracy |
---|---|
all | 1.0 |
Uses
Direct Use for Inference
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("mini1013/master_cate_fi7")
# Run inference
preds = model("오운 어린이 침대 프레임 SS 가구/인테리어>아동/주니어가구>침대>일반침대")
Training Details
Training Set Metrics
Training set | Min | Median | Max |
---|---|---|---|
Word count | 3 | 8.3744 | 18 |
Label | Training Sample Count |
---|---|
0.0 | 65 |
1.0 | 70 |
2.0 | 70 |
3.0 | 70 |
4.0 | 37 |
5.0 | 70 |
6.0 | 21 |
7.0 | 70 |
8.0 | 70 |
9.0 | 70 |
10.0 | 70 |
11.0 | 70 |
12.0 | 70 |
13.0 | 69 |
Training Hyperparameters
- batch_size: (256, 256)
- num_epochs: (30, 30)
- max_steps: -1
- sampling_strategy: oversampling
- num_iterations: 50
- body_learning_rate: (2e-05, 1e-05)
- head_learning_rate: 0.01
- loss: CosineSimilarityLoss
- distance_metric: cosine_distance
- margin: 0.25
- end_to_end: False
- use_amp: False
- warmup_proportion: 0.1
- l2_weight: 0.01
- seed: 42
- eval_max_steps: -1
- load_best_model_at_end: False
Training Results
Epoch | Step | Training Loss | Validation Loss |
---|---|---|---|
0.0057 | 1 | 0.5123 | - |
0.2857 | 50 | 0.5012 | - |
0.5714 | 100 | 0.3699 | - |
0.8571 | 150 | 0.1028 | - |
1.1429 | 200 | 0.0304 | - |
1.4286 | 250 | 0.0147 | - |
1.7143 | 300 | 0.012 | - |
2.0 | 350 | 0.009 | - |
2.2857 | 400 | 0.0074 | - |
2.5714 | 450 | 0.0033 | - |
2.8571 | 500 | 0.004 | - |
3.1429 | 550 | 0.0036 | - |
3.4286 | 600 | 0.0036 | - |
3.7143 | 650 | 0.0036 | - |
4.0 | 700 | 0.0036 | - |
4.2857 | 750 | 0.0027 | - |
4.5714 | 800 | 0.0034 | - |
4.8571 | 850 | 0.004 | - |
5.1429 | 900 | 0.0016 | - |
5.4286 | 950 | 0.0001 | - |
5.7143 | 1000 | 0.0 | - |
6.0 | 1050 | 0.0 | - |
6.2857 | 1100 | 0.0 | - |
6.5714 | 1150 | 0.0 | - |
6.8571 | 1200 | 0.0 | - |
7.1429 | 1250 | 0.0 | - |
7.4286 | 1300 | 0.0 | - |
7.7143 | 1350 | 0.0 | - |
8.0 | 1400 | 0.0 | - |
8.2857 | 1450 | 0.0 | - |
8.5714 | 1500 | 0.0 | - |
8.8571 | 1550 | 0.0 | - |
9.1429 | 1600 | 0.0 | - |
9.4286 | 1650 | 0.0 | - |
9.7143 | 1700 | 0.0 | - |
10.0 | 1750 | 0.0 | - |
10.2857 | 1800 | 0.0 | - |
10.5714 | 1850 | 0.0 | - |
10.8571 | 1900 | 0.0 | - |
11.1429 | 1950 | 0.0 | - |
11.4286 | 2000 | 0.0 | - |
11.7143 | 2050 | 0.0 | - |
12.0 | 2100 | 0.0 | - |
12.2857 | 2150 | 0.0 | - |
12.5714 | 2200 | 0.0 | - |
12.8571 | 2250 | 0.0 | - |
13.1429 | 2300 | 0.0 | - |
13.4286 | 2350 | 0.0 | - |
13.7143 | 2400 | 0.0 | - |
14.0 | 2450 | 0.0 | - |
14.2857 | 2500 | 0.0 | - |
14.5714 | 2550 | 0.0 | - |
14.8571 | 2600 | 0.0 | - |
15.1429 | 2650 | 0.0 | - |
15.4286 | 2700 | 0.0 | - |
15.7143 | 2750 | 0.0 | - |
16.0 | 2800 | 0.0 | - |
16.2857 | 2850 | 0.0 | - |
16.5714 | 2900 | 0.0 | - |
16.8571 | 2950 | 0.0 | - |
17.1429 | 3000 | 0.0 | - |
17.4286 | 3050 | 0.0 | - |
17.7143 | 3100 | 0.0 | - |
18.0 | 3150 | 0.0 | - |
18.2857 | 3200 | 0.0 | - |
18.5714 | 3250 | 0.0 | - |
18.8571 | 3300 | 0.0 | - |
19.1429 | 3350 | 0.0 | - |
19.4286 | 3400 | 0.0 | - |
19.7143 | 3450 | 0.0 | - |
20.0 | 3500 | 0.0 | - |
20.2857 | 3550 | 0.0 | - |
20.5714 | 3600 | 0.0 | - |
20.8571 | 3650 | 0.0 | - |
21.1429 | 3700 | 0.0 | - |
21.4286 | 3750 | 0.0 | - |
21.7143 | 3800 | 0.0 | - |
22.0 | 3850 | 0.0 | - |
22.2857 | 3900 | 0.0 | - |
22.5714 | 3950 | 0.0 | - |
22.8571 | 4000 | 0.0 | - |
23.1429 | 4050 | 0.0 | - |
23.4286 | 4100 | 0.0 | - |
23.7143 | 4150 | 0.0 | - |
24.0 | 4200 | 0.0 | - |
24.2857 | 4250 | 0.0 | - |
24.5714 | 4300 | 0.0 | - |
24.8571 | 4350 | 0.0 | - |
25.1429 | 4400 | 0.0 | - |
25.4286 | 4450 | 0.0 | - |
25.7143 | 4500 | 0.0 | - |
26.0 | 4550 | 0.0 | - |
26.2857 | 4600 | 0.0 | - |
26.5714 | 4650 | 0.0 | - |
26.8571 | 4700 | 0.0 | - |
27.1429 | 4750 | 0.0 | - |
27.4286 | 4800 | 0.0 | - |
27.7143 | 4850 | 0.0 | - |
28.0 | 4900 | 0.0 | - |
28.2857 | 4950 | 0.0 | - |
28.5714 | 5000 | 0.0 | - |
28.8571 | 5050 | 0.0 | - |
29.1429 | 5100 | 0.0 | - |
29.4286 | 5150 | 0.0 | - |
29.7143 | 5200 | 0.0 | - |
30.0 | 5250 | 0.0 | - |
Framework Versions
- Python: 3.10.12
- SetFit: 1.1.0
- Sentence Transformers: 3.3.1
- Transformers: 4.44.2
- PyTorch: 2.2.0a0+81ea7a4
- Datasets: 3.2.0
- Tokenizers: 0.19.1
Citation
BibTeX
@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}
}