pamparamm commited on
Commit
9127a87
·
1 Parent(s): 41bb4bb

LoRA weights

Browse files
README.md CHANGED
@@ -1,3 +1,134 @@
1
- ---
2
- license: apache-2.0
3
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: apache-2.0
3
+ library_name: peft
4
+ tags:
5
+ - generated_from_trainer
6
+ base_model: WlappaAI/Mistral-7B-wikipedia_ru_pruned-0.1_merged
7
+ model-index:
8
+ - name: dracor-ru-small-lora
9
+ results: []
10
+ ---
11
+
12
+ [<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)
13
+ <details><summary>See axolotl config</summary>
14
+
15
+ axolotl version: `0.4.0`
16
+ ```yaml
17
+ base_model: WlappaAI/Mistral-7B-wikipedia_ru_pruned-0.1_merged
18
+ model_type: MistralForCausalLM
19
+ tokenizer_type: LlamaTokenizer
20
+ is_mistral_derived_model: true
21
+
22
+ load_in_8bit: true
23
+ load_in_4bit: false
24
+ strict: false
25
+
26
+ datasets:
27
+ - path: ./datasets/ru-dracor
28
+ type: completion
29
+ field: text
30
+ dataset_prepared_path: last_run_prepared
31
+ val_set_size: 0.05
32
+ output_dir: ./models/output/dracor_ru_lora
33
+
34
+ adapter: lora
35
+ lora_model_dir:
36
+
37
+ sequence_len: 1024
38
+ sample_packing: true
39
+ pad_to_sequence_len: true
40
+
41
+ lora_r: 32
42
+ lora_alpha: 16
43
+ lora_dropout: 0.05
44
+ lora_target_linear: true
45
+ lora_fan_in_fan_out:
46
+ lora_target_modules:
47
+ - gate_proj
48
+ - down_proj
49
+ - up_proj
50
+ - q_proj
51
+ - v_proj
52
+ - k_proj
53
+ - o_proj
54
+
55
+ wandb_project:
56
+ wandb_entity:
57
+ wandb_watch:
58
+ wandb_name:
59
+ wandb_log_model:
60
+
61
+ gradient_accumulation_steps: 1
62
+ micro_batch_size: 6
63
+ num_epochs: 1
64
+ optimizer: adamw_torch
65
+ lr_scheduler: cosine
66
+ learning_rate: 0.0002
67
+
68
+ train_on_inputs: false
69
+ group_by_length: false
70
+ bf16: auto
71
+ fp16:
72
+ tf32: false
73
+
74
+ gradient_checkpointing: true
75
+ early_stopping_patience:
76
+ resume_from_checkpoint:
77
+ local_rank:
78
+ logging_steps:
79
+ xformers_attention:
80
+ flash_attention: true
81
+
82
+ loss_watchdog_threshold: 5.0
83
+ loss_watchdog_patience: 3
84
+
85
+ warmup_steps: 10
86
+ evals_per_epoch: 1
87
+ eval_table_size:
88
+ eval_max_new_tokens: 128
89
+ saves_per_epoch: 1
90
+ debug:
91
+ deepspeed:
92
+ weight_decay: 0.0
93
+ fsdp:
94
+ fsdp_config:
95
+ special_tokens:
96
+
97
+ ```
98
+
99
+ </details><br>
100
+
101
+ # dracor-ru-small-lora
102
+
103
+ This model is a fine-tuned version of [WlappaAI/Mistral-7B-wikipedia_ru_pruned-0.1_merged](https://huggingface.co/WlappaAI/Mistral-7B-wikipedia_ru_pruned-0.1_merged) on Russian DraCor dataset.
104
+ It achieves the following results on the evaluation set:
105
+ - Loss: 1.6606
106
+
107
+ ## Training procedure
108
+
109
+ ### Training hyperparameters
110
+
111
+ The following hyperparameters were used during training:
112
+ - learning_rate: 0.0002
113
+ - train_batch_size: 6
114
+ - eval_batch_size: 6
115
+ - seed: 42
116
+ - optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
117
+ - lr_scheduler_type: cosine
118
+ - lr_scheduler_warmup_steps: 10
119
+ - num_epochs: 1
120
+
121
+ ### Training results
122
+
123
+ | Training Loss | Epoch | Step | Validation Loss |
124
+ |:-------------:|:-----:|:----:|:---------------:|
125
+ | 1.7921 | 1.0 | 1056 | 1.6606 |
126
+
127
+
128
+ ### Framework versions
129
+
130
+ - PEFT 0.10.0
131
+ - Transformers 4.40.0.dev0
132
+ - Pytorch 2.2.2+cu121
133
+ - Datasets 2.18.0
134
+ - Tokenizers 0.15.0
adapter_config.json ADDED
@@ -0,0 +1,34 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "alpha_pattern": {},
3
+ "auto_mapping": null,
4
+ "base_model_name_or_path": "WlappaAI/Mistral-7B-wikipedia_ru_pruned-0.1_merged",
5
+ "bias": "none",
6
+ "fan_in_fan_out": null,
7
+ "inference_mode": true,
8
+ "init_lora_weights": true,
9
+ "layer_replication": null,
10
+ "layers_pattern": null,
11
+ "layers_to_transform": null,
12
+ "loftq_config": {},
13
+ "lora_alpha": 16,
14
+ "lora_dropout": 0.05,
15
+ "megatron_config": null,
16
+ "megatron_core": "megatron.core",
17
+ "modules_to_save": null,
18
+ "peft_type": "LORA",
19
+ "r": 32,
20
+ "rank_pattern": {},
21
+ "revision": null,
22
+ "target_modules": [
23
+ "q_proj",
24
+ "up_proj",
25
+ "gate_proj",
26
+ "down_proj",
27
+ "v_proj",
28
+ "o_proj",
29
+ "k_proj"
30
+ ],
31
+ "task_type": "CAUSAL_LM",
32
+ "use_dora": false,
33
+ "use_rslora": false
34
+ }
adapter_model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:3ec582c51f6e7df996459c64a7ba219eea6d8d5c2579c53363c305bc6f488076
3
+ size 335604696
config.json ADDED
@@ -0,0 +1,41 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_name_or_path": "WlappaAI/Mistral-7B-wikipedia_ru_pruned-0.1_merged",
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
+ "quantization_config": {
19
+ "_load_in_4bit": false,
20
+ "_load_in_8bit": true,
21
+ "bnb_4bit_compute_dtype": "float32",
22
+ "bnb_4bit_quant_storage": "uint8",
23
+ "bnb_4bit_quant_type": "fp4",
24
+ "bnb_4bit_use_double_quant": false,
25
+ "llm_int8_enable_fp32_cpu_offload": false,
26
+ "llm_int8_has_fp16_weight": false,
27
+ "llm_int8_skip_modules": null,
28
+ "llm_int8_threshold": 6.0,
29
+ "load_in_4bit": false,
30
+ "load_in_8bit": true,
31
+ "quant_method": "bitsandbytes"
32
+ },
33
+ "rms_norm_eps": 1e-05,
34
+ "rope_theta": 10000.0,
35
+ "sliding_window": 4096,
36
+ "tie_word_embeddings": false,
37
+ "torch_dtype": "float16",
38
+ "transformers_version": "4.40.0.dev0",
39
+ "use_cache": false,
40
+ "vocab_size": 32000
41
+ }
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
+ }