LeoChiuu commited on
Commit
38af483
1 Parent(s): 4f490a2

Upload README.md with huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +160 -337
README.md CHANGED
@@ -1,378 +1,201 @@
1
  ---
2
- base_model: colorfulscoop/sbert-base-ja
3
- datasets: []
4
- language: []
5
- library_name: sentence-transformers
6
- metrics:
7
- - accuracy
8
- pipeline_tag: sentence-similarity
9
- tags:
10
- - sentence-transformers
11
- - sentence-similarity
12
- - feature-extraction
13
- - generated_from_trainer
14
- - dataset_size:124
15
- - loss:SoftmaxLoss
16
- widget:
17
- - source_sentence: 木の上に布がある?
18
- sentences:
19
- - あれってキミのスカーフ?
20
- - 家の外へ行こう
21
- - 夜当番だから
22
- - source_sentence: スリッパはいてた?
23
- sentences:
24
- - 夕飯が辛かったから
25
- - これはレオの毛?
26
- - どこ?
27
- - source_sentence: スカーフはベッドにある?
28
- sentences:
29
- - やっぱり、タイマツがいい
30
- - キミって猫?
31
- - ベッドにある?
32
- - source_sentence: 昨日は何を作ったの?
33
- sentences:
34
- - スリッパはいてた?
35
- - 何を作ったの?
36
- - お鍋からの香り
37
- - source_sentence: ビーフシチュー食べた?
38
- sentences:
39
- - なんで話せるの?
40
- - 窓から風で飛ばされた
41
- - ビーフシチュー作った?
42
- model-index:
43
- - name: SentenceTransformer based on colorfulscoop/sbert-base-ja
44
- results:
45
- - task:
46
- type: label-accuracy
47
- name: Label Accuracy
48
- dataset:
49
- name: val
50
- type: val
51
- metrics:
52
- - type: accuracy
53
- value: 0.8387096774193549
54
- name: Accuracy
55
  ---
56
 
57
- # SentenceTransformer based on colorfulscoop/sbert-base-ja
 
 
 
58
 
