Add SetFit ABSA model
Browse files- README.md +68 -66
- config.json +2 -2
- model.safetensors +1 -1
- model_head.pkl +1 -1
README.md
CHANGED
@@ -9,51 +9,54 @@ tags:
|
|
9 |
metrics:
|
10 |
- accuracy
|
11 |
widget:
|
12 |
-
- text: '
|
13 |
-
|
14 |
-
|
15 |
-
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
- text:
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
|
|
|
|
|
|
57 |
pipeline_tag: text-classification
|
58 |
inference: false
|
59 |
base_model: sentence-transformers/all-MiniLM-L6-v2
|
@@ -69,7 +72,7 @@ model-index:
|
|
69 |
split: test
|
70 |
metrics:
|
71 |
- type: accuracy
|
72 |
-
value: 0.
|
73 |
name: Accuracy
|
74 |
---
|
75 |
|
@@ -120,7 +123,7 @@ This model was trained within the context of a larger system for ABSA, which loo
|
|
120 |
### Metrics
|
121 |
| Label | Accuracy |
|
122 |
|:--------|:---------|
|
123 |
-
| **all** | 0.
|
124 |
|
125 |
## Uses
|
126 |
|
@@ -175,12 +178,12 @@ preds = model("The food was great, but the venue is just way too busy.")
|
|
175 |
### Training Set Metrics
|
176 |
| Training set | Min | Median | Max |
|
177 |
|:-------------|:----|:---------|:----|
|
178 |
-
| Word count | 21 |
|
179 |
|
180 |
| Label | Training Sample Count |
|
181 |
|:----------|:----------------------|
|
182 |
-
| no aspect |
|
183 |
-
| aspect |
|
184 |
|
185 |
### Training Hyperparameters
|
186 |
- batch_size: (50, 50)
|
@@ -202,21 +205,20 @@ preds = model("The food was great, but the venue is just way too busy.")
|
|
202 |
### Training Results
|
203 |
| Epoch | Step | Training Loss | Validation Loss |
|
204 |
|:----------:|:-------:|:-------------:|:---------------:|
|
205 |
-
| 0.0003 | 1 | 0.
|
206 |
-
| 0.
|
207 |
-
| 0.
|
208 |
-
| 0.
|
209 |
-
| 0.
|
210 |
-
| 0.
|
211 |
-
| 0.
|
212 |
-
| 0.
|
213 |
-
| 0.
|
214 |
-
|
|
215 |
-
| 0.
|
216 |
-
| 0.
|
217 |
-
| 0.
|
218 |
-
| 0.
|
219 |
-
| 0.2061 | 700 | 0.008 | 0.0896 |
|
220 |
|
221 |
* The bold row denotes the saved checkpoint.
|
222 |
### Framework Versions
|
@@ -224,7 +226,7 @@ preds = model("The food was great, but the venue is just way too busy.")
|
|
224 |
- SetFit: 1.0.3
|
225 |
- Sentence Transformers: 2.6.0
|
226 |
- spaCy: 3.7.4
|
227 |
-
- Transformers: 4.
|
228 |
- PyTorch: 2.2.1+cu121
|
229 |
- Datasets: 2.18.0
|
230 |
- Tokenizers: 0.15.2
|
|
|
9 |
metrics:
|
10 |
- accuracy
|
11 |
widget:
|
12 |
+
- text: variety:I'm not sure what what I would do if I'd never discovered Nikka, since
|
13 |
+
it's the definitely the most authentic ramen one can get in the area. Prices are
|
14 |
+
standard for ramen (especially in SB) and the service is friendly and efficient.
|
15 |
+
Not only is Nikka's ramen amazing, their variety of appetizers is also great.
|
16 |
+
I've yet to try one that I don't like. Definitely come here if you're looking
|
17 |
+
to satisfy your ramen craving!
|
18 |
+
- text: wrap:Pretty good food, just had a wrap and it was delicious pretty much on
|
19 |
+
Mediterranean or Greek style food around here. Petra's who had really good Greek
|
20 |
+
dinners closed
|
21 |
+
- text: goat cheese:I had the Genoa Salami, Kalamata olive tapenade, with roasted
|
22 |
+
red peppers and goat cheese. I ended up going with this sandwich mainly because
|
23 |
+
I am lactose sensitive and found out that goat cheese is supposed to have less
|
24 |
+
lactose making it easier for the stomach to digest. The goat cheese had a nice
|
25 |
+
smooth and creamy flavor and when combined with the olive tapenade really made
|
26 |
+
a burst of flavor in my mouth. I also had the sandwich on Foccaica bread but they
|
27 |
+
also have three other choices of bread to choose from. Overall the sandwich was
|
28 |
+
delicious. I love the simple clean look of the store and it had some inside seating
|
29 |
+
as well as gated outdoor seating. All the staff members seemed very nice and helpful.
|
30 |
+
The one problem I had with Panino is the price. Although I love the sandwich,
|
31 |
+
I do not believe it is worth $12. When I originally looked up the menu on Yelp
|
32 |
+
I was looking at the pictures that were paired by other reviewers and I saw that
|
33 |
+
they were about $10. $10 still expensive but a little more understandable and
|
34 |
+
worth what you're getting.
|
35 |
+
- text: toppings:FINALLY tried Mizza and wasn't disappointed. Loved (almost) everything
|
36 |
+
we ordered, great atmosphere, excellent service, and the perfect setting for a
|
37 |
+
lovely bday Sunday. The burrata & heirloom tomatoes app was scrumptious, the salmon
|
38 |
+
pasta, very flavorful and the salmon perfectly cooked, I liked the toppings of
|
39 |
+
the veggie pizza but wasn't a super fan of the crust (doesn't mean I won't come
|
40 |
+
back and try another pizza on their menu ) and the cannoli was good although that
|
41 |
+
dessert in general isn't my fave (it was my bf's bday so had to get what he wanted
|
42 |
+
). The flourless chocolate cake and limoncello cake are what I'll try next time.
|
43 |
+
Had a great time and will be back. Gave it 4 stars just cuz I wasn't that excited
|
44 |
+
about the pizza and that's something they're supposed to so well. Would recommend
|
45 |
+
the restaurant though!
|
46 |
+
- text: mouth:I had the Genoa Salami, Kalamata olive tapenade, with roasted red peppers
|
47 |
+
and goat cheese. I ended up going with this sandwich mainly because I am lactose
|
48 |
+
sensitive and found out that goat cheese is supposed to have less lactose making
|
49 |
+
it easier for the stomach to digest. The goat cheese had a nice smooth and creamy
|
50 |
+
flavor and when combined with the olive tapenade really made a burst of flavor
|
51 |
+
in my mouth. I also had the sandwich on Foccaica bread but they also have three
|
52 |
+
other choices of bread to choose from. Overall the sandwich was delicious. I love
|
53 |
+
the simple clean look of the store and it had some inside seating as well as gated
|
54 |
+
outdoor seating. All the staff members seemed very nice and helpful. The one problem
|
55 |
+
I had with Panino is the price. Although I love the sandwich, I do not believe
|
56 |
+
it is worth $12. When I originally looked up the menu on Yelp I was looking at
|
57 |
+
the pictures that were paired by other reviewers and I saw that they were about
|
58 |
+
$10. $10 still expensive but a little more understandable and worth what you're
|
59 |
+
getting.
|
60 |
pipeline_tag: text-classification
|
61 |
inference: false
|
62 |
base_model: sentence-transformers/all-MiniLM-L6-v2
|
|
|
72 |
split: test
|
73 |
metrics:
|
74 |
- type: accuracy
|
75 |
+
value: 0.956989247311828
|
76 |
name: Accuracy
|
77 |
---
|
78 |
|
|
|
123 |
### Metrics
|
124 |
| Label | Accuracy |
|
125 |
|:--------|:---------|
|
126 |
+
| **all** | 0.9570 |
|
127 |
|
128 |
## Uses
|
129 |
|
|
|
178 |
### Training Set Metrics
|
179 |
| Training set | Min | Median | Max |
|
180 |
|:-------------|:----|:---------|:----|
|
181 |
+
| Word count | 21 | 152.7030 | 268 |
|
182 |
|
183 |
| Label | Training Sample Count |
|
184 |
|:----------|:----------------------|
|
185 |
+
| no aspect | 383 |
|
186 |
+
| aspect | 21 |
|
187 |
|
188 |
### Training Hyperparameters
|
189 |
- batch_size: (50, 50)
|
|
|
205 |
### Training Results
|
206 |
| Epoch | Step | Training Loss | Validation Loss |
|
207 |
|:----------:|:-------:|:-------------:|:---------------:|
|
208 |
+
| 0.0003 | 1 | 0.2856 | - |
|
209 |
+
| 0.0169 | 50 | 0.2755 | 0.3092 |
|
210 |
+
| 0.0339 | 100 | 0.2895 | 0.2962 |
|
211 |
+
| 0.0508 | 150 | 0.2845 | 0.2876 |
|
212 |
+
| 0.0678 | 200 | 0.2471 | 0.2826 |
|
213 |
+
| 0.0847 | 250 | 0.2124 | 0.2691 |
|
214 |
+
| 0.1017 | 300 | 0.1357 | 0.184 |
|
215 |
+
| 0.1186 | 350 | 0.0362 | 0.0871 |
|
216 |
+
| **0.1355** | **400** | **0.07** | **0.0848** |
|
217 |
+
| 0.1525 | 450 | 0.0184 | 0.092 |
|
218 |
+
| 0.1694 | 500 | 0.0179 | 0.096 |
|
219 |
+
| 0.1864 | 550 | 0.0033 | 0.097 |
|
220 |
+
| 0.2033 | 600 | 0.0037 | 0.0978 |
|
221 |
+
| 0.2203 | 650 | 0.04 | 0.1046 |
|
|
|
222 |
|
223 |
* The bold row denotes the saved checkpoint.
|
224 |
### Framework Versions
|
|
|
226 |
- SetFit: 1.0.3
|
227 |
- Sentence Transformers: 2.6.0
|
228 |
- spaCy: 3.7.4
|
229 |
+
- Transformers: 4.38.2
|
230 |
- PyTorch: 2.2.1+cu121
|
231 |
- Datasets: 2.18.0
|
232 |
- Tokenizers: 0.15.2
|
config.json
CHANGED
@@ -1,5 +1,5 @@
|
|
1 |
{
|
2 |
-
"_name_or_path": "models/
|
3 |
"architectures": [
|
4 |
"BertModel"
|
5 |
],
|
@@ -19,7 +19,7 @@
|
|
19 |
"pad_token_id": 0,
|
20 |
"position_embedding_type": "absolute",
|
21 |
"torch_dtype": "float32",
|
22 |
-
"transformers_version": "4.
|
23 |
"type_vocab_size": 2,
|
24 |
"use_cache": true,
|
25 |
"vocab_size": 30522
|
|
|
1 |
{
|
2 |
+
"_name_or_path": "models/step_400",
|
3 |
"architectures": [
|
4 |
"BertModel"
|
5 |
],
|
|
|
19 |
"pad_token_id": 0,
|
20 |
"position_embedding_type": "absolute",
|
21 |
"torch_dtype": "float32",
|
22 |
+
"transformers_version": "4.38.2",
|
23 |
"type_vocab_size": 2,
|
24 |
"use_cache": true,
|
25 |
"vocab_size": 30522
|
model.safetensors
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
size 90864192
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:e573a59592709fb620050ee49692c250a6952412960a4daba4c7723ad59ff88e
|
3 |
size 90864192
|
model_head.pkl
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
size 3919
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:bea6b3947fdff0d923557939878c49e5648729c8a250e8e97b64dd03ae886aba
|
3 |
size 3919
|