BTS: Harmonizing Specialized Experts into a Generalist LLM

Qizhen Zhang, Prajjwal Bhargava, Chloe Bi, Chris X. Cai, Jakob Foerster +7 more
1/31/2025
cs.CLcs.LG

No confident code implementation found for this paper.

Abstract

We present Branch-Train-Stitch (BTS), an efficient and flexible training algorithm for combining independently trained large language model (LLM) experts into a single, capable generalist model. Following Li et al., we start with a single seed language model which is branched into domain-specific (e.g., coding or math) experts with continual pretraining. BTS combines experts into a generalist model using lightweight stitch layers, which are inserted between frozen experts and the seed LLM, and trained on a small datamix of the expert domains. Stitch layers enable the seed LLM to integrate representations from any number of experts during the forward pass, allowing it to generalize to new domains, despite remaining frozen. Because BTS does not alter the constituent LLMs, BTS provides a modular and flexible approach: experts can be easily removed and new experts can be added with only a small amount of training. Compared to alternative model merging approaches, BTS yields the best generalist performance on a variety of downstream tasks, retaining the specialized capabilities of each of the experts.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{zhang2025bts,
  title  = {BTS: Harmonizing Specialized Experts into a Generalist LLM},
  author = {Qizhen Zhang and Prajjwal Bhargava and Chloe Bi and Chris X. Cai and Jakob Foerster and Jeremy Fu and Punit Singh Koura and Ruan Silva and Sheng Shen and Emily Dinan and Suchin Gururangan and Mike Lewis},
  year   = {2025},
  eprint = {2502.00075},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2502.00075v1}
}

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/2502.00075.svg)](https://codeofpaper.com/paper/2502.00075)

Discussion