Answer, review, revise
Self-refine (Madaan et al.) asks one model to improve its own output in a loop: it answers, then gives feedback on its answer, then rewrites the answer using that feedback, round after round, until the feedback says there is nothing left to fix or a round limit is reached. There is no second model, no reference answer and no training; the same weights write, criticise and revise. The idea is borrowed from how people draft and edit, and the paper reports gains on tasks such as dialogue responses and code readability, where a model can judge its output better than it can write it the first time.
This page runs self-refine with Qwen2.5-Math-1.5B-Instruct on GSM8K test rows 0–39, the model and problems of the Self-consistency tab. Round 0 is that tab's greedy answer, with the system prompt "Please reason step by step, and put your final answer within \boxed{}." Each later round adds two user turns to the same conversation, a request for feedback and a request to revise, and the model's reply to each. Every turn is greedy, so the run is deterministic, at most 512 tokens a turn.
The feedback and its verdict
Feedback is free text, so the loop needs a stopping signal it can read. The feedback request asks the model to end with "The solution is correct." or "The solution is incorrect.", and the page reads the last such sentence as the feedback's verdict. A pilot on ten problems found that the model ignores an instruction to write a "Verdict:" line but keeps to this sentence.
Two feedback requests are recorded, each its own conversation from the same round 0, and the toolbar switches between them. One asks the model to check its solution for a possible mistake. The other says there is an error: "There is an error in your solution above because of a lack of understanding of the question. What is the error?", Self-Refine's own feedback prompt for GSM8K, adapted from code to a written solution. The first tests whether the model finds its mistakes when asked; the second whether a model told it is wrong revises its way to the right answer, or away from it.
The panel The verdict shows the model's next-token probabilities at the word where it wrote its verdict, so a confident and a hesitant "correct" look different.
The conversation
The conversation is kept as the model's own token ids, and each new user turn is appended as the chat template writes it, so the model reads exactly the tokens it wrote. The panel Round r: feedback, then a revision shows the answer under review faded, the two requests in amber and the model's feedback and revision shaded by surprise, of each token under the model. A conversation that reaches the model's 4,096-token context would cut the last turn short; three rounds fit.
Does revising help?
Round 0 is right on 31 of the 40 problems. After three rounds both conversations are right on 29. Asked to check, the model fixed no wrong answer and broke two right ones: row 39 went from 18 to 36 in round 1, and row 13 lost its boxed answer in round 3. Told there was an error, it fixed one, row 7 (140 minutes to the reference 160), and broke three: rows 16 (230 to 170) and 23 (8 to no answer) in round 1, and row 13 in round 3. The panel Accuracy against tokens spent and its table give the counts round by round; the strip's grid shows every problem after every round.
Rounds 2 and 3 mostly repeat round 1. Decoding is greedy and the conversation repeats itself, so the model writes the same feedback and the same solution again: in round 2 all 40 final numbers stay as they were under both requests. The tokens keep adding up, from 306 per problem in round 0 to 1,842 by round 3 when asked to check (its feedback is longer) and 1,568 when told there is an error.
Is the feedback right?
Asked to check, the round-1 feedback called 28 of the 31 right answers correct, and also 6 of the 9 wrong ones; it never called an answer incorrect, and 6 feedbacks gave no verdict. Self-refine's stopping rule therefore keeps round 0 for 34 problems and ends right on 31, the accuracy of not refining at all, at 796 tokens per problem instead of 306.
Told there was an error, the round-1 feedback called 16 of the 31 right answers incorrect and 5 of the 9 wrong ones, called 5 right and 2 wrong answers correct, and gave no verdict 12 times. Its stopping rule ends right on 29 with 1,408 tokens. In the panel Is the feedback right? the verdicts follow the request more than the answer: the same model, judging the same answers, says correct to almost everything when asked to check and incorrect to most when told something is wrong. Even then it seldom changes its number, as row 12 shows: the feedback calls 12 incorrect, and the revision repeats 12.
Huang et al. report the same pattern for larger models: without an outside signal of which answers are wrong, self-correction on reasoning problems does not raise accuracy, and prompts that presume an error lead models to abandon right answers. Self-Refine's gains came mostly from tasks judged by preference or style, where the feedback can point at something concrete.
Revising versus sampling
The dashed line on the chart is the Self-consistency tab: a majority vote over answers sampled from the same model at temperature 0.7, averaged over orderings. At about the tokens three rounds of self-refine spend, five or six samples, the vote is right on 84.6–85% of the problems against 72.5% for either self-refine conversation; one sample already reaches 80.3% at 312 tokens. For this model and these problems, spending tokens on independent attempts helps and spending them on its own reviews does not.
Self-correction can be learned rather than prompted: SCoRe trains a model with reinforcement learning on its own two-attempt traces so that the second attempt improves on the first, and Reflexion feeds outside signals such as test results back into the model's reflections. The PRM and Tree search tabs take the other route, a separate model that scores each step.
Papers
- Self-Refine: Iterative Refinement with Self-Feedback The method: one model writes, gives itself feedback and refines, round by round, stopping when the feedback finds nothing to fix.
- Large Language Models Cannot Self-Correct Reasoning Yet Without an oracle telling it when an answer is wrong, a model's self-correction on reasoning tasks rarely fixes answers and can break right ones.
- Qwen2.5-Math Technical Report: Toward Mathematical Expert Model via Self-Improvement The model recorded here and its chain-of-thought prompt.
- Self-Consistency Improves Chain of Thought Reasoning in Language Models Sampling many solutions and voting: the parallel way of spending tokens this page compares with.
- Training Language Models to Self-Correct via Reinforcement Learning SCoRe: training a model on its own correction traces so that a second attempt improves on the first.
- Reflexion: Language Agents with Verbal Reinforcement Learning Self-reflection guided by an outside signal (test results, an environment's reward) rather than the model's own judgement.
- Training Verifiers to Solve Math Word Problems GSM8K, the grade-school maths problems every Reasoning tab answers.