Reproduce “CodeBLEU: a Method for Automatic Evaluation of Code Synthesis” on OpenResearch
Turn your favorite coding agents into research agents that review literature, develop hypotheses, and run experiments.
Universal app for Apple silicon and Intel. Requires macOS 11 or later.
About this paper
Shuo Ren, Daya Guo, Shuai Lu, Long Zhou, Shujie Liu, Duyu Tang, Neel Sundaresan, Ming Zhou and 2 more
Researchers from Microsoft and leading Chinese universities developed CodeBLEU, a new automatic evaluation metric for code synthesis that integrates n-gram, weighted n-gram, Abstract Syntax Tree, and data-flow matching. CodeBLEU consistently shows a higher Pearson correlation with human evaluation scores across text-to-code, code translation, and code refinement tasks compared to the traditional BLEU metric.
Key insights
- Programming languages possess distinct characteristics (e.g., rigid syntax, specific keywords, tree structures, precise semantics) that differ fundamentally from natural languages, making direct application of NLP metrics insufficient.
- Integrating syntactic information (via Abstract Syntax Trees) and semantic information (via data-flow analysis) is crucial for developing an automatic metric that aligns more closely with human judgment of code quality.
- Emphasizing structural and semantic correctness components significantly improves the reliability and discriminatory power of automatic code evaluation.
Summary by alphaXiv.
Tip: change arxiv.org to autoarxiv.org in any arXiv abstract link to open the paper here.