
摘要
我们介绍了Codex,这是一种在GitHub上公开可用的代码基础上微调的GPT语言模型,并研究了其编写Python代码的能力。Codex的一个特定生产版本为GitHub Copilot提供支持。在HumanEval(一个我们发布的用于评估从文档字符串合成程序的功能正确性的新数据集)上,我们的模型解决了28.8%的问题,而GPT-3解决了0%的问题,GPT-J解决了11.4%的问题。此外,我们发现从模型中重复采样是一种令人惊讶的有效策略,可以生成解决复杂提示的工作解决方案。使用这种方法,我们在每个问题上采样100次的情况下解决了70.2%的问题。对我们的模型进行仔细分析后,揭示了其局限性,包括难以处理描述长操作链的文档字符串以及将操作绑定到变量上的困难。最后,我们讨论了部署强大的代码生成技术可能带来的更广泛影响,涵盖了安全、安全性和经济方面。
代码仓库
openai/human-eval
官方
GitHub 中提及
codefuse-ai/codefuse-evaluation
pytorch
GitHub 中提及
2796gaurav/human-eval
GitHub 中提及
ncoop57/gpt-code-clippy
jax
GitHub 中提及
superli3/codenavi
tf
GitHub 中提及
codedotal/gpt-code-clippy
jax
GitHub 中提及
fsoft-ai4code/codecapybara
pytorch
GitHub 中提及
glouppe/info8010-deep-learning
pytorch
GitHub 中提及
THUDM/CodeGeeX
mindspore
GitHub 中提及
vhellendoorn/code-lms
GitHub 中提及
superli3/CYRMPR
tf
GitHub 中提及
microsoft/PythonProgrammingPuzzles
GitHub 中提及
基准测试
| 基准 | 方法 | 指标 |
|---|---|---|
| code-generation-on-apps | Codex 12B (Raw) | Competition Pass@1: 0.50% Competition Pass@1000: 13.51% Competition Pass@5: 1.00% Competition Pass@any: 13.51% Interview Pass@1: 1.00% Interview Pass@1000: 13.15% Interview Pass@5: 1.73% Interview Pass@any: 13.15% Introductory Pass@1: 5.60% Introductory Pass@1000: 35.20% Introductory Pass@5: 9.20% Introductory Pass@any: 35.20% |
| multi-task-language-understanding-on-bbh-alg | code-davinci-002 175B (CoT) | Average (%): 73.9 |
| multi-task-language-understanding-on-bbh-nlp | code-davinci-002 175B (CoT) | Average (%): 73.5 |