[Paper Review] ClarEval: A Benchmark for Evaluating Clarification Skills of Code Agents under Ambiguous Instructions
ClarEval introduces an ambiguity-driven benchmark to assess code agents' collaborative clarification skills via single-turn and multi-turn interaction, measuring intent inference, premise identification, and dialogue efficiency.
To integrate seamlessly into real-world software engineering, Code Agents must evolve from passive instruction followers into proactive collaborative partners. However, current evaluation paradigms predominantly reward "guessing" user intent under ideal conditions, neglecting the agent's ability to align with users through dialogue--a critical trait for collaborative intelligence. In this work, we propose a paradigm shift in evaluation to drive this transition. We introduce ClarEval, a framework designed to assess an agent's "Collaborative Quotient" by simulating the inherent ambiguity of human communication. By systematically injecting three types of realistic ambiguity (missing goals, premises, and ambiguous terminology) into standard tasks, we force agents to step out of their "generator" role and engage in requirement elicitation. To quantify this capability, we propose a metric suite led by Average Turns to Clarify (ATC) and Key Question Coverage (KQC), which measure not just the correctness of the generated code, but the efficiency and precision of the collaboration. Our experiments on eleven state-of-the-art agents reveal a stark reality: while models like GPT-5-Coder excel at coding, they often lack the strategic communication skills required for efficient partnership. ClarEval thus serves as a crucial roadmap for bridging the gap between strong coders and capable collaborators.The code is available at https://github.com/JialinLi13/ClarEval
Motivation & Objective
- Motivate a shift from passive code generation to proactive collaborative partnering in Code Agents.
- Systematically inject three ambiguity types into standard tasks to stress-test clarification abilities.
- Develop and validate metrics that quantify collaboration efficiency and diagnostic capability (ATC, KQC, PIR, MPR, EAR).
Proposed method
- Construct Ambiguity-injected tasks by transforming 750 source tasks (HumanEval + LiveCodeBench) into 2,250 ambiguous instances.
- Define three ambiguity types: Missing Goal, Missing Premises, Ambiguous Terminology, with formal transformation rules.
- Use GPT-4o prompts to perform ambiguity injection and employ a two-stage human verification protocol for realism.
- Evaluate 11 code agents under single-turn and multi-turn settings with a deterministic user simulator for reproducibility.
- Introduce metrics: Key Question Coverage (KQC), Missing Premises Recall (MPR), Average Turns to Clarify (ATC), and Efficiency-Adjusted Recall (EAR).
Experimental results
Research questions
- RQ1Can code agents infer high-level intent from underspecified prompts (KQC) in a single turn?
- RQ2Can agents surface missing technical premises (PIR) and recall them through dialogue (MPR in multi-turn)?
- RQ3How does ambiguity type (Missing Goal, Missing Premises, Ambiguous Terminology) affect clarification effectiveness and efficiency (ATC) across models?
- RQ4Do top-coding agents balance code correctness with collaboration efficiency, and how does this vary between single-turn and multi-turn settings?
Key findings
- Top coder GPT5-Coder achieves the highest single-turn KQC (0.867) and MPR (0.661) among 11 agents.
- Multi-turn results show Claude-Opus 4.1 achieves the highest KQC (0.754) and GPT5-Coder leads MPR (0.951) with the lowest ATC (1.493).
- Ambiguous Terminology poses the strongest challenge across models, with the lowest Pass@1 under ambiguity in ablation tests.
- Strong intent inference in isolation does not guarantee effective long-horizon clarification; a weak correlation (r = 0.32) exists between single-turn and multi-turn performance.
- ClarEval reveals a gap between coding prowess and collaborative efficiency, highlighting the need for adaptive clarification policies.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.