Add SetFit model
Browse files- README.md +14 -14
- config.json +1 -1
- config_setfit.json +2 -2
- model.safetensors +1 -1
- model_head.pkl +1 -1
README.md
CHANGED
@@ -1,5 +1,5 @@
|
|
1 |
---
|
2 |
-
base_model: akhooli/
|
3 |
library_name: setfit
|
4 |
metrics:
|
5 |
- accuracy
|
@@ -35,7 +35,7 @@ widget:
|
|
35 |
فالفندق
|
36 |
inference: true
|
37 |
model-index:
|
38 |
-
- name: SetFit with akhooli/
|
39 |
results:
|
40 |
- task:
|
41 |
type: text-classification
|
@@ -46,13 +46,13 @@ model-index:
|
|
46 |
split: test
|
47 |
metrics:
|
48 |
- type: accuracy
|
49 |
-
value: 0.
|
50 |
name: Accuracy
|
51 |
---
|
52 |
|
53 |
-
# SetFit with akhooli/
|
54 |
|
55 |
-
This is a [SetFit](https://github.com/huggingface/setfit) model that can be used for Text Classification. This SetFit model uses [akhooli/
|
56 |
|
57 |
The model has been trained using an efficient few-shot learning technique that involves:
|
58 |
|
@@ -63,7 +63,7 @@ The model has been trained using an efficient few-shot learning technique that i
|
|
63 |
|
64 |
### Model Description
|
65 |
- **Model Type:** SetFit
|
66 |
-
- **Sentence Transformer body:** [akhooli/
|
67 |
- **Classification head:** a [LogisticRegression](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LogisticRegression.html) instance
|
68 |
- **Maximum Sequence Length:** 512 tokens
|
69 |
- **Number of Classes:** 3 classes
|
@@ -89,7 +89,7 @@ The model has been trained using an efficient few-shot learning technique that i
|
|
89 |
### Metrics
|
90 |
| Label | Accuracy |
|
91 |
|:--------|:---------|
|
92 |
-
| **all** | 0.
|
93 |
|
94 |
## Uses
|
95 |
|
@@ -145,12 +145,12 @@ preds = model("مكان راحه البال . المكان نظيف جدا وم
|
|
145 |
|
146 |
| Label | Training Sample Count |
|
147 |
|:---------|:----------------------|
|
|
|
148 |
| Negative | 8 |
|
149 |
| Positive | 8 |
|
150 |
-
| Mixed | 8 |
|
151 |
|
152 |
### Training Hyperparameters
|
153 |
-
- batch_size: (
|
154 |
- num_epochs: (4, 4)
|
155 |
- max_steps: -1
|
156 |
- sampling_strategy: oversampling
|
@@ -170,11 +170,11 @@ preds = model("مكان راحه البال . المكان نظيف جدا وم
|
|
170 |
### Training Results
|
171 |
| Epoch | Step | Training Loss | Validation Loss |
|
172 |
|:------:|:----:|:-------------:|:---------------:|
|
173 |
-
| 0.
|
174 |
-
| 1.0 |
|
175 |
-
| 2.0 |
|
176 |
-
| 3.0 |
|
177 |
-
| 4.0 |
|
178 |
|
179 |
### Framework Versions
|
180 |
- Python: 3.10.14
|
|
|
1 |
---
|
2 |
+
base_model: akhooli/Arabic-SBERT-100K
|
3 |
library_name: setfit
|
4 |
metrics:
|
5 |
- accuracy
|
|
|
35 |
فالفندق
|
36 |
inference: true
|
37 |
model-index:
|
38 |
+
- name: SetFit with akhooli/Arabic-SBERT-100K
|
39 |
results:
|
40 |
- task:
|
41 |
type: text-classification
|
|
|
46 |
split: test
|
47 |
metrics:
|
48 |
- type: accuracy
|
49 |
+
value: 0.5005050505050505
|
50 |
name: Accuracy
|
51 |
---
|
52 |
|
53 |
+
# SetFit with akhooli/Arabic-SBERT-100K
|
54 |
|
55 |
+
This is a [SetFit](https://github.com/huggingface/setfit) model that can be used for Text Classification. This SetFit model uses [akhooli/Arabic-SBERT-100K](https://huggingface.co/akhooli/Arabic-SBERT-100K) 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.
|
56 |
|
57 |
The model has been trained using an efficient few-shot learning technique that involves:
|
58 |
|
|
|
63 |
|
64 |
### Model Description
|
65 |
- **Model Type:** SetFit
|
66 |
+
- **Sentence Transformer body:** [akhooli/Arabic-SBERT-100K](https://huggingface.co/akhooli/Arabic-SBERT-100K)
|
67 |
- **Classification head:** a [LogisticRegression](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LogisticRegression.html) instance
|
68 |
- **Maximum Sequence Length:** 512 tokens
|
69 |
- **Number of Classes:** 3 classes
|
|
|
89 |
### Metrics
|
90 |
| Label | Accuracy |
|
91 |
|:--------|:---------|
|
92 |
+
| **all** | 0.5005 |
|
93 |
|
94 |
## Uses
|
95 |
|
|
|
145 |
|
146 |
| Label | Training Sample Count |
|
147 |
|:---------|:----------------------|
|
148 |
+
| Mixed | 8 |
|
149 |
| Negative | 8 |
|
150 |
| Positive | 8 |
|
|
|
151 |
|
152 |
### Training Hyperparameters
|
153 |
+
- batch_size: (32, 32)
|
154 |
- num_epochs: (4, 4)
|
155 |
- max_steps: -1
|
156 |
- sampling_strategy: oversampling
|
|
|
170 |
### Training Results
|
171 |
| Epoch | Step | Training Loss | Validation Loss |
|
172 |
|:------:|:----:|:-------------:|:---------------:|
|
173 |
+
| 0.1667 | 1 | 0.2506 | - |
|
174 |
+
| 1.0 | 6 | - | 0.2707 |
|
175 |
+
| 2.0 | 12 | - | 0.2555 |
|
176 |
+
| 3.0 | 18 | - | 0.2677 |
|
177 |
+
| 4.0 | 24 | - | 0.2754 |
|
178 |
|
179 |
### Framework Versions
|
180 |
- Python: 3.10.14
|
config.json
CHANGED
@@ -1,5 +1,5 @@
|
|
1 |
{
|
2 |
-
"_name_or_path": "akhooli/
|
3 |
"architectures": [
|
4 |
"BertModel"
|
5 |
],
|
|
|
1 |
{
|
2 |
+
"_name_or_path": "akhooli/Arabic-SBERT-100K",
|
3 |
"architectures": [
|
4 |
"BertModel"
|
5 |
],
|
config_setfit.json
CHANGED
@@ -1,8 +1,8 @@
|
|
1 |
{
|
2 |
"normalize_embeddings": false,
|
3 |
"labels": [
|
|
|
4 |
"Negative",
|
5 |
-
"Positive"
|
6 |
-
"Mixed"
|
7 |
]
|
8 |
}
|
|
|
1 |
{
|
2 |
"normalize_embeddings": false,
|
3 |
"labels": [
|
4 |
+
"Mixed",
|
5 |
"Negative",
|
6 |
+
"Positive"
|
|
|
7 |
]
|
8 |
}
|
model.safetensors
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
size 540795752
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:1a56c33d50e4ea6defd40d5c06e9feb367b7d6e473eb03e975cf65f772deab63
|
3 |
size 540795752
|
model_head.pkl
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
size 19375
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:5f4e48c683cb7411d3312fb65609c7d3b5ee2bfba3b96357f2e84b85a38abad1
|
3 |
size 19375
|