vidhi0206 commited on
Commit
1844c6b
1 Parent(s): eaafdc5

Add SetFit model

Browse files
Files changed (4) hide show
  1. README.md +31 -25
  2. config_setfit.json +2 -2
  3. model.safetensors +1 -1
  4. model_head.pkl +2 -2
README.md CHANGED
@@ -8,18 +8,13 @@ tags:
8
  metrics:
9
  - accuracy
10
  widget:
11
- - text: '"She sums up this theme with this pithy quote: \\\\\The first two letters
12
- of Fundamentalist are F-U.\\\\\"" However, these are the parents who drop everything
13
- to spend weeks caring for her when she is near death and all the friends from
14
- her newly emancipated life are missing in action."""'
15
- - text: This was a christmas gift for my son , he couldn't wait to get it home and
16
- set it up and watch movies and play video games on it...when he did he was speachless.
17
- - text: The shorts are made out of a good, durable material but not so stiff that
18
- you feel like you can't move.
19
- - text: The only problem I knew I was going to have upfront was on the reciever end
20
- of things as I needed an extra set of speaker outputs,but the Monoprice 4ch speaker
21
- selector (#9995) took care of that deal.
22
- - text: This book is so good, I have to rave!
23
  pipeline_tag: text-classification
24
  inference: true
25
  base_model: sentence-transformers/paraphrase-mpnet-base-v2
@@ -35,7 +30,7 @@ model-index:
35
  split: test
36
  metrics:
37
  - type: accuracy
38
- value: 0.7018
39
  name: Accuracy
40
  ---
41
 
@@ -55,7 +50,7 @@ The model has been trained using an efficient few-shot learning technique that i
55
  - **Sentence Transformer body:** [sentence-transformers/paraphrase-mpnet-base-v2](https://huggingface.co/sentence-transformers/paraphrase-mpnet-base-v2)
56
  - **Classification head:** a [LogisticRegression](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LogisticRegression.html) instance
57
  - **Maximum Sequence Length:** 512 tokens
58
- - **Number of Classes:** 2 classes
59
  <!-- - **Training Dataset:** [Unknown](https://huggingface.co/datasets/unknown) -->
60
  <!-- - **Language:** Unknown -->
61
  <!-- - **License:** Unknown -->
@@ -67,17 +62,21 @@ The model has been trained using an efficient few-shot learning technique that i
67
  - **Blogpost:** [SetFit: Efficient Few-Shot Learning Without Prompts](https://huggingface.co/blog/setfit)
68
 
69
  ### Model Labels
70
- | Label | Examples |
71
- |:------|:---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
72
- | 0 | <ul><li>'Bank and Gaza city of thompson falls in love with your kindle fire and rescue plan for the most important thing is the kindle fire department for sure to check it out for sure to use none of them'</li><li>"I really wanted green, really wanted beige, really wanted white didn't get any of those colors I got grey brown red instead."</li><li>'My only complaint is that I would like more colours please!!!'</li></ul> |
73
- | 1 | <ul><li>'I WOULD BUY MORE IN THE FUTURE FOR MY OWN REAL TREE.'</li><li>'I had to give this item one star but if there was a negative 5 star rating I would have chosen that.'</li><li>'The only thing I would have like for it to have a hole in the middle so I can put the stopper in without removing the mat.'</li></ul> |
 
 
 
 
74
 
75
  ## Evaluation
76
 
77
  ### Metrics
78
  | Label | Accuracy |
79
  |:--------|:---------|
80
- | **all** | 0.7018 |
81
 
82
  ## Uses
83
 
@@ -97,7 +96,7 @@ from setfit import SetFitModel
97
  # Download from the 🤗 Hub
98
  model = SetFitModel.from_pretrained("vidhi0206/setfit-paraphrase-mpnet-amazoncf")
99
  # Run inference
100
- preds = model("This book is so good, I have to rave!")
101
  ```
102
 
103
  <!--
@@ -127,14 +126,18 @@ preds = model("This book is so good, I have to rave!")
127
  ## Training Details
128
 
129
  ### Training Set Metrics
130
- | Training set | Min | Median | Max |
131
- |:-------------|:----|:-------|:----|
132
- | Word count | 9 | 19.875 | 39 |
133
 
134
  | Label | Training Sample Count |
135
  |:------|:----------------------|
136
  | 0 | 8 |
137
  | 1 | 8 |
 
 
 
 
138
 
139
  ### Training Hyperparameters
140
  - batch_size: (8, 8)
@@ -157,8 +160,11 @@ preds = model("This book is so good, I have to rave!")
157
  ### Training Results
158
  | Epoch | Step | Training Loss | Validation Loss |
159
  |:------:|:----:|:-------------:|:---------------:|
160
- | 0.0125 | 1 | 0.1979 | - |
161
- | 0.625 | 50 | 0.0022 | - |
 
 
 
162
 
163
  ### Framework Versions
164
  - Python: 3.8.10
 
8
  metrics:
9
  - accuracy
10
  widget:
11
+ - text: i honestly thought impossible at this point i feel pretty
12
+ - text: i feel convinced that im going to shy away from whatever is really good for
13
+ me
14
+ - text: i feel guilt that i should be more caring and im not
15
+ - text: i found myself feeling nostalgic as i thought about the temporarily abandoned
16
+ little bishop chronicles
17
+ - text: i am feeling very indecisive and spontaneous
 
 
 
 
 
18
  pipeline_tag: text-classification
19
  inference: true
20
  base_model: sentence-transformers/paraphrase-mpnet-base-v2
 
30
  split: test
31
  metrics:
32
  - type: accuracy
33
+ value: 0.439
34
  name: Accuracy
35
  ---
36
 
 
50
  - **Sentence Transformer body:** [sentence-transformers/paraphrase-mpnet-base-v2](https://huggingface.co/sentence-transformers/paraphrase-mpnet-base-v2)
51
  - **Classification head:** a [LogisticRegression](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LogisticRegression.html) instance
52
  - **Maximum Sequence Length:** 512 tokens
53
+ - **Number of Classes:** 6 classes
54
  <!-- - **Training Dataset:** [Unknown](https://huggingface.co/datasets/unknown) -->
55
  <!-- - **Language:** Unknown -->
56
  <!-- - **License:** Unknown -->
 
62
  - **Blogpost:** [SetFit: Efficient Few-Shot Learning Without Prompts](https://huggingface.co/blog/setfit)
63
 
64
  ### Model Labels
65
+ | Label | Examples |
66
+ |:------|:---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
67
+ | 4 | <ul><li>'i feel kind of strange'</li><li>'i am feeling pretty restless right now while typing this'</li><li>'i feel pressured when people say im going t beat you or whatever'</li></ul> |
68
+ | 3 | <ul><li>'i feel cranky and annoyed when i dont'</li><li>'i feel i did some thing impolite katanya'</li><li>'i feel like i should be offended but yawwwn'</li></ul> |
69
+ | 5 | <ul><li>'i was feeling an act of god at work in my life and it was an amazing feeling'</li><li>'i tween sat for my moms boss year old and year old boys this weekend id say babysit but that feels weird considering there were n'</li><li>'i started feeling funny and then friday i woke up sick as a dog'</li></ul> |
70
+ | 0 | <ul><li>'i am from new jersey and this first drink was consumed at a post prom party so i feel it s appropriately lame'</li><li>'i feel inside cause life is like a game sometimes then you came around me the walls just disappeared nothing to surround me and keep me from my fears im unprotected see how ive opened up oh youve made me trust cause ive never felt like this before im naked around you does it show'</li><li>'i cant believe with that statement being said that im already feeling sexually deprived'</li></ul> |
71
+ | 2 | <ul><li>'i suddenly feel that this is more than a sweet love song that every girls could sing in front of their boyfriends'</li><li>'i really wish i had the courage to drag a blade across my skin i wish i could do it i wish i could see the blood and feel that sweet release as it starts to pour out of my flesh and down my body'</li><li>'im sure they feel the more caring loving people in the kids lives the better'</li></ul> |
72
+ | 1 | <ul><li>'i am not feeling particularly creative'</li><li>'id probably go with none on and hope that my date admires a confident girl who feels fine without makeup'</li><li>'i woke on saturday feeling a little brighter and was very keen to get outdoors after spending all day friday wallowing in self pity'</li></ul> |
73
 
74
  ## Evaluation
75
 
76
  ### Metrics
77
  | Label | Accuracy |
78
  |:--------|:---------|
79
+ | **all** | 0.439 |
80
 
81
  ## Uses
82
 
 
96
  # Download from the 🤗 Hub
97
  model = SetFitModel.from_pretrained("vidhi0206/setfit-paraphrase-mpnet-amazoncf")
98
  # Run inference
99
+ preds = model("i am feeling very indecisive and spontaneous")
100
  ```
101
 
102
  <!--
 
126
  ## Training Details
127
 
128
  ### Training Set Metrics
129
+ | Training set | Min | Median | Max |
130
+ |:-------------|:----|:--------|:----|
131
+ | Word count | 4 | 17.6458 | 55 |
132
 
133
  | Label | Training Sample Count |
134
  |:------|:----------------------|
135
  | 0 | 8 |
136
  | 1 | 8 |
137
+ | 2 | 8 |
138
+ | 3 | 8 |
139
+ | 4 | 8 |
140
+ | 5 | 8 |
141
 
142
  ### Training Hyperparameters
143
  - batch_size: (8, 8)
 
160
  ### Training Results
161
  | Epoch | Step | Training Loss | Validation Loss |
162
  |:------:|:----:|:-------------:|:---------------:|
163
+ | 0.0042 | 1 | 0.2972 | - |
164
+ | 0.2083 | 50 | 0.1452 | - |
165
+ | 0.4167 | 100 | 0.0452 | - |
166
+ | 0.625 | 150 | 0.0085 | - |
167
+ | 0.8333 | 200 | 0.0011 | - |
168
 
169
  ### Framework Versions
170
  - Python: 3.8.10
config_setfit.json CHANGED
@@ -1,4 +1,4 @@
1
  {
2
- "labels": null,
3
- "normalize_embeddings": false
4
  }
 
1
  {
2
+ "normalize_embeddings": false,
3
+ "labels": null
4
  }
model.safetensors CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:e387cf2fc21345adeca754210c1fa63e69432279892bf6f5cca41406c20bdf69
3
  size 437967672
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:8553bfa05ce749a7010a57a4d0b20bff04b969b5fdc6413b47d22891a6ca9db6
3
  size 437967672
model_head.pkl CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:1386ef67f86c97814c5157951eb1fcb2595b5b1a1fe627359d8ec7df67e03123
3
- size 6991
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:39280de3dcf2dda1aa46cfec6d4343b1230b26c29b75fa471b5e02a8e663f299
3
+ size 37783