# CURE **Repository Path**: ByteDance/CURE ## Basic Information - **Project Name**: CURE - **Description**: No description available - **Primary Language**: Unknown - **License**: Apache-2.0 - **Default Branch**: main - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2025-08-23 - **Last Updated**: 2025-09-25 ## Categories & Tags **Categories**: mathlibs **Tags**: None ## README # CURE: Critical-Token-Guided Re-concatenation for Entropy-collapse Prevention

If you find this project useful, please give us a star ๐ŸŒŸ.

arXiv Hugging Face Model Hugging Face Dataset GitHub Repo stars

## ๐Ÿ”ฅ News - *2024.8.14*: Weโ€™re excited to announce the release of CUREโ€™s [paper](https://arxiv.org/abs/2508.11016). - *2024.8.22*: Weโ€™re excited to announce the release of CUREโ€™s [model](https://huggingface.co/bytedance-research/CURE). ## ๐Ÿ“š Algorithm Overview ![](https://github.com/bytedance/CURE/blob/main/main.png) In Stage 1, given an input query $q$, the policy model produces a pool of candidate responses. We compute token-level entropy to identify critical tokens (high entropy), extract the clauses immediately preceding those tokens, append them to $q$ to form refined prompts, and query the model again. The newly generated responses are aggregated with the original ones and jointly optimized within a single group. In Stage 2, we continue training to translate the exploration bonus into realized performance. ## ๐Ÿ“š Experimental Results ![](https://github.com/bytedance/CURE/blob/main/entropy.jpg) Comparison of Entropy comparison of CURE-First-Stage and other methods at temperature 1.0. ![](https://github.com/bytedance/CURE/blob/main/main_table.jpg) CURE performs competitively compared with other algorithms. We report avg@32 for AIME24, AIME25, and AMC23 and avg@1 for others. ## โš™๏ธ Installation Our code has been incorporated into VERL as a plugin, located in [recipe-CURE](https://github.com/bytedance/CURE/tree/main/recipe) ### 1. Prepare the environment Exactly the same as the environment setup in [verl](https://github.com/volcengine/verl), no additional configuration is required. In our actual workflow, we executed the following operations directly within the released image. ```bash cd CURE pip install --no-deps -e . pip install --no-deps git+https://github.com/=hiyouga/MathRuler.git pip install math_verify ``` ### 2. Prepare the dataset and model For training, simply download the dataset from [DAPO-Math-17K](https://huggingface.co/datasets/BytedTsinghua-SIA/DAPO-Math-17k) and set its path as `TRAIN_FILE` in the [startup script](https://github.com/bytedance/CURE/blob/main/recipe/CURE_First_Stage/run_cure_stage_1.sh). We use [Qwen-2.5-Math-Base](https://huggingface.co/Qwen/Qwen2.5-Math-7B) as the training baseline; download it and set its path as `CKPTS_DIR` in the same script. > We also recommend downloading [AIME-2024](https://huggingface.co/datasets/BytedTsinghua-SIA/AIME-2024) and setting its path as `TEST_FILE` in the same script. ## ๐Ÿš€ Train ### 1. First Stage Training ```bash cd CURE sh ./recipe/CURE_First_Stage/run_cure_stage_1.sh ``` ### 2. Second Stage Training ```bash cd CURE sh ./recipe/CURE_Second_Stage/run_cure_stage_2.sh ``` ## ๐Ÿ’“ Acknowledgement This project has been developed partially based on the following pioneering works on GitHub repositories. We express our profound gratitude for these foundational resources: - https://github.com/volcengine/verl - https://github.com/NVlabs/NFT - https://github.com/huggingface/Math-Verify We would like to extend our special thanks to the following contributors [@Qingbin Li](https://github.com/BetuBin18070), [@Rongkun Xue](https://github.com/rongkunxue), for their valuable contributions and support to this algorithm library. ## ๐ŸŒ Citation ```bibtex @misc{li2025curecriticaltokenguidedreconcatenationentropycollapse, title={CURE: Critical-Token-Guided Re-concatenation for Entropy-collapse Prevention}, author={Qingbin Li and Rongkun Xue and Jie Wang and Ming Zhou and Zhi Li and Xiaofeng Ji and Yongqi Wang and Miao Liu and Zheming Yang and Minghui Qiu and Jing Yang}, year={2025}, eprint={2508.11016}, archivePrefix={arXiv}, primaryClass={cs.LG}, url={https://arxiv.org/abs/2508.11016}, } ``` ## ๐Ÿท๏ธ License All code within this repository is under [Apache License 2.0](https://www.apache.org/licenses/LICENSE-2.0).