59
- This is a [sentence-transformers](https://www.SBERT.net) model finetuned from [colorfulscoop/sbert-base-ja](https://huggingface.co/colorfulscoop/sbert-base-ja). It maps sentences & paragraphs to a 768-dimensional dense vector space and can be used for semantic textual similarity, semantic search, paraphrase mining, text classification, clustering, and more.
60
 
61
  ## Model Details
62
 
63
  ### Model Description
64
- - **Model Type:** Sentence Transformer
65
- - **Base model:** [colorfulscoop/sbert-base-ja](https://huggingface.co/colorfulscoop/sbert-base-ja) <!-- at revision ecb8a98cd5176719ff7ab0d770a27420118732cf -->
66
- - **Maximum Sequence Length:** 512 tokens
67
- - **Output Dimensionality:** 768 tokens
68
- - **Similarity Function:** Cosine Similarity
69
- <!-- - **Training Dataset:** Unknown -->
70
- <!-- - **Language:** Unknown -->
71
- <!-- - **License:** Unknown -->
72
 
73
- ### Model Sources
74
 
75
- - **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
76
- - **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
77
- - **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers)
78
 
79
- ### Full Model Architecture
 
 
 
 
 
 
80
 
81
- ```
82
- SentenceTransformer(
83
- (0): Transformer({'max_seq_length': 512, 'do_lower_case': False}) with Transformer model: BertModel
84
- (1): Pooling({'word_embedding_dimension': 768, 'pooling_mode_cls_token': False, 'pooling_mode_mean_tokens': True, 'pooling_mode_max_tokens': False, 'pooling_mode_mean_sqrt_len_tokens': False, 'pooling_mode_weightedmean_tokens': False, 'pooling_mode_lasttoken': False, 'include_prompt': True})
85
- )
86
- ```
87
 
88
- ## Usage
89
 
90
- ### Direct Usage (Sentence Transformers)
 
 
91
 
92
- First install the Sentence Transformers library:
93
 
94
- ```bash
95
- pip install -U sentence-transformers
96
- ```
97
 
98
- Then you can load this model and run inference.
99
- ```python
100
- from sentence_transformers import SentenceTransformer
101
 
102
- # Download from the 🤗 Hub
103
- model = SentenceTransformer("LeoChiuu/sbert-base-ja")
104
- # Run inference
105
- sentences = [
106
- 'ビーフシチュー食べた?',
107
- 'ビーフシチュー作った?',
108
- '窓から風で飛ばされた',
109
- ]
110
- embeddings = model.encode(sentences)
111
- print(embeddings.shape)
112
- # [3, 768]
113
 
114
- # Get the similarity scores for the embeddings
115
- similarities = model.similarity(embeddings, embeddings)
116
- print(similarities.shape)
117
- # [3, 3]
118
- ```
119
 
120
- <!--
121
- ### Direct Usage (Transformers)
122
 
123
- <details><summary>Click to see the direct usage in Transformers</summary>
124
 
125
- </details>
126
- -->
127
 
128
- <!--
129
- ### Downstream Usage (Sentence Transformers)
130
 
131
- You can finetune this model on your own dataset.
132
 
133
- <details><summary>Click to expand</summary>
134
 
135
- </details>
136
- -->
137
 
138
- <!--
139
- ### Out-of-Scope Use
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
140
 
141
- *List how the model may foreseeably be misused and address what users ought not to do with the model.*
142
- -->
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
143
 
144
  ## Evaluation
145
 
146
- ### Metrics
147
 
148
- #### Label Accuracy
149
- * Dataset: `val`
150
- * Evaluated with [<code>LabelAccuracyEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.LabelAccuracyEvaluator)
151
 
152
- | Metric | Value |
153
- |:-------------|:-----------|
154
- | **accuracy** | **0.8387** |
155
 
156
- <!--
157
- ## Bias, Risks and Limitations
158
 
159
- *What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*
160
- -->
161
 
162
- <!--
163
- ### Recommendations
164
 
165
- *What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*
166
- -->
167
 
168
- ## Training Details
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
169
 
170
- ### Training Dataset
171
-
172
- #### Unnamed Dataset
173
-
174
-
175
- * Size: 124 training samples
176
- * Columns: <code>sentence_0</code>, <code>sentence_1</code>, and <code>label</code>
177
- * Approximate statistics based on the first 1000 samples:
178
- | | sentence_0 | sentence_1 | label |
179
- |:--------|:---------------------------------------------------------------------------------|:---------------------------------------------------------------------------------|:-----------------------------|
180
- | type | string | string | int |
181
- | details | <ul><li>min: 4 tokens</li><li>mean: 8.59 tokens</li><li>max: 14 tokens</li></ul> | <ul><li>min: 5 tokens</li><li>mean: 8.58 tokens</li><li>max: 14 tokens</li></ul> | <ul><li>1: 100.00%</li></ul> |
182
- * Samples:
183
- | sentence_0 | sentence_1 | label |
184
- |:-------------------------|:---------------------------|:---------------|
185
- | <code>辛いスープがあったから</code> | <code>辛いスープを食べたから</code> | <code>1</code> |
186
- | <code>昨日は何を作ったの?</code> | <code>何を作ったの?</code> | <code>1</code> |
187
- | <code>キャンプファイヤ</code> | <code>キャンプファイヤを調べよう</code> | <code>1</code> |
188
- * Loss: [<code>SoftmaxLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#softmaxloss)
189
-
190
- ### Training Hyperparameters
191
- #### Non-Default Hyperparameters
192
-
193
- - `eval_strategy`: steps
194
- - `num_train_epochs`: 13
195
- - `multi_dataset_batch_sampler`: round_robin
196
-
197
- #### All Hyperparameters
198
- <details><summary>Click to expand</summary>
199
-
200
- - `overwrite_output_dir`: False
201
- - `do_predict`: False
202
- - `eval_strategy`: steps
203
- - `prediction_loss_only`: True
204
- - `per_device_train_batch_size`: 8
205
- - `per_device_eval_batch_size`: 8
206
- - `per_gpu_train_batch_size`: None
207
- - `per_gpu_eval_batch_size`: None
208
- - `gradient_accumulation_steps`: 1
209
- - `eval_accumulation_steps`: None
210
- - `torch_empty_cache_steps`: None
211
- - `learning_rate`: 5e-05
212
- - `weight_decay`: 0.0
213
- - `adam_beta1`: 0.9
214
- - `adam_beta2`: 0.999
215
- - `adam_epsilon`: 1e-08
216
- - `max_grad_norm`: 1
217
- - `num_train_epochs`: 13
218
- - `max_steps`: -1
219
- - `lr_scheduler_type`: linear
220
- - `lr_scheduler_kwargs`: {}
221
- - `warmup_ratio`: 0.0
222
- - `warmup_steps`: 0
223
- - `log_level`: passive
224
- - `log_level_replica`: warning
225
- - `log_on_each_node`: True
226
- - `logging_nan_inf_filter`: True
227
- - `save_safetensors`: True
228
- - `save_on_each_node`: False
229
- - `save_only_model`: False
230
- - `restore_callback_states_from_checkpoint`: False
231
- - `no_cuda`: False
232
- - `use_cpu`: False
233
- - `use_mps_device`: False
234
- - `seed`: 42
235
- - `data_seed`: None
236
- - `jit_mode_eval`: False
237
- - `use_ipex`: False
238
- - `bf16`: False
239
- - `fp16`: False
240
- - `fp16_opt_level`: O1
241
- - `half_precision_backend`: auto
242
- - `bf16_full_eval`: False
243
- - `fp16_full_eval`: False
244
- - `tf32`: None
245
- - `local_rank`: 0
246
- - `ddp_backend`: None
247
- - `tpu_num_cores`: None
248
- - `tpu_metrics_debug`: False
249
- - `debug`: []
250
- - `dataloader_drop_last`: False
251
- - `dataloader_num_workers`: 0
252
- - `dataloader_prefetch_factor`: None
253
- - `past_index`: -1
254
- - `disable_tqdm`: False
255
- - `remove_unused_columns`: True
256
- - `label_names`: None
257
- - `load_best_model_at_end`: False
258
- - `ignore_data_skip`: False
259
- - `fsdp`: []
260
- - `fsdp_min_num_params`: 0
261
- - `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
262
- - `fsdp_transformer_layer_cls_to_wrap`: None
263
- - `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
264
- - `deepspeed`: None
265
- - `label_smoothing_factor`: 0.0
266
- - `optim`: adamw_torch
267
- - `optim_args`: None
268
- - `adafactor`: False
269
- - `group_by_length`: False
270
- - `length_column_name`: length
271
- - `ddp_find_unused_parameters`: None
272
- - `ddp_bucket_cap_mb`: None
273
- - `ddp_broadcast_buffers`: False
274
- - `dataloader_pin_memory`: True
275
- - `dataloader_persistent_workers`: False
276
- - `skip_memory_metrics`: True
277
- - `use_legacy_prediction_loop`: False
278
- - `push_to_hub`: False
279
- - `resume_from_checkpoint`: None
280
- - `hub_model_id`: None
281
- - `hub_strategy`: every_save
282
- - `hub_private_repo`: False
283
- - `hub_always_push`: False
284
- - `gradient_checkpointing`: False
285
- - `gradient_checkpointing_kwargs`: None
286
- - `include_inputs_for_metrics`: False
287
- - `eval_do_concat_batches`: True
288
- - `fp16_backend`: auto
289
- - `push_to_hub_model_id`: None
290
- - `push_to_hub_organization`: None
291
- - `mp_parameters`:
292
- - `auto_find_batch_size`: False
293
- - `full_determinism`: False
294
- - `torchdynamo`: None
295
- - `ray_scope`: last
296
- - `ddp_timeout`: 1800
297
- - `torch_compile`: False
298
- - `torch_compile_backend`: None
299
- - `torch_compile_mode`: None
300
- - `dispatch_batches`: None
301
- - `split_batches`: None
302
- - `include_tokens_per_second`: False
303
- - `include_num_input_tokens_seen`: False
304
- - `neftune_noise_alpha`: None
305
- - `optim_target_modules`: None
306
- - `batch_eval_metrics`: False
307
- - `eval_on_start`: False
308
- - `eval_use_gather_object`: False
309
- - `batch_sampler`: batch_sampler
310
- - `multi_dataset_batch_sampler`: round_robin
311
-
312
- </details>
313
-
314
- ### Training Logs
315
- | Epoch | Step | val_accuracy |
316
- |:-----:|:----:|:------------:|
317
- | 1.0 | 16 | 0.1613 |
318
- | 2.0 | 32 | 0.1613 |
319
- | 3.0 | 48 | 0.1613 |
320
- | 3.125 | 50 | 0.1613 |
321
- | 4.0 | 64 | 0.1935 |
322
- | 5.0 | 80 | 0.2581 |
323
- | 6.0 | 96 | 0.2903 |
324
- | 6.25 | 100 | 0.2903 |
325
- | 7.0 | 112 | 0.3226 |
326
- | 8.0 | 128 | 0.3226 |
327
- | 9.0 | 144 | 0.4194 |
328
- | 9.375 | 150 | 0.4516 |
329
- | 10.0 | 160 | 0.5484 |
330
- | 11.0 | 176 | 0.6452 |
331
- | 12.0 | 192 | 0.7419 |
332
- | 12.5 | 200 | 0.8387 |
333
- | 13.0 | 208 | 0.8387 |
334
-
335
-
336
- ### Framework Versions
337
- - Python: 3.10.14
338
- - Sentence Transformers: 3.0.1
339
- - Transformers: 4.44.2
340
- - PyTorch: 2.4.0+cu121
341
- - Accelerate: 0.34.0
342
- - Datasets: 2.20.0
343
- - Tokenizers: 0.19.1
344
-
345
- ## Citation
346
-
347
- ### BibTeX
348
-
349
- #### Sentence Transformers and SoftmaxLoss
350
- ```bibtex
351
- @inproceedings{reimers-2019-sentence-bert,
352
- title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
353
- author = "Reimers, Nils and Gurevych, Iryna",
354
- booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
355
- month = "11",
356
- year = "2019",
357
- publisher = "Association for Computational Linguistics",
358
- url = "https://arxiv.org/abs/1908.10084",
359
- }
360
- ```
361
-
362
- <!--
363
- ## Glossary
364
-
365
- *Clearly define terms in order to be accessible across audiences.*
366
- -->
367
-
368
- <!--
369
- ## Model Card Authors
370
-
371
- *Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
372
- -->
373
-
374
- <!--
375
  ## Model Card Contact
376
 
377
- *Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
378
- -->
 
1
  ---
2
+ datasets: custom-data
3
+ language: en
4
+ license: apache-2.0
5
+ model_name: LeoChiuu/sbert-base-ja
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
6
  ---
7
 
8
+ # Model Card for LeoChiuu/sbert-base-ja
9
+
10
+ <!-- Provide a quick summary of what the model is/does. -->
11
+
12
 
 
13
 
14
  ## Model Details
15
 
16
  ### Model Description
 
 
 
 
 
 
 
 
17
 
18
+ <!-- Provide a longer summary of what this model is. -->
19
 
20
+ Binary classification of sentences
 
 
21
 
22
+ - **Developed by:** [More Information Needed]
23
+ - **Funded by [optional]:** [More Information Needed]
24
+ - **Shared by [optional]:** [More Information Needed]
25
+ - **Model type:** [More Information Needed]
26
+ - **Language(s) (NLP):** en
27
+ - **License:** apache-2.0
28
+ - **Finetuned from model [optional]:** [More Information Needed]
29
 
30
+ ### Model Sources [optional]
 
 
 
 
 
31
 
32
+ <!-- Provide the basic links for the model. -->
33
 
34
+ - **Repository:** https://github.com/huggingface/huggingface_hub
35
+ - **Paper [optional]:** [More Information Needed]
36
+ - **Demo [optional]:** [More Information Needed]
37
 
38
+ ## Uses
39
 
40
+ <!-- Address questions around how the model is intended to be used, including the foreseeable users of the model and those affected by the model. -->
 
 
41
 
42
+ ### Direct Use
 
 
43
 
44
+ <!-- This section is for the model use without fine-tuning or plugging into a larger ecosystem/app. -->
 
 
 
 
 
 
 
 
 
 
45
 
46
+ [More Information Needed]
 
 
 
 
47
 
48
+ ### Downstream Use [optional]
 
49
 
50
+ <!-- This section is for the model use when fine-tuned for a task, or when plugged into a larger ecosystem/app -->
51
 
52
+ [More Information Needed]
 
53
 
54
+ ### Out-of-Scope Use
 
55
 
56
+ <!-- This section addresses misuse, malicious use, and uses that the model will not work well for. -->
57
 
58
+ [More Information Needed]
59
 
60
+ ## Bias, Risks, and Limitations
 
61
 
62
+ <!-- This section is meant to convey both technical and sociotechnical limitations. -->
63
+
64
+ [More Information Needed]
65
+
66
+ ### Recommendations
67
+
68
+ <!-- This section is meant to convey recommendations with respect to the bias, risk, and technical limitations. -->
69
+
70
+ Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model. More information needed for further recommendations.
71
+
72
+ ## How to Get Started with the Model
73
+
74
+ Use the code below to get started with the model.
75
+
76
+ [More Information Needed]
77
+
78
+ ## Training Details
79
+
80
+ ### Training Data
81
+
82
+ <!-- This should link to a Dataset Card, perhaps with a short stub of information on what the training data is all about as well as documentation related to data pre-processing or additional filtering. -->
83
+
84
+ [More Information Needed]
85
 
86
+ ### Training Procedure
87
+
88
+ <!-- This relates heavily to the Technical Specifications. Content here should link to that section when it is relevant to the training procedure. -->
89
+
90
+ #### Preprocessing [optional]
91
+
92
+ [More Information Needed]
93
+
94
+
95
+ #### Training Hyperparameters
96
+
97
+ - **Training regime:** [More Information Needed] <!--fp32, fp16 mixed precision, bf16 mixed precision, bf16 non-mixed precision, fp16 non-mixed precision, fp8 mixed precision -->
98
+
99
+ #### Speeds, Sizes, Times [optional]
100
+
101
+ <!-- This section provides information about throughput, start/end time, checkpoint size if relevant, etc. -->
102
+
103
+ [More Information Needed]
104
 
105
  ## Evaluation
106
 
107
+ <!-- This section describes the evaluation protocols and provides the results. -->
108
 
109
+ ### Testing Data, Factors & Metrics
 
 
110
 
111
+ #### Testing Data
 
 
112
 
113
+ <!-- This should link to a Dataset Card if possible. -->
 
114
 
115
+ [More Information Needed]
 
116
 
117
+ #### Factors
 
118
 
119
+ <!-- These are the things the evaluation is disaggregating by, e.g., subpopulations or domains. -->
 
120
 
121
+ [More Information Needed]
122
+
123
+ #### Metrics
124
+
125
+ <!-- These are the evaluation metrics being used, ideally with a description of why. -->
126
+
127
+ [More Information Needed]
128
+
129
+ ### Results
130
+
131
+ [More Information Needed]
132
+
133
+ #### Summary
134
+
135
+
136
+
137
+ ## Model Examination [optional]
138
+
139
+ <!-- Relevant interpretability work for the model goes here -->
140
+
141
+ [More Information Needed]
142
+
143
+ ## Environmental Impact
144
+
145
+ <!-- Total emissions (in grams of CO2eq) and additional considerations, such as electricity usage, go here. Edit the suggested text below accordingly -->
146
+
147
+ Carbon emissions can be estimated using the [Machine Learning Impact calculator](https://mlco2.github.io/impact#compute) presented in [Lacoste et al. (2019)](https://arxiv.org/abs/1910.09700).
148
+
149
+ - **Hardware Type:** [More Information Needed]
150
+ - **Hours used:** [More Information Needed]
151
+ - **Cloud Provider:** [More Information Needed]
152
+ - **Compute Region:** [More Information Needed]
153
+ - **Carbon Emitted:** [More Information Needed]
154
+
155
+ ## Technical Specifications [optional]
156
+
157
+ ### Model Architecture and Objective
158
+
159
+ [More Information Needed]
160
+
161
+ ### Compute Infrastructure
162
+
163
+ [More Information Needed]
164
+
165
+ #### Hardware
166
+
167
+ [More Information Needed]
168
+
169
+ #### Software
170
+
171
+ [More Information Needed]
172
+
173
+ ## Citation [optional]
174
+
175
+ <!-- If there is a paper or blog post introducing the model, the APA and Bibtex information for that should go in this section. -->
176
+
177
+ **BibTeX:**
178
+
179
+ [More Information Needed]
180
+
181
+ **APA:**
182
+
183
+ [More Information Needed]
184
+
185
+ ## Glossary [optional]
186
+
187
+ <!-- If relevant, include terms and calculations in this section that can help readers understand the model or model card. -->
188
+
189
+ [More Information Needed]
190
+
191
+ ## More Information [optional]
192
+
193
+ [More Information Needed]
194
+
195
+ ## Model Card Authors [optional]
196
+
197
+ [More Information Needed]
198
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
199
  ## Model Card Contact
200
 
201
+ [More Information Needed]