jiechau commited on
Commit
a9a6eb6
1 Parent(s): a9c5bd5

Upload TFBertForSequenceClassification

Browse files
Files changed (3) hide show
  1. README.md +25 -20
  2. config.json +6 -6
  3. tf_model.h5 +1 -1
README.md CHANGED
@@ -2,14 +2,8 @@
2
  tags:
3
  - generated_from_keras_callback
4
  model-index:
5
- - name: adult-content-classifier-text
6
  results: []
7
- pipeline_tag: text-classification
8
- widget:
9
- - text: "情趣睡衣 性感睡衣 角色扮演 惹火 緊身連身 漆皮膠衣 黑 L"
10
- example_title: "adult_成人商品標題"
11
- - text: "男平織運動外套-立領外套 慢跑 路跑 藍黑螢光黃 L"
12
- example_title: "regular_一般商品標題"
13
  ---
14
 
15
  <!-- This model card has been generated automatically according to the information Keras had access to. You should
@@ -17,26 +11,37 @@ probably proofread and complete it, then remove this comment. -->
17
 
18
  # adult-content-identify-text
19
 
20
- Determine whether online sales products are adult content. Input: product title or description, Output results: 0 Unknown, 1 Adult Content, 2 General Merchandise.
 
21
 
22
- 判斷網路銷售商品是否屬於成人內容。輸入: 商品名稱文字,輸出結果: 0 未知, 1 成人內容, 2 一般商品。
23
 
24
- # use transformers pipeline
25
- ```python
26
- from transformers import pipeline
27
- pipe = pipeline("text-classification", model="jiechau/adult-content-classifier")
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
28
 
29
- q = '男平織運動外套-立領外套 慢跑 路跑 藍黑螢光黃 L'
30
- q = '情趣睡衣 性感睡衣 角色扮演 惹火 緊身連身 漆皮膠衣 黑 L'
31
 
32
- result = pipe(q)
33
- print(result)
34
- # [{'label': 'adult_成人商品', 'score': 0.9994813799858093}]
35
- ```
36
 
37
  ### Framework versions
38
 
39
  - Transformers 4.37.1
40
  - TensorFlow 2.15.0
41
  - Datasets 2.17.0
42
- - Tokenizers 0.15.1
 
2
  tags:
3
  - generated_from_keras_callback
4
  model-index:
5
+ - name: adult-content-identify-text
6
  results: []
 
 
 
 
 
 
7
  ---
8
 
9
  <!-- This model card has been generated automatically according to the information Keras had access to. You should
 
11
 
12
  # adult-content-identify-text
13
 
14
+ This model was trained from scratch on an unknown dataset.
15
+ It achieves the following results on the evaluation set:
16
 
 
17
 
18
+ ## Model description
19
+
20
+ More information needed
21
+
22
+ ## Intended uses & limitations
23
+
24
+ More information needed
25
+
26
+ ## Training and evaluation data
27
+
28
+ More information needed
29
+
30
+ ## Training procedure
31
+
32
+ ### Training hyperparameters
33
+
34
+ The following hyperparameters were used during training:
35
+ - optimizer: None
36
+ - training_precision: float32
37
+
38
+ ### Training results
39
 
 
 
40
 
 
 
 
 
41
 
42
  ### Framework versions
43
 
44
  - Transformers 4.37.1
45
  - TensorFlow 2.15.0
46
  - Datasets 2.17.0
47
+ - Tokenizers 0.15.1
config.json CHANGED
@@ -1,5 +1,5 @@
1
  {
2
- "_name_or_path": "/home/jie/model",
3
  "architectures": [
4
  "BertForSequenceClassification"
5
  ],
@@ -12,15 +12,15 @@
12
  "hidden_size": 768,
13
  "id2label": {
14
  "0": "unknown",
15
- "1": "adult_成人商品",
16
- "2": "regular_一般商品"
17
  },
18
  "initializer_range": 0.02,
19
  "intermediate_size": 3072,
20
  "label2id": {
21
- "unknown": 0,
22
- "adult_成人商品": 1,
23
- "regular_一般商品": 2
24
  },
25
  "layer_norm_eps": 1e-05,
26
  "max_position_embeddings": 514,
 
1
  {
2
+ "_name_or_path": "/home/rundeck/_ai_bulk_files/Colab_Notebooks/_saved_model/_saved_model_friDay/friDay_adult_sexy/FacebookAI-xlm-roberta-base-tf-keras",
3
  "architectures": [
4
  "BertForSequenceClassification"
5
  ],
 
12
  "hidden_size": 768,
13
  "id2label": {
14
  "0": "unknown",
15
+ "1": "adult_\u6210\u4eba\u5546\u54c1",
16
+ "2": "regular_\u4e00\u822c\u5546\u54c1"
17
  },
18
  "initializer_range": 0.02,
19
  "intermediate_size": 3072,
20
  "label2id": {
21
+ "adult_\u6210\u4eba\u5546\u54c1": 1,
22
+ "regular_\u4e00\u822c\u5546\u54c1": 2,
23
+ "unknown": 0
24
  },
25
  "layer_norm_eps": 1e-05,
26
  "max_position_embeddings": 514,
tf_model.h5 CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:9d11fc48bb5c516da55c0b6560548ed8ca62b9212dc43bbfed71e41fa36ef681
3
  size 1112471836
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:a461b2d560dde6bec8706a1ac9da1412397c0e3bf8aa3c3aef90457a06c161f1
3
  size 1112471836