marigold334
commited on
Commit
•
96f2d9d
1
Parent(s):
ad32fce
Update README.md
Browse files
README.md
CHANGED
@@ -22,9 +22,9 @@ widget:
|
|
22 |
example_title: "Sleepy"
|
23 |
---
|
24 |
|
25 |
-
#
|
26 |
|
27 |
-
|
28 |
|
29 |
<!--- Describe your model here -->
|
30 |
|
@@ -42,7 +42,7 @@ Then you can use the model like this:
|
|
42 |
from sentence_transformers import SentenceTransformer
|
43 |
sentences = ["This is an example sentence", "Each sentence is converted"]
|
44 |
|
45 |
-
model = SentenceTransformer('snunlp/KR-SBERT-V40K-klueNLI-augSTS')
|
46 |
embeddings = model.encode(sentences)
|
47 |
print(embeddings)
|
48 |
```
|
@@ -69,7 +69,7 @@ sentences = ['This is an example sentence', 'Each sentence is converted']
|
|
69 |
|
70 |
# Load model from HuggingFace Hub
|
71 |
tokenizer = AutoTokenizer.from_pretrained('snunlp/KR-SBERT-V40K-klueNLI-augSTS')
|
72 |
-
model = AutoModel.from_pretrained('snunlp/KR-SBERT-V40K-klueNLI-augSTS')
|
73 |
|
74 |
# Tokenize sentences
|
75 |
encoded_input = tokenizer(sentences, padding=True, truncation=True, return_tensors='pt')
|
@@ -85,16 +85,6 @@ print("Sentence embeddings:")
|
|
85 |
print(sentence_embeddings)
|
86 |
```
|
87 |
|
88 |
-
|
89 |
-
|
90 |
-
## Evaluation Results
|
91 |
-
|
92 |
-
<!--- Describe how your model was evaluated -->
|
93 |
-
|
94 |
-
For an automated evaluation of this model, see the *Sentence Embeddings Benchmark*: [https://seb.sbert.net](https://seb.sbert.net?model_name=snunlp/KR-SBERT-V40K-klueNLI-augSTS)
|
95 |
-
|
96 |
-
|
97 |
-
|
98 |
## Full Model Architecture
|
99 |
```
|
100 |
SentenceTransformer(
|
@@ -102,29 +92,3 @@ SentenceTransformer(
|
|
102 |
(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})
|
103 |
)
|
104 |
```
|
105 |
-
|
106 |
-
## Application for document classification
|
107 |
-
|
108 |
-
Tutorial in Google Colab: https://colab.research.google.com/drive/1S6WSjOx9h6Wh_rX1Z2UXwx9i_uHLlOiM
|
109 |
-
|
110 |
-
|
111 |
-
|Model|Accuracy|
|
112 |
-
|-|-|
|
113 |
-
|KR-SBERT-Medium-NLI-STS|0.8400|
|
114 |
-
|KR-SBERT-V40K-NLI-STS|0.8400|
|
115 |
-
|KR-SBERT-V40K-NLI-augSTS|0.8511|
|
116 |
-
|KR-SBERT-V40K-klueNLI-augSTS|**0.8628**|
|
117 |
-
|
118 |
-
|
119 |
-
## Citation
|
120 |
-
|
121 |
-
```bibtex
|
122 |
-
@misc{kr-sbert,
|
123 |
-
author = {Park, Suzi and Hyopil Shin},
|
124 |
-
title = {KR-SBERT: A Pre-trained Korean-specific Sentence-BERT model},
|
125 |
-
year = {2021},
|
126 |
-
publisher = {GitHub},
|
127 |
-
journal = {GitHub repository},
|
128 |
-
howpublished = {\url{https://github.com/snunlp/KR-SBERT}}
|
129 |
-
}
|
130 |
-
```
|
|
|
22 |
example_title: "Sleepy"
|
23 |
---
|
24 |
|
25 |
+
# marigold334/KR-SBERT-V40K-klueNLI-augSTS-ft
|
26 |
|
27 |
+
SNUNLP lab에서 tuning한 [KR-SBERT](snunlp/KR-SBERT-V40K-klueNLI-augSTS)를 다시 [fine-tuning](https://www.sbert.net/docs/package_reference/losses.html#multiplenegativesrankingloss)한 버전이다.
|
28 |
|
29 |
<!--- Describe your model here -->
|
30 |
|
|
|
42 |
from sentence_transformers import SentenceTransformer
|
43 |
sentences = ["This is an example sentence", "Each sentence is converted"]
|
44 |
|
45 |
+
model = SentenceTransformer('snunlp/KR-SBERT-V40K-klueNLI-augSTS-ft')
|
46 |
embeddings = model.encode(sentences)
|
47 |
print(embeddings)
|
48 |
```
|
|
|
69 |
|
70 |
# Load model from HuggingFace Hub
|
71 |
tokenizer = AutoTokenizer.from_pretrained('snunlp/KR-SBERT-V40K-klueNLI-augSTS')
|
72 |
+
model = AutoModel.from_pretrained('snunlp/KR-SBERT-V40K-klueNLI-augSTS-ft')
|
73 |
|
74 |
# Tokenize sentences
|
75 |
encoded_input = tokenizer(sentences, padding=True, truncation=True, return_tensors='pt')
|
|
|
85 |
print(sentence_embeddings)
|
86 |
```
|
87 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
88 |
## Full Model Architecture
|
89 |
```
|
90 |
SentenceTransformer(
|
|
|
92 |
(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})
|
93 |
)
|
94 |
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|