Skip to main content
QUICK REVIEW

[Paper Review] Evolutionary Optimization of Model Merging Recipes

Takuya Akiba, Makoto Shing|arXiv (Cornell University)|Mar 19, 2024
Scheduling and Optimization AlgorithmsEngineering3 citations
TL;DR

This paper proposes EvoLLM, an evolutionary algorithm that automatically discovers optimal combinations of open-source foundation models by optimizing both parameter space (model weights) and data flow space (inference pathways), resulting in state-of-the-art performance for a 7B-parameter Japanese LLM with math reasoning and a culturally-aware Japanese VLM, outperforming larger models without explicit fine-tuning.

ABSTRACT

Large language models (LLMs) have become increasingly capable, but their development often requires substantial computational resources. While model merging has emerged as a cost-effective promising approach for creating new models by combining existing ones, it currently relies on human intuition and domain knowledge, limiting its potential. Here, we propose an evolutionary approach that overcomes this limitation by automatically discovering effective combinations of diverse open-source models, harnessing their collective intelligence without requiring extensive additional training data or compute. Our approach operates in both parameter space and data flow space, allowing for optimization beyond just the weights of the individual models. This approach even facilitates cross-domain merging, generating models like a Japanese LLM with Math reasoning capabilities. Surprisingly, our Japanese Math LLM achieved state-of-the-art performance on a variety of established Japanese LLM benchmarks, even surpassing models with significantly more parameters, despite not being explicitly trained for such tasks. Furthermore, a culturally-aware Japanese VLM generated through our approach demonstrates its effectiveness in describing Japanese culture-specific content, outperforming previous Japanese VLMs. This work not only contributes new state-of-the-art models back to the open-source community, but also introduces a new paradigm for automated model composition, paving the way for exploring alternative, efficient approaches to foundation model development.

Motivation & Objective

  • To automate the creation of high-performing foundation models by replacing human intuition in model merging with a systematic, evolutionary approach.
  • To overcome the limitations of human-designed merging recipes that rely on domain expertise and are prone to suboptimal combinations.
  • To explore cross-domain model merging, such as combining non-English language models with reasoning or vision models, to generate novel, emergent capabilities.
  • To develop a scalable, cost-effective alternative to large-scale pretraining by leveraging existing open-source models.
  • To demonstrate that evolutionary optimization can yield models with surprising generalization and performance, even surpassing larger models on benchmarks.

Proposed method

  • The method employs an evolutionary algorithm that searches over both parameter space (model weights) and data flow space (inference pathways) to discover optimal merging recipes.
  • It uses weighted averaging and interpolation techniques such as SLERP and DARE-TIES to combine model weights in parameter space.
  • In data flow space, it evolves the structure of the inference path, inspired by neural architecture search and morphology evolution, to determine how intermediate features are combined.
  • The evolutionary process evaluates candidate models on a diverse set of benchmark tasks, including Japanese NLP, math reasoning, and vision-language understanding.
  • The framework supports hybrid merging strategies that combine parameter and data flow optimization, enabling more flexible and powerful model compositions.
  • The approach is applied to create EvoLLM-JP (a Japanese LLM with math reasoning) and EvoVLM-JP (a culturally-aware VLM), both open-sourced for community use.

Experimental results

Research questions

  • RQ1Can evolutionary algorithms discover more effective model merging recipes than human intuition, especially in cross-domain settings?
  • RQ2Can merging models from disparate domains—such as Japanese language and mathematical reasoning—produce emergent capabilities not present in the source models?
  • RQ3Does optimizing for a broad range of tasks lead to better generalization and state-of-the-art performance, even without explicit optimization for any single benchmark?
  • RQ4Can a 7B-parameter model outperform larger 70B-parameter models through evolutionary merging, indicating high efficiency and knowledge distillation?
  • RQ5Can evolutionary model merging generate models that are culturally aware and perform better on domain-specific datasets, such as Japanese image-description pairs?

Key findings

  • The 7B-parameter EvoLLM-JP achieved state-of-the-art performance on multiple Japanese LLM benchmarks, outperforming several previous 70B-parameter models despite no explicit training for these tasks.
  • The EvoVLM-JP model achieved top results on a domestically-sourced dataset of Japanese image-description pairs, demonstrating superior performance on culture-specific visual content.
  • The evolutionary approach discovered unintuitive merging recipes that led to emergent capabilities, such as math reasoning in a Japanese LLM, without any fine-tuning for that task.
  • The method achieved high efficiency, producing competitive models without additional training data or compute, challenging the paradigm of expensive model pretraining.
  • The approach demonstrated surprising generalization, with models performing well on a wide array of benchmarks beyond the ones used during optimization.
  • The open-sourced EvoLLM-JP and EvoVLM-JP models are now available to the community, enabling further research and development in efficient foundation model creation.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.