mini1013 commited on
Commit
a0cb3ab
1 Parent(s): 9b456d6

Push model using huggingface_hub.

Browse files
1_Pooling/config.json ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "word_embedding_dimension": 768,
3
+ "pooling_mode_cls_token": false,
4
+ "pooling_mode_mean_tokens": true,
5
+ "pooling_mode_max_tokens": false,
6
+ "pooling_mode_mean_sqrt_len_tokens": false,
7
+ "pooling_mode_weightedmean_tokens": false,
8
+ "pooling_mode_lasttoken": false,
9
+ "include_prompt": true
10
+ }
README.md ADDED
@@ -0,0 +1,229 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ base_model: mini1013/master_domain
3
+ library_name: setfit
4
+ metrics:
5
+ - metric
6
+ pipeline_tag: text-classification
7
+ tags:
8
+ - setfit
9
+ - sentence-transformers
10
+ - text-classification
11
+ - generated_from_setfit_trainer
12
+ widget:
13
+ - text: LG전자 올레드 TV OLED55C2FNA 스탠드 윤성 운송료상이 윤성종합가전
14
+ - text: '[엡손] EH-LS500W / 4K UHD 4000안시 2,500,000:1 EPSON 빔 프로젝터 초단초점 (주)메리트정보'
15
+ - text: 루컴즈 2024년형 50인치 스마트 UHD 구글 TV 4K 에너지효율 1등급 T5003KUG 스탠드 빌리어네어디
16
+ - text: 이노스 S8601KU LG 패널 스마트 TV 구글티비 벽걸이 기사방문설치(브라켓별도)_수도권(서울경기인천)_86인치 QLED 구글TV
17
+ (주)티지디지털
18
+ - text: 삼성 WMN4070SG 벽결이브라켓 삼성고정브라켓 두루엠에스
19
+ inference: true
20
+ model-index:
21
+ - name: SetFit with mini1013/master_domain
22
+ results:
23
+ - task:
24
+ type: text-classification
25
+ name: Text Classification
26
+ dataset:
27
+ name: Unknown
28
+ type: unknown
29
+ split: test
30
+ metrics:
31
+ - type: metric
32
+ value: 0.763001415762152
33
+ name: Metric
34
+ ---
35
+
36
+ # SetFit with mini1013/master_domain
37
+
38
+ This is a [SetFit](https://github.com/huggingface/setfit) model that can be used for Text Classification. This SetFit model uses [mini1013/master_domain](https://huggingface.co/mini1013/master_domain) as the Sentence Transformer embedding model. A [LogisticRegression](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LogisticRegression.html) instance is used for classification.
39
+
40
+ The model has been trained using an efficient few-shot learning technique that involves:
41
+
42
+ 1. Fine-tuning a [Sentence Transformer](https://www.sbert.net) with contrastive learning.
43
+ 2. Training a classification head with features from the fine-tuned Sentence Transformer.
44
+
45
+ ## Model Details
46
+
47
+ ### Model Description
48
+ - **Model Type:** SetFit
49
+ - **Sentence Transformer body:** [mini1013/master_domain](https://huggingface.co/mini1013/master_domain)
50
+ - **Classification head:** a [LogisticRegression](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LogisticRegression.html) instance
51
+ - **Maximum Sequence Length:** 512 tokens
52
+ - **Number of Classes:** 7 classes
53
+ <!-- - **Training Dataset:** [Unknown](https://huggingface.co/datasets/unknown) -->
54
+ <!-- - **Language:** Unknown -->
55
+ <!-- - **License:** Unknown -->
56
+
57
+ ### Model Sources
58
+
59
+ - **Repository:** [SetFit on GitHub](https://github.com/huggingface/setfit)
60
+ - **Paper:** [Efficient Few-Shot Learning Without Prompts](https://arxiv.org/abs/2209.11055)
61
+ - **Blogpost:** [SetFit: Efficient Few-Shot Learning Without Prompts](https://huggingface.co/blog/setfit)
62
+
63
+ ### Model Labels
64
+ | Label | Examples |
65
+ |:------|:---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
66
+ | 6 | <ul><li>'윤씨네 J-SV / 족자스크린 4:3비율 100인치 에스앤피'</li><li>'[ FLAT FLOW ] 플랏플로우 100인치 와이드 분리형 족자스크린 F-HJ100W F-HJ100W (100인치 와이드 족자형) 아이티원'</li><li>'윤씨네 J-SH40 / 와이드 족자스크린 16:9 40인치 에스앤피'</li></ul> |
67
+ | 2 | <ul><li>'75인치 189cm 4K UHD 비즈니스TV LH75BECH 스탠드 에너지효율등급 1등급 우수한 내구성 주식회사 쇼핑하는니체'</li><li>'[LG] 55인치 UHD 단독형 사이니지 3시리즈 (55UL3J) 고정형 벽걸이 설치 주식회사 케이엠시스템'</li><li>'[LG] 55인치 비디오월 슬림 베젤 1.74 mm, 500nit (55VM5J) 벽걸이 설치 (별도문의) 주식회사 케이엠시스템'</li></ul> |
68
+ | 5 | <ul><li>'벤큐 GS50 풀HD 캠핑용 빔프로젝터 안드로이드 아이폰 무선미러링 배터리내장 블루투스 (주)아솔컴퍼니'</li><li>'에이서 DX227 🧡정품 신형🧡 5200안시 XGA 20000:1 DLP 회의용 교육용 강당용 멀티용 도움에이브이'</li><li>'[피제이시스] 엡손 EB-L1070U 레이저프로젝터 ❤️정품새상품 ❤️ 주식회사 피제이시스(PJSYS.co.Ltd.)'</li></ul> |
69
+ | 0 | <ul><li>'이노스 S2401KU 어반스톡'</li><li>'[무결점] 프리즘 바이런 75인치 1등급 4K HDR 베젤리스TV 패널 2년 무상보증 / BR750UD_기사설치포함 (주)프리즘코리아'</li><li>'[무결점] 프리즘 바이런 55인치 1등급 4K HDR 베젤리스TV 패널 2년 무상보증 / BR550UHD (주)프리즘코리아'</li></ul> |
70
+ | 4 | <ul><li>'[PICO 국내 공식판매처] PICO NEO3 Enterprise VR (256GB) / 공공기관 및 공공교육기관 전용 주식회사 메타에듀시스'</li><li>'에듀플레이어 EA400 DVD플레이어 CD/DVD리핑 투웨이 블루투스 EA400 (ED404) 주식회사 에듀플레이어'</li><li>'오큘러스 퀘스트2 Oculus Quest2 올인원 VR게임헤드셋 퀘스트2 128GB (관세 대납) 팽마켓'</li></ul> |
71
+ | 1 | <ul><li>'카멜 디지털액자화이트(블랙) / PF1040IPS /10인치 디지털액자(동영상,슬리이드쇼,앨범) 선물용디지털액자PF-1040IPS / 디지털사진액자/ 16:9화면(화이트or 블랙) 블랙 에스라B2B'</li><li>'컴스마트 BM170 15.4형 스마트 디지털 액자 동영상 시계 달력 HDMI 서브 모니터 블루시스템쇼핑몰 주식회사'</li><li>'카멜 디지털액자 10인치 PF-1040IPS 미니모니터 사진 동영상 음악 에스제이인터내셔널'</li></ul> |
72
+ | 3 | <ul><li>'COMBO-2000A (금영 (KY)/ 내셔널 (NATIONAL) / 넥스디지탈 (NEX) /넥슨 (NEXN) /뉴썬인더스트리 엔플러스(NPLUS)/ 다비디스플레이 (DAVI) COMBO-2000A 메카트로주식회사'</li><li>'COMBO-119 /APH13000/AP-H3020/AP-H4000/APH-H2300/AP-HH232N/IAS-T1010/IAS-T810/IAS-T82CA 지에이치스토어'</li><li>'COMBO-2201 (AKB75455603 / AKB75635301 / AKB75635305 / AKB75675304 / akb75675306 / AKB75755301) 메카트로'</li></ul> |
73
+
74
+ ## Evaluation
75
+
76
+ ### Metrics
77
+ | Label | Metric |
78
+ |:--------|:-------|
79
+ | **all** | 0.7630 |
80
+
81
+ ## Uses
82
+
83
+ ### Direct Use for Inference
84
+
85
+ First install the SetFit library:
86
+
87
+ ```bash
88
+ pip install setfit
89
+ ```
90
+
91
+ Then you can load this model and run inference.
92
+
93
+ ```python
94
+ from setfit import SetFitModel
95
+
96
+ # Download from the 🤗 Hub
97
+ model = SetFitModel.from_pretrained("mini1013/master_cate_el13")
98
+ # Run inference
99
+ preds = model("삼성 WMN4070SG 벽결이브라켓 삼성고정브라켓 두루엠에스")
100
+ ```
101
+
102
+ <!--
103
+ ### Downstream Use
104
+
105
+ *List how someone could finetune this model on their own dataset.*
106
+ -->
107
+
108
+ <!--
109
+ ### Out-of-Scope Use
110
+
111
+ *List how the model may foreseeably be misused and address what users ought not to do with the model.*
112
+ -->
113
+
114
+ <!--
115
+ ## Bias, Risks and Limitations
116
+
117
+ *What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*
118
+ -->
119
+
120
+ <!--
121
+ ### Recommendations
122
+
123
+ *What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*
124
+ -->
125
+
126
+ ## Training Details
127
+
128
+ ### Training Set Metrics
129
+ | Training set | Min | Median | Max |
130
+ |:-------------|:----|:--------|:----|
131
+ | Word count | 3 | 10.4229 | 25 |
132
+
133
+ | Label | Training Sample Count |
134
+ |:------|:----------------------|
135
+ | 0 | 50 |
136
+ | 1 | 50 |
137
+ | 2 | 50 |
138
+ | 3 | 50 |
139
+ | 4 | 50 |
140
+ | 5 | 50 |
141
+ | 6 | 50 |
142
+
143
+ ### Training Hyperparameters
144
+ - batch_size: (512, 512)
145
+ - num_epochs: (20, 20)
146
+ - max_steps: -1
147
+ - sampling_strategy: oversampling
148
+ - num_iterations: 40
149
+ - body_learning_rate: (2e-05, 2e-05)
150
+ - head_learning_rate: 2e-05
151
+ - loss: CosineSimilarityLoss
152
+ - distance_metric: cosine_distance
153
+ - margin: 0.25
154
+ - end_to_end: False
155
+ - use_amp: False
156
+ - warmup_proportion: 0.1
157
+ - seed: 42
158
+ - eval_max_steps: -1
159
+ - load_best_model_at_end: False
160
+
161
+ ### Training Results
162
+ | Epoch | Step | Training Loss | Validation Loss |
163
+ |:-------:|:----:|:-------------:|:---------------:|
164
+ | 0.0182 | 1 | 0.4965 | - |
165
+ | 0.9091 | 50 | 0.118 | - |
166
+ | 1.8182 | 100 | 0.0382 | - |
167
+ | 2.7273 | 150 | 0.0008 | - |
168
+ | 3.6364 | 200 | 0.0003 | - |
169
+ | 4.5455 | 250 | 0.0002 | - |
170
+ | 5.4545 | 300 | 0.0002 | - |
171
+ | 6.3636 | 350 | 0.0002 | - |
172
+ | 7.2727 | 400 | 0.0001 | - |
173
+ | 8.1818 | 450 | 0.0001 | - |
174
+ | 9.0909 | 500 | 0.0001 | - |
175
+ | 10.0 | 550 | 0.0001 | - |
176
+ | 10.9091 | 600 | 0.0001 | - |
177
+ | 11.8182 | 650 | 0.0001 | - |
178
+ | 12.7273 | 700 | 0.0001 | - |
179
+ | 13.6364 | 750 | 0.0001 | - |
180
+ | 14.5455 | 800 | 0.0001 | - |
181
+ | 15.4545 | 850 | 0.0001 | - |
182
+ | 16.3636 | 900 | 0.0001 | - |
183
+ | 17.2727 | 950 | 0.0001 | - |
184
+ | 18.1818 | 1000 | 0.0001 | - |
185
+ | 19.0909 | 1050 | 0.0001 | - |
186
+ | 20.0 | 1100 | 0.0 | - |
187
+
188
+ ### Framework Versions
189
+ - Python: 3.10.12
190
+ - SetFit: 1.1.0.dev0
191
+ - Sentence Transformers: 3.1.1
192
+ - Transformers: 4.46.1
193
+ - PyTorch: 2.4.0+cu121
194
+ - Datasets: 2.20.0
195
+ - Tokenizers: 0.20.0
196
+
197
+ ## Citation
198
+
199
+ ### BibTeX
200
+ ```bibtex
201
+ @article{https://doi.org/10.48550/arxiv.2209.11055,
202
+ doi = {10.48550/ARXIV.2209.11055},
203
+ url = {https://arxiv.org/abs/2209.11055},
204
+ author = {Tunstall, Lewis and Reimers, Nils and Jo, Unso Eun Seo and Bates, Luke and Korat, Daniel and Wasserblat, Moshe and Pereg, Oren},
205
+ keywords = {Computation and Language (cs.CL), FOS: Computer and information sciences, FOS: Computer and information sciences},
206
+ title = {Efficient Few-Shot Learning Without Prompts},
207
+ publisher = {arXiv},
208
+ year = {2022},
209
+ copyright = {Creative Commons Attribution 4.0 International}
210
+ }
211
+ ```
212
+
213
+ <!--
214
+ ## Glossary
215
+
216
+ *Clearly define terms in order to be accessible across audiences.*
217
+ -->
218
+
219
+ <!--
220
+ ## Model Card Authors
221
+
222
+ *Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
223
+ -->
224
+
225
+ <!--
226
+ ## Model Card Contact
227
+
228
+ *Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
229
+ -->
config.json ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_name_or_path": "mini1013/master_item_el",
3
+ "architectures": [
4
+ "RobertaModel"
5
+ ],
6
+ "attention_probs_dropout_prob": 0.1,
7
+ "bos_token_id": 0,
8
+ "classifier_dropout": null,
9
+ "eos_token_id": 2,
10
+ "gradient_checkpointing": false,
11
+ "hidden_act": "gelu",
12
+ "hidden_dropout_prob": 0.1,
13
+ "hidden_size": 768,
14
+ "initializer_range": 0.02,
15
+ "intermediate_size": 3072,
16
+ "layer_norm_eps": 1e-05,
17
+ "max_position_embeddings": 514,
18
+ "model_type": "roberta",
19
+ "num_attention_heads": 12,
20
+ "num_hidden_layers": 12,
21
+ "pad_token_id": 1,
22
+ "position_embedding_type": "absolute",
23
+ "tokenizer_class": "BertTokenizer",
24
+ "torch_dtype": "float32",
25
+ "transformers_version": "4.46.1",
26
+ "type_vocab_size": 1,
27
+ "use_cache": true,
28
+ "vocab_size": 32000
29
+ }
config_sentence_transformers.json ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "__version__": {
3
+ "sentence_transformers": "3.1.1",
4
+ "transformers": "4.46.1",
5
+ "pytorch": "2.4.0+cu121"
6
+ },
7
+ "prompts": {},
8
+ "default_prompt_name": null,
9
+ "similarity_fn_name": null
10
+ }
config_setfit.json ADDED
@@ -0,0 +1,4 @@
 
 
 
 
 
1
+ {
2
+ "labels": null,
3
+ "normalize_embeddings": false
4
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:36e4f032f882ef3781dd700cc59cf2d2067445a2701d9691cf0859b19684ce28
3
+ size 442494816
model_head.pkl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:a9b904517ee41fa25b3b80068b3c733f9181269d615dcecdf922dd2a949ee342
3
+ size 43967
modules.json ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "idx": 0,
4
+ "name": "0",
5
+ "path": "",
6
+ "type": "sentence_transformers.models.Transformer"
7
+ },
8
+ {
9
+ "idx": 1,
10
+ "name": "1",
11
+ "path": "1_Pooling",
12
+ "type": "sentence_transformers.models.Pooling"
13
+ }
14
+ ]
sentence_bert_config.json ADDED
@@ -0,0 +1,4 @@
 
 
 
 
 
1
+ {
2
+ "max_seq_length": 512,
3
+ "do_lower_case": false
4
+ }
special_tokens_map.json ADDED
@@ -0,0 +1,51 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "bos_token": {
3
+ "content": "[CLS]",
4
+ "lstrip": false,
5
+ "normalized": false,
6
+ "rstrip": false,
7
+ "single_word": false
8
+ },
9
+ "cls_token": {
10
+ "content": "[CLS]",
11
+ "lstrip": false,
12
+ "normalized": false,
13
+ "rstrip": false,
14
+ "single_word": false
15
+ },
16
+ "eos_token": {
17
+ "content": "[SEP]",
18
+ "lstrip": false,
19
+ "normalized": false,
20
+ "rstrip": false,
21
+ "single_word": false
22
+ },
23
+ "mask_token": {
24
+ "content": "[MASK]",
25
+ "lstrip": false,
26
+ "normalized": false,
27
+ "rstrip": false,
28
+ "single_word": false
29
+ },
30
+ "pad_token": {
31
+ "content": "[PAD]",
32
+ "lstrip": false,
33
+ "normalized": false,
34
+ "rstrip": false,
35
+ "single_word": false
36
+ },
37
+ "sep_token": {
38
+ "content": "[SEP]",
39
+ "lstrip": false,
40
+ "normalized": false,
41
+ "rstrip": false,
42
+ "single_word": false
43
+ },
44
+ "unk_token": {
45
+ "content": "[UNK]",
46
+ "lstrip": false,
47
+ "normalized": false,
48
+ "rstrip": false,
49
+ "single_word": false
50
+ }
51
+ }
tokenizer.json ADDED
The diff for this file is too large to render. See raw diff
 
tokenizer_config.json ADDED
@@ -0,0 +1,66 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "added_tokens_decoder": {
3
+ "0": {
4
+ "content": "[CLS]",
5
+ "lstrip": false,
6
+ "normalized": false,
7
+ "rstrip": false,
8
+ "single_word": false,
9
+ "special": true
10
+ },
11
+ "1": {
12
+ "content": "[PAD]",
13
+ "lstrip": false,
14
+ "normalized": false,
15
+ "rstrip": false,
16
+ "single_word": false,
17
+ "special": true
18
+ },
19
+ "2": {
20
+ "content": "[SEP]",
21
+ "lstrip": false,
22
+ "normalized": false,
23
+ "rstrip": false,
24
+ "single_word": false,
25
+ "special": true
26
+ },
27
+ "3": {
28
+ "content": "[UNK]",
29
+ "lstrip": false,
30
+ "normalized": false,
31
+ "rstrip": false,
32
+ "single_word": false,
33
+ "special": true
34
+ },
35
+ "4": {
36
+ "content": "[MASK]",
37
+ "lstrip": false,
38
+ "normalized": false,
39
+ "rstrip": false,
40
+ "single_word": false,
41
+ "special": true
42
+ }
43
+ },
44
+ "bos_token": "[CLS]",
45
+ "clean_up_tokenization_spaces": false,
46
+ "cls_token": "[CLS]",
47
+ "do_basic_tokenize": true,
48
+ "do_lower_case": false,
49
+ "eos_token": "[SEP]",
50
+ "mask_token": "[MASK]",
51
+ "max_length": 512,
52
+ "model_max_length": 512,
53
+ "never_split": null,
54
+ "pad_to_multiple_of": null,
55
+ "pad_token": "[PAD]",
56
+ "pad_token_type_id": 0,
57
+ "padding_side": "right",
58
+ "sep_token": "[SEP]",
59
+ "stride": 0,
60
+ "strip_accents": null,
61
+ "tokenize_chinese_chars": true,
62
+ "tokenizer_class": "BertTokenizer",
63
+ "truncation_side": "right",
64
+ "truncation_strategy": "longest_first",
65
+ "unk_token": "[UNK]"
66
+ }
vocab.txt ADDED
The diff for this file is too large to render. See raw diff