Views
No views yet
pip install ms-swift[llm]Nvidia A100(80G) x 41CUDA_VISIBLE_DEVICES=0,1,2,3 swift sft \
2 --model_type qwen2_5-7b-instruct \
3 --dataset longwriter-6k-filtered#666 qwen2-pro-zh#6660 qwen2-pro-en#6660 \
4 --max_length 28672 \
5 --num_train_epochs 2 \
6 --eval_steps 200 \
7 --batch_size 1 \
8 --gradient_accumulation_steps 64 \
9 --gradient_checkpointing true \
10 --warmup_ratio 0.1 \
11 --learning_rate 1e-5 \
12 --sft_type full \
13 --loss_name long-ce \
14 --check_dataset_strategy warning \
15 --save_only_model false \
16 --save_total_limit -1 \
17 --lazy_tokenize true \
18 --dataloader_num_workers 1 \
19 --resume_only_model true \
20 --neftune_noise_alpha 5 \
21 --use_flash_attn true1CUDA_VISIBLE_DEVICES=0,1,2,3 swift sft \
2 --model_type qwen2_5-7b-instruct \
3 --dataset longwriter-6k-filtered#666 \
4 --max_length 28672 \
5 --num_train_epochs 2 \
6 --eval_steps 200 \
7 --batch_size 1 \
8 --gradient_accumulation_steps 64 \
9 --gradient_checkpointing true \
10 --warmup_ratio 0.1 \
11 --learning_rate 2e-6 \
12 --sft_type full \
13 --loss_name long-ce \
14 --check_dataset_strategy warning \
15 --save_only_model false \
16 --save_total_limit -1 \
17 --lazy_tokenize true \
18 --dataloader_num_workers 1 \
19 --resume_only_model true \
20 --neftune_noise_alpha 5 \
21 --use_flash_attn true \
22 --resume_from_checkpoint {previous-checkpoint-path}
23--resume_from_checkpoint parameter is used to specify the path of the previous checkpoint. (see the step2)1@misc{chen2024minimumtuningunlocklong,
2 title={Minimum Tuning to Unlock Long Output from LLMs with High Quality Data as the Key},
3 author={Yingda Chen and Xingjun Wang and Jintao Huang and Yunlin Mao and Daoze Zhang and Yuze Zhao},
4 year={2024},
5 eprint={2410.10210},
6 archivePrefix={arXiv},
7 primaryClass={cs.CL},
8 url={https://arxiv.org/abs/2410.10210},
9}