Can Code Language Models Learn Clarification-Seeking Behaviors?
Michigan Technological University(密歇根技术大学);Indian Institute of Information Technology (IIIT)(印度信息科技研究所);University of California, San Diego (UCSD)(加州大学圣地亚哥分校);University of British Columbia(不列颠哥伦比亚大学);Stanford University(斯坦福大学)
Jie JW Wu, Manav Chaudhary, Davit Abrahamyan, Arhaan Khaku, Anjiang Wei, Fatemeh H. Fard
Large language models (LLMs) have demonstrated remarkable capabilities in code generation tasks. However, a gap remains between their output and the problem-solving strategies of human developers. Unlike humans, who spend substantial time disambiguating requirements through iterative dialogue, LLMs often generate code despite ambiguities in natural language requirements, leading to unreliable solutions. Different from prior work, we study whether a Code LLM can be fine-tuned to learn clarification-seeking behavior. While recent work has focused on LLM-based agents for iterative code generation, we argue that the ability to recognize and query ambiguous requirements should be intrinsic to the models themselves, especially in agentic AI where models and humans collaborate. We present ClarifyCoder, a framework with synthetic data generation and instruction-tuning that fine-tunes an LLM to identify ambiguities and request clarification before code generation. Our approach has two components: (1) a data synthesis technique that augments programming datasets with scenarios requiring clarification to generate clarification-aware training data, and (2) a fine-tuning strategy that teaches models to prioritize seeking clarification over immediate code generation when faced with incomplete or ambiguous requirements. We also provide an empirical analysis of integrating ClarifyCoder with standard fine-tuning for joint optimization of clarification-awareness and coding ability. Experimental results show that ClarifyCoder achieves a 63% communication rate (40% absolute increase) and a 52% good question rate (30% absolute increase) on ambiguous tasks, significantly improving LLMs' communication capabilities while maintaining code generation performance.
ClarEval: A Benchmark for Evaluating Clarification Skills of Code Agents under Ambiguous Instructions
School of Artificial Intelligence, Jilin University(吉林大学人工智能学院);Engineering Research Center of Knowledge-Driven Human-Machine Intelligence, MOE, China(教育部知识驱动人机智能工程研究中心);International Center of Future Science, Jilin University(吉林大学未来科学国际中心)
A Unified Issue Resolution Benchmark for Requirement Clarification, Planning, and Code Generation for Coding Agents
Singapore Management University(新加坡管理大学);Monash University Malaysia(马来西亚莫纳什大学);Daegu Gyeongbuk Institute of Science and Technology (DGIST)(大邱庆北科学技术院);The Chinese University of Hong Kong(香港中文大学);North Carolina State University(北卡罗来纳州立大学);City University of Hong Kong(香港城市大学);The Hong Kong University of Science and Technology(香港科技大学);The University of Hong Kong(香港大学)
SoAy: A Solution-based LLM API-using Methodology for Academic Information Seeking
Renmin University of China(中国人民大学);Key Laboratory of Data Engineering and Knowledge Engineering, MOE(数据工程与知识工程重点实验室);Tsinghua University(清华大学);Institute of Education(教育学院);Department of Computer Science and Technology(计算机科学与技术系);Engineering Research Center of Database and Business Intelligence, MOE(数据库与商务智能工程研究中心);School of Information(信息学院)
针对学术查询中的复杂 API 耦合问题,提出基于预构建 API 调用方案与代码推理的 SoAy 方法,并通过 SoAyBench/SoAyEval 验证其显著优于现有基线。
From Conversation to Evaluation: Benchmarking LLMs on Development Knowledge via SimpleDevQA
Sun Yat-Sen University(中山大学);Huawei CodeArts Model Team(华为代码arts模型团队);Monash University(蒙纳士大学);Chongqing University(重庆大学);The State Key Laboratory of Blockchain and Data Security, Zhejiang University(浙江大学区块链与数据安全国家重点实验室)
Enhancing LLM Code Generation: A Systematic Evaluation of Multi-Agent Collaboration and Runtime Debugging for Improved Accuracy, Reliability, and Latency
LLaMoCo: Instruction Tuning of Large Language Models for Optimization Code Generation
School of Computer Science and Engineering, South China University of Technology(华南理工大学计算机科学与工程学院);School of Computing and Information Systems, Singapore Management University(新加坡管理大学计算与信息系统学院);Nanyang Technological University(南洋理工大学)