HBO: Hierarchical Balancing Optimization for Fine-Tuning Large Language Models

Weixuan Wang, Minghao Wu, Barry Haddow, Alexandra Birch
5/18/2025
cs.CL

No official code found. Best implementation: weixuan-wang123/HBO (1 star, last commit 2026-02-02).

Abstract

Fine-tuning large language models (LLMs) on a mixture of diverse datasets poses challenges due to data imbalance and heterogeneity. Existing methods often address these issues across datasets (globally) but overlook the imbalance and heterogeneity within individual datasets (locally), which limits their effectiveness. We introduce Hierarchical Balancing Optimization (HBO), a novel method that enables LLMs to autonomously adjust data allocation during fine-tuning both across datasets (globally) and within each individual dataset (locally). HBO employs a bilevel optimization strategy with two types of actors: a Global Actor, which balances data sampling across different subsets of the training mixture, and several Local Actors, which optimizes data usage within each subset based on difficulty levels. These actors are guided by reward functions derived from the LLM's training state, which measure learning progress and relative performance improvement. We evaluate HBO on three LLM backbones across nine diverse tasks in multilingual and multitask setups. Results show that HBO consistently outperforms existing baselines, achieving significant accuracy gains. Our in-depth analysis further demonstrates that both the global actor and local actors of HBO effectively adjust data usage during fine-tuning. HBO provides a comprehensive solution to the challenges of data imbalance and heterogeneity in LLM fine-tuning, enabling more effective training across diverse datasets.

View on arXivView PDF

Code Implementations(1)

weixuan-wang123/HBOCommunity100%
10Shell, PythonMay 16, 20258 months ago

Similar Papers

Cite this paper

@article{wang2025hbo,
  title  = {HBO: Hierarchical Balancing Optimization for Fine-Tuning Large Language Models},
  author = {Weixuan Wang and Minghao Wu and Barry Haddow and Alexandra Birch},
  year   = {2025},
  eprint = {2505.12300},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2505.12300v3}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2505.12300.svg)](https://codeofpaper.com/paper/2505.12300)

Discussion