georgian-io/LLM-Finetuning-Toolkit
Toolkit for fine-tuning, ablating and unit-testing open-source LLMs.
What it solves
This toolkit provides a streamlined, configuration-based approach to LLM fine-tuning experiments. It eliminates the need to write repetitive boilerplate code for every experiment, allowing users to systematically test different models, prompts, and optimization strategies to find the best performing configuration.
How it works
The tool is a CLI application that uses a single YAML configuration file to manage the entire pipeline. It handles data ingestion (from Hugging Face, JSON, or CSV), model loading with quantization (via bitsandbytes), and fine-tuning using LoRA. It also includes a built-in quality assurance (QA) system to test the fine-tuned model's output against ground truth data.
Who it’s for
Developers and AI researchers who need to run ablation studies and fine-tuning experiments on open-source LLMs using their own datasets.
Highlights
- Config-driven workflow: Manage prompts, models, and LoRA parameters via YAML.
- Ablation study support: Run multiple experiments by specifying lists of models, prompts, or hyperparameters in the config.
- Flexible data ingestion: Supports Hugging Face datasets, CSV, and JSON files.
- Integrated QA: Built-in metrics like length tests and word overlap to validate model behavior.
- Checkpointing: Automatically uses unique hashes for experiment directories to resume interrupted training.
- Hardware optimization: Support for Flash Attention 2 for faster training on supported GPUs.