Noisy Test-Time Reinforcement Learning for Code LLMs
Xikai Yang, Hieu Trung Nguyen, Dunyuan Xu, Yuzhi Zhao, Jinpeng Li, Wenao Ma, Pheng-Ann Heng
Abstract
Large language models (LLMs) have demonstrated remarkable performance across various code-related tasks. However, unlike carefully curated datasets that are typically high-quality and error-free, real-world user instructions are often vague and error-prone, posing significant challenges to the robustness of code LLMs. Furthermore, robustness-oriented fine-tuning relies on paired clean-noisy samples, which are costly to curate and require sophisticated noisy simulation techniques. To address these challenges, we propose the Noisy Test-time Reinforcement Learning framework (NTRL-Code), which enables robust self-evolution of code LLMs using only unlabeled noisy data during the testing stage. Specifically, NTRL-Code uses conservative self-denoising to obtain a cleaner semantic anchor for target estimation, and employs an abstract-syntax-tree (AST)-based structural aggregation mechanism to estimate a proxy target from multiple candidate programs. The policy is then optimized on the original noisy prompts with a hybrid reward that combines format validity, code similarity, and anti-repetition signals. Extensive experiments on three benchmarks, each incorporating character-level, word-level, and paragraph-level perturbations, demonstrate that NTRL-Code yields robust and consistent improvements, stabilizing the predictions of various base models. Our code is available at https://github.com/Xikai97/NTRL-Code.
Create a lesson
Metadata
- Comments
- This paper has been accepted by EMNLP 2026
Related papers
ProTTT: Learning to Learn Semantic User Memory with Test-Time Training
Shared title terminologycs.AISejun Park, Hyoungjo Bhang, Hyein Jeong et al.
Delayed Supervision for Test-Time Language Models
Shared title terminologycs.AIJinha Kim, Taksh Kothari
How Many Parameters Does Forecasting Need? A Survey and Code-Level Audit of Lightweight Long-Term Time Series Forecasting
Shared title terminologycs.AIIssam Ait Yahia, Abdelkader El Mahdaouy, Ismail Berrada
Despite Instructions: Frontier Agents Improvise Covert Channels at Test Time
Shared title terminologycs.AIJacob Dineen, Silei Ren, Muhao Chen et al.
A Generative AI Agent to Emulate Interactive Human-driven Vehicles for Automated Driving Testing in Urban Areas
Shared title terminologycs.AIJia Hu, Changjian Yu, Panqu Wang et al.
AGL-SKILL: Coding Harnesses as Agentic Optimizers
Shared title terminologycs.AIRyan Tsui, Yuge Zhang, Yuqing Yang