Good Reasoning Makes Good Demonstrations: Implicit Reasoning Quality Supervision via In-Context Reinforcement Learning
Authors: Tiehua Mei, Minxuan Lv, Leiyu Pan, Zhenpeng Su, Hongru Hou, Hengrui Chen, Ao Xu, Deqing Yang
Organizations: School of Data Science, Fudan University · University of Chinese Academy of Sciences · College of Intelligence and Computing, Tianjin University
Reinforcement Learning with Verifiable Rewards (RLVR) improves reasoning in large language models but treats all correct solutions equally, potentially reinforcing flawed traces that arrive at correct answers by chance. We observe that better reasoning makes better demonstrations: high-quality solutions serve as more effective in-context examples than low-quality ones. We term this teaching ability Demonstration Utility, and show that the policy model's own in-context learning ability provides an efficient way to measure it, yielding a quality signal termed Evidence Gain. To leverage this signal during training, we introduce In-Context RLVR, which prepends demonstrations before each rollout. Theoretically, we prove that this simple input modification implicitly reweights rewards by a factor approximately proportional to Evidence Gain, assigning higher weights to high-quality traces without requiring costly computation. Experiments on mathematical reasoning benchmarks demonstrate consistent improvements in both accuracy and reasoning quality over standard RLVR baselines. Our codes and datasets are available at https://github.com/Mithas-114/IC-DAPO.
Figures & tables
Figure 1: Mean Evidence Gain by quality score with 95% confidence intervals on two models.
Length
LogProb
MajorVote
Δ (Ours)
1.5B
− 0.147
0.129
0.079
0.405
7B
− 0.161
0.178
0.109
0.444
Table 1: Spearman correlation ( ρ ) between proxy signals and reasoning quality. Evidence Gain achieves stronger correlation than alternatives.
Method
AIME24
AIME25
HMMT25
MATH500
AMC23
Olympiad
Average
Time/Step (s)
DS-R1-Distill-Qwen-1.5B
29.2
24.1
13.1
86.0
73.7
51.8
46.3
–
+ GRPO ( Shao et al., 2024 )
33.4
28.1
16.6
88.3
79.3
56.2
50.3
457.4
+ IC-GRPO (Ours)
38.3 ↑
30.6 ↑
17.7 ↑
89.5 ↑
82.5 ↑
56.9 ↑
52.6 ↑
461.8
+ DAPO ( Yu et al., 2025a )
40.0
28.4
19.2
90.0
84.4
61.6
53.9
459.6
+ CISPO ( MiniMax et al., 2025 )
32.9
25.1
13.2
85.8
80.9
54.9
48.8
466.3
+ GSPO ( Zheng et al., 2025 )
42.5
33.6
19.0
90.3
85.9
62.6
55.7
437.3
Table 2: Performance comparison across mathematical reasoning benchmarks. Bold and underline indicate the best and second-best results respectively. ↑ denotes improvement over the corresponding baseline (GRPO or DAPO). Notably, training times are incomparable across scales due to different GPU configurations (32 vs. 128 GPUs). Given this high GPU requirements at 7B scales, GSPO and CISPO are evaluated only at 1.5B.
Figure 2: Training dynamics of Evidence Gain, quality score, and their correlation ( ρ ) across training steps.
Figure 3: Spearman correlation between Evidence Gain and individual quality dimensions, alongside mean scores for each dimension. Evaluated on DeepSeek-R1-Distill-Qwen-1.5B with the same setup as Section 2 .
Method
AIME24
AIME25
HMMT25
MATH500
AMC23
Olympiad
Average
DS-R1-Distill-Qwen-1.5B
29.2
24.1
13.1
86.0
73.7
51.8
46.3
+ DAPO ( Yu et al., 2025a )
40.0
28.4
19.2
90.0
84.4
61.6
53.9
+ IC-DAPO (V3.1)
44.5 ↑
32.3 ↑
19.5 ↑
90.3 ↑
85.8 ↑
61.7 ↑
55.7 ↑
+ IC-DAPO (R1)
45.6 ↑
34.2 ↑
19.7 ↑
90.6 ↑
86.2 ↑
62.1 ↑
56.4 ↑
DS-R1-Distill-Qwen-7B
54.5
39.1
26.2
93.6
90.6
67.0
61.8
+ DAPO ( Yu et al., 2025a )
62.0
45.9
27.4
94.1
92.3
69.9
65.3
Appendix
Table 5: Ablation on demonstration quality. IC-DAPO (R1) uses refined reasoning traces from DeepSeek-R1, while IC-DAPO (V3.1) uses solutions from DeepSeek-V3.1, a non-reasoning model. Both variants outperform DAPO, with R1 demonstrations yielding stronger results. Bold and underline indicate best and second-best results. ↑ denotes improvement over DAPO.
Figure 4: Spearman correlation matrix between DeepSeek-V3.2 quality scores and four human expert ratings on 100 sampled reasoning traces, together with inter rater correlations among experts.
Method
Scale
HumanEval
LCB
IFBench
IFEval
MMLU
DAPO
1.5B
73.6
30.4
9.1
38.3
46.6
IC-DAPO
1.5B
75.5
31.9
10.7
40.6
48.3
DAPO
7B
90.5
48.5
13.3
56.7
65.7
IC-DAPO
7B
92.3
49.8
14.2
58.6
67.3
Appendix
Table 6: Cross-domain zero-shot evaluation on code generation (HumanEval, LCB), instruction following (IFBench, IFEval), and general knowledge (MMLU).
Figure 5: Training dynamics across 1.5B and 7B models. IC-DAPO variants consistently outperform DAPO on AIME24 and AIME25 while maintaining stable entropy throughout training.
Figure 6: Quality Evaluation Prompt Template. Placeholders {question} and {response} are replaced with the actual math problem and reasoning trace during evaluation.
Figure 7: Empirical verification of the log-linear relationship between logw(q,r)=logEe[exp(Δe)] and Δ(q,r)=Ee[Δe] . Strong Pearson correlations ( r=0.855 for 1.5B, r=0.822 for 7B) confirm that Evidence Gain serves as a reliable proxy for the implicit weight.