San-Analytics commited on
Commit
4b9c55b
·
verified ·
1 Parent(s): 8236113

San-Analytics/invoice-classifier

Browse files
Files changed (6) hide show
  1. README.md +68 -0
  2. config.json +42 -0
  3. model.safetensors +3 -0
  4. tokenizer.json +0 -0
  5. tokenizer_config.json +15 -0
  6. training_args.bin +3 -0
README.md ADDED
@@ -0,0 +1,68 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ library_name: transformers
3
+ license: apache-2.0
4
+ base_model: distilbert-base-uncased
5
+ tags:
6
+ - generated_from_trainer
7
+ metrics:
8
+ - accuracy
9
+ model-index:
10
+ - name: classifier
11
+ results: []
12
+ ---
13
+
14
+ <!-- This model card has been generated automatically according to the information the Trainer had access to. You
15
+ should probably proofread and complete it, then remove this comment. -->
16
+
17
+ # classifier
18
+
19
+ This model is a fine-tuned version of [distilbert-base-uncased](https://huggingface.co/distilbert-base-uncased) on the None dataset.
20
+ It achieves the following results on the evaluation set:
21
+ - Loss: 0.0090
22
+ - Accuracy: 1.0
23
+ - F1 Macro: 1.0
24
+ - F1 Weighted: 1.0
25
+
26
+ ## Model description
27
+
28
+ More information needed
29
+
30
+ ## Intended uses & limitations
31
+
32
+ More information needed
33
+
34
+ ## Training and evaluation data
35
+
36
+ More information needed
37
+
38
+ ## Training procedure
39
+
40
+ ### Training hyperparameters
41
+
42
+ The following hyperparameters were used during training:
43
+ - learning_rate: 2e-05
44
+ - train_batch_size: 32
45
+ - eval_batch_size: 32
46
+ - seed: 42
47
+ - optimizer: Use OptimizerNames.ADAMW_TORCH_FUSED with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
48
+ - lr_scheduler_type: linear
49
+ - lr_scheduler_warmup_steps: 0.1
50
+ - num_epochs: 5
51
+
52
+ ### Training results
53
+
54
+ | Training Loss | Epoch | Step | Validation Loss | Accuracy | F1 Macro | F1 Weighted |
55
+ |:-------------:|:-----:|:----:|:---------------:|:--------:|:--------:|:-----------:|
56
+ | 1.2992 | 1.0 | 63 | 0.1976 | 1.0 | 1.0 | 1.0 |
57
+ | 0.1725 | 2.0 | 126 | 0.0234 | 1.0 | 1.0 | 1.0 |
58
+ | 0.0314 | 3.0 | 189 | 0.0133 | 1.0 | 1.0 | 1.0 |
59
+ | 0.0143 | 4.0 | 252 | 0.0101 | 1.0 | 1.0 | 1.0 |
60
+ | 0.0124 | 5.0 | 315 | 0.0093 | 1.0 | 1.0 | 1.0 |
61
+
62
+
63
+ ### Framework versions
64
+
65
+ - Transformers 5.8.0
66
+ - Pytorch 2.11.0+cu130
67
+ - Datasets 4.8.5
68
+ - Tokenizers 0.22.2
config.json ADDED
@@ -0,0 +1,42 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "activation": "gelu",
3
+ "architectures": [
4
+ "DistilBertForSequenceClassification"
5
+ ],
6
+ "attention_dropout": 0.1,
7
+ "bos_token_id": null,
8
+ "dim": 768,
9
+ "dropout": 0.1,
10
+ "dtype": "float32",
11
+ "eos_token_id": null,
12
+ "hidden_dim": 3072,
13
+ "id2label": {
14
+ "0": "DISPUTE",
15
+ "1": "GOODS_RECEIPT",
16
+ "2": "INVOICE",
17
+ "3": "PAYMENT_REQUEST",
18
+ "4": "PURCHASE_ORDER"
19
+ },
20
+ "initializer_range": 0.02,
21
+ "label2id": {
22
+ "DISPUTE": 0,
23
+ "GOODS_RECEIPT": 1,
24
+ "INVOICE": 2,
25
+ "PAYMENT_REQUEST": 3,
26
+ "PURCHASE_ORDER": 4
27
+ },
28
+ "max_position_embeddings": 512,
29
+ "model_type": "distilbert",
30
+ "n_heads": 12,
31
+ "n_layers": 6,
32
+ "pad_token_id": 0,
33
+ "problem_type": "single_label_classification",
34
+ "qa_dropout": 0.1,
35
+ "seq_classif_dropout": 0.2,
36
+ "sinusoidal_pos_embds": false,
37
+ "tie_weights_": true,
38
+ "tie_word_embeddings": true,
39
+ "transformers_version": "5.8.0",
40
+ "use_cache": false,
41
+ "vocab_size": 30522
42
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e0ffb347b723b726724e49ca45c962d0eb4c7bfb406af8848df846bd39c722b7
3
+ size 267841796
tokenizer.json ADDED
The diff for this file is too large to render. See raw diff
 
tokenizer_config.json ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "backend": "tokenizers",
3
+ "cls_token": "[CLS]",
4
+ "do_lower_case": true,
5
+ "is_local": false,
6
+ "local_files_only": false,
7
+ "mask_token": "[MASK]",
8
+ "model_max_length": 512,
9
+ "pad_token": "[PAD]",
10
+ "sep_token": "[SEP]",
11
+ "strip_accents": null,
12
+ "tokenize_chinese_chars": true,
13
+ "tokenizer_class": "BertTokenizer",
14
+ "unk_token": "[UNK]"
15
+ }
training_args.bin ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:52b490c10594d6bd2caae2fbdf5b12d3c50285af30b751b62c468f148aa43d8a
3
+ size 5329