arXiv:2610.41769cs.CLOct 2026

Manuscript Offprint

arXiv:2610.41769

Stepwise-Querying: Distilling Reasoning without Access to Teacher Chain-of-Thought

Dicong Yu, Wenhua Wang, Tian Wang

Abstract

Reasoning distillation is widely used to transfer the reasoning capabilities of large language models to smaller students through teacher-generated supervision. In the black-box setting, however, teachers may expose only final answers and brief solutions, leaving intermediate calculations and validity conditions unavailable and thus limiting the reasoning supervision available for distillation. We propose Stepwise-Querying, which elicits step-specific explanations without requiring access to the teacher's internal chain-of-thought (CoT) traces. Independent queries to the same teacher request intermediate derivations, validity checks, and corrections for individual steps, the assembled solutions are then used for standard supervised fine-tuning. Across two teachers, two students, and four mathematics and code benchmarks, our method achieves the highest score in 14 of 16 comparisons with three baselines. We further introduce Stepwise Explanation Information Gain (SEIG), a diagnostic based on the log-ratio of a frozen student's probabilities of correct step completion under stepwise and global explanations. Analyses on GSM8K show that incorrect-answer trajectories can remain useful when they preserve valid intermediate reasoning, while further decomposition yields limited additional gains.

1 Introduction

Reasoning distillation transfers capabilities to smaller language models through teacher-generated reasoning supervision (Magister et al., 2023). In a black-box settings, however, teachers may expose only final answers and brief solutions, leaving intermediate calculations and validity conditions unavailable (Zhang et al., 2026), which limits the reasoning supervision available for distillation. MathFimer

expands mathematical solutions with a trained fill-in-the-middle model (Yan et al., 2026), while Trace Inversion synthesizes detailed traces from observable questions, answers, and optional summaries (Zhang et al., 2026). These approaches motivate studying how further queries to the same teacher can turn brief solutions into useful training data.

The quality of such data depends on both query organization and prompting. Research on reverse chain-of-thought generation identifies post-hoc rationalization (Peng et al., 2026), and answer-conditioned distillation experiments distinguish instructions to rationalize toward an answer from answer visibility alone (Lee et al., 2026). A simple example illustrates the problem: for (x−1)2=2\sqrt{(x-1)^2} = 2, an initial answer x=3x = 3 is valid but incomplete. A request to explain this answer may produce a correct substitution without discovering x=−1x = -1. A prompt requesting independent derivation, enumeration of all cases, and correction of the candidate instead targets the complete solution. This example motivates a comparison; it does not establish that either prompt reliably produces a particular outcome.

Considering the above observation, we propose Stepwise-Querying, which targets independent derivation and correction with prompts. Firstly, the teacher provides a candidate answer and brief solution steps. Then, subsequent calls target individual steps, requesting intermediate calculations, mathematical justifications, and necessary conditions, and each call uses an independent context containing the original problem and initial solution. The prompts treat the initial candidate answer and steps as provisional, potentially incorrect or incomplete. They ask the teacher to derive the target step from the problem before comparing it with the candidate, and they allow the teacher to identify missing cases and pro-

Figure

Figure 1: Comparison of supervision construction. (a) Global CoT: a single teacher call produces one explanation for all steps. (b) Stepwise-Querying (ours): independent calls, each targeting one step under a shared initial context, are assembled, checked for validity, consistency, and completeness, and used for standard SFT.

pose corrections. The expanded solutions are then checked for consistency and completeness before being used for standard supervised fine-tuning, where the student receives only the original problem as input. Our study asks whether combining multiple targeted queries with these prompts improves supervision quality and student reasoning under controlled costs (Figure 1).

Our methodological contributions are:

  • A stepwise querying protocol for black-box reasoning distillation. We turn brief teacher solutions into detailed training data without access to internal CoT traces: each step receives an independent query whose prompt asks the teacher to derive the step from the problem, verify its validity and completeness, and correct the provisional candidate answer—rather than to rationalize toward it. The protocol applies to any multi-step task, from mathematics to code generation.

  • Stepwise Explanation Information Gain (SEIG), a diagnostic for local supervisory value. SEIG measures the log-ratio of a frozen student's probability of correct step completion under stepwise versus global CoT explanations, using only public explanation text and indepen-

dent verification labels, with no teacher logits or hidden traces required.

  • A controlled evaluation with actionable findings. Across two teachers, two students, and four benchmarks, our method achieves the best score in 14 of 16 comparisons with three published baselines and outperforms global CoT and answer-explanation supervision in all 16 settings. SEIG analyses further show that incorrect-answer trajectories remain useful when they preserve valid intermediate reasoning, and that recursive decomposition beyond the step level yields diminishing returns.