ginkgogo commited on
Commit
88ee448
1 Parent(s): 4442ca2

Add SetFit ABSA model

Browse files
Files changed (4) hide show
  1. README.md +68 -66
  2. config.json +2 -2
  3. model.safetensors +1 -1
  4. model_head.pkl +1 -1
README.md CHANGED
@@ -9,51 +9,54 @@ tags:
9
  metrics:
10
  - accuracy
11
  widget:
12
- - text: 'Wifi:Go get your coffee on.
13
-
14
- Hey the coffee was strong, so what else?
15
-
16
- Easy FWY on/off access
17
-
18
- Close the beach
19
-
20
- Other food choice nearby
21
-
22
- Smaller starbucks, with less seating both indoors and outdoors
23
-
24
- Wifi was slow at the time'
25
- - text: "place:Stopped by after a long day visit to Santa Barbara. There were few\
26
- \ different places near by but remembering that 'smaller place with limited menu'\
27
- \ has 70/30 chance of being better than a big place with big menu. It's generally\
28
- \ a good ratio to keep in mind, and depending on the category of food, like sushi,\
29
- \ it leans to a higher ratio like 80/20. \n\nOther places may have better seating\
30
- \ and views, but I believe this place has better food. Their clam chowder was\
31
- \ the best I've had so far in California (been here only for 5 months, I'm just\
32
- \ getting started). Their 2 options of fresh oysters were good choices. Their\
33
- \ lemonade was good and sweet. I just wished their shrimp cocktail came with more\
34
- \ ...Cocktail. (Easy fix, just ask for more)"
35
- - text: "evening:Three reasons why it gets three stars:\n\n1. The crab cakes were\
36
- \ good and is a definitely must try!\n2. The shrimp scampi was actually amazing\
37
- \ in the sauce that it comes with, so that's another must try!\n3. The real reason\
38
- \ why it is getting three stars is because service is everything in ANY restaurant\
39
- \ you go to. Service started off great, waitress was attentive, but once we paid\
40
- \ the bill and left a 20% tip, my guests and I, which was only three of us, stayed\
41
- \ at the table to finish our drinks and we're looking at funny videos from a trip\
42
- \ we went to. Point is the waitress rudely told my friend to lower the volume\
43
- \ on his phone, yet other guests were just as loud and we were sitting OUTSIDE...where\
44
- \ it is already a loud environment! \n\nI really want to give it 4 stars, but\
45
- \ if I give 4 stars it changes it to, \"Yay! I'm a fan\", but I am not. The only\
46
- \ reason why it's not getting 1 star, is because the food was decent, the view\
47
- \ is nice and also the manager was extremely empathetic to the situation and it\
48
- \ wasn't her fault at all that her waitress was obviously having an off day. I\
49
- \ have never met a manager that attentive and she was incredible at handling and\
50
- \ diffusing the situation. I cannot thank her enough for salvaging the rest of\
51
- \ our evening for how poor the waitress treated paying customers."
52
- - text: Mediterranean:Pretty good food, just had a wrap and it was delicious pretty
53
- much on Mediterranean or Greek style food around here. Petra's who had really
54
- good Greek dinners closed
55
- - text: sauce:The chicken made worth the waiting, my mild sauce was awesome, the honey
56
- mustard my favorite
 
 
 
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.9602649006622517
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.9603 |
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 | 200.4733 | 491 |
179
 
180
  | Label | Training Sample Count |
181
  |:----------|:----------------------|
182
- | no aspect | 411 |
183
- | aspect | 20 |
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.2706 | - |
206
- | 0.0147 | 50 | 0.2856 | 0.3049 |
207
- | 0.0294 | 100 | 0.2817 | 0.2904 |
208
- | 0.0442 | 150 | 0.2453 | 0.2837 |
209
- | 0.0589 | 200 | 0.2637 | 0.2756 |
210
- | 0.0736 | 250 | 0.199 | 0.2668 |
211
- | 0.0883 | 300 | 0.1917 | 0.2523 |
212
- | 0.1031 | 350 | 0.1071 | 0.1889 |
213
- | 0.1178 | 400 | 0.049 | 0.0826 |
214
- | **0.1325** | **450** | **0.022** | **0.0718** |
215
- | 0.1472 | 500 | 0.0275 | 0.0767 |
216
- | 0.1620 | 550 | 0.0152 | 0.0779 |
217
- | 0.1767 | 600 | 0.0185 | 0.0905 |
218
- | 0.1914 | 650 | 0.0044 | 0.0785 |
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.39.1
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/step_450",
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.39.1",
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:e9d06919a73b192295c0113d0b1353a8d70beba101c5c6668307cc8ea0ee22d6
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:9068d01421488717eeca7e48762fa2dcb717a2d9dd6b4be4e3851edf3c600a96
3
  size 3919
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:bea6b3947fdff0d923557939878c49e5648729c8a250e8e97b64dd03ae886aba
3
  size 3919