Add SetFit model
Browse files- README.md +75 -75
- model.safetensors +1 -1
- model_head.pkl +1 -1
README.md
CHANGED
@@ -10,11 +10,11 @@ tags:
|
|
10 |
- text-classification
|
11 |
- generated_from_setfit_trainer
|
12 |
widget:
|
13 |
-
- text:
|
14 |
-
- text:
|
15 |
-
- text:
|
16 |
-
- text:
|
17 |
-
- text:
|
18 |
inference: true
|
19 |
model-index:
|
20 |
- name: SetFit with BAAI/bge-large-en-v1.5
|
@@ -28,7 +28,7 @@ model-index:
|
|
28 |
split: test
|
29 |
metrics:
|
30 |
- type: accuracy
|
31 |
-
value: 0.
|
32 |
name: Accuracy
|
33 |
---
|
34 |
|
@@ -60,22 +60,22 @@ The model has been trained using an efficient few-shot learning technique that i
|
|
60 |
- **Blogpost:** [SetFit: Efficient Few-Shot Learning Without Prompts](https://huggingface.co/blog/setfit)
|
61 |
|
62 |
### Model Labels
|
63 |
-
| Label | Examples
|
64 |
-
|
65 |
-
| Aggregation | <ul><li>'
|
66 |
-
|
|
67 |
-
|
|
68 |
-
|
|
69 |
-
|
|
70 |
-
| Generalreply | <ul><li>"
|
71 |
-
|
|
72 |
|
73 |
## Evaluation
|
74 |
|
75 |
### Metrics
|
76 |
| Label | Accuracy |
|
77 |
|:--------|:---------|
|
78 |
-
| **all** | 0.
|
79 |
|
80 |
## Uses
|
81 |
|
@@ -95,7 +95,7 @@ from setfit import SetFitModel
|
|
95 |
# Download from the 🤗 Hub
|
96 |
model = SetFitModel.from_pretrained("nazhan/bge-large-en-v1.5-brahmaputra-iter-10-3rd")
|
97 |
# Run inference
|
98 |
-
preds = model("
|
99 |
```
|
100 |
|
101 |
<!--
|
@@ -127,17 +127,17 @@ preds = model("Show me average asset value.")
|
|
127 |
### Training Set Metrics
|
128 |
| Training set | Min | Median | Max |
|
129 |
|:-------------|:----|:-------|:----|
|
130 |
-
| Word count | 1 | 8.
|
131 |
|
132 |
| Label | Training Sample Count |
|
133 |
|:-------------|:----------------------|
|
134 |
-
| Tablejoin |
|
135 |
-
| Rejection |
|
136 |
-
| Aggregation |
|
137 |
-
| Lookup |
|
138 |
-
| Generalreply |
|
139 |
-
| Viewtables |
|
140 |
-
| Lookup_1 |
|
141 |
|
142 |
### Training Hyperparameters
|
143 |
- batch_size: (16, 16)
|
@@ -159,56 +159,56 @@ preds = model("Show me average asset value.")
|
|
159 |
### Training Results
|
160 |
| Epoch | Step | Training Loss | Validation Loss |
|
161 |
|:----------:|:--------:|:-------------:|:---------------:|
|
162 |
-
| 0.0000 | 1 | 0.
|
163 |
-
| 0.
|
164 |
-
| 0.
|
165 |
-
| 0.
|
166 |
-
| 0.
|
167 |
-
| 0.
|
168 |
-
| 0.
|
169 |
-
| 0.
|
170 |
-
| 0.
|
171 |
-
| 0.
|
172 |
-
| 0.
|
173 |
-
| 0.
|
174 |
-
| 0.
|
175 |
-
| 0.
|
176 |
-
| 0.
|
177 |
-
| 0.
|
178 |
-
| 0.
|
179 |
-
| 0.
|
180 |
-
| 0.
|
181 |
-
| 0.
|
182 |
-
| 0.
|
183 |
-
| 0.
|
184 |
-
| 0.
|
185 |
-
| 0.
|
186 |
-
| 0.
|
187 |
-
| 0.
|
188 |
-
| 0.
|
189 |
-
| 0.
|
190 |
-
| 0.
|
191 |
-
| 0.
|
192 |
-
| 0.
|
193 |
-
| 0.
|
194 |
-
| 0.
|
195 |
-
| 0.
|
196 |
-
| 0.
|
197 |
-
| 0.
|
198 |
-
| 0.
|
199 |
-
| 0.
|
200 |
-
| 0.
|
201 |
-
| 0.
|
202 |
-
| 0.
|
203 |
-
| 0.
|
204 |
-
| 0.
|
205 |
-
| 0.
|
206 |
-
| 0.
|
207 |
-
| 0.
|
208 |
-
| 0.
|
209 |
-
| 0.
|
210 |
-
| 0.
|
211 |
-
| **0.
|
212 |
|
213 |
* The bold row denotes the saved checkpoint.
|
214 |
### Framework Versions
|
|
|
10 |
- text-classification
|
11 |
- generated_from_setfit_trainer
|
12 |
widget:
|
13 |
+
- text: I don't want to handle any filtering tasks.
|
14 |
+
- text: Show me all customers who have the last name 'Doe'.
|
15 |
+
- text: What tables are available for data analysis in starhub_data_asset?
|
16 |
+
- text: what do you think it is?
|
17 |
+
- text: Provide data_asset_001_pcc product category details.
|
18 |
inference: true
|
19 |
model-index:
|
20 |
- name: SetFit with BAAI/bge-large-en-v1.5
|
|
|
28 |
split: test
|
29 |
metrics:
|
30 |
- type: accuracy
|
31 |
+
value: 0.9818181818181818
|
32 |
name: Accuracy
|
33 |
---
|
34 |
|
|
|
60 |
- **Blogpost:** [SetFit: Efficient Few-Shot Learning Without Prompts](https://huggingface.co/blog/setfit)
|
61 |
|
62 |
### Model Labels
|
63 |
+
| Label | Examples |
|
64 |
+
|:-------------|:----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
65 |
+
| Aggregation | <ul><li>'Show me median Intangible Assets'</li><li>'Can I have sum Cost_Entertainment?'</li><li>'Get me min RevenueVariance_Actual_vs_Forecast.'</li></ul> |
|
66 |
+
| Lookup_1 | <ul><li>'Show me data_asset_kpi_cf details.'</li><li>'Retrieve data_asset_kpi_cf details.'</li><li>'Show M&A deal size by sector.'</li></ul> |
|
67 |
+
| Viewtables | <ul><li>'What tables are included in the starhub_data_asset database that are required for performing a basic data analysis?'</li><li>'What is the full list of tables available for use in queries within the starhub_data_asset database?'</li><li>'What are the table names within the starhub_data_asset database that enable data analysis of customer feedback?'</li></ul> |
|
68 |
+
| Tablejoin | <ul><li>'Is it possible to merge the Employees and Orders tables to see which employee handled each order?'</li><li>'Join data_asset_001_ta with data_asset_kpi_cf.'</li><li>'How can I connect the Customers and Orders tables to find customers who made purchases during a specific promotion?'</li></ul> |
|
69 |
+
| Lookup | <ul><li>'Filter by customers who have placed more than 3 orders and get me their email addresses.'</li><li>"Filter by customers in the city 'New York' and show me their phone numbers."</li><li>"Can you filter by employees who work in the 'Research' department?"</li></ul> |
|
70 |
+
| Generalreply | <ul><li>"Oh, I just stepped outside and it's actually quite lovely! The sun is shining and there's a light breeze. How about you?"</li><li>"One of my short-term goals is to learn a new skill, like coding or cooking. I also want to save up enough money for a weekend trip with friends. How about you, any short-term goals you're working towards?"</li><li>'Hey! My day is going pretty well, thanks for asking. How about yours?'</li></ul> |
|
71 |
+
| Rejection | <ul><li>'I have no interest in generating more data.'</li><li>"I don't want to engage in filtering operations."</li><li>"I'd rather not filter this dataset."</li></ul> |
|
72 |
|
73 |
## Evaluation
|
74 |
|
75 |
### Metrics
|
76 |
| Label | Accuracy |
|
77 |
|:--------|:---------|
|
78 |
+
| **all** | 0.9818 |
|
79 |
|
80 |
## Uses
|
81 |
|
|
|
95 |
# Download from the 🤗 Hub
|
96 |
model = SetFitModel.from_pretrained("nazhan/bge-large-en-v1.5-brahmaputra-iter-10-3rd")
|
97 |
# Run inference
|
98 |
+
preds = model("what do you think it is?")
|
99 |
```
|
100 |
|
101 |
<!--
|
|
|
127 |
### Training Set Metrics
|
128 |
| Training set | Min | Median | Max |
|
129 |
|:-------------|:----|:-------|:----|
|
130 |
+
| Word count | 1 | 8.7137 | 62 |
|
131 |
|
132 |
| Label | Training Sample Count |
|
133 |
|:-------------|:----------------------|
|
134 |
+
| Tablejoin | 128 |
|
135 |
+
| Rejection | 73 |
|
136 |
+
| Aggregation | 222 |
|
137 |
+
| Lookup | 55 |
|
138 |
+
| Generalreply | 75 |
|
139 |
+
| Viewtables | 76 |
|
140 |
+
| Lookup_1 | 157 |
|
141 |
|
142 |
### Training Hyperparameters
|
143 |
- batch_size: (16, 16)
|
|
|
159 |
### Training Results
|
160 |
| Epoch | Step | Training Loss | Validation Loss |
|
161 |
|:----------:|:--------:|:-------------:|:---------------:|
|
162 |
+
| 0.0000 | 1 | 0.2001 | - |
|
163 |
+
| 0.0022 | 50 | 0.1566 | - |
|
164 |
+
| 0.0045 | 100 | 0.0816 | - |
|
165 |
+
| 0.0067 | 150 | 0.0733 | - |
|
166 |
+
| 0.0089 | 200 | 0.0075 | - |
|
167 |
+
| 0.0112 | 250 | 0.0059 | - |
|
168 |
+
| 0.0134 | 300 | 0.0035 | - |
|
169 |
+
| 0.0156 | 350 | 0.0034 | - |
|
170 |
+
| 0.0179 | 400 | 0.0019 | - |
|
171 |
+
| 0.0201 | 450 | 0.0015 | - |
|
172 |
+
| 0.0223 | 500 | 0.0021 | - |
|
173 |
+
| 0.0246 | 550 | 0.003 | - |
|
174 |
+
| 0.0268 | 600 | 0.0021 | - |
|
175 |
+
| 0.0290 | 650 | 0.0011 | - |
|
176 |
+
| 0.0313 | 700 | 0.0015 | - |
|
177 |
+
| 0.0335 | 750 | 0.0011 | - |
|
178 |
+
| 0.0357 | 800 | 0.001 | - |
|
179 |
+
| 0.0380 | 850 | 0.001 | - |
|
180 |
+
| 0.0402 | 900 | 0.0012 | - |
|
181 |
+
| 0.0424 | 950 | 0.0012 | - |
|
182 |
+
| 0.0447 | 1000 | 0.0011 | - |
|
183 |
+
| 0.0469 | 1050 | 0.0008 | - |
|
184 |
+
| 0.0491 | 1100 | 0.0009 | - |
|
185 |
+
| 0.0514 | 1150 | 0.001 | - |
|
186 |
+
| 0.0536 | 1200 | 0.0008 | - |
|
187 |
+
| 0.0558 | 1250 | 0.0011 | - |
|
188 |
+
| 0.0581 | 1300 | 0.0009 | - |
|
189 |
+
| 0.0603 | 1350 | 0.001 | - |
|
190 |
+
| 0.0625 | 1400 | 0.0007 | - |
|
191 |
+
| 0.0647 | 1450 | 0.0008 | - |
|
192 |
+
| 0.0670 | 1500 | 0.0007 | - |
|
193 |
+
| 0.0692 | 1550 | 0.001 | - |
|
194 |
+
| 0.0714 | 1600 | 0.0007 | - |
|
195 |
+
| 0.0737 | 1650 | 0.0007 | - |
|
196 |
+
| 0.0759 | 1700 | 0.0006 | - |
|
197 |
+
| 0.0781 | 1750 | 0.0008 | - |
|
198 |
+
| 0.0804 | 1800 | 0.0006 | - |
|
199 |
+
| 0.0826 | 1850 | 0.0005 | - |
|
200 |
+
| 0.0848 | 1900 | 0.0006 | - |
|
201 |
+
| 0.0871 | 1950 | 0.0005 | - |
|
202 |
+
| 0.0893 | 2000 | 0.0007 | - |
|
203 |
+
| 0.0915 | 2050 | 0.0005 | - |
|
204 |
+
| 0.0938 | 2100 | 0.0006 | - |
|
205 |
+
| 0.0960 | 2150 | 0.0007 | - |
|
206 |
+
| 0.0982 | 2200 | 0.0005 | - |
|
207 |
+
| 0.1005 | 2250 | 0.0008 | - |
|
208 |
+
| 0.1027 | 2300 | 0.0005 | - |
|
209 |
+
| 0.1049 | 2350 | 0.0008 | - |
|
210 |
+
| 0.1072 | 2400 | 0.0007 | - |
|
211 |
+
| **0.1094** | **2450** | **0.0007** | **0.0094** |
|
212 |
|
213 |
* The bold row denotes the saved checkpoint.
|
214 |
### Framework Versions
|
model.safetensors
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
size 1340612432
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:1941e8a083852250f1fd0c92ea0183a452ce351c669ba6ca68cbef16239d867a
|
3 |
size 1340612432
|
model_head.pkl
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
size 58575
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:6c3b0d9c84ab235a2347871b8e1618c39f31a68828768a64307ff479bd0e88d5
|
3 |
size 58575
|