Text Generation
Transformers
Safetensors
qwen2_moe
Generated from Trainer
open-r1
trl
sft
conversational
Instructions to use HectorHe/Qwen1.5-MOE-sft-coommonsense15k with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use HectorHe/Qwen1.5-MOE-sft-coommonsense15k with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="HectorHe/Qwen1.5-MOE-sft-coommonsense15k") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("HectorHe/Qwen1.5-MOE-sft-coommonsense15k") model = AutoModelForCausalLM.from_pretrained("HectorHe/Qwen1.5-MOE-sft-coommonsense15k", device_map="auto") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use HectorHe/Qwen1.5-MOE-sft-coommonsense15k with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "HectorHe/Qwen1.5-MOE-sft-coommonsense15k" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "HectorHe/Qwen1.5-MOE-sft-coommonsense15k", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/HectorHe/Qwen1.5-MOE-sft-coommonsense15k
- SGLang
How to use HectorHe/Qwen1.5-MOE-sft-coommonsense15k with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "HectorHe/Qwen1.5-MOE-sft-coommonsense15k" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "HectorHe/Qwen1.5-MOE-sft-coommonsense15k", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "HectorHe/Qwen1.5-MOE-sft-coommonsense15k" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "HectorHe/Qwen1.5-MOE-sft-coommonsense15k", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use HectorHe/Qwen1.5-MOE-sft-coommonsense15k with Docker Model Runner:
docker model run hf.co/HectorHe/Qwen1.5-MOE-sft-coommonsense15k
Training in progress, epoch 1
Browse files- .gitattributes +1 -0
- added_tokens.json +5 -0
- config.json +38 -0
- merges.txt +0 -0
- model-00001-of-00006.safetensors +3 -0
- model-00002-of-00006.safetensors +3 -0
- model-00003-of-00006.safetensors +3 -0
- model-00004-of-00006.safetensors +3 -0
- model-00005-of-00006.safetensors +3 -0
- model-00006-of-00006.safetensors +3 -0
- model.safetensors.index.json +0 -0
- special_tokens_map.json +14 -0
- tokenizer.json +3 -0
- tokenizer_config.json +45 -0
- training.log +194 -0
- training_args.bin +3 -0
- vocab.json +0 -0
.gitattributes
CHANGED
|
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
+
tokenizer.json filter=lfs diff=lfs merge=lfs -text
|
added_tokens.json
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"<|endoftext|>": 151643,
|
| 3 |
+
"<|im_end|>": 151645,
|
| 4 |
+
"<|im_start|>": 151644
|
| 5 |
+
}
|
config.json
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"architectures": [
|
| 3 |
+
"Qwen2MoeForCausalLM"
|
| 4 |
+
],
|
| 5 |
+
"attention_dropout": 0.0,
|
| 6 |
+
"bos_token_id": 151643,
|
| 7 |
+
"decoder_sparse_step": 1,
|
| 8 |
+
"eos_token_id": 151643,
|
| 9 |
+
"hidden_act": "silu",
|
| 10 |
+
"hidden_size": 2048,
|
| 11 |
+
"initializer_range": 0.02,
|
| 12 |
+
"intermediate_size": 5632,
|
| 13 |
+
"max_position_embeddings": 8192,
|
| 14 |
+
"max_window_layers": 21,
|
| 15 |
+
"mlp_only_layers": [],
|
| 16 |
+
"model_type": "qwen2_moe",
|
| 17 |
+
"moe_intermediate_size": 1408,
|
| 18 |
+
"norm_topk_prob": false,
|
| 19 |
+
"num_attention_heads": 16,
|
| 20 |
+
"num_experts": 60,
|
| 21 |
+
"num_experts_per_tok": 4,
|
| 22 |
+
"num_hidden_layers": 24,
|
| 23 |
+
"num_key_value_heads": 16,
|
| 24 |
+
"output_router_logits": false,
|
| 25 |
+
"qkv_bias": true,
|
| 26 |
+
"rms_norm_eps": 1e-06,
|
| 27 |
+
"rope_scaling": null,
|
| 28 |
+
"rope_theta": 1000000.0,
|
| 29 |
+
"router_aux_loss_coef": 0.001,
|
| 30 |
+
"shared_expert_intermediate_size": 5632,
|
| 31 |
+
"sliding_window": null,
|
| 32 |
+
"tie_word_embeddings": false,
|
| 33 |
+
"torch_dtype": "bfloat16",
|
| 34 |
+
"transformers_version": "4.51.0",
|
| 35 |
+
"use_cache": false,
|
| 36 |
+
"use_sliding_window": false,
|
| 37 |
+
"vocab_size": 151936
|
| 38 |
+
}
|
merges.txt
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
model-00001-of-00006.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:faa065ef6fa9b6b8431ec471faad1ffd285f1d94ae1159c9ce28a9bfa747fc18
|
| 3 |
+
size 4996577736
|
model-00002-of-00006.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:73f6431fa3cbe8658ddfcfebbc81751529dd49ee91d233435c2acbbeb54a7cb1
|
| 3 |
+
size 4996347752
|
model-00003-of-00006.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:4ce6c067790552143314511df03d5ebb25ddbdd9cdf4fd9a2da1e016639f719a
|
| 3 |
+
size 4997127120
|
model-00004-of-00006.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:33ccce916c43b937c1c6ec6b3ca0b04082f8f822b4e66440aa1a111061294cfc
|
| 3 |
+
size 4985592520
|
model-00005-of-00006.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:05746e0b1c4aede757b879d293b195068d3d6d5065491347bc677d84ae204040
|
| 3 |
+
size 4996348976
|
model-00006-of-00006.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:eb7434981ff1e8c6548f91586bed4d326471860d52747bbba534aab8449b6fae
|
| 3 |
+
size 3660151400
|
model.safetensors.index.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
special_tokens_map.json
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"additional_special_tokens": [
|
| 3 |
+
"<|im_start|>",
|
| 4 |
+
"<|im_end|>"
|
| 5 |
+
],
|
| 6 |
+
"eos_token": {
|
| 7 |
+
"content": "<|endoftext|>",
|
| 8 |
+
"lstrip": false,
|
| 9 |
+
"normalized": false,
|
| 10 |
+
"rstrip": false,
|
| 11 |
+
"single_word": false
|
| 12 |
+
},
|
| 13 |
+
"pad_token": "<|endoftext|>"
|
| 14 |
+
}
|
tokenizer.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:bcfe42da0a4497e8b2b172c1f9f4ec423a46dc12907f4349c55025f670422ba9
|
| 3 |
+
size 11418266
|
tokenizer_config.json
ADDED
|
@@ -0,0 +1,45 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"add_prefix_space": false,
|
| 3 |
+
"added_tokens_decoder": {
|
| 4 |
+
"151643": {
|
| 5 |
+
"content": "<|endoftext|>",
|
| 6 |
+
"lstrip": false,
|
| 7 |
+
"normalized": false,
|
| 8 |
+
"rstrip": false,
|
| 9 |
+
"single_word": false,
|
| 10 |
+
"special": true
|
| 11 |
+
},
|
| 12 |
+
"151644": {
|
| 13 |
+
"content": "<|im_start|>",
|
| 14 |
+
"lstrip": false,
|
| 15 |
+
"normalized": false,
|
| 16 |
+
"rstrip": false,
|
| 17 |
+
"single_word": false,
|
| 18 |
+
"special": true
|
| 19 |
+
},
|
| 20 |
+
"151645": {
|
| 21 |
+
"content": "<|im_end|>",
|
| 22 |
+
"lstrip": false,
|
| 23 |
+
"normalized": false,
|
| 24 |
+
"rstrip": false,
|
| 25 |
+
"single_word": false,
|
| 26 |
+
"special": true
|
| 27 |
+
}
|
| 28 |
+
},
|
| 29 |
+
"additional_special_tokens": [
|
| 30 |
+
"<|im_start|>",
|
| 31 |
+
"<|im_end|>"
|
| 32 |
+
],
|
| 33 |
+
"bos_token": null,
|
| 34 |
+
"chat_template": "{% for message in messages %}{% if loop.first and messages[0]['role'] != 'system' %}{{ '<|im_start|>system\nYou are a helpful assistant<|im_end|>\n' }}{% endif %}{{'<|im_start|>' + message['role'] + '\n' + message['content'] + '<|im_end|>' + '\n'}}{% endfor %}{% if add_generation_prompt %}{{ '<|im_start|>assistant\n' }}{% endif %}",
|
| 35 |
+
"clean_up_tokenization_spaces": false,
|
| 36 |
+
"eos_token": "<|endoftext|>",
|
| 37 |
+
"errors": "replace",
|
| 38 |
+
"extra_special_tokens": {},
|
| 39 |
+
"fast_tokenizer": true,
|
| 40 |
+
"model_max_length": 32768,
|
| 41 |
+
"pad_token": "<|endoftext|>",
|
| 42 |
+
"split_special_tokens": false,
|
| 43 |
+
"tokenizer_class": "Qwen2Tokenizer",
|
| 44 |
+
"unk_token": null
|
| 45 |
+
}
|
training.log
ADDED
|
@@ -0,0 +1,194 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
2025-09-23 13:11:33 - INFO - __main__ - Model parameters ModelConfig(model_name_or_path='Qwen/Qwen1.5-MoE-A2.7B', model_revision='main', torch_dtype='bfloat16', trust_remote_code=True, attn_implementation='flash_attention_2', use_peft=False, lora_r=16, lora_alpha=32, lora_dropout=0.05, lora_target_modules=None, lora_modules_to_save=None, lora_task_type='CAUSAL_LM', use_rslora=False, load_in_8bit=False, load_in_4bit=False, bnb_4bit_quant_type='nf4', use_bnb_nested_quant=False)
|
| 2 |
+
2025-09-23 13:11:33 - INFO - __main__ - Script parameters ScriptArguments(dataset_name='fw407/Commonsense-15K', dataset_config=None, dataset_train_split='train', dataset_test_split='test', gradient_checkpointing_use_reentrant=False, ignore_bias_buffers=False)
|
| 3 |
+
2025-09-23 13:11:33 - INFO - __main__ - Training parameters SFTConfig(
|
| 4 |
+
_n_gpu=1,
|
| 5 |
+
accelerator_config={'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None, 'use_configured_state': False},
|
| 6 |
+
adafactor=False,
|
| 7 |
+
adam_beta1=0.9,
|
| 8 |
+
adam_beta2=0.999,
|
| 9 |
+
adam_epsilon=1e-08,
|
| 10 |
+
auto_find_batch_size=False,
|
| 11 |
+
average_tokens_across_devices=False,
|
| 12 |
+
batch_eval_metrics=False,
|
| 13 |
+
benchmarks=[],
|
| 14 |
+
bf16=True,
|
| 15 |
+
bf16_full_eval=False,
|
| 16 |
+
callbacks=[],
|
| 17 |
+
chars_per_token=<CHARS_PER_TOKEN>,
|
| 18 |
+
chat_template=None,
|
| 19 |
+
data_seed=None,
|
| 20 |
+
dataloader_drop_last=False,
|
| 21 |
+
dataloader_num_workers=0,
|
| 22 |
+
dataloader_persistent_workers=False,
|
| 23 |
+
dataloader_pin_memory=True,
|
| 24 |
+
dataloader_prefetch_factor=None,
|
| 25 |
+
dataset_batch_size=None,
|
| 26 |
+
dataset_kwargs=None,
|
| 27 |
+
dataset_num_proc=None,
|
| 28 |
+
dataset_text_field=text,
|
| 29 |
+
ddp_backend=None,
|
| 30 |
+
ddp_broadcast_buffers=None,
|
| 31 |
+
ddp_bucket_cap_mb=None,
|
| 32 |
+
ddp_find_unused_parameters=None,
|
| 33 |
+
ddp_timeout=1800000000,
|
| 34 |
+
debug=[],
|
| 35 |
+
deepspeed=None,
|
| 36 |
+
disable_tqdm=False,
|
| 37 |
+
do_eval=True,
|
| 38 |
+
do_predict=False,
|
| 39 |
+
do_train=False,
|
| 40 |
+
eval_accumulation_steps=None,
|
| 41 |
+
eval_delay=0,
|
| 42 |
+
eval_do_concat_batches=True,
|
| 43 |
+
eval_on_start=False,
|
| 44 |
+
eval_packing=None,
|
| 45 |
+
eval_steps=None,
|
| 46 |
+
eval_strategy=IntervalStrategy.NO,
|
| 47 |
+
eval_use_gather_object=False,
|
| 48 |
+
fp16=False,
|
| 49 |
+
fp16_backend=auto,
|
| 50 |
+
fp16_full_eval=False,
|
| 51 |
+
fp16_opt_level=O1,
|
| 52 |
+
fsdp=[],
|
| 53 |
+
fsdp_config={'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False},
|
| 54 |
+
fsdp_min_num_params=0,
|
| 55 |
+
fsdp_transformer_layer_cls_to_wrap=None,
|
| 56 |
+
full_determinism=False,
|
| 57 |
+
gradient_accumulation_steps=1,
|
| 58 |
+
gradient_checkpointing=True,
|
| 59 |
+
gradient_checkpointing_kwargs={'use_reentrant': False},
|
| 60 |
+
greater_is_better=None,
|
| 61 |
+
group_by_length=False,
|
| 62 |
+
half_precision_backend=auto,
|
| 63 |
+
hub_always_push=False,
|
| 64 |
+
hub_model_id=Qwen1.5-MOE-sft-coommonsense15k,
|
| 65 |
+
hub_model_revision=main,
|
| 66 |
+
hub_private_repo=None,
|
| 67 |
+
hub_strategy=HubStrategy.EVERY_SAVE,
|
| 68 |
+
hub_token=<HUB_TOKEN>,
|
| 69 |
+
ignore_data_skip=False,
|
| 70 |
+
include_for_metrics=[],
|
| 71 |
+
include_inputs_for_metrics=False,
|
| 72 |
+
include_num_input_tokens_seen=False,
|
| 73 |
+
include_tokens_per_second=False,
|
| 74 |
+
jit_mode_eval=False,
|
| 75 |
+
label_names=None,
|
| 76 |
+
label_smoothing_factor=0.0,
|
| 77 |
+
learning_rate=1e-05,
|
| 78 |
+
length_column_name=length,
|
| 79 |
+
load_best_model_at_end=False,
|
| 80 |
+
local_rank=0,
|
| 81 |
+
log_level=info,
|
| 82 |
+
log_level_replica=warning,
|
| 83 |
+
log_on_each_node=True,
|
| 84 |
+
logging_dir=/tmp/data/Qwen1.5-MOE/sft/commonsense15k/runs/Sep23_13-11-32_orchard-community-0,
|
| 85 |
+
logging_first_step=False,
|
| 86 |
+
logging_nan_inf_filter=True,
|
| 87 |
+
logging_steps=1,
|
| 88 |
+
logging_strategy=IntervalStrategy.STEPS,
|
| 89 |
+
lr_scheduler_kwargs={'min_lr_rate': 0.1},
|
| 90 |
+
lr_scheduler_type=SchedulerType.COSINE_WITH_MIN_LR,
|
| 91 |
+
max_grad_norm=1.0,
|
| 92 |
+
max_length=2048,
|
| 93 |
+
max_seq_length=None,
|
| 94 |
+
max_steps=-1,
|
| 95 |
+
metric_for_best_model=None,
|
| 96 |
+
model_init_kwargs=None,
|
| 97 |
+
mp_parameters=,
|
| 98 |
+
neftune_noise_alpha=None,
|
| 99 |
+
no_cuda=False,
|
| 100 |
+
num_of_sequences=None,
|
| 101 |
+
num_train_epochs=3,
|
| 102 |
+
optim=OptimizerNames.ADAMW_TORCH,
|
| 103 |
+
optim_args=None,
|
| 104 |
+
optim_target_modules=None,
|
| 105 |
+
output_dir=/tmp/data/Qwen1.5-MOE/sft/commonsense15k,
|
| 106 |
+
overwrite_hub_revision=False,
|
| 107 |
+
overwrite_output_dir=True,
|
| 108 |
+
packing=False,
|
| 109 |
+
past_index=-1,
|
| 110 |
+
per_device_eval_batch_size=16,
|
| 111 |
+
per_device_train_batch_size=16,
|
| 112 |
+
prediction_loss_only=False,
|
| 113 |
+
push_to_hub=True,
|
| 114 |
+
push_to_hub_model_id=None,
|
| 115 |
+
push_to_hub_organization=None,
|
| 116 |
+
push_to_hub_revision=False,
|
| 117 |
+
push_to_hub_token=<PUSH_TO_HUB_TOKEN>,
|
| 118 |
+
ray_scope=last,
|
| 119 |
+
remove_unused_columns=True,
|
| 120 |
+
report_to=['wandb'],
|
| 121 |
+
restore_callback_states_from_checkpoint=False,
|
| 122 |
+
resume_from_checkpoint=None,
|
| 123 |
+
run_name=/tmp/data/Qwen1.5-MOE/sft/commonsense15k,
|
| 124 |
+
save_on_each_node=False,
|
| 125 |
+
save_only_model=False,
|
| 126 |
+
save_safetensors=True,
|
| 127 |
+
save_steps=500,
|
| 128 |
+
save_strategy=SaveStrategy.EPOCH,
|
| 129 |
+
save_total_limit=3,
|
| 130 |
+
seed=1234,
|
| 131 |
+
skip_memory_metrics=True,
|
| 132 |
+
system_prompt=None,
|
| 133 |
+
tf32=None,
|
| 134 |
+
torch_compile=False,
|
| 135 |
+
torch_compile_backend=None,
|
| 136 |
+
torch_compile_mode=None,
|
| 137 |
+
torch_empty_cache_steps=None,
|
| 138 |
+
torchdynamo=None,
|
| 139 |
+
tp_size=0,
|
| 140 |
+
tpu_metrics_debug=False,
|
| 141 |
+
tpu_num_cores=None,
|
| 142 |
+
use_cpu=False,
|
| 143 |
+
use_ipex=False,
|
| 144 |
+
use_legacy_prediction_loop=False,
|
| 145 |
+
use_liger=False,
|
| 146 |
+
use_liger_kernel=False,
|
| 147 |
+
use_mps_device=False,
|
| 148 |
+
wandb_entity=None,
|
| 149 |
+
wandb_project=None,
|
| 150 |
+
warmup_ratio=0.1,
|
| 151 |
+
warmup_steps=0,
|
| 152 |
+
weight_decay=0.0,
|
| 153 |
+
)
|
| 154 |
+
2025-09-23 13:11:34 - INFO - __main__ - *** Initializing model kwargs ***
|
| 155 |
+
2025-09-23 13:13:23 - INFO - __main__ - *** Train ***
|
| 156 |
+
2025-09-23 13:13:23 - INFO - __main__ - Qwen2MoeForCausalLM(
|
| 157 |
+
(model): Qwen2MoeModel(
|
| 158 |
+
(embed_tokens): Embedding(151936, 2048)
|
| 159 |
+
(layers): ModuleList(
|
| 160 |
+
(0-23): 24 x Qwen2MoeDecoderLayer(
|
| 161 |
+
(self_attn): Qwen2MoeFlashAttention2(
|
| 162 |
+
(q_proj): Linear(in_features=2048, out_features=2048, bias=True)
|
| 163 |
+
(k_proj): Linear(in_features=2048, out_features=2048, bias=True)
|
| 164 |
+
(v_proj): Linear(in_features=2048, out_features=2048, bias=True)
|
| 165 |
+
(o_proj): Linear(in_features=2048, out_features=2048, bias=False)
|
| 166 |
+
(rotary_emb): Qwen2MoeRotaryEmbedding()
|
| 167 |
+
)
|
| 168 |
+
(mlp): Qwen2MoeSparseMoeBlock(
|
| 169 |
+
(gate): Linear(in_features=2048, out_features=60, bias=False)
|
| 170 |
+
(experts): ModuleList(
|
| 171 |
+
(0-59): 60 x Qwen2MoeMLP(
|
| 172 |
+
(gate_proj): Linear(in_features=2048, out_features=1408, bias=False)
|
| 173 |
+
(up_proj): Linear(in_features=2048, out_features=1408, bias=False)
|
| 174 |
+
(down_proj): Linear(in_features=1408, out_features=2048, bias=False)
|
| 175 |
+
(act_fn): SiLU()
|
| 176 |
+
)
|
| 177 |
+
)
|
| 178 |
+
(shared_expert): Qwen2MoeMLP(
|
| 179 |
+
(gate_proj): Linear(in_features=2048, out_features=5632, bias=False)
|
| 180 |
+
(up_proj): Linear(in_features=2048, out_features=5632, bias=False)
|
| 181 |
+
(down_proj): Linear(in_features=5632, out_features=2048, bias=False)
|
| 182 |
+
(act_fn): SiLU()
|
| 183 |
+
)
|
| 184 |
+
(shared_expert_gate): Linear(in_features=2048, out_features=1, bias=False)
|
| 185 |
+
)
|
| 186 |
+
(input_layernorm): Qwen2MoeRMSNorm((0,), eps=1e-06)
|
| 187 |
+
(post_attention_layernorm): Qwen2MoeRMSNorm((0,), eps=1e-06)
|
| 188 |
+
)
|
| 189 |
+
)
|
| 190 |
+
(norm): Qwen2MoeRMSNorm((0,), eps=1e-06)
|
| 191 |
+
(rotary_emb): Qwen2MoeRotaryEmbedding()
|
| 192 |
+
)
|
| 193 |
+
(lm_head): Linear(in_features=2048, out_features=151936, bias=False)
|
| 194 |
+
)
|
training_args.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:543569c470f240a86311ef868a0cca385df021f95066ef2dabf9e03809372224
|
| 3 |
+
size 7544
|
vocab.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|