Update README.md
Browse files
README.md
CHANGED
@@ -15,35 +15,18 @@ widget:
|
|
15 |
<!-- This model card has been generated automatically according to the information Keras had access to. You should
|
16 |
probably proofread and complete it, then remove this comment. -->
|
17 |
|
18 |
-
#
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
More information needed
|
31 |
-
|
32 |
-
## Training and evaluation data
|
33 |
-
|
34 |
-
More information needed
|
35 |
-
|
36 |
-
## Training procedure
|
37 |
-
|
38 |
-
### Training hyperparameters
|
39 |
-
|
40 |
-
The following hyperparameters were used during training:
|
41 |
-
- optimizer: None
|
42 |
-
- training_precision: float32
|
43 |
-
|
44 |
-
### Training results
|
45 |
-
|
46 |
-
|
47 |
|
48 |
### Framework versions
|
49 |
|
|
|
15 |
<!-- This model card has been generated automatically according to the information Keras had access to. You should
|
16 |
probably proofread and complete it, then remove this comment. -->
|
17 |
|
18 |
+
# use transformers pipeline
|
19 |
+
```python
|
20 |
+
from transformers import pipeline
|
21 |
+
pipe = pipeline("text-classification", model="jiechau/adult-content-classifier")
|
22 |
+
|
23 |
+
q = '男平織運動外套-立領外套 慢跑 路跑 藍黑螢光黃 L'
|
24 |
+
q = '情趣睡衣 性感睡衣 角色扮演 惹火 緊身連身 漆皮膠衣 黑 L'
|
25 |
+
|
26 |
+
result = pipe(q)
|
27 |
+
print(result)
|
28 |
+
# [{'label': '成人商品', 'score': 0.9994813799858093}]
|
29 |
+
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
30 |
|
31 |
### Framework versions
|
32 |
|