LLM library for training and evaluating large language models
Top 43.8% on sourcepulse
LLMBox is a comprehensive Python library for training and evaluating Large Language Models (LLMs), targeting researchers and practitioners. It offers a unified pipeline for diverse training strategies and extensive model evaluation capabilities, aiming to streamline LLM development and benchmarking.
How It Works
LLMBox provides a flexible framework supporting multiple training paradigms including Supervised Fine-tuning (SFT), Pre-training (PT), PPO, and DPO. It integrates parameter-efficient fine-tuning methods like LoRA and QLoRA, and efficiency boosters such as Flash Attention and DeepSpeed. For utilization, it supports various inference acceleration techniques like KV Cache management and vLLM, alongside advanced evaluation methods (generation, perplexity, probability) across 59+ datasets, with support for In-Context Learning and Chain-of-Thought prompting.
Quick Start & Requirements
git clone
and pip install -r requirements.txt
. Minimal requirements for OpenAI model evaluation are available via requirements-openai.txt
.python train.py --model_name_or_path meta-llama/Llama-2-7b-hf ...
python inference.py -m gpt-3.5-turbo -d copa
Highlighted Details
Maintenance & Community
@xansar
for issue resolution.Licensing & Compatibility
Limitations & Caveats
The README notes that vLLM, while faster, may require parameter adjustments for optimal results compared to default transformer configurations. Specific dataset evaluation methods (e.g., normalized accuracy for ARC, OpenbookQA, RACE) are mentioned, implying potential variations in how metrics are reported across different datasets and methods.
1 month ago
1 day