Table of Contents
Fetching ...

Reasoning Pattern Alignment Merging for Adaptive Reasoning

Zhaofeng Zhong, Wei Yuan, Tong Chen, Xiangyu Zhao, Quoc Viet Hung Nguyen, Hongzhi Yin

TL;DR

RPAM introduces Reasoning Pattern Alignment Merging to enable query-level adaptive reasoning by merging a Long-CoT model with a Short-CoT instruction model without retraining. It constructs a pattern-labeled calibration set and learns layer-wise merging coefficients through representation alignment to a positive model and a contrastive push away from a negative model, enabling Long-CoT on hard problems and Short-CoT on easy ones. Across seven benchmarks and two model scales, RPAM achieves substantial token reductions (up to about 63%) with minimal accuracy loss, outperforming several baselines and RL-based methods while maintaining lightweight calibration. This approach offers a practical, data-efficient path to balance reasoning quality and inference cost in large reasoning systems.

Abstract

Recent large reasoning models (LRMs) have made substantial progress in complex reasoning tasks, yet they often generate lengthy reasoning paths for every query, incurring unnecessary computation and latency. Existing speed-up approaches typically rely on retraining the model or designing sophisticated prompting, which are either prohibitively expensive or highly sensitive to the input and prompt formulation. In this work, we study model merging as a lightweight alternative for efficient reasoning: by combining a long chain-of-thought (Long-CoT) reasoning model with a Short-CoT instruction model, we obtain an adaptive reasoner without training from scratch or requiring large-scale additional data. Building on this idea, we propose Reasoning Pattern Alignment Merging (RPAM), a layer-wise model merging framework based on feature alignment to facilitate query-adaptive reasoning. RPAM first constructs a small pattern-labeled calibration set that assigns each query an appropriate reasoning pattern. It then optimizes layer-wise merging coefficients by aligning the merged model's intermediate representations with those of the selected model, while a contrastive objective explicitly pushes them away from the non-selected model. Experiments on seven widely used reasoning benchmarks show that RPAM substantially reduces inference cost while maintaining strong performance. Upon article acceptance, we will provide open-source code to reproduce experiments for RPAM.

Reasoning Pattern Alignment Merging for Adaptive Reasoning

TL;DR

RPAM introduces Reasoning Pattern Alignment Merging to enable query-level adaptive reasoning by merging a Long-CoT model with a Short-CoT instruction model without retraining. It constructs a pattern-labeled calibration set and learns layer-wise merging coefficients through representation alignment to a positive model and a contrastive push away from a negative model, enabling Long-CoT on hard problems and Short-CoT on easy ones. Across seven benchmarks and two model scales, RPAM achieves substantial token reductions (up to about 63%) with minimal accuracy loss, outperforming several baselines and RL-based methods while maintaining lightweight calibration. This approach offers a practical, data-efficient path to balance reasoning quality and inference cost in large reasoning systems.

Abstract

Recent large reasoning models (LRMs) have made substantial progress in complex reasoning tasks, yet they often generate lengthy reasoning paths for every query, incurring unnecessary computation and latency. Existing speed-up approaches typically rely on retraining the model or designing sophisticated prompting, which are either prohibitively expensive or highly sensitive to the input and prompt formulation. In this work, we study model merging as a lightweight alternative for efficient reasoning: by combining a long chain-of-thought (Long-CoT) reasoning model with a Short-CoT instruction model, we obtain an adaptive reasoner without training from scratch or requiring large-scale additional data. Building on this idea, we propose Reasoning Pattern Alignment Merging (RPAM), a layer-wise model merging framework based on feature alignment to facilitate query-adaptive reasoning. RPAM first constructs a small pattern-labeled calibration set that assigns each query an appropriate reasoning pattern. It then optimizes layer-wise merging coefficients by aligning the merged model's intermediate representations with those of the selected model, while a contrastive objective explicitly pushes them away from the non-selected model. Experiments on seven widely used reasoning benchmarks show that RPAM substantially reduces inference cost while maintaining strong performance. Upon article acceptance, we will provide open-source code to reproduce experiments for RPAM.
Paper Structure (22 sections, 9 equations, 7 figures, 7 tables)

This paper contains 22 sections, 9 equations, 7 figures, 7 tables.

Figures (7)

  • Figure 1: Overview of RPAM. The framework consists of two components: (I) Constructing a pattern-labeled (PL) dataset that identifies the optimal reasoning pattern (Long-CoT or Short-CoT) for each query $x$; (II) Performing layer-wise merging via feature alignment and contrastive enhanced shaping.
  • Figure 2: Comparison with RL-based training approaches. We report the average accuracy and response length on GSM8K, MATH500, and AIME24.
  • Figure 3: Details analysis across five MATH difficulty levels on Qwen3-4B model series, including accuracy, response length, and ratio of thinking. The difficulty grows from Level-1 to Level-5.
  • Figure 4: Effect of linear merging coefficients for merged model. As merging coefficients increase, accuracy improves while response length grows.
  • Figure 5: For a simple math problem from GSM8K, Qwen3-4B-Thinking produces a wrong answer with about 6825 tokens for reasoning, which contains many unnecessary steps and redundant tokens. In contrast, our RPAM adaptively chooses the Short-CoT pattern and directly produces a concise final answer with only 326 tokens.
  • ...and 2 more figures