A response-formatting reward adds an auxiliary training signal for required output structure. It can encourage reasoning models to place their reasoning inside <think>...</think> tags alongside an answer-correctness reward. section 7.6 section 7.0
Implement the reward in the training pipeline:
- Use a tokenizer that recognizes <think> and </think>, either by adding special tokens to the base tokenizer or loading a reasoning tokenizer. section 7.6.1
- Inspect only generated tokens after the prompt and return 1.0 when the opening tag occurs before the closing tag; otherwise return 0.0. section 7.6.1
- Add the format score to the correctness reward with a tunable format_reward_weight, and prompt the model to emit the tags explicitly. section 7.6.1 section 7.6.2
Testing malformed tags
A rollout containing both tags in the correct order receives 1.0. A typo, reversed order, or missing tag receives 0.0. During training, excessive format credit can keep average reward high while evaluation accuracy and response length decline; lowering the weight or conditioning the reward on correctness can mitigate this failure mode. section 7.6.1 section 7.6.2
Figure 7.17 Implementing a format reward that encourages the model to generate <think>...</think> tokens
Use the workflow figure to inspect how the format reward supplements correctness reward and encourages <think>...</think> output structure. section 7.6

