This is a modified version of LLaMA-Factory that supports training ChatTS models.
- 2025/08/01: We have updated the code for data preprocessing. No need to preprocess the dataset before training now!
- Please download the latest datasets (we have updated them) from ChatTS-Training-Dataset.
- If you want to generate the datasets by yourself, please use
noencoding instead ofspencoding when generating the data.
Following the steps in LLaMA-Factory.
Make sure that flash-attention and DeepSpeed are installed.
- Put your training data in
data/. - Set your training data path in
data/dataset_info.json. - Configure your base model (see the instructions below), output model, training datasets and training parameters in
scripts/train_chatts.sh. - Run
bash scripts/train_chatts.shfor full SFT. Runbash scripts/train_lora.shfor LoRA SFT.
- Download the base models (Qwen2 Series) from huggingface
- Replace
*.py,added_tokens.json,config.json,special_tokens_map.json,tokenizer_config.jsonin the base model folder with the files in the ChatTS's model (https://huggingface.co/bytedance-research/ChatTS-14B) folder.