ipatate
commited on
Commit
·
41aeba4
1
Parent(s):
4abc5f4
pass to safetensor
Browse files- README.md +2 -5
- config.json +2 -2
- pytorch_model.bin → model.safetensors +0 -0
README.md
CHANGED
@@ -16,16 +16,13 @@ This model is fine-tuned from `microsoft/Multilingual-MiniLM-L12-H384` to classi
|
|
16 |
|
17 |
This model is fine-tuned from `microsoft/Multilingual-MiniLM-L12-H384` to classify email subjects as SPAM or NOSPAM.
|
18 |
|
19 |
-
### Loading the model
|
20 |
-
To load this model, ensure you specify `from_safetensors=True`:
|
21 |
-
|
22 |
```python
|
23 |
from transformers import AutoTokenizer, AutoModelForSequenceClassification
|
24 |
|
25 |
model_name = "Goodmotion/spam-mail-classifier"
|
26 |
tokenizer = AutoTokenizer.from_pretrained(model_name)
|
27 |
model = AutoModelForSequenceClassification.from_pretrained(
|
28 |
-
model_name
|
29 |
)
|
30 |
|
31 |
text = "Félicitations ! Vous avez gagné un iPhone."
|
@@ -43,7 +40,7 @@ from transformers import AutoTokenizer, AutoModelForSequenceClassification
|
|
43 |
model_name = "Goodmotion/spam-mail-classifier"
|
44 |
|
45 |
tokenizer = AutoTokenizer.from_pretrained(model_name)
|
46 |
-
model = AutoModelForSequenceClassification.from_pretrained(model_name
|
47 |
|
48 |
texts = [
|
49 |
'Join us for a webinar on AI innovations',
|
|
|
16 |
|
17 |
This model is fine-tuned from `microsoft/Multilingual-MiniLM-L12-H384` to classify email subjects as SPAM or NOSPAM.
|
18 |
|
|
|
|
|
|
|
19 |
```python
|
20 |
from transformers import AutoTokenizer, AutoModelForSequenceClassification
|
21 |
|
22 |
model_name = "Goodmotion/spam-mail-classifier"
|
23 |
tokenizer = AutoTokenizer.from_pretrained(model_name)
|
24 |
model = AutoModelForSequenceClassification.from_pretrained(
|
25 |
+
model_name
|
26 |
)
|
27 |
|
28 |
text = "Félicitations ! Vous avez gagné un iPhone."
|
|
|
40 |
model_name = "Goodmotion/spam-mail-classifier"
|
41 |
|
42 |
tokenizer = AutoTokenizer.from_pretrained(model_name)
|
43 |
+
model = AutoModelForSequenceClassification.from_pretrained(model_name)
|
44 |
|
45 |
texts = [
|
46 |
'Join us for a webinar on AI innovations',
|
config.json
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
-
size
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:e1f5d888b080781be08c900cb8478a9024c698e80161535b4112b298674d6539
|
3 |
+
size 769
|
pytorch_model.bin → model.safetensors
RENAMED
File without changes
|