The reviewed record of science sign in
Pith

arxiv: 2206.03865 · v2 · pith:TME25OL4 · submitted 2022-06-04 · cs.PL · cs.AI· cs.SE

Fault-Aware Neural Code Rankers

Reviewed by Pith T0 review T1 audit T2 compute T3 formal T4 kernel pith:TME25OL4record.jsonopen to challenge →

classification cs.PL cs.AIcs.SE
keywords codecoderankerprogramprogramsabilityassumeexecutionfault-aware
0
0 comments X
read the original abstract

Large language models (LLMs) have demonstrated an impressive ability to generate code for various programming tasks. In many instances, LLMs can generate a correct program for a task when given numerous trials. Consequently, a recent trend is to do large scale sampling of programs using a model and then filtering/ranking the programs based on the program execution on a small number of known unit tests to select one candidate solution. However, these approaches assume that the unit tests are given and assume the ability to safely execute the generated programs (which can do arbitrary dangerous operations such as file manipulations). Both of the above assumptions are impractical in real-world software development. In this paper, we propose CodeRanker, a neural ranker that can predict the correctness of a sampled program without executing it. Our CodeRanker is fault-aware i.e., it is trained to predict different kinds of execution information such as predicting the exact compile/runtime error type (e.g., an IndexError or a TypeError). We show that CodeRanker can significantly increase the pass@1 accuracy of various code generation models (including Codex, GPT-Neo, GPT-J) on APPS, HumanEval and MBPP datasets.

This paper has not been read by Pith yet.

discussion (0)

Sign in with ORCID, Apple, or X to comment. Anyone can read and Pith papers without signing in.

Forward citations

Cited by 1 Pith paper

Reviewed papers in the Pith corpus that reference this work. Sorted by Pith novelty score.

  1. CodeT: Code Generation with Generated Tests

    cs.CL 2022-07 conditional novelty 7.0

    CodeT improves code generation accuracy by using the same model to create test cases and then selecting solutions via output agreement on those tests, raising HumanEval pass@1 from 47% to 65.8%.