Views
No views yet
0.8.0.dev01# === Start-up Commands ===
2# curl -LsSf https://astral.sh/uv/install.sh | sh
3# export PATH="$HOME/.local/bin:$PATH"
4# git clone https://github.com/axolotl-ai-cloud/axolotl
5# cd axolotl
6# git checkout d8b4027200de0fe60f4ae0a71272c1a8cb2888f7
7# uv venv
8# source .venv/bin/activate
9# uv pip install packaging ninja setuptools huggingface_hub[cli,hf_transfer]
10# uv pip install "cut-cross-entropy[transformers] @ git+https://github.com/apple/ml-cross-entropy.git"
11# uv pip install apollo-torch
12# uv pip install --no-build-isolation -e .[flash-attn,deepspeed]
13# uv pip install git+https://github.com/huggingface/transformers.git
14# export HF_HUB_ENABLE_HF_TRANSFER=1
15# huggingface-cli login --token $hf_key && wandb login $wandb_key
16# axolotl preprocess qwen14-creative-v2-2.yml
17# axolotl train qwen14-creative-v2-2.yml
18
19# curl -LsSf https://astral.sh/uv/install.sh | sh && export PATH="$HOME/.local/bin:$PATH" && git clone https://github.com/axolotl-ai-cloud/axolotl && cd axolotl && uv venv && source .venv/bin/activate && uv pip install packaging ninja setuptools huggingface_hub[cli,hf_transfer] && uv pip install apollo-torch && uv pip install --no-build-isolation -e .[flash-attn,deepspeed] && uv pip install git+https://github.com/huggingface/transformers.git && export HF_HUB_ENABLE_HF_TRANSFER=1 && cd .. && huggingface-cli login --token $hf_key && wandb login $wandb_key
20
21# === Model Configuration ===
22base_model: ToastyPigeon/qwen2.5-14b-1m-unalign-v2
23load_in_8bit: false
24load_in_4bit: false
25
26# === Training Setup ===
27num_epochs: 2
28micro_batch_size: 2
29gradient_accumulation_steps: 1
30sequence_len: 4096
31sample_packing: true
32pad_to_sequence_len: true
33
34# === Evaluation ===
35val_set_size: 50
36evals_per_epoch: 10
37eval_table_size:
38eval_max_new_tokens: 256
39eval_sample_packing: true
40
41# === Hyperparameter Configuration ===
42optimizer: apollo_adamw_layerwise
43# Apollo-mini configuration:
44optim_args: "proj=random,rank=1,scale=128.0,scale_type=tensor,update_proj_gap=200"
45# Regular Apollo configuration:
46# optim_args:
47optim_target_modules: all_linear
48learning_rate: 1e-5
49lr_scheduler: cosine
50weight_decay: 0.01
51warmup_ratio: 0.05
52
53# === Data Configuration ===
54datasets:
55 - path: Columbidae/merge-glue
56 data_files: conversation-glue.json
57 type: chat_template
58 split: train[:50%]
59 field_messages: conversations
60 message_field_role: from
61 message_field_content: value
62 - path: Columbidae/merge-glue
63 data_files: completion-glue.json
64 type: completion
65 split: train[:50%]
66 field: text
67
68dataset_prepared_path: last_run_prepared
69chat_template: tokenizer_default
70# Example custom template:
71# chat_template: jinja
72# chat_template_jinja: |
73# {{- bos_token }}{%- for message in messages %}
74# {%- if message['role'] == 'system' %}
75# {{- '[SYSTEM_PROMPT]' + message['content'] + '[/SYSTEM_PROMPT]' }}
76# {%- elif message['role'] == 'user' %}
77# {{- '[INST]' + message['content'] + '[/INST]' }}
78# {%- elif message['role'] == 'assistant' %}
79# {{- message['content'] + eos_token }}
80# {%- endif %}
81# {%- endfor %}
82
83# === Plugins ===
84plugins:
85 - axolotl.integrations.liger.LigerPlugin
86# - axolotl.integrations.cut_cross_entropy.CutCrossEntropyPlugin
87
88# === Hardware Optimization ===
89gradient_checkpointing: true
90gradient_checkpointing_kwargs:
91 use_reentrant: false
92liger_rope: true
93liger_rms_norm: true
94liger_glu_activation: true
95liger_fused_linear_cross_entropy: true
96#unsloth_cross_entropy_loss: true
97#cut_cross_entropy: true
98# Only if using multiple GPUs:
99#deepspeed: axolotl/deepspeed_configs/zero3_bf16.json
100
101# === Wandb Tracking ===
102wandb_project: Qwen-14b-Revisit
103# wandb_entity: [WANDB_ENTITY]
104# wandb_name: [WANDB_RUN_NAME]
105
106# === MLflow Tracking ===
107#mlflow_tracking_uri: https://public-tracking.mlflow-e00zzfjq11ky6jcgtv.backbone-#e00bgn6e63256prmhq.msp.eu-north1.nebius.cloud
108#mlflow_experiment_name: [EXPERIMENT NAME] # e.g. "ms-24b-rp-inkmixv2-apollo"
109#hf_mlflow_log_artifacts: true
110
111# === Checkpointing ===
112saves_per_epoch: 2
113save_total_limit: 2
114
115# === Advanced Settings ===
116output_dir: ./ckpts
117bf16: auto
118flash_attention: true
119train_on_inputs: false
120group_by_length: false
121save_safetensors: true
122logging_steps: 1
123gc_steps: 10
124seed: 69| Training Loss | Epoch | Step | Validation Loss |
|---|---|---|---|
| 2.3282 | 0.0009 | 1 | 2.2377 |
| 2.1584 | 0.1 | 116 | 2.1839 |
| 2.2901 | 0.2 | 232 | 2.1747 |
| 2.0968 | 0.3 | 348 | 2.1847 |
| 1.9414 | 0.4 | 464 | 2.1670 |
| 2.0265 | 0.5 | 580 | 2.1619 |
| 2.1412 | 0.6 | 696 | 2.1608 |
| 1.7849 | 0.7 | 812 | 2.1596 |
| 1.8671 | 0.8 | 928 | 2.1594 |
| 2.0826 | 0.9 | 1044 | 2.1577 |
| 2.2851 | 1.0 | 1160 | 2.1572 |
| 2.121 | 1.1 | 1276 | 2.1565 |
| 2.6014 | 1.2 | 1392 | 2.1565 |
| 2.4435 | 1.3 | 1508 | 2.1565 |
| 2.3827 | 1.4 | 1624 | 2.1560 |
| 2.2584 | 1.5 | 1740 | 2.1558 |
| 2.1037 | 1.6 | 1856 | 2.1559 |
| 2.197 | 1.7 | 1972 | 2.1559 |
| 2.1096 | 1.8 | 2088 | 2.1559 |
| 2.0501 | 1.9 | 2204 | 2.1558 |
| 2.1046 | 2.0 | 2320 | 2.1558 |