arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2410.15037cs.CL
收藏

mHumanEval——一个用于评估大语言模型代码生成能力的多语言基准

mHumanEval -- A Multilingual Benchmark to Evaluate Large Language Models for Code Generation

George Mason University(乔治梅森大学)

Nishat Raihan, Antonios Anastasopoulos, Marcos Zampieri

AI总结:

针对现有代码生成基准语言覆盖范围有限、低资源语言提示代码生成研究不足的问题,本文提出支持200多种自然语言提示的多语言基准mHumanEval,并分析了SOTA代码大模型的跨语言代码生成能力。

摘要:

大语言模型(LLMs)的最新进展显著提升了从自然语言提示生成代码的能力。由OpenAI开发的HumanEval基准仍是目前使用最广泛的代码生成基准。然而,该基准及其他代码大语言模型基准存在关键局限,尤其是在任务多样性、测试覆盖度和语言范围方面。当前评估主要聚焦于英语转Python的任务,测试用例有限,可能会高估模型性能。虽然近期研究已解决了测试覆盖度和编程语言(PL)多样性的问题,但从低资源语言提示生成代码的研究仍很大程度上未被探索。为填补这一空白,我们推出了mHumanEval,这是一个支持200多种自然语言提示的扩展基准。我们采用成熟的机器翻译方法构建该基准,并配套了质量保障流程。此外,我们还为15种不同的自然语言(NLs)提供了专业人工翻译。最后,我们分析了当前最先进(SOTA)的代码大语言模型的多语言代码生成能力,为跨语言代码生成的现状提供了洞见。

英文摘要:

Recent advancements in large language models (LLMs) have significantly enhanced code generation from natural language prompts. The HumanEval Benchmark, developed by OpenAI, remains the most widely used code generation benchmark. However, this and other Code LLM benchmarks face critical limitations, particularly in task diversity, test coverage, and linguistic scope. Current evaluations primarily focus on English-to-Python conversion tasks with limited test cases, potentially overestimating model performance. While recent works have addressed test coverage and programming language (PL) diversity, code generation from low-resource language prompts remains largely unexplored. To address this gap, we introduce mHumanEval, an extended benchmark supporting prompts in over 200 natural languages. We employ established machine translation methods to compile the benchmark, coupled with a quality assurance process. Furthermore, we provide expert human translations for 15 diverse natural languages (NLs). We conclude by analyzing the multilingual code generation capabilities of state-of-the-art (SOTA) Code LLMs, offering insights into the current landscape of cross-lingual code generation.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