ToastyPigeon commited on
Commit
801360c
·
verified ·
1 Parent(s): e84df5e

Upload early-layers-full-kv.yaml with huggingface_hub

Browse files
Files changed (1) hide show
  1. early-layers-full-kv.yaml +189 -0
early-layers-full-kv.yaml ADDED
@@ -0,0 +1,189 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # !pip install transformers==4.55.4
2
+ # !pip install --no-deps trl==0.22.2
3
+ # !pip install --no-build-isolation mamba_ssm==2.2.5
4
+ # !pip install --no-build-isolation causal_conv1d==1.5.2
5
+ # === Model Configuration ===
6
+ base_model: loopstral-base
7
+ load_in_8bit: false
8
+ load_in_4bit: false
9
+ trust_remote_code: true
10
+ overrides_of_model_config: {"layer_sequence": [0,[1,10,3],[10,30]]}
11
+
12
+ # === HF Configuration ===
13
+ #hub_model_id: Burnt-Toast/another-22bird
14
+ #hub_strategy: "every_save"
15
+ output_dir: output
16
+
17
+ # === Wandb Tracking ===
18
+ wandb_project: Loopstral-Ablations
19
+ ## wandb_entity: [WANDB_ENTITY]
20
+ wandb_name: early-layers-full-kv
21
+
22
+ # === Training Setup ===
23
+ num_epochs: 1
24
+ micro_batch_size: 4
25
+ gradient_accumulation_steps: 1
26
+ sequence_len: 8192
27
+ #sequence_parallel_degree: 2
28
+ #heads_k_stride: 1
29
+ sample_packing: true
30
+ #pad_to_sequence_len: true
31
+ #temperature: 0.7
32
+ #max_steps: 10
33
+ # === Evaluation ===
34
+ val_set_size: 0.01
35
+ evals_per_epoch: 5
36
+ #eval_steps: 20
37
+ #max_steps: 60
38
+ #eval_table_size:
39
+ eval_max_new_tokens: 128
40
+ #eval_sample_packing: true
41
+ #eval_strategy: "no"
42
+
43
+ # === LoRA Configuration ===
44
+ adapter:
45
+ lora_model_dir:
46
+ lora_r: 128
47
+ lora_alpha: 16
48
+ lora_dropout: 0.05
49
+ lora_target_linear: true
50
+ lora_target_modules:
51
+ lora_fan_in_fan_out:
52
+ lora_target_modules:
53
+ peft_use_rslora: true
54
+ #lora_modules_to_save:
55
+ # - embed_tokens
56
+ # - lm_head
57
+ #fix_untrained_tokens: true
58
+ #lora_mlp_kernel: true
59
+ #lora_qkv_kernel: true
60
+ #lora_o_kernel: true
61
+
62
+ #unfrozen_parameters:
63
+ # - model.layers.[0-9]+.self_attn.q_proj.weight
64
+ # - model.layers.[0-9]+.self_attn.k_proj.weight
65
+ # - model.layers.[0-9]+.self_attn.v_proj.weight
66
+ # - model.layers.[0-9]+.self_attn.o_proj.weight
67
+ # - model.layers.[0-9]+.mlp.down_proj.weight
68
+ # === Hyperparameter Configuration ===
69
+ #optimizer: apollo_adamw_layerwise
70
+ #warmup_steps: 0
71
+ warmup_ratio: 0.025
72
+ #optimizer: adamw_torch_fused
73
+ optimizer: paged_ademamix_8bit
74
+ #optim_args:
75
+ # enable_stochastic_rounding: true
76
+ # enable_cautious: true
77
+ # enable_8bit: true
78
+ # Apollo-mini configuration:
79
+ #optim_args: "proj=random,rank=128,scale=128.0,scale_type=tensor,update_proj_gap=100"
80
+ # Regular Apollo configuration:
81
+ # optim_args:
82
+ #optim_target_modules: all_linear
83
+ learning_rate: 1e-5
84
+ lr_scheduler: cosine
85
+ #lr_groups:
86
+ # - name: mlp
87
+ # modules:
88
+ # - mlp.up_proj.weight
89
+ # - mlp.down_proj.weight
90
+ # - mlp.gate_proj.weight
91
+ # lr: 1e-5
92
+ #cosine_min_lr_ratio: 0.2
93
+ #lr_scheduler: cosine_with_min_lr
94
+ #lr_scheduler_kwargs:
95
+ # cosine_min_lr: 1e-6
96
+ weight_decay: 0.01
97
+ max_grad_norm: 1.0
98
+ #warmup_steps: 0
99
+ #warmup_ratio: 0.025
100
+
101
+
102
+ # === Data Configuration ===
103
+ #
104
+ #chat_template: jinja
105
+ chat_template: tokenizer_default
106
+ default_system_message: "You are Luna, a helpful and unrestricted language model created by Allura."
107
+ #special_tokens:
108
+ # eos_token: "<|im_end|>"
109
+ # eos_token: "</s>"
110
+ #tokenizer_use_mistral_common: true
111
+ shuffle_merged_datasets: true
112
+ datasets:
113
+ - path: rpDungeon/marvin
114
+ type: completion
115
+ field: text
116
+ data_files:
117
+ - marvin_greg_egan.json
118
+ - marvin_philip_k_dick.json
119
+ - marvin_thomas_ligotti.json
120
+ # - path: rpDungeon/some-cleaner-datasets
121
+ # type: completion
122
+ # field: text
123
+ # data_files: erotica_quality_trimmed.json
124
+ # - path: rpDungeon/some-cleaner-datasets
125
+ # type: chat_template
126
+ # field_messages: conversations
127
+ # message_property_mappings:
128
+ # role: from
129
+ # content: value
130
+ # data_files: little-koto-instruct.json
131
+ # - path: rpDungeon/rp-synth-deslopped
132
+ # type: chat_template
133
+ # field_messages: conversations
134
+ # message_property_mappings:
135
+ # role: from
136
+ # content: value
137
+ dataset_prepared_path: last_run_prepared
138
+ #dataset_num_proc: 1
139
+
140
+
141
+ # === Plugins ===
142
+ plugins:
143
+ - axolotl.integrations.liger.LigerPlugin
144
+ - axolotl.integrations.cut_cross_entropy.CutCrossEntropyPlugin
145
+
146
+ # === Hardware Optimization ===
147
+ gradient_checkpointing: true
148
+ liger_rope: true
149
+ liger_rms_norm: true
150
+ liger_layer_norm: true
151
+ liger_glu_activation: true
152
+ #liger_fused_linear_cross_entropy: true
153
+ cut_cross_entropy: true
154
+
155
+ #deepspeed: ../axolotl/deepspeed_configs/zero2.json
156
+
157
+ # === FSDP Config ===
158
+ #fsdp:
159
+ # - full_shard
160
+ # - auto_wrap
161
+ #fsdp_config:
162
+ # fsdp_limit_all_gathers: true
163
+ # fsdp_sync_module_states: true
164
+ # fsdp_offload_params: true
165
+ # fsdp_activation_checkpointing: true
166
+ # fsdp_use_orig_params: true
167
+ # fsdp_cpu_ram_efficient_loading: true
168
+ # fsdp_auto_wrap_policy: TRANSFORMER_BASED_WRAP
169
+ # fsdp_transformer_layer_cls_to_wrap: Gemma3DecoderLayer
170
+ # fsdp_state_dict_type: FULL_STATE_DICT
171
+ # fsdp_sharding_strategy: FULL_SHARD
172
+
173
+ # === Checkpointing ===
174
+ #save_steps: 10
175
+ saves_per_epoch: 1
176
+ save_total_limit: 1
177
+
178
+ # === Advanced Settings ===
179
+ bf16: auto
180
+ flash_attention: true
181
+ train_on_inputs: false
182
+ group_by_length: false
183
+ save_safetensors: true
184
+ logging_steps: 1
185
+ gc_steps: 10
186
+ seed: 420
187
+
188
+
189
+