joseagmz commited on
Commit
136f845
1 Parent(s): cb40250

Upload folder using huggingface_hub

Browse files
README.md ADDED
@@ -0,0 +1,145 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: apache-2.0
3
+ base_model: mistralai/Mistral-7B-v0.1
4
+ tags:
5
+ - generated_from_trainer
6
+ model-index:
7
+ - name: mistral-7B-PsychiatryCaseNotes-epochs-3-lr-000002
8
+ results: []
9
+ ---
10
+
11
+ <!-- This model card has been generated automatically according to the information the Trainer had access to. You
12
+ should probably proofread and complete it, then remove this comment. -->
13
+
14
+ [<img src="https://raw.githubusercontent.com/OpenAccess-AI-Collective/axolotl/main/image/axolotl-badge-web.png" alt="Built with Axolotl" width="200" height="32"/>](https://github.com/OpenAccess-AI-Collective/axolotl)
15
+ <details><summary>See axolotl config</summary>
16
+
17
+ axolotl version: `0.4.0`
18
+ ```yaml
19
+ base_model: mistralai/Mistral-7B-v0.1
20
+ model_type: MistralForCausalLM
21
+ tokenizer_type: LlamaTokenizer
22
+ is_mistral_derived_model: true
23
+
24
+ load_in_8bit: false
25
+ load_in_4bit: false
26
+ strict: false
27
+
28
+ datasets:
29
+ - path: utrgvseniorproject/PsychiatryCaseNotes
30
+ type: completion
31
+ dataset_prepared_path: /home/josegomez15/med-llm/last_run_prepared
32
+ val_set_size: 0.05
33
+ output_dir: ./mistral-7B-PsychiatryCaseNotes-epochs-3-lr-000002
34
+
35
+ sequence_len: 4096
36
+ sample_packing: false
37
+ pad_to_sequence_len: true
38
+
39
+ wandb_project: mistral-7B-PsychiatryCaseNotes
40
+ wandb_entity: utrgvmedai
41
+ wandb_watch:
42
+ wandb_name: mistral-7B-PsychiatryCaseNotes-epochs-3-lr-000002
43
+ wandb_log_model:
44
+
45
+ gradient_accumulation_steps: 1
46
+ micro_batch_size: 1
47
+ num_epochs: 3
48
+ optimizer: adamw_bnb_8bit
49
+ lr_scheduler: cosine
50
+ learning_rate: 0.000002
51
+
52
+ train_on_inputs: True # make sure you have this on True
53
+ group_by_length: false
54
+ bf16: auto
55
+ fp16:
56
+ tf32: false
57
+
58
+ gradient_checkpointing: true
59
+ early_stopping_patience:
60
+ resume_from_checkpoint: true
61
+ local_rank:
62
+ logging_steps: 1
63
+ xformers_attention:
64
+ flash_attention: true
65
+ flash_attn_cross_entropy: false
66
+ flash_attn_rms_norm: true
67
+ flash_attn_fuse_qkv: false
68
+ flash_attn_fuse_mlp: true
69
+
70
+ warmup_steps: 100
71
+ evals_per_epoch: 4
72
+ eval_table_size:
73
+ eval_sample_packing:
74
+ saves_per_epoch: 1
75
+ debug:
76
+ deepspeed: /home/josegomez15/axolotl/deepspeed_configs/zero2.json
77
+ weight_decay: 0.1
78
+ fsdp:
79
+ fsdp_config:
80
+ special_tokens:
81
+
82
+ ```
83
+
84
+ </details><br>
85
+
86
+ # mistral-7B-PsychiatryCaseNotes-epochs-3-lr-000002
87
+
88
+ This model is a fine-tuned version of [mistralai/Mistral-7B-v0.1](https://huggingface.co/mistralai/Mistral-7B-v0.1) on the None dataset.
89
+ It achieves the following results on the evaluation set:
90
+ - Loss: 1.8637
91
+
92
+ ## Model description
93
+
94
+ More information needed
95
+
96
+ ## Intended uses & limitations
97
+
98
+ More information needed
99
+
100
+ ## Training and evaluation data
101
+
102
+ More information needed
103
+
104
+ ## Training procedure
105
+
106
+ ### Training hyperparameters
107
+
108
+ The following hyperparameters were used during training:
109
+ - learning_rate: 2e-06
110
+ - train_batch_size: 1
111
+ - eval_batch_size: 1
112
+ - seed: 42
113
+ - distributed_type: multi-GPU
114
+ - num_devices: 8
115
+ - total_train_batch_size: 8
116
+ - total_eval_batch_size: 8
117
+ - optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
118
+ - lr_scheduler_type: cosine
119
+ - lr_scheduler_warmup_steps: 100
120
+ - num_epochs: 3
121
+
122
+ ### Training results
123
+
124
+ | Training Loss | Epoch | Step | Validation Loss |
125
+ |:-------------:|:-----:|:----:|:---------------:|
126
+ | 5.0059 | 0.0 | 1 | 5.1706 |
127
+ | 2.457 | 0.25 | 626 | 2.0648 |
128
+ | 2.5571 | 0.5 | 1252 | 2.0728 |
129
+ | 2.3072 | 0.75 | 1878 | 1.9165 |
130
+ | 1.6655 | 1.0 | 2504 | 1.8590 |
131
+ | 1.6336 | 1.25 | 3130 | 1.8558 |
132
+ | 1.8686 | 1.5 | 3756 | 1.8526 |
133
+ | 1.6373 | 1.75 | 4382 | 1.8241 |
134
+ | 1.2849 | 2.0 | 5008 | 1.7712 |
135
+ | 1.1089 | 2.25 | 5634 | 1.8462 |
136
+ | 1.2999 | 2.5 | 6260 | 1.8523 |
137
+ | 1.0041 | 2.75 | 6886 | 1.8637 |
138
+
139
+
140
+ ### Framework versions
141
+
142
+ - Transformers 4.38.0
143
+ - Pytorch 2.0.1+cu117
144
+ - Datasets 2.17.0
145
+ - Tokenizers 0.15.0
config.json ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_name_or_path": "mistralai/Mistral-7B-v0.1",
3
+ "architectures": [
4
+ "MistralForCausalLM"
5
+ ],
6
+ "attention_dropout": 0.0,
7
+ "bos_token_id": 1,
8
+ "eos_token_id": 2,
9
+ "hidden_act": "silu",
10
+ "hidden_size": 4096,
11
+ "initializer_range": 0.02,
12
+ "intermediate_size": 14336,
13
+ "max_position_embeddings": 32768,
14
+ "model_type": "mistral",
15
+ "num_attention_heads": 32,
16
+ "num_hidden_layers": 32,
17
+ "num_key_value_heads": 8,
18
+ "rms_norm_eps": 1e-05,
19
+ "rope_theta": 10000.0,
20
+ "sliding_window": 4096,
21
+ "tie_word_embeddings": false,
22
+ "torch_dtype": "bfloat16",
23
+ "transformers_version": "4.38.0",
24
+ "use_cache": false,
25
+ "vocab_size": 32000
26
+ }
generation_config.json ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
 
1
+ {
2
+ "_from_model_config": true,
3
+ "bos_token_id": 1,
4
+ "do_sample": true,
5
+ "eos_token_id": 2,
6
+ "transformers_version": "4.38.0"
7
+ }
pytorch_model.bin ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ac8b7041e02e303a53aa0f7d1dc87c46a2492146b6f101f387cd9a8b4a7277bc
3
+ size 14483504421
special_tokens_map.json ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "bos_token": {
3
+ "content": "<s>",
4
+ "lstrip": false,
5
+ "normalized": false,
6
+ "rstrip": false,
7
+ "single_word": false
8
+ },
9
+ "eos_token": {
10
+ "content": "</s>",
11
+ "lstrip": false,
12
+ "normalized": false,
13
+ "rstrip": false,
14
+ "single_word": false
15
+ },
16
+ "pad_token": "</s>",
17
+ "unk_token": {
18
+ "content": "<unk>",
19
+ "lstrip": false,
20
+ "normalized": false,
21
+ "rstrip": false,
22
+ "single_word": false
23
+ }
24
+ }
tokenizer.model ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:dadfd56d766715c61d2ef780a525ab43b8e6da4de6865bda3d95fdef5e134055
3
+ size 493443
tokenizer_config.json ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "add_bos_token": true,
3
+ "add_eos_token": false,
4
+ "add_prefix_space": true,
5
+ "added_tokens_decoder": {
6
+ "0": {
7
+ "content": "<unk>",
8
+ "lstrip": false,
9
+ "normalized": false,
10
+ "rstrip": false,
11
+ "single_word": false,
12
+ "special": true
13
+ },
14
+ "1": {
15
+ "content": "<s>",
16
+ "lstrip": false,
17
+ "normalized": false,
18
+ "rstrip": false,
19
+ "single_word": false,
20
+ "special": true
21
+ },
22
+ "2": {
23
+ "content": "</s>",
24
+ "lstrip": false,
25
+ "normalized": false,
26
+ "rstrip": false,
27
+ "single_word": false,
28
+ "special": true
29
+ }
30
+ },
31
+ "additional_special_tokens": [],
32
+ "bos_token": "<s>",
33
+ "clean_up_tokenization_spaces": false,
34
+ "eos_token": "</s>",
35
+ "legacy": true,
36
+ "model_max_length": 1000000000000000019884624838656,
37
+ "pad_token": "</s>",
38
+ "sp_model_kwargs": {},
39
+ "spaces_between_special_tokens": false,
40
+ "tokenizer_class": "LlamaTokenizer",
41
+ "unk_token": "<unk>",
42
+ "use_default_system_prompt": false,
43
+ "use_fast": true
44
+ }