Fine-tuning tool for ChatGLM-6B
Top 13.3% on sourcepulse
This repository provides an efficient framework for fine-tuning the ChatGLM-6B language model using Parameter-Efficient Fine-Tuning (PEFT) techniques. It targets researchers and developers looking to adapt ChatGLM for specific tasks or datasets with reduced computational resources. The primary benefit is enabling effective fine-tuning on consumer-grade hardware.
How It Works
The framework leverages Hugging Face's PEFT library to implement various efficient fine-tuning methods, including LoRA, P-Tuning V2, Freeze, and Full Tuning. It supports supervised fine-tuning (SFT), reward modeling (RM), and Reinforcement Learning from Human Feedback (RLHF). The approach dynamically pads inputs to the longest sequence in a batch, accelerating training compared to padding to a fixed maximum length.
Quick Start & Requirements
pip install -r requirements.txt
CUDA_VISIBLE_DEVICES=0 python src/train_web.py
(single GPU only)Highlighted Details
Maintenance & Community
This repository will not be maintained in the future. Users are directed to follow LLaMA-Factory for continued development.
Licensing & Compatibility
Apache-2.0 License. Users must also adhere to the ChatGLM-6B model license. Compatible with commercial use, provided the ChatGLM model license is respected.
Limitations & Caveats
The project is no longer actively maintained. The Web UI currently only supports single-GPU training. Windows users may need a specific bitsandbytes
installation for QLoRA.
1 year ago
1 day