Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
ModelZoo
Telechat_pytorch
Commits
f7db21eb
Commit
f7db21eb
authored
Aug 22, 2024
by
lvzhen
Browse files
first
parents
Pipeline
#1580
canceled with stages
Changes
674
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
20 changed files
with
429 additions
and
0 deletions
+429
-0
ms-swift/examples/pytorch/llm/scripts/chatglm3_6b_32k/rome.sh
...wift/examples/pytorch/llm/scripts/chatglm3_6b_32k/rome.sh
+13
-0
ms-swift/examples/pytorch/llm/scripts/chatglm3_6b_base/lora/infer.sh
...amples/pytorch/llm/scripts/chatglm3_6b_base/lora/infer.sh
+12
-0
ms-swift/examples/pytorch/llm/scripts/chatglm3_6b_base/lora/sft.sh
...examples/pytorch/llm/scripts/chatglm3_6b_base/lora/sft.sh
+31
-0
ms-swift/examples/pytorch/llm/scripts/chatglm3_6b_base/lora_ddp_ds/infer.sh
...pytorch/llm/scripts/chatglm3_6b_base/lora_ddp_ds/infer.sh
+12
-0
ms-swift/examples/pytorch/llm/scripts/chatglm3_6b_base/lora_ddp_ds/sft.sh
...s/pytorch/llm/scripts/chatglm3_6b_base/lora_ddp_ds/sft.sh
+38
-0
ms-swift/examples/pytorch/llm/scripts/codefuse_codellama_34b/lora/infer.sh
.../pytorch/llm/scripts/codefuse_codellama_34b/lora/infer.sh
+13
-0
ms-swift/examples/pytorch/llm/scripts/codefuse_codellama_34b/lora/sft.sh
...es/pytorch/llm/scripts/codefuse_codellama_34b/lora/sft.sh
+32
-0
ms-swift/examples/pytorch/llm/scripts/codegeex2_6b/lora_ddp_ds/infer.sh
...les/pytorch/llm/scripts/codegeex2_6b/lora_ddp_ds/infer.sh
+12
-0
ms-swift/examples/pytorch/llm/scripts/codegeex2_6b/lora_ddp_ds/sft.sh
...mples/pytorch/llm/scripts/codegeex2_6b/lora_ddp_ds/sft.sh
+37
-0
ms-swift/examples/pytorch/llm/scripts/codeqwen1half_7b_chat/lora/infer.sh
...s/pytorch/llm/scripts/codeqwen1half_7b_chat/lora/infer.sh
+11
-0
ms-swift/examples/pytorch/llm/scripts/codeqwen1half_7b_chat/lora/sft.sh
...les/pytorch/llm/scripts/codeqwen1half_7b_chat/lora/sft.sh
+29
-0
ms-swift/examples/pytorch/llm/scripts/codeqwen1half_7b_chat_awq/lora/infer.sh
...torch/llm/scripts/codeqwen1half_7b_chat_awq/lora/infer.sh
+13
-0
ms-swift/examples/pytorch/llm/scripts/codeqwen1half_7b_chat_awq/lora/sft.sh
...pytorch/llm/scripts/codeqwen1half_7b_chat_awq/lora/sft.sh
+24
-0
ms-swift/examples/pytorch/llm/scripts/cogagent_18b_chat/lora/infer.sh
...mples/pytorch/llm/scripts/cogagent_18b_chat/lora/infer.sh
+12
-0
ms-swift/examples/pytorch/llm/scripts/cogagent_18b_chat/lora/sft.sh
...xamples/pytorch/llm/scripts/cogagent_18b_chat/lora/sft.sh
+28
-0
ms-swift/examples/pytorch/llm/scripts/custom/tigerbot_13b_chat/qlora_ddp_ds/infer.sh
...lm/scripts/custom/tigerbot_13b_chat/qlora_ddp_ds/infer.sh
+12
-0
ms-swift/examples/pytorch/llm/scripts/custom/tigerbot_13b_chat/qlora_ddp_ds/sft.sh
.../llm/scripts/custom/tigerbot_13b_chat/qlora_ddp_ds/sft.sh
+39
-0
ms-swift/examples/pytorch/llm/scripts/custom/tigerbot_7b/lora_ddp_ds/infer.sh
...torch/llm/scripts/custom/tigerbot_7b/lora_ddp_ds/infer.sh
+12
-0
ms-swift/examples/pytorch/llm/scripts/custom/tigerbot_7b/lora_ddp_ds/sft.sh
...pytorch/llm/scripts/custom/tigerbot_7b/lora_ddp_ds/sft.sh
+37
-0
ms-swift/examples/pytorch/llm/scripts/dbrx-instruct/lora_mp/infer.sh
...amples/pytorch/llm/scripts/dbrx-instruct/lora_mp/infer.sh
+12
-0
No files found.
Too many changes to show.
To preserve performance only
674 of 674+
files are displayed.
Plain diff
Email patch
ms-swift/examples/pytorch/llm/scripts/chatglm3_6b_32k/rome.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: A10
PYTHONPATH
=
../../..
\
CUDA_VISIBLE_DEVICES
=
0
\
python rome_infer.py
\
--model_id_or_path
ZhipuAI/chatglm3-6b-32k
\
--model_revision
master
\
--template_type
AUTO
\
--dtype
AUTO
\
--max_new_tokens
128
\
--temperature
0.1
\
--top_p
0.7
\
--do_sample
true
\
--rome_request_file
rome_example/request.json
ms-swift/examples/pytorch/llm/scripts/chatglm3_6b_base/lora/infer.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: V100, A10, 3090
PYTHONPATH
=
../../..
\
CUDA_VISIBLE_DEVICES
=
0
\
python llm_infer.py
\
--ckpt_dir
"output/chatglm3-6b-base/vx-xxx/checkpoint-xxx"
\
--load_dataset_config
true
\
--max_new_tokens
2048
\
--temperature
0.7
\
--top_p
0.7
\
--repetition_penalty
1.
\
--do_sample
true
\
--merge_lora
false
\
ms-swift/examples/pytorch/llm/scripts/chatglm3_6b_base/lora/sft.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: V100, A10, 3090
# 16GB GPU memory
PYTHONPATH
=
../../..
\
CUDA_VISIBLE_DEVICES
=
0
\
python llm_sft.py
\
--model_id_or_path
ZhipuAI/chatglm3-6b-base
\
--model_revision
master
\
--sft_type
lora
\
--tuner_backend
peft
\
--template_type
chatglm-generation
\
--dtype
AUTO
\
--output_dir
output
\
--dataset
dureader-robust-zh
\
--num_train_epochs
1
\
--max_length
2048
\
--check_dataset_strategy
warning
\
--lora_rank
8
\
--lora_alpha
32
\
--lora_dropout_p
0.05
\
--lora_target_modules
DEFAULT
\
--gradient_checkpointing
true
\
--batch_size
1
\
--weight_decay
0.1
\
--learning_rate
1e-4
\
--gradient_accumulation_steps
16
\
--max_grad_norm
0.5
\
--warmup_ratio
0.03
\
--eval_steps
100
\
--save_steps
100
\
--save_total_limit
2
\
--logging_steps
10
\
ms-swift/examples/pytorch/llm/scripts/chatglm3_6b_base/lora_ddp_ds/infer.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: 3090
PYTHONPATH
=
../../..
\
CUDA_VISIBLE_DEVICES
=
0
\
python llm_infer.py
\
--ckpt_dir
"output/chatglm3-6b-base/vx-xxx/checkpoint-xxx"
\
--load_dataset_config
true
\
--max_new_tokens
2048
\
--temperature
0.7
\
--top_p
0.7
\
--repetition_penalty
1.
\
--do_sample
true
\
--merge_lora
false
\
ms-swift/examples/pytorch/llm/scripts/chatglm3_6b_base/lora_ddp_ds/sft.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: 2 * 3090
# 2 * 17GB GPU memory
nproc_per_node
=
2
PYTHONPATH
=
../../..
\
CUDA_VISIBLE_DEVICES
=
0,1
\
torchrun
\
--nproc_per_node
=
$nproc_per_node
\
--master_port
29500
\
llm_sft.py
\
--model_id_or_path
ZhipuAI/chatglm3-6b-base
\
--model_revision
master
\
--sft_type
lora
\
--tuner_backend
peft
\
--template_type
chatglm-generation
\
--dtype
AUTO
\
--output_dir
output
\
--ddp_backend
nccl
\
--dataset
dureader-robust-zh
\
--num_train_epochs
1
\
--max_length
2048
\
--check_dataset_strategy
warning
\
--lora_rank
8
\
--lora_alpha
32
\
--lora_dropout_p
0.05
\
--lora_target_modules
DEFAULT
\
--gradient_checkpointing
true
\
--batch_size
1
\
--weight_decay
0.1
\
--learning_rate
1e-4
\
--gradient_accumulation_steps
$(
expr
16 /
$nproc_per_node
)
\
--max_grad_norm
0.5
\
--warmup_ratio
0.03
\
--eval_steps
100
\
--save_steps
100
\
--save_total_limit
2
\
--logging_steps
10
\
--deepspeed
default-zero2
\
ms-swift/examples/pytorch/llm/scripts/codefuse_codellama_34b/lora/infer.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: V100, A10, 3090
PYTHONPATH
=
../../..
\
CUDA_VISIBLE_DEVICES
=
0
\
python llm_infer.py
\
--ckpt_dir
"output/codefuse-codellama-34b-chat/vx-xxx/checkpoint-xxx"
\
--load_dataset_config
true
\
--use_flash_attn
true
\
--max_new_tokens
2048
\
--temperature
0.3
\
--top_p
0.7
\
--repetition_penalty
1.
\
--do_sample
true
\
--merge_lora
false
\
ms-swift/examples/pytorch/llm/scripts/codefuse_codellama_34b/lora/sft.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: V100, A10, 3090
# 18GB GPU memory
PYTHONPATH
=
../../..
\
CUDA_VISIBLE_DEVICES
=
0
\
python llm_sft.py
\
--model_type
codefuse-codellama-34b-chat
\
--sft_type
lora
\
--tuner_backend
peft
\
--template_type
AUTO
\
--dtype
fp16
\
--output_dir
output
\
--dataset
xxx.jsonl
\
--val_dataset
yyy.jsonl
\
--num_train_epochs
1
\
--max_length
4096
\
--check_dataset_strategy
warning
\
--lora_rank
8
\
--lora_alpha
32
\
--lora_dropout_p
0.05
\
--lora_target_modules
DEFAULT
\
--gradient_checkpointing
true
\
--batch_size
1
\
--weight_decay
0.1
\
--learning_rate
1e-4
\
--gradient_accumulation_steps
16
\
--max_grad_norm
0.5
\
--warmup_ratio
0.03
\
--eval_steps
100
\
--save_steps
100
\
--save_total_limit
2
\
--logging_steps
10
\
--use_flash_attn
true
\
ms-swift/examples/pytorch/llm/scripts/codegeex2_6b/lora_ddp_ds/infer.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: 3090
PYTHONPATH
=
../../..
\
CUDA_VISIBLE_DEVICES
=
0
\
python llm_infer.py
\
--ckpt_dir
"output/codegeex2-6b/vx-xxx/checkpoint-xxx"
\
--load_dataset_config
true
\
--max_new_tokens
2048
\
--temperature
0.1
\
--top_p
0.7
\
--repetition_penalty
1.
\
--do_sample
true
\
--merge_lora
false
\
ms-swift/examples/pytorch/llm/scripts/codegeex2_6b/lora_ddp_ds/sft.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: 2 * 3090
# 2 * 20GB GPU memory
nproc_per_node
=
2
PYTHONPATH
=
../../..
\
CUDA_VISIBLE_DEVICES
=
0,1
\
torchrun
\
--nproc_per_node
=
$nproc_per_node
\
--master_port
29500
\
llm_sft.py
\
--model_type
codegeex2-6b
\
--model_revision
master
\
--sft_type
lora
\
--tuner_backend
peft
\
--dtype
AUTO
\
--output_dir
output
\
--ddp_backend
nccl
\
--dataset
leetcode-python-en
\
--num_train_epochs
1
\
--max_length
4096
\
--check_dataset_strategy
warning
\
--lora_rank
8
\
--lora_alpha
32
\
--lora_dropout_p
0.05
\
--lora_target_modules
DEFAULT
\
--gradient_checkpointing
true
\
--batch_size
1
\
--weight_decay
0.1
\
--learning_rate
1e-4
\
--gradient_accumulation_steps
$(
expr
16 /
$nproc_per_node
)
\
--max_grad_norm
0.5
\
--warmup_ratio
0.03
\
--eval_steps
100
\
--save_steps
100
\
--save_total_limit
2
\
--logging_steps
10
\
--deepspeed
default-zero2
\
ms-swift/examples/pytorch/llm/scripts/codeqwen1half_7b_chat/lora/infer.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: 3090
CUDA_VISIBLE_DEVICES
=
0
\
swift infer
\
--ckpt_dir
"output/codeqwen1half-7b-chat/vx-xxx/checkpoint-xxx"
\
--load_dataset_config
true
\
--max_new_tokens
2048
\
--temperature
0.1
\
--top_p
0.7
\
--repetition_penalty
1.
\
--do_sample
true
\
--merge_lora
false
\
ms-swift/examples/pytorch/llm/scripts/codeqwen1half_7b_chat/lora/sft.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: 3090,A10,V100...
# 20GB GPU memory
CUDA_VISIBLE_DEVICES
=
0
\
swift sft
\
--model_type
codeqwen1half-7b-chat
\
--model_revision
master
\
--sft_type
lora
\
--tuner_backend
peft
\
--dtype
AUTO
\
--output_dir
output
\
--dataset
leetcode-python-en
\
--num_train_epochs
3
\
--max_length
2048
\
--check_dataset_strategy
warning
\
--lora_rank
8
\
--lora_alpha
32
\
--lora_dropout_p
0.05
\
--lora_target_modules
DEFAULT
\
--gradient_checkpointing
true
\
--batch_size
1
\
--weight_decay
0.1
\
--learning_rate
1e-4
\
--gradient_accumulation_steps
16
\
--max_grad_norm
0.5
\
--warmup_ratio
0.03
\
--eval_steps
100
\
--save_steps
100
\
--save_total_limit
2
\
--logging_steps
10
\
ms-swift/examples/pytorch/llm/scripts/codeqwen1half_7b_chat_awq/lora/infer.sh
0 → 100644
View file @
f7db21eb
# Experiment env: A10, RTX3090/4090, A100
CUDA_VISIBLE_DEVICES
=
0
\
swift infer
\
--ckpt_dir
"output/codeqwen1half-7b-chat-awq/vx-xxx/checkpoint-xxx"
\
--load_dataset_config
true
\
--use_flash_attn
false
\
--max_new_tokens
2048
\
--temperature
0.1
\
--top_p
0.7
\
--repetition_penalty
1.
\
--do_sample
true
\
--stream
false
\
--merge_lora
false
\
ms-swift/examples/pytorch/llm/scripts/codeqwen1half_7b_chat_awq/lora/sft.sh
0 → 100644
View file @
f7db21eb
# Experiment env: A10, RTX3090/4090, A100
CUDA_VISIBLE_DEVICES
=
0
\
swift sft
\
--model_type
codeqwen1half-7b-chat-awq
\
--dataset
leetcode-python-en
\
--batch_size
4
\
--max_length
2048
\
--gradient_accumulation_steps
2
\
--learning_rate
5e-5
\
--use_flash_attn
true
\
--eval_steps
2000
\
--save_steps
2000
\
--num_train_epochs
3
\
--check_dataset_strategy
none
\
--gradient_checkpointing
true
\
--weight_decay
0.1
\
--max_grad_norm
1.0
\
--warmup_ratio
0.03
\
--save_total_limit
2
\
--logging_steps
10
\
--sft_type
lora
\
--lora_target_modules
ALL
\
--lora_rank
8
\
--lora_alpha
32
ms-swift/examples/pytorch/llm/scripts/cogagent_18b_chat/lora/infer.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: V100, A10, 3090
CUDA_VISIBLE_DEVICES
=
0
\
swift infer
\
--ckpt_dir
"output/cogagent-18b-chat/vx-xxx/checkpoint-xx"
\
--load_args_from_ckpt_dir
true
\
--eval_human
true
\
--max_new_tokens
2048
\
--temperature
0.3
\
--top_p
0.7
\
--repetition_penalty
1.
\
--do_sample
true
\
--merge_lora
false
\
ms-swift/examples/pytorch/llm/scripts/cogagent_18b_chat/lora/sft.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: 2 * A100
# 2 * 45GB
CUDA_VISIBLE_DEVICES
=
0,1
\
swift sft
\
--model_type
cogagent-18b-chat
\
--sft_type
lora
\
--tuner_backend
peft
\
--dtype
AUTO
\
--output_dir
output
\
--dataset
coco-en-2-mini
\
--num_train_epochs
2
\
--max_length
2048
\
--check_dataset_strategy
warning
\
--lora_rank
8
\
--lora_alpha
32
\
--lora_dropout_p
0.05
\
--lora_target_modules
DEFAULT
\
--gradient_checkpointing
false
\
--batch_size
1
\
--weight_decay
0.1
\
--learning_rate
1e-4
\
--gradient_accumulation_steps
16
\
--max_grad_norm
0.5
\
--warmup_ratio
0.03
\
--eval_steps
100
\
--save_steps
100
\
--save_total_limit
2
\
--logging_steps
10
\
ms-swift/examples/pytorch/llm/scripts/custom/tigerbot_13b_chat/qlora_ddp_ds/infer.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: A10
PYTHONPATH
=
../../..
\
CUDA_VISIBLE_DEVICES
=
0
\
python llm_infer.py
\
--ckpt_dir
"output/tigerbot-13b-chat/vx-xxx/checkpoint-xxx"
\
--load_dataset_config
true
\
--max_new_tokens
2048
\
--temperature
0.3
\
--top_p
0.7
\
--repetition_penalty
1.
\
--do_sample
true
\
--merge_lora
false
\
ms-swift/examples/pytorch/llm/scripts/custom/tigerbot_13b_chat/qlora_ddp_ds/sft.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: 2 * 3090
# 2 * 12GB GPU memory
nproc_per_node
=
2
PYTHONPATH
=
../../..
\
CUDA_VISIBLE_DEVICES
=
0,1
\
torchrun
\
--nproc_per_node
=
$nproc_per_node
\
--master_port
29500
\
llm_sft.py
\
--model_type
tigerbot-13b-chat
\
--sft_type
lora
\
--tuner_backend
peft
\
--template_type
AUTO
\
--dtype
AUTO
\
--output_dir
output
\
--ddp_backend
nccl
\
--dataset
stsb-en
\
--num_train_epochs
1
\
--max_length
2048
\
--check_dataset_strategy
warning
\
--quantization_bit
4
\
--bnb_4bit_comp_dtype
AUTO
\
--lora_rank
8
\
--lora_alpha
32
\
--lora_dropout_p
0.05
\
--lora_target_modules
DEFAULT
\
--gradient_checkpointing
true
\
--batch_size
1
\
--weight_decay
0.1
\
--learning_rate
1e-4
\
--gradient_accumulation_steps
$(
expr
16 /
$nproc_per_node
)
\
--max_grad_norm
0.5
\
--warmup_ratio
0.03
\
--eval_steps
100
\
--save_steps
100
\
--save_total_limit
2
\
--logging_steps
10
\
--deepspeed
default-zero2
\
ms-swift/examples/pytorch/llm/scripts/custom/tigerbot_7b/lora_ddp_ds/infer.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: A10
PYTHONPATH
=
../../..
\
CUDA_VISIBLE_DEVICES
=
0
\
python llm_infer.py
\
--ckpt_dir
"output/tigerbot-13b/vx-xxx/checkpoint-xxx"
\
--load_dataset_config
true
\
--max_new_tokens
2048
\
--temperature
0.3
\
--top_p
0.7
\
--repetition_penalty
1.
\
--do_sample
true
\
--merge_lora
false
\
ms-swift/examples/pytorch/llm/scripts/custom/tigerbot_7b/lora_ddp_ds/sft.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: 2 * 3090
# 2 * 16GB GPU memory
nproc_per_node
=
2
PYTHONPATH
=
../../..
\
CUDA_VISIBLE_DEVICES
=
0,1
\
torchrun
\
--nproc_per_node
=
$nproc_per_node
\
--master_port
29500
\
llm_sft.py
\
--model_type
tigerbot-7b
\
--sft_type
lora
\
--tuner_backend
peft
\
--template_type
default-generation
\
--dtype
AUTO
\
--output_dir
output
\
--ddp_backend
nccl
\
--dataset
stsb-en
\
--num_train_epochs
1
\
--max_length
2048
\
--check_dataset_strategy
warning
\
--lora_rank
8
\
--lora_alpha
32
\
--lora_dropout_p
0.05
\
--lora_target_modules
DEFAULT
\
--gradient_checkpointing
true
\
--batch_size
1
\
--weight_decay
0.1
\
--learning_rate
1e-4
\
--gradient_accumulation_steps
$(
expr
16 /
$nproc_per_node
)
\
--max_grad_norm
0.5
\
--warmup_ratio
0.03
\
--eval_steps
100
\
--save_steps
100
\
--save_total_limit
2
\
--logging_steps
10
\
--deepspeed
default-zero2
\
ms-swift/examples/pytorch/llm/scripts/dbrx-instruct/lora_mp/infer.sh
0 → 100644
View file @
f7db21eb
# Experimental environment: 4 * A100
# 4 * 65GB GPU memory
CUDA_VISIBLE_DEVICES
=
0,1,2,3
\
swift infer
\
--ckpt_dir
"output/dbrx-instruct/vx-xxx/checkpoint-xxx"
\
--load_dataset_config
true
\
--use_flash_attn
true
\
--temperature
0.3
\
--top_p
0.7
\
--repetition_penalty
1.
\
--do_sample
true
\
--merge_lora
false
\
Prev
1
…
22
23
24
25
26
27
28
29
30
…
34
Next
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment